@@ -8,25 +8,25 @@ use std::sync::atomic::{AtomicI32, Ordering::*};
8
8
// CHECK-LABEL: @compare_exchange
9
9
#[ no_mangle]
10
10
pub fn compare_exchange ( a : & AtomicI32 ) {
11
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 10 monotonic monotonic
11
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 10 monotonic monotonic
12
12
let _ = a. compare_exchange ( 0 , 10 , Relaxed , Relaxed ) ;
13
13
14
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 20 release monotonic
14
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 20 release monotonic
15
15
let _ = a. compare_exchange ( 0 , 20 , Release , Relaxed ) ;
16
16
17
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 30 acquire monotonic
18
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 31 acquire acquire
17
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 30 acquire monotonic
18
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 31 acquire acquire
19
19
let _ = a. compare_exchange ( 0 , 30 , Acquire , Relaxed ) ;
20
20
let _ = a. compare_exchange ( 0 , 31 , Acquire , Acquire ) ;
21
21
22
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 40 acq_rel monotonic
23
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 41 acq_rel acquire
22
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 40 acq_rel monotonic
23
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 41 acq_rel acquire
24
24
let _ = a. compare_exchange ( 0 , 40 , AcqRel , Relaxed ) ;
25
25
let _ = a. compare_exchange ( 0 , 41 , AcqRel , Acquire ) ;
26
26
27
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 50 seq_cst monotonic
28
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 51 seq_cst acquire
29
- // CHECK: cmpxchg i32* %{{.*}}, i32 0, i32 52 seq_cst seq_cst
27
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 50 seq_cst monotonic
28
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 51 seq_cst acquire
29
+ // CHECK: cmpxchg {{ i32\*|ptr}} %{{.*}}, i32 0, i32 52 seq_cst seq_cst
30
30
let _ = a. compare_exchange ( 0 , 50 , SeqCst , Relaxed ) ;
31
31
let _ = a. compare_exchange ( 0 , 51 , SeqCst , Acquire ) ;
32
32
let _ = a. compare_exchange ( 0 , 52 , SeqCst , SeqCst ) ;
@@ -35,25 +35,25 @@ pub fn compare_exchange(a: &AtomicI32) {
35
35
// CHECK-LABEL: @compare_exchange_weak
36
36
#[ no_mangle]
37
37
pub fn compare_exchange_weak ( w : & AtomicI32 ) {
38
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 10 monotonic monotonic
38
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 10 monotonic monotonic
39
39
let _ = w. compare_exchange_weak ( 1 , 10 , Relaxed , Relaxed ) ;
40
40
41
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 20 release monotonic
41
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 20 release monotonic
42
42
let _ = w. compare_exchange_weak ( 1 , 20 , Release , Relaxed ) ;
43
43
44
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 30 acquire monotonic
45
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 31 acquire acquire
44
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 30 acquire monotonic
45
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 31 acquire acquire
46
46
let _ = w. compare_exchange_weak ( 1 , 30 , Acquire , Relaxed ) ;
47
47
let _ = w. compare_exchange_weak ( 1 , 31 , Acquire , Acquire ) ;
48
48
49
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 40 acq_rel monotonic
50
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 41 acq_rel acquire
49
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 40 acq_rel monotonic
50
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 41 acq_rel acquire
51
51
let _ = w. compare_exchange_weak ( 1 , 40 , AcqRel , Relaxed ) ;
52
52
let _ = w. compare_exchange_weak ( 1 , 41 , AcqRel , Acquire ) ;
53
53
54
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 50 seq_cst monotonic
55
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 51 seq_cst acquire
56
- // CHECK: cmpxchg weak i32* %{{.*}}, i32 1, i32 52 seq_cst seq_cst
54
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 50 seq_cst monotonic
55
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 51 seq_cst acquire
56
+ // CHECK: cmpxchg weak {{ i32\*|ptr}} %{{.*}}, i32 1, i32 52 seq_cst seq_cst
57
57
let _ = w. compare_exchange_weak ( 1 , 50 , SeqCst , Relaxed ) ;
58
58
let _ = w. compare_exchange_weak ( 1 , 51 , SeqCst , Acquire ) ;
59
59
let _ = w. compare_exchange_weak ( 1 , 52 , SeqCst , SeqCst ) ;
0 commit comments