@@ -211,7 +211,7 @@ void c11_atomic_cmpxchg_strong(_Atomic(int) *ptr, int *expected, int desired) {
211211
212212  __c11_atomic_compare_exchange_strong (ptr , expected , desired ,
213213                                       __ATOMIC_SEQ_CST , __ATOMIC_ACQUIRE );
214-   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg( %{{.+}} : !cir.ptr<!s32i> , %{{.+}} : !s32i , %{{.+}} : ! s32i, success = seq_cst, failure = acquire) align(4) :  (!s32i, !cir.bool) 
214+   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg success(seq_cst) failure(acquire)  %{{.+}}, %{{.+}}, %{{.+}} align(4) : (!cir.ptr<! s32i>, !s32i, !s32i) ->  (!s32i, !cir.bool) 
215215  // CIR-NEXT:    %[[FAILED:.+]] = cir.unary(not, %[[SUCCESS]]) : !cir.bool, !cir.bool 
216216  // CIR-NEXT:    cir.if %[[FAILED]] { 
217217  // CIR-NEXT:      cir.store align(4) %[[OLD]], %{{.+}} : !s32i, !cir.ptr<!s32i> 
@@ -249,7 +249,7 @@ void c11_atomic_cmpxchg_weak(_Atomic(int) *ptr, int *expected, int desired) {
249249
250250  __c11_atomic_compare_exchange_weak (ptr , expected , desired ,
251251                                     __ATOMIC_SEQ_CST , __ATOMIC_ACQUIRE );
252-   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg( %{{.+}} : !cir.ptr<!s32i> , %{{.+}} : !s32i , %{{.+}} : ! s32i, success = seq_cst, failure = acquire) align(4) weak :  (!s32i, !cir.bool) 
252+   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg weak success(seq_cst) failure(acquire)  %{{.+}}, %{{.+}}, %{{.+}} align(4) : (!cir.ptr<! s32i>, !s32i, !s32i) ->  (!s32i, !cir.bool) 
253253  // CIR-NEXT:    %[[FAILED:.+]] = cir.unary(not, %[[SUCCESS]]) : !cir.bool, !cir.bool 
254254  // CIR-NEXT:    cir.if %[[FAILED]] { 
255255  // CIR-NEXT:      cir.store align(4) %[[OLD]], %{{.+}} : !s32i, !cir.ptr<!s32i> 
@@ -286,7 +286,7 @@ void atomic_cmpxchg(int *ptr, int *expected, int *desired) {
286286  // OGCG-LABEL: @atomic_cmpxchg 
287287
288288  __atomic_compare_exchange (ptr , expected , desired , /*weak=*/ 0 , __ATOMIC_SEQ_CST , __ATOMIC_ACQUIRE );
289-   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg( %{{.+}} : !cir.ptr<!s32i> , %{{.+}} : !s32i , %{{.+}} : ! s32i, success = seq_cst, failure = acquire) align(4) :  (!s32i, !cir.bool) 
289+   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg success(seq_cst) failure(acquire)  %{{.+}}, %{{.+}}, %{{.+}} align(4) : (!cir.ptr<! s32i>, !s32i, !s32i) ->  (!s32i, !cir.bool) 
290290  // CIR-NEXT:    %[[FAILED:.+]] = cir.unary(not, %[[SUCCESS]]) : !cir.bool, !cir.bool 
291291  // CIR-NEXT:    cir.if %[[FAILED]] { 
292292  // CIR-NEXT:      cir.store align(4) %[[OLD]], %{{.+}} : !s32i, !cir.ptr<!s32i> 
@@ -317,7 +317,7 @@ void atomic_cmpxchg(int *ptr, int *expected, int *desired) {
317317  // OGCG-NEXT:    store i8 %[[SUCCESS_2]], ptr %{{.+}}, align 1 
318318
319319  __atomic_compare_exchange (ptr , expected , desired , /*weak=*/ 1 , __ATOMIC_SEQ_CST , __ATOMIC_ACQUIRE );
320-   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg( %{{.+}} : !cir.ptr<!s32i> , %{{.+}} : !s32i , %{{.+}} : ! s32i, success = seq_cst, failure = acquire) align(4) weak :  (!s32i, !cir.bool) 
320+   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg weak success(seq_cst) failure(acquire)  %{{.+}}, %{{.+}}, %{{.+}} align(4) : (!cir.ptr<! s32i>, !s32i, !s32i) ->  (!s32i, !cir.bool) 
321321  // CIR-NEXT:    %[[FAILED:.+]] = cir.unary(not, %[[SUCCESS]]) : !cir.bool, !cir.bool 
322322  // CIR-NEXT:    cir.if %[[FAILED]] { 
323323  // CIR-NEXT:      cir.store align(4) %[[OLD]], %{{.+}} : !s32i, !cir.ptr<!s32i> 
@@ -354,7 +354,7 @@ void atomic_cmpxchg_n(int *ptr, int *expected, int desired) {
354354  // OGCG-LABEL: @atomic_cmpxchg_n 
355355
356356  __atomic_compare_exchange_n (ptr , expected , desired , /*weak=*/ 0 , __ATOMIC_SEQ_CST , __ATOMIC_ACQUIRE );
357-   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg( %{{.+}} : !cir.ptr<!s32i> , %{{.+}} : !s32i , %{{.+}} : ! s32i, success = seq_cst, failure = acquire) align(4) :  (!s32i, !cir.bool) 
357+   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg success(seq_cst) failure(acquire)  %{{.+}}, %{{.+}}, %{{.+}} align(4) : (!cir.ptr<! s32i>, !s32i, !s32i) ->  (!s32i, !cir.bool) 
358358  // CIR-NEXT:    %[[FAILED:.+]] = cir.unary(not, %[[SUCCESS]]) : !cir.bool, !cir.bool 
359359  // CIR-NEXT:    cir.if %[[FAILED]] { 
360360  // CIR-NEXT:      cir.store align(4) %[[OLD]], %{{.+}} : !s32i, !cir.ptr<!s32i> 
@@ -385,7 +385,7 @@ void atomic_cmpxchg_n(int *ptr, int *expected, int desired) {
385385  // OGCG-NEXT:    store i8 %[[SUCCESS_2]], ptr %{{.+}}, align 1 
386386
387387  __atomic_compare_exchange_n (ptr , expected , desired , /*weak=*/ 1 , __ATOMIC_SEQ_CST , __ATOMIC_ACQUIRE );
388-   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg( %{{.+}} : !cir.ptr<!s32i> , %{{.+}} : !s32i , %{{.+}} : ! s32i, success = seq_cst, failure = acquire) align(4) weak :  (!s32i, !cir.bool) 
388+   // CIR:         %[[OLD:.+]], %[[SUCCESS:.+]] = cir.atomic.cmpxchg weak success(seq_cst) failure(acquire)  %{{.+}}, %{{.+}}, %{{.+}} align(4) : (!cir.ptr<! s32i>, !s32i, !s32i) ->  (!s32i, !cir.bool) 
389389  // CIR-NEXT:    %[[FAILED:.+]] = cir.unary(not, %[[SUCCESS]]) : !cir.bool, !cir.bool 
390390  // CIR-NEXT:    cir.if %[[FAILED]] { 
391391  // CIR-NEXT:      cir.store align(4) %[[OLD]], %{{.+}} : !s32i, !cir.ptr<!s32i> 
@@ -427,12 +427,12 @@ void c11_atomic_exchange(_Atomic(int) *ptr, int value) {
427427  __c11_atomic_exchange (ptr , value , __ATOMIC_RELEASE );
428428  __c11_atomic_exchange (ptr , value , __ATOMIC_ACQ_REL );
429429  __c11_atomic_exchange (ptr , value , __ATOMIC_SEQ_CST );
430-   // CIR: %{{.+}} = cir.atomic.xchg relaxed %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
431-   // CIR: %{{.+}} = cir.atomic.xchg consume %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
432-   // CIR: %{{.+}} = cir.atomic.xchg acquire %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
433-   // CIR: %{{.+}} = cir.atomic.xchg release %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
434-   // CIR: %{{.+}} = cir.atomic.xchg acq_rel %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
435-   // CIR: %{{.+}} = cir.atomic.xchg seq_cst %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
430+   // CIR: %{{.+}} = cir.atomic.xchg relaxed %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
431+   // CIR: %{{.+}} = cir.atomic.xchg consume %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
432+   // CIR: %{{.+}} = cir.atomic.xchg acquire %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
433+   // CIR: %{{.+}} = cir.atomic.xchg release %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
434+   // CIR: %{{.+}} = cir.atomic.xchg acq_rel %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
435+   // CIR: %{{.+}} = cir.atomic.xchg seq_cst %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
436436
437437  // LLVM: %{{.+}} = atomicrmw xchg ptr %{{.+}}, i32 %{{.+}} monotonic, align 4 
438438  // LLVM: %{{.+}} = atomicrmw xchg ptr %{{.+}}, i32 %{{.+}} acquire, align 4 
@@ -460,12 +460,12 @@ void atomic_exchange(int *ptr, int *value, int *old) {
460460  __atomic_exchange (ptr , value , old , __ATOMIC_RELEASE );
461461  __atomic_exchange (ptr , value , old , __ATOMIC_ACQ_REL );
462462  __atomic_exchange (ptr , value , old , __ATOMIC_SEQ_CST );
463-   // CIR: %{{.+}} = cir.atomic.xchg relaxed %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
464-   // CIR: %{{.+}} = cir.atomic.xchg consume %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
465-   // CIR: %{{.+}} = cir.atomic.xchg acquire %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
466-   // CIR: %{{.+}} = cir.atomic.xchg release %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
467-   // CIR: %{{.+}} = cir.atomic.xchg acq_rel %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
468-   // CIR: %{{.+}} = cir.atomic.xchg seq_cst %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
463+   // CIR: %{{.+}} = cir.atomic.xchg relaxed %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
464+   // CIR: %{{.+}} = cir.atomic.xchg consume %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
465+   // CIR: %{{.+}} = cir.atomic.xchg acquire %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
466+   // CIR: %{{.+}} = cir.atomic.xchg release %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
467+   // CIR: %{{.+}} = cir.atomic.xchg acq_rel %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
468+   // CIR: %{{.+}} = cir.atomic.xchg seq_cst %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
469469
470470  // LLVM: %{{.+}} = atomicrmw xchg ptr %{{.+}}, i32 %{{.+}} monotonic, align 4 
471471  // LLVM: %{{.+}} = atomicrmw xchg ptr %{{.+}}, i32 %{{.+}} acquire, align 4 
@@ -493,12 +493,12 @@ void atomic_exchange_n(int *ptr, int value) {
493493  __atomic_exchange_n (ptr , value , __ATOMIC_RELEASE );
494494  __atomic_exchange_n (ptr , value , __ATOMIC_ACQ_REL );
495495  __atomic_exchange_n (ptr , value , __ATOMIC_SEQ_CST );
496-   // CIR: %{{.+}} = cir.atomic.xchg relaxed %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
497-   // CIR: %{{.+}} = cir.atomic.xchg consume %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
498-   // CIR: %{{.+}} = cir.atomic.xchg acquire %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
499-   // CIR: %{{.+}} = cir.atomic.xchg release %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
500-   // CIR: %{{.+}} = cir.atomic.xchg acq_rel %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
501-   // CIR: %{{.+}} = cir.atomic.xchg seq_cst %{{.+}}, %{{.+}} : !cir.ptr<!s32i> -> !s32i 
496+   // CIR: %{{.+}} = cir.atomic.xchg relaxed %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
497+   // CIR: %{{.+}} = cir.atomic.xchg consume %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
498+   // CIR: %{{.+}} = cir.atomic.xchg acquire %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
499+   // CIR: %{{.+}} = cir.atomic.xchg release %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
500+   // CIR: %{{.+}} = cir.atomic.xchg acq_rel %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
501+   // CIR: %{{.+}} = cir.atomic.xchg seq_cst %{{.+}}, %{{.+}} : ( !cir.ptr<!s32i>, !s32i)  -> !s32i 
502502
503503  // LLVM: %{{.+}} = atomicrmw xchg ptr %{{.+}}, i32 %{{.+}} monotonic, align 4 
504504  // LLVM: %{{.+}} = atomicrmw xchg ptr %{{.+}}, i32 %{{.+}} acquire, align 4 
0 commit comments