OLD | NEW |
1 ; RUN: not pnacl-abicheck < %s | FileCheck %s | 1 ; RUN: not pnacl-abicheck < %s | FileCheck %s |
2 ; Test instruction opcodes allowed by PNaCl ABI | 2 ; Test instruction opcodes allowed by PNaCl ABI |
3 | 3 |
4 target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64
:64:64-p:32:32:32-v128:32:32" | 4 target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64
:64:64-p:32:32:32-v128:32:32" |
5 target triple = "le32-unknown-nacl" | 5 target triple = "le32-unknown-nacl" |
6 | 6 |
7 define internal void @terminators() { | 7 define internal void @terminators() { |
8 ; CHECK: ERROR: Function terminators | 8 ; CHECK: ERROR: Function terminators |
9 ; Terminator instructions | 9 ; Terminator instructions |
10 terminators: | 10 terminators: |
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
261 %phi8 = phi i8 [0, %entry], [0, %foo] | 261 %phi8 = phi i8 [0, %entry], [0, %foo] |
262 %phi16 = phi i16 [0, %entry], [0, %foo] | 262 %phi16 = phi i16 [0, %entry], [0, %foo] |
263 %phi32 = phi i32 [0, %entry], [0, %foo] | 263 %phi32 = phi i32 [0, %entry], [0, %foo] |
264 %phi64 = phi i64 [0, %entry], [0, %foo] | 264 %phi64 = phi i64 [0, %entry], [0, %foo] |
265 %vphi4x1 = phi <4 x i1> [undef, %entry], [undef, %foo] | 265 %vphi4x1 = phi <4 x i1> [undef, %entry], [undef, %foo] |
266 %vphi8x1 = phi <8 x i1> [undef, %entry], [undef, %foo] | 266 %vphi8x1 = phi <8 x i1> [undef, %entry], [undef, %foo] |
267 %vphi16x1 = phi <16 x i1> [undef, %entry], [undef, %foo] | 267 %vphi16x1 = phi <16 x i1> [undef, %entry], [undef, %foo] |
268 %vphi8 = phi <16 x i8> [undef, %entry], [undef, %foo] | 268 %vphi8 = phi <16 x i8> [undef, %entry], [undef, %foo] |
269 %vphi16 = phi <8 x i16> [undef, %entry], [undef, %foo] | 269 %vphi16 = phi <8 x i16> [undef, %entry], [undef, %foo] |
270 %vphi32 = phi <4 x i32> [undef, %entry], [undef, %foo] | 270 %vphi32 = phi <4 x i32> [undef, %entry], [undef, %foo] |
| 271 |
271 %select = select i1 true, i8 undef, i8 undef | 272 %select = select i1 true, i8 undef, i8 undef |
| 273 |
272 %vselect4x1 = select i1 true, <4 x i1> undef, <4 x i1> undef | 274 %vselect4x1 = select i1 true, <4 x i1> undef, <4 x i1> undef |
273 %vselect8x1 = select i1 true, <8 x i1> undef, <8 x i1> undef | 275 %vselect8x1 = select i1 true, <8 x i1> undef, <8 x i1> undef |
274 %vselect16x1 = select i1 true, <16 x i1> undef, <16 x i1> undef | 276 %vselect16x1 = select i1 true, <16 x i1> undef, <16 x i1> undef |
275 %vselect8 = select i1 true, <16 x i8> undef, <16 x i8> undef | 277 %vselect8 = select i1 true, <16 x i8> undef, <16 x i8> undef |
276 %vselect16 = select i1 true, <8 x i16> undef, <8 x i16> undef | 278 %vselect16 = select i1 true, <8 x i16> undef, <8 x i16> undef |
277 %vselect32 = select i1 true, <4 x i32> undef, <4 x i32> undef | 279 %vselect32 = select i1 true, <4 x i32> undef, <4 x i32> undef |
| 280 |
| 281 %vvselect4x1 = select <4 x i1> undef, <4 x i1> undef, <4 x i1> undef |
| 282 %vvselect8x1 = select <8 x i1> undef, <8 x i1> undef, <8 x i1> undef |
| 283 %vvselect16x1 = select <16 x i1> undef, <16 x i1> undef, <16 x i1> undef |
| 284 %vvselect8 = select <16 x i1> undef, <16 x i8> undef, <16 x i8> undef |
| 285 %vvselect16 = select <8 x i1> undef, <8 x i16> undef, <8 x i16> undef |
| 286 %vvselect32 = select <4 x i1> undef, <4 x i32> undef, <4 x i32> undef |
| 287 |
278 call void @conversion() | 288 call void @conversion() |
279 br i1 undef, label %foo, label %bar | 289 br i1 undef, label %foo, label %bar |
280 bar: | 290 bar: |
281 ret void | 291 ret void |
282 } | 292 } |
283 ; CHECK-NOT: disallowed | 293 ; CHECK-NOT: disallowed |
284 | 294 |
285 define internal void @throwing_func() { | 295 define internal void @throwing_func() { |
286 ; CHECK-NOT: Function throwing_func | 296 ; CHECK-NOT: Function throwing_func |
287 ret void | 297 ret void |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
332 define internal void @inline_asm() { | 342 define internal void @inline_asm() { |
333 ; CHECK: ERROR: Function inline_asm | 343 ; CHECK: ERROR: Function inline_asm |
334 call void asm "foo", ""() | 344 call void asm "foo", ""() |
335 ret void | 345 ret void |
336 } | 346 } |
337 ; CHECK-NOT: disallowed | 347 ; CHECK-NOT: disallowed |
338 ; CHECK: disallowed: inline assembly: call void asm "foo", ""() | 348 ; CHECK: disallowed: inline assembly: call void asm "foo", ""() |
339 | 349 |
340 ; CHECK-NOT: disallowed | 350 ; CHECK-NOT: disallowed |
341 ; If another check is added, there should be a check-not in between each check | 351 ; If another check is added, there should be a check-not in between each check |
OLD | NEW |