OLD | NEW |
1 ; Test that some errors trigger when the usage of NaCl atomic | 1 ; Test that some errors trigger when the usage of NaCl atomic |
2 ; intrinsics does not match the required ABI. | 2 ; intrinsics does not match the required ABI. |
3 | 3 |
4 ; RUN: %p2i -i %s --args --verbose none --exit-success 2>&1 | FileCheck %s | 4 ; RUN: %p2i -i %s --args --verbose none --exit-success -threads=0 2>&1 \ |
| 5 ; RUN: | FileCheck %s |
5 | 6 |
6 declare i8 @llvm.nacl.atomic.load.i8(i8*, i32) | 7 declare i8 @llvm.nacl.atomic.load.i8(i8*, i32) |
7 declare i16 @llvm.nacl.atomic.load.i16(i16*, i32) | 8 declare i16 @llvm.nacl.atomic.load.i16(i16*, i32) |
8 declare i64 @llvm.nacl.atomic.load.i64(i64*, i32) | 9 declare i64 @llvm.nacl.atomic.load.i64(i64*, i32) |
9 declare void @llvm.nacl.atomic.store.i32(i32, i32*, i32) | 10 declare void @llvm.nacl.atomic.store.i32(i32, i32*, i32) |
10 declare void @llvm.nacl.atomic.store.i64(i64, i64*, i32) | 11 declare void @llvm.nacl.atomic.store.i64(i64, i64*, i32) |
11 declare i8 @llvm.nacl.atomic.rmw.i8(i32, i8*, i8, i32) | 12 declare i8 @llvm.nacl.atomic.rmw.i8(i32, i8*, i8, i32) |
12 declare i16 @llvm.nacl.atomic.rmw.i16(i32, i16*, i16, i32) | 13 declare i16 @llvm.nacl.atomic.rmw.i16(i32, i16*, i16, i32) |
13 declare i32 @llvm.nacl.atomic.rmw.i32(i32, i32*, i32, i32) | 14 declare i32 @llvm.nacl.atomic.rmw.i32(i32, i32*, i32, i32) |
14 declare i64 @llvm.nacl.atomic.rmw.i64(i32, i64*, i64, i32) | 15 declare i64 @llvm.nacl.atomic.rmw.i64(i32, i64*, i64, i32) |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 ; CHECK: Unexpected memory ordering for AtomicFence | 161 ; CHECK: Unexpected memory ordering for AtomicFence |
161 | 162 |
162 define i32 @error_atomic_is_lock_free_var(i32 %iptr, i32 %bs) { | 163 define i32 @error_atomic_is_lock_free_var(i32 %iptr, i32 %bs) { |
163 entry: | 164 entry: |
164 %ptr = inttoptr i32 %iptr to i8* | 165 %ptr = inttoptr i32 %iptr to i8* |
165 %i = call i1 @llvm.nacl.atomic.is.lock.free(i32 %bs, i8* %ptr) | 166 %i = call i1 @llvm.nacl.atomic.is.lock.free(i32 %bs, i8* %ptr) |
166 %r = zext i1 %i to i32 | 167 %r = zext i1 %i to i32 |
167 ret i32 %r | 168 ret i32 %r |
168 } | 169 } |
169 ; CHECK: AtomicIsLockFree byte size should be compile-time const | 170 ; CHECK: AtomicIsLockFree byte size should be compile-time const |
OLD | NEW |