blob: 4d1f05629b414d233ffded4678903179d4c74c64 [file] [log] [blame]
Jakob Stoklund Olesen8eb9c312010-03-31 00:40:13 +00001; RUN: llc < %s -march=x86 -mattr=+sse2 | FileCheck %s
Dan Gohmanf17a25c2007-07-18 16:29:46 +00002
Jakob Stoklund Olesen8eb9c312010-03-31 00:40:13 +00003; CHECK: xorps
Tanya Lattner632e88a2008-02-21 07:42:26 +00004define void @foo(<4 x float>* %P) {
5 %T = load <4 x float>* %P ; <<4 x float>> [#uses=1]
Dan Gohman7ce405e2009-06-04 22:49:04 +00006 %S = fadd <4 x float> zeroinitializer, %T ; <<4 x float>> [#uses=1]
Tanya Lattner632e88a2008-02-21 07:42:26 +00007 store <4 x float> %S, <4 x float>* %P
8 ret void
Dan Gohmanf17a25c2007-07-18 16:29:46 +00009}
10
Jakob Stoklund Olesen8eb9c312010-03-31 00:40:13 +000011; CHECK: pxor
Tanya Lattner632e88a2008-02-21 07:42:26 +000012define void @bar(<4 x i32>* %P) {
13 %T = load <4 x i32>* %P ; <<4 x i32>> [#uses=1]
14 %S = add <4 x i32> zeroinitializer, %T ; <<4 x i32>> [#uses=1]
15 store <4 x i32> %S, <4 x i32>* %P
16 ret void
Dan Gohmanf17a25c2007-07-18 16:29:46 +000017}
Tanya Lattner632e88a2008-02-21 07:42:26 +000018