1 ; RUN: llc < %s -march=x86 -mattr=+mmx,+sse2 > %t1 2 ; RUN: grep movzwl %t1 | count 2 3 ; RUN: grep movzbl %t1 | count 2 4 ; RUN: grep movd %t1 | count 4 5 6 define <4 x i16> @a(i32* %x1) nounwind { 7 %x2 = load i32* %x1 8 %x3 = lshr i32 %x2, 1 9 %x = trunc i32 %x3 to i16 10 %r = insertelement <4 x i16> zeroinitializer, i16 %x, i32 0 11 ret <4 x i16> %r 12 } 13 14 define <8 x i16> @b(i32* %x1) nounwind { 15 %x2 = load i32* %x1 16 %x3 = lshr i32 %x2, 1 17 %x = trunc i32 %x3 to i16 18 %r = insertelement <8 x i16> zeroinitializer, i16 %x, i32 0 19 ret <8 x i16> %r 20 } 21 22 define <8 x i8> @c(i32* %x1) nounwind { 23 %x2 = load i32* %x1 24 %x3 = lshr i32 %x2, 1 25 %x = trunc i32 %x3 to i8 26 %r = insertelement <8 x i8> zeroinitializer, i8 %x, i32 0 27 ret <8 x i8> %r 28 } 29 30 define <16 x i8> @d(i32* %x1) nounwind { 31 %x2 = load i32* %x1 32 %x3 = lshr i32 %x2, 1 33 %x = trunc i32 %x3 to i8 34 %r = insertelement <16 x i8> zeroinitializer, i8 %x, i32 0 35 ret <16 x i8> %r 36 } 37 38