llvm.org GIT mirror llvm / 5e249b4
"The original bug was a complaint that _mm_srli_si128 mis-compiled when passed a constant vector ("{0x123, 0x456}" syntax). The fix is to simplify the _mm_srli_si128 macro, and move the "* 8" from the macro into the compiler back-end. I can't change the existing __builtins because so many people are using them :-(." Patch by Stuart Hastings! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56944 91177308-0d34-0410-b5e6-96231b3b80d8 Bill Wendling 12 years ago
2 changed file(s) with 10 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
368368 Intrinsic<[llvm_v2i64_ty, llvm_v2i64_ty,
369369 llvm_i32_ty], [IntrNoMem]>;
370370 def int_x86_sse2_psrl_dq : GCCBuiltin<"__builtin_ia32_psrldqi128">,
371 Intrinsic<[llvm_v2i64_ty, llvm_v2i64_ty,
372 llvm_i32_ty], [IntrNoMem]>;
373 def int_x86_sse2_psll_dq_bs : GCCBuiltin<"__builtin_ia32_pslldqi128_byteshift">,
374 Intrinsic<[llvm_v2i64_ty, llvm_v2i64_ty,
375 llvm_i32_ty], [IntrNoMem]>;
376 def int_x86_sse2_psrl_dq_bs : GCCBuiltin<"__builtin_ia32_psrldqi128_byteshift">,
371377 Intrinsic<[llvm_v2i64_ty, llvm_v2i64_ty,
372378 llvm_i32_ty], [IntrNoMem]>;
373379 }
19681968 (v2i64 (PSLLDQri VR128:$src1, (PSxLDQ_imm imm:$src2)))>;
19691969 def : Pat<(int_x86_sse2_psrl_dq VR128:$src1, imm:$src2),
19701970 (v2i64 (PSRLDQri VR128:$src1, (PSxLDQ_imm imm:$src2)))>;
1971 def : Pat<(int_x86_sse2_psll_dq_bs VR128:$src1, imm:$src2),
1972 (v2i64 (PSLLDQri VR128:$src1, imm:$src2))>;
1973 def : Pat<(int_x86_sse2_psrl_dq_bs VR128:$src1, imm:$src2),
1974 (v2i64 (PSRLDQri VR128:$src1, imm:$src2))>;
19711975 def : Pat<(v2f64 (X86fsrl VR128:$src1, i32immSExt8:$src2)),
19721976 (v2f64 (PSRLDQri VR128:$src1, (PSxLDQ_imm imm:$src2)))>;
19731977