diff options
author | Bill Wendling <isanbard@gmail.com> | 2013-11-25 05:20:10 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2013-11-25 05:20:10 +0000 |
commit | 16f81f783207fa359f3afc589e2135d4805c9b98 (patch) | |
tree | 84c10709744a95cf41b303825d43b8e526363ef7 /test | |
parent | 9add5c2d4b282f7cae583ece5cea3f83d33c488b (diff) | |
download | external_llvm-16f81f783207fa359f3afc589e2135d4805c9b98.zip external_llvm-16f81f783207fa359f3afc589e2135d4805c9b98.tar.gz external_llvm-16f81f783207fa359f3afc589e2135d4805c9b98.tar.bz2 |
Merging r195476:
------------------------------------------------------------------------
r195476 | hliao | 2013-11-22 09:56:57 -0800 (Fri, 22 Nov 2013) | 6 lines
Fix PR18014
- When simplifying the mask generation for BLEND, check whether that mask is
also consumed by other non-BLEND insns. If true, skip that simplification.
------------------------------------------------------------------------
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_34@195602 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/CodeGen/X86/pr18014.ll | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/CodeGen/X86/pr18014.ll b/test/CodeGen/X86/pr18014.ll new file mode 100644 index 0000000..e3860b8 --- /dev/null +++ b/test/CodeGen/X86/pr18014.ll @@ -0,0 +1,16 @@ +; RUN: llc < %s -mtriple=x86_64-linux-pc -mcpu=penryn | FileCheck %s + +; Ensure PSRAD is generated as the condition is consumed by both PADD and +; BLENDVPS. PAND requires all bits setting properly. + +define <4 x i32> @foo(<4 x i32>* %p, <4 x i1> %cond, <4 x i32> %v1, <4 x i32> %v2, <4 x i32> %v3) { + %sext_cond = sext <4 x i1> %cond to <4 x i32> + %t1 = add <4 x i32> %v1, %sext_cond + %t2 = select <4 x i1> %cond, <4 x i32> %v1, <4 x i32> %v2 + store <4 x i32> %t2, <4 x i32>* %p + ret <4 x i32> %t1 +; CHECK: foo +; CHECK: pslld +; CHECK: psrad +; CHECK: ret +} |