[mono][llvm] Fix generation of LLVM IR for OP_SSE_CVTII. (#72731)
authorZoltan Varga <vargaz@gmail.com>
Mon, 25 Jul 2022 16:02:53 +0000 (12:02 -0400)
committerGitHub <noreply@github.com>
Mon, 25 Jul 2022 16:02:53 +0000 (12:02 -0400)
src/mono/mono/mini/mini-llvm.c

index 2cbf80a..245ea5e 100644 (file)
@@ -9453,7 +9453,8 @@ MONO_RESTORE_WARNING
 
                        LLVMValueRef value;
                        if (LLVMGetTypeKind (LLVMTypeOf (lhs)) != LLVMVectorTypeKind) {
-                               LLVMValueRef bitcasted = LLVMBuildBitCast (ctx->builder, lhs, pointer_type (vec_type), "");
+                               // FIXME: Handle this in simd-intrinsics.c
+                               LLVMValueRef bitcasted = convert (ctx, lhs, pointer_type (vec_type));
                                value = mono_llvm_build_aligned_load (builder, vec_type, bitcasted, "", FALSE, 1);
                        } else {
                                value = LLVMBuildBitCast (ctx->builder, lhs, vec_type, "");