aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/X86/split-vector-bitcast.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/X86/split-vector-bitcast.ll')
-rw-r--r--test/CodeGen/X86/split-vector-bitcast.ll12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/CodeGen/X86/split-vector-bitcast.ll b/test/CodeGen/X86/split-vector-bitcast.ll
new file mode 100644
index 0000000..55ba07d
--- /dev/null
+++ b/test/CodeGen/X86/split-vector-bitcast.ll
@@ -0,0 +1,12 @@
+; RUN: llc < %s -march=x86 -mattr=-sse2,+sse | grep addps
+
+; PR10497
+; (This is primarily checking that this construct doesn't crash.)
+define void @a(<2 x float>* %a, <2 x i32>* %b) {
+ %cc = load <2 x float>* %a
+ %c = fadd <2 x float> %cc, %cc
+ %dd = bitcast <2 x float> %c to <2 x i32>
+ %d = add <2 x i32> %dd, %dd
+ store <2 x i32> %d, <2 x i32>* %b
+ ret void
+}