diff options
author | Evan Cheng <evan.cheng@apple.com> | 2008-07-16 07:28:14 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2008-07-16 07:28:14 +0000 |
commit | be8efa54b6253e0c3c641c007e791e9d1a12bb47 (patch) | |
tree | 8ab137f2983f31052da0866c7dc2c5e9f31b3ebd | |
parent | 817a6a9eaa96a82c821143f13c756d7fa76cea71 (diff) |
Fix PR2296. Do not transform x86_sse2_storel_dq into a full-width store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53666 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Transforms/Scalar/InstructionCombining.cpp | 1 | ||||
-rw-r--r-- | test/Transforms/InstCombine/2008-07-16-sse2_storel_dq.ll | 13 |
2 files changed, 13 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/InstructionCombining.cpp b/lib/Transforms/Scalar/InstructionCombining.cpp index 743c0c1a30..c35d92c28f 100644 --- a/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/lib/Transforms/Scalar/InstructionCombining.cpp @@ -8646,7 +8646,6 @@ Instruction *InstCombiner::visitCallInst(CallInst &CI) { case Intrinsic::x86_sse_storeu_ps: case Intrinsic::x86_sse2_storeu_pd: case Intrinsic::x86_sse2_storeu_dq: - case Intrinsic::x86_sse2_storel_dq: // Turn X86 storeu -> store if the pointer is known aligned. if (GetOrEnforceKnownAlignment(II->getOperand(1), 16) >= 16) { const Type *OpPtrTy = diff --git a/test/Transforms/InstCombine/2008-07-16-sse2_storel_dq.ll b/test/Transforms/InstCombine/2008-07-16-sse2_storel_dq.ll new file mode 100644 index 0000000000..49e6cdd037 --- /dev/null +++ b/test/Transforms/InstCombine/2008-07-16-sse2_storel_dq.ll @@ -0,0 +1,13 @@ +; RUN: llvm-as < %s | opt -instcombine | llvm-dis | not grep {store } +; PR2296 + +@G = common global double 0.000000e+00, align 16 + +define void @x(<2 x i64> %y) nounwind { +entry: + bitcast <2 x i64> %y to <4 x i32> + call void @llvm.x86.sse2.storel.dq( i8* bitcast (double* @G to i8*), <4 x i32> %0 ) nounwind + ret void +} + +declare void @llvm.x86.sse2.storel.dq(i8*, <4 x i32>) nounwind |