about summary refs log tree commit diff
path: root/compiler/rustc_codegen_ssa/src
diff options
context:
space:
mode:
authorOli Scherer <git-spam-no-reply9815368754983@oli-obk.de>2023-07-10 13:03:48 +0000
committerOli Scherer <git-spam-no-reply9815368754983@oli-obk.de>2023-08-03 09:29:00 +0000
commit4457ef2c6db2aa65aeaba084d2d85f3355595f5a (patch)
treeeff5cae1af3af7c260958a78dc1e60c949b1e060 /compiler/rustc_codegen_ssa/src
parent2e6ac7fe5bb96bcc2d8c0b3e20db7cf7d2baa241 (diff)
downloadrust-4457ef2c6db2aa65aeaba084d2d85f3355595f5a.tar.gz
rust-4457ef2c6db2aa65aeaba084d2d85f3355595f5a.zip
Forbid old-style `simd_shuffleN` intrinsics
Diffstat (limited to 'compiler/rustc_codegen_ssa/src')
-rw-r--r--compiler/rustc_codegen_ssa/src/mir/block.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_codegen_ssa/src/mir/block.rs b/compiler/rustc_codegen_ssa/src/mir/block.rs
index f13dfd96b8e..4f26383ed05 100644
--- a/compiler/rustc_codegen_ssa/src/mir/block.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/block.rs
@@ -862,11 +862,11 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
                     .iter()
                     .enumerate()
                     .map(|(i, arg)| {
-                        // The indices passed to simd_shuffle* in the
+                        // The indices passed to simd_shuffle in the
                         // third argument must be constant. This is
                         // checked by const-qualification, which also
                         // promotes any complex rvalues to constants.
-                        if i == 2 && intrinsic.as_str().starts_with("simd_shuffle") {
+                        if i == 2 && intrinsic == sym::simd_shuffle {
                             if let mir::Operand::Constant(constant) = arg {
                                 let (llval, ty) = self.simd_shuffle_indices(&bx, constant);
                                 return OperandRef {