1 ; RUN: llc < %s -mtriple=i686--
2 ; RUN: llc < %s -mtriple=x86_64--
8 define void @test_lshr_i128(i128 %x, i128 %a, i128* nocapture %r) nounwind {
11 store i128 %0, i128* %r, align 16
15 define void @test_ashr_i128(i128 %x, i128 %a, i128* nocapture %r) nounwind {
18 store i128 %0, i128* %r, align 16
22 define void @test_shl_i128(i128 %x, i128 %a, i128* nocapture %r) nounwind {
25 store i128 %0, i128* %r, align 16
29 define void @test_lshr_i128_outofrange(i128 %x, i128* nocapture %r) nounwind {
32 store i128 %0, i128* %r, align 16
36 define void @test_ashr_i128_outofrange(i128 %x, i128* nocapture %r) nounwind {
39 store i128 %0, i128* %r, align 16
43 define void @test_shl_i128_outofrange(i128 %x, i128* nocapture %r) nounwind {
46 store i128 %0, i128* %r, align 16
54 define void @test_lshr_v2i128(<2 x i128> %x, <2 x i128> %a, <2 x i128>* nocapture %r) nounwind {
56 %0 = lshr <2 x i128> %x, %a
57 store <2 x i128> %0, <2 x i128>* %r, align 16
61 define void @test_ashr_v2i128(<2 x i128> %x, <2 x i128> %a, <2 x i128>* nocapture %r) nounwind {
63 %0 = ashr <2 x i128> %x, %a
64 store <2 x i128> %0, <2 x i128>* %r, align 16
68 define void @test_shl_v2i128(<2 x i128> %x, <2 x i128> %a, <2 x i128>* nocapture %r) nounwind {
70 %0 = shl <2 x i128> %x, %a
71 store <2 x i128> %0, <2 x i128>* %r, align 16
75 define void @test_lshr_v2i128_outofrange(<2 x i128> %x, <2 x i128>* nocapture %r) nounwind {
77 %0 = lshr <2 x i128> %x, <i128 -1, i128 -1>
78 store <2 x i128> %0, <2 x i128>* %r, align 16
82 define void @test_ashr_v2i128_outofrange(<2 x i128> %x, <2 x i128>* nocapture %r) nounwind {
84 %0 = ashr <2 x i128> %x, <i128 -1, i128 -1>
85 store <2 x i128> %0, <2 x i128>* %r, align 16
89 define void @test_shl_v2i128_outofrange(<2 x i128> %x, <2 x i128>* nocapture %r) nounwind {
91 %0 = shl <2 x i128> %x, <i128 -1, i128 -1>
92 store <2 x i128> %0, <2 x i128>* %r, align 16
96 define void @test_lshr_v2i128_outofrange_sum(<2 x i128> %x, <2 x i128>* nocapture %r) nounwind {
98 %0 = lshr <2 x i128> %x, <i128 -1, i128 -1>
99 %1 = lshr <2 x i128> %0, <i128 1, i128 1>
100 store <2 x i128> %1, <2 x i128>* %r, align 16
104 define void @test_ashr_v2i128_outofrange_sum(<2 x i128> %x, <2 x i128>* nocapture %r) nounwind {
106 %0 = ashr <2 x i128> %x, <i128 -1, i128 -1>
107 %1 = ashr <2 x i128> %0, <i128 1, i128 1>
108 store <2 x i128> %1, <2 x i128>* %r, align 16
112 define void @test_shl_v2i128_outofrange_sum(<2 x i128> %x, <2 x i128>* nocapture %r) nounwind {
114 %0 = shl <2 x i128> %x, <i128 -1, i128 -1>
115 %1 = shl <2 x i128> %0, <i128 1, i128 1>
116 store <2 x i128> %1, <2 x i128>* %r, align 16
124 define <2 x i256> @shl_sext_shl_outofrange(<2 x i128> %a0) {
125 %1 = shl <2 x i128> %a0, <i128 -1, i128 -1>
126 %2 = sext <2 x i128> %1 to <2 x i256>
127 %3 = shl <2 x i256> %2, <i256 128, i256 128>
131 define <2 x i256> @shl_zext_shl_outofrange(<2 x i128> %a0) {
132 %1 = shl <2 x i128> %a0, <i128 -1, i128 -1>
133 %2 = zext <2 x i128> %1 to <2 x i256>
134 %3 = shl <2 x i256> %2, <i256 128, i256 128>
138 define <2 x i256> @shl_zext_lshr_outofrange(<2 x i128> %a0) {
139 %1 = lshr <2 x i128> %a0, <i128 -1, i128 -1>
140 %2 = zext <2 x i128> %1 to <2 x i256>
141 %3 = shl <2 x i256> %2, <i256 128, i256 128>
145 define i128 @lshr_shl_mask(i128 %a0) {