; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB35_2
; RV32I-NEXT: .LBB35_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB35_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB35_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB35_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB35_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB35_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB35_4
-; RV32I-NEXT: .LBB35_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB35_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB35_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB35_1
-; RV32I-NEXT: .LBB35_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB35_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB35_2
; RV64I-NEXT: .LBB35_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB35_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB35_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB35_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB35_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB35_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB35_4
-; RV64I-NEXT: .LBB35_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB35_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB35_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB35_1
-; RV64I-NEXT: .LBB35_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB35_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB36_2
; RV32I-NEXT: .LBB36_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB36_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB36_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB36_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB36_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB36_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB36_4
-; RV32I-NEXT: .LBB36_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB36_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB36_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB36_1
-; RV32I-NEXT: .LBB36_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB36_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB36_2
; RV64I-NEXT: .LBB36_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB36_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB36_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB36_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB36_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB36_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB36_4
-; RV64I-NEXT: .LBB36_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB36_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB36_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB36_1
-; RV64I-NEXT: .LBB36_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB36_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB37_2
; RV32I-NEXT: .LBB37_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB37_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB37_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB37_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB37_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB37_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB37_4
-; RV32I-NEXT: .LBB37_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB37_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB37_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB37_1
-; RV32I-NEXT: .LBB37_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB37_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB37_2
; RV64I-NEXT: .LBB37_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB37_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB37_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB37_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB37_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB37_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB37_4
-; RV64I-NEXT: .LBB37_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB37_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB37_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB37_1
-; RV64I-NEXT: .LBB37_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB37_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB38_2
; RV32I-NEXT: .LBB38_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB38_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB38_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB38_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB38_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB38_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB38_4
-; RV32I-NEXT: .LBB38_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB38_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB38_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB38_1
-; RV32I-NEXT: .LBB38_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB38_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB38_2
; RV64I-NEXT: .LBB38_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB38_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB38_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB38_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB38_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB38_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB38_4
-; RV64I-NEXT: .LBB38_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB38_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB38_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB38_1
-; RV64I-NEXT: .LBB38_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB38_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB39_2
; RV32I-NEXT: .LBB39_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB39_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB39_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB39_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB39_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB39_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB39_4
-; RV32I-NEXT: .LBB39_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB39_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB39_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB39_1
-; RV32I-NEXT: .LBB39_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB39_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB39_2
; RV64I-NEXT: .LBB39_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB39_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB39_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB39_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB39_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB39_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB39_4
-; RV64I-NEXT: .LBB39_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB39_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB39_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB39_1
-; RV64I-NEXT: .LBB39_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB39_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB40_2
; RV32I-NEXT: .LBB40_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB40_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB40_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB40_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB40_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB40_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB40_4
-; RV32I-NEXT: .LBB40_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB40_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB40_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB40_1
-; RV32I-NEXT: .LBB40_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB40_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB40_2
; RV64I-NEXT: .LBB40_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB40_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB40_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB40_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB40_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB40_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB40_4
-; RV64I-NEXT: .LBB40_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB40_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB40_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB40_1
-; RV64I-NEXT: .LBB40_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB40_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB41_2
; RV32I-NEXT: .LBB41_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB41_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB41_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB41_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB41_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB41_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB41_4
-; RV32I-NEXT: .LBB41_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB41_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB41_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB41_1
-; RV32I-NEXT: .LBB41_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB41_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB41_2
; RV64I-NEXT: .LBB41_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB41_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB41_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB41_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB41_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB41_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB41_4
-; RV64I-NEXT: .LBB41_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB41_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB41_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB41_1
-; RV64I-NEXT: .LBB41_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB41_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB42_2
; RV32I-NEXT: .LBB42_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB42_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB42_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB42_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB42_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB42_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB42_4
-; RV32I-NEXT: .LBB42_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB42_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB42_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB42_1
-; RV32I-NEXT: .LBB42_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB42_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB42_2
; RV64I-NEXT: .LBB42_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB42_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB42_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB42_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB42_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB42_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB42_4
-; RV64I-NEXT: .LBB42_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB42_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB42_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB42_1
-; RV64I-NEXT: .LBB42_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB42_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB43_2
; RV32I-NEXT: .LBB43_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB43_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB43_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB43_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB43_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB43_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB43_4
-; RV32I-NEXT: .LBB43_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB43_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB43_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB43_1
-; RV32I-NEXT: .LBB43_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB43_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB43_2
; RV64I-NEXT: .LBB43_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB43_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB43_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB43_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB43_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB43_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB43_4
-; RV64I-NEXT: .LBB43_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB43_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB43_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB43_1
-; RV64I-NEXT: .LBB43_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB43_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 24
; RV32I-NEXT: srai s0, a1, 24
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB44_2
; RV32I-NEXT: .LBB44_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB44_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 24
+; RV32I-NEXT: srai a1, a1, 24
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB44_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB44_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB44_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB44_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB44_4
-; RV32I-NEXT: .LBB44_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 24
-; RV32I-NEXT: srai a1, a1, 24
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB44_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB44_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB44_1
-; RV32I-NEXT: .LBB44_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB44_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 56
; RV64I-NEXT: srai s0, a1, 56
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB44_2
; RV64I-NEXT: .LBB44_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB44_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 56
+; RV64I-NEXT: srai a1, a1, 56
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB44_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB44_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB44_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB44_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB44_4
-; RV64I-NEXT: .LBB44_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 56
-; RV64I-NEXT: srai a1, a1, 56
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB44_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB44_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB44_1
-; RV64I-NEXT: .LBB44_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB44_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB45_2
; RV32I-NEXT: .LBB45_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB45_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s0, a1, .LBB45_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB45_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB45_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB45_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB45_4
-; RV32I-NEXT: .LBB45_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s0, a1, .LBB45_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB45_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB45_1
-; RV32I-NEXT: .LBB45_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB45_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB45_2
; RV64I-NEXT: .LBB45_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB45_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB45_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB45_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB45_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB45_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB45_4
-; RV64I-NEXT: .LBB45_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB45_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB45_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB45_1
-; RV64I-NEXT: .LBB45_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB45_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB46_2
; RV32I-NEXT: .LBB46_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB46_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s0, a1, .LBB46_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB46_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB46_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB46_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB46_4
-; RV32I-NEXT: .LBB46_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s0, a1, .LBB46_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB46_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB46_1
-; RV32I-NEXT: .LBB46_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB46_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB46_2
; RV64I-NEXT: .LBB46_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB46_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB46_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB46_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB46_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB46_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB46_4
-; RV64I-NEXT: .LBB46_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB46_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB46_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB46_1
-; RV64I-NEXT: .LBB46_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB46_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB47_2
; RV32I-NEXT: .LBB47_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB47_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s0, a1, .LBB47_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB47_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB47_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB47_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB47_4
-; RV32I-NEXT: .LBB47_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s0, a1, .LBB47_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB47_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB47_1
-; RV32I-NEXT: .LBB47_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB47_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB47_2
; RV64I-NEXT: .LBB47_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB47_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB47_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB47_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB47_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB47_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB47_4
-; RV64I-NEXT: .LBB47_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB47_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB47_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB47_1
-; RV64I-NEXT: .LBB47_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB47_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB48_2
; RV32I-NEXT: .LBB48_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB48_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s0, a1, .LBB48_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB48_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB48_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB48_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB48_4
-; RV32I-NEXT: .LBB48_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s0, a1, .LBB48_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB48_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB48_1
-; RV32I-NEXT: .LBB48_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB48_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB48_2
; RV64I-NEXT: .LBB48_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB48_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB48_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB48_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB48_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB48_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB48_4
-; RV64I-NEXT: .LBB48_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB48_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB48_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB48_1
-; RV64I-NEXT: .LBB48_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB48_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB49_2
; RV32I-NEXT: .LBB49_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB49_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s0, a1, .LBB49_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB49_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB49_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB49_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB49_4
-; RV32I-NEXT: .LBB49_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s0, a1, .LBB49_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB49_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB49_1
-; RV32I-NEXT: .LBB49_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB49_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB49_2
; RV64I-NEXT: .LBB49_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB49_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB49_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB49_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB49_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB49_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB49_4
-; RV64I-NEXT: .LBB49_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB49_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB49_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB49_1
-; RV64I-NEXT: .LBB49_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB49_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB50_2
; RV32I-NEXT: .LBB50_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB50_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s0, a1, .LBB50_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB50_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB50_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB50_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB50_4
-; RV32I-NEXT: .LBB50_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s0, a1, .LBB50_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB50_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB50_1
-; RV32I-NEXT: .LBB50_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB50_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB50_2
; RV64I-NEXT: .LBB50_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB50_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB50_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB50_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB50_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB50_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB50_4
-; RV64I-NEXT: .LBB50_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB50_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB50_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB50_1
-; RV64I-NEXT: .LBB50_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB50_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB51_2
; RV32I-NEXT: .LBB51_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB51_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s0, a1, .LBB51_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB51_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB51_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB51_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB51_4
-; RV32I-NEXT: .LBB51_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s0, a1, .LBB51_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB51_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB51_1
-; RV32I-NEXT: .LBB51_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB51_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB51_2
; RV64I-NEXT: .LBB51_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB51_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB51_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB51_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB51_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB51_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB51_4
-; RV64I-NEXT: .LBB51_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB51_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB51_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB51_1
-; RV64I-NEXT: .LBB51_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB51_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB52_2
; RV32I-NEXT: .LBB52_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB52_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s0, a1, .LBB52_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB52_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB52_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB52_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB52_4
-; RV32I-NEXT: .LBB52_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s0, a1, .LBB52_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB52_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB52_1
-; RV32I-NEXT: .LBB52_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB52_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB52_2
; RV64I-NEXT: .LBB52_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB52_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB52_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB52_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB52_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB52_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB52_4
-; RV64I-NEXT: .LBB52_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB52_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB52_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB52_1
-; RV64I-NEXT: .LBB52_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB52_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB53_2
; RV32I-NEXT: .LBB53_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB53_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s0, a1, .LBB53_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB53_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB53_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB53_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB53_4
-; RV32I-NEXT: .LBB53_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s0, a1, .LBB53_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB53_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB53_1
-; RV32I-NEXT: .LBB53_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB53_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB53_2
; RV64I-NEXT: .LBB53_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB53_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB53_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB53_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB53_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB53_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB53_4
-; RV64I-NEXT: .LBB53_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB53_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB53_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB53_1
-; RV64I-NEXT: .LBB53_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB53_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lbu a0, 0(a0)
; RV32I-NEXT: andi s0, a1, 255
; RV32I-NEXT: addi s3, sp, 11
-; RV32I-NEXT: j .LBB54_2
; RV32I-NEXT: .LBB54_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB54_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: andi a1, a0, 255
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s0, a1, .LBB54_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB54_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB54_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB54_1 Depth=1
; RV32I-NEXT: sb a0, 11(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_1
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lb a0, 11(sp)
-; RV32I-NEXT: bnez a1, .LBB54_4
-; RV32I-NEXT: .LBB54_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: andi a1, a0, 255
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s0, a1, .LBB54_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB54_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB54_1
-; RV32I-NEXT: .LBB54_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB54_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lbu a0, 0(a0)
; RV64I-NEXT: andi s0, a1, 255
; RV64I-NEXT: addi s3, sp, 7
-; RV64I-NEXT: j .LBB54_2
; RV64I-NEXT: .LBB54_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB54_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: andi a1, a0, 255
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB54_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB54_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB54_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB54_1 Depth=1
; RV64I-NEXT: sb a0, 7(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_1
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lb a0, 7(sp)
-; RV64I-NEXT: bnez a1, .LBB54_4
-; RV64I-NEXT: .LBB54_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: andi a1, a0, 255
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB54_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB54_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB54_1
-; RV64I-NEXT: .LBB54_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB54_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB90_2
; RV32I-NEXT: .LBB90_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB90_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB90_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB90_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB90_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB90_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB90_4
-; RV32I-NEXT: .LBB90_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB90_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB90_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB90_1
-; RV32I-NEXT: .LBB90_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB90_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB90_2
; RV64I-NEXT: .LBB90_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB90_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB90_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB90_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB90_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB90_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB90_4
-; RV64I-NEXT: .LBB90_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB90_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB90_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB90_1
-; RV64I-NEXT: .LBB90_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB90_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB91_2
; RV32I-NEXT: .LBB91_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB91_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB91_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB91_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB91_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB91_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB91_4
-; RV32I-NEXT: .LBB91_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB91_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB91_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB91_1
-; RV32I-NEXT: .LBB91_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB91_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB91_2
; RV64I-NEXT: .LBB91_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB91_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB91_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB91_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB91_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB91_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB91_4
-; RV64I-NEXT: .LBB91_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB91_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB91_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB91_1
-; RV64I-NEXT: .LBB91_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB91_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB92_2
; RV32I-NEXT: .LBB92_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB92_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB92_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB92_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB92_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB92_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB92_4
-; RV32I-NEXT: .LBB92_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB92_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB92_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB92_1
-; RV32I-NEXT: .LBB92_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB92_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB92_2
; RV64I-NEXT: .LBB92_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB92_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB92_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB92_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB92_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB92_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB92_4
-; RV64I-NEXT: .LBB92_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB92_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB92_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB92_1
-; RV64I-NEXT: .LBB92_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB92_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB93_2
; RV32I-NEXT: .LBB93_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB93_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB93_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB93_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB93_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB93_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB93_4
-; RV32I-NEXT: .LBB93_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB93_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB93_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB93_1
-; RV32I-NEXT: .LBB93_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB93_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB93_2
; RV64I-NEXT: .LBB93_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB93_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB93_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB93_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB93_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB93_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB93_4
-; RV64I-NEXT: .LBB93_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB93_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB93_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB93_1
-; RV64I-NEXT: .LBB93_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB93_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB94_2
; RV32I-NEXT: .LBB94_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB94_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: blt s0, a1, .LBB94_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB94_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB94_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB94_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB94_4
-; RV32I-NEXT: .LBB94_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: blt s0, a1, .LBB94_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB94_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB94_1
-; RV32I-NEXT: .LBB94_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB94_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB94_2
; RV64I-NEXT: .LBB94_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB94_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB94_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB94_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB94_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB94_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB94_4
-; RV64I-NEXT: .LBB94_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB94_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB94_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB94_1
-; RV64I-NEXT: .LBB94_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB94_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB95_2
; RV32I-NEXT: .LBB95_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB95_2 Depth=1
-; RV32I-NEXT: sh a0, 10(sp)
-; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB95_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB95_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB95_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB95_1 Depth=1
+; RV32I-NEXT: sh a0, 10(sp)
+; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: mv a3, zero
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB95_4
-; RV32I-NEXT: .LBB95_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB95_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB95_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB95_1
-; RV32I-NEXT: .LBB95_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB95_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB95_2
; RV64I-NEXT: .LBB95_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB95_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB95_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB95_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB95_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB95_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB95_4
-; RV64I-NEXT: .LBB95_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB95_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB95_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB95_1
-; RV64I-NEXT: .LBB95_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB95_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB96_2
; RV32I-NEXT: .LBB96_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB96_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB96_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB96_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB96_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB96_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB96_4
-; RV32I-NEXT: .LBB96_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB96_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB96_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB96_1
-; RV32I-NEXT: .LBB96_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB96_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB96_2
; RV64I-NEXT: .LBB96_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB96_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB96_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB96_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB96_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB96_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB96_4
-; RV64I-NEXT: .LBB96_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB96_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB96_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB96_1
-; RV64I-NEXT: .LBB96_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB96_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB97_2
; RV32I-NEXT: .LBB97_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB97_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB97_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB97_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB97_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB97_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB97_4
-; RV32I-NEXT: .LBB97_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB97_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB97_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB97_1
-; RV32I-NEXT: .LBB97_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB97_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB97_2
; RV64I-NEXT: .LBB97_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB97_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB97_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB97_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB97_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB97_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB97_4
-; RV64I-NEXT: .LBB97_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB97_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB97_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB97_1
-; RV64I-NEXT: .LBB97_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB97_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB98_2
; RV32I-NEXT: .LBB98_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB98_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB98_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB98_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB98_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB98_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB98_4
-; RV32I-NEXT: .LBB98_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB98_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB98_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB98_1
-; RV32I-NEXT: .LBB98_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB98_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB98_2
; RV64I-NEXT: .LBB98_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB98_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB98_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB98_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB98_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB98_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB98_4
-; RV64I-NEXT: .LBB98_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB98_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB98_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB98_1
-; RV64I-NEXT: .LBB98_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB98_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: slli a1, a1, 16
; RV32I-NEXT: srai s0, a1, 16
; RV32I-NEXT: addi s3, sp, 10
-; RV32I-NEXT: j .LBB99_2
; RV32I-NEXT: .LBB99_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB99_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: slli a1, a0, 16
+; RV32I-NEXT: srai a1, a1, 16
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bge s0, a1, .LBB99_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB99_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB99_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB99_1 Depth=1
; RV32I-NEXT: sh a0, 10(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 10(sp)
-; RV32I-NEXT: bnez a1, .LBB99_4
-; RV32I-NEXT: .LBB99_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: slli a1, a0, 16
-; RV32I-NEXT: srai a1, a1, 16
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bge s0, a1, .LBB99_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB99_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB99_1
-; RV32I-NEXT: .LBB99_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB99_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: slli a1, a1, 48
; RV64I-NEXT: srai s0, a1, 48
; RV64I-NEXT: addi s3, sp, 6
-; RV64I-NEXT: j .LBB99_2
; RV64I-NEXT: .LBB99_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB99_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: slli a1, a0, 48
+; RV64I-NEXT: srai a1, a1, 48
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB99_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB99_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB99_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB99_1 Depth=1
; RV64I-NEXT: sh a0, 6(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 6(sp)
-; RV64I-NEXT: bnez a1, .LBB99_4
-; RV64I-NEXT: .LBB99_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: slli a1, a0, 48
-; RV64I-NEXT: srai a1, a1, 48
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB99_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB99_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB99_1
-; RV64I-NEXT: .LBB99_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB99_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB100_2
; RV32I-NEXT: .LBB100_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB100_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s1, a1, .LBB100_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB100_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB100_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB100_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB100_4
-; RV32I-NEXT: .LBB100_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s1, a1, .LBB100_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB100_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB100_1
-; RV32I-NEXT: .LBB100_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB100_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB100_2
; RV64I-NEXT: .LBB100_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB100_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s1, a1, .LBB100_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB100_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB100_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB100_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB100_4
-; RV64I-NEXT: .LBB100_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s1, a1, .LBB100_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB100_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB100_1
-; RV64I-NEXT: .LBB100_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB100_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB101_2
; RV32I-NEXT: .LBB101_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB101_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s1, a1, .LBB101_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB101_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB101_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB101_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB101_4
-; RV32I-NEXT: .LBB101_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s1, a1, .LBB101_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB101_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB101_1
-; RV32I-NEXT: .LBB101_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB101_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB101_2
; RV64I-NEXT: .LBB101_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB101_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s1, a1, .LBB101_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB101_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB101_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB101_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB101_4
-; RV64I-NEXT: .LBB101_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s1, a1, .LBB101_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB101_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB101_1
-; RV64I-NEXT: .LBB101_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB101_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB102_2
; RV32I-NEXT: .LBB102_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB102_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s1, a1, .LBB102_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB102_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB102_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB102_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB102_4
-; RV32I-NEXT: .LBB102_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s1, a1, .LBB102_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB102_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB102_1
-; RV32I-NEXT: .LBB102_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB102_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB102_2
; RV64I-NEXT: .LBB102_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB102_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s1, a1, .LBB102_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB102_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB102_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB102_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB102_4
-; RV64I-NEXT: .LBB102_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s1, a1, .LBB102_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB102_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB102_1
-; RV64I-NEXT: .LBB102_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB102_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB103_2
; RV32I-NEXT: .LBB103_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB103_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s1, a1, .LBB103_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB103_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB103_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB103_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB103_4
-; RV32I-NEXT: .LBB103_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s1, a1, .LBB103_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB103_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB103_1
-; RV32I-NEXT: .LBB103_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB103_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB103_2
; RV64I-NEXT: .LBB103_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB103_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s1, a1, .LBB103_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB103_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB103_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB103_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB103_4
-; RV64I-NEXT: .LBB103_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s1, a1, .LBB103_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB103_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB103_1
-; RV64I-NEXT: .LBB103_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB103_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB104_2
; RV32I-NEXT: .LBB104_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB104_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bltu s1, a1, .LBB104_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB104_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB104_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB104_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB104_4
-; RV32I-NEXT: .LBB104_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bltu s1, a1, .LBB104_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB104_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB104_1
-; RV32I-NEXT: .LBB104_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB104_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB104_2
; RV64I-NEXT: .LBB104_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB104_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s1, a1, .LBB104_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB104_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB104_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB104_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB104_4
-; RV64I-NEXT: .LBB104_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s1, a1, .LBB104_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB104_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB104_1
-; RV64I-NEXT: .LBB104_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB104_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB105_2
; RV32I-NEXT: .LBB105_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB105_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s1, a1, .LBB105_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB105_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB105_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB105_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB105_4
-; RV32I-NEXT: .LBB105_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s1, a1, .LBB105_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB105_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB105_1
-; RV32I-NEXT: .LBB105_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB105_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB105_2
; RV64I-NEXT: .LBB105_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB105_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s1, a1, .LBB105_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB105_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB105_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB105_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB105_4
-; RV64I-NEXT: .LBB105_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s1, a1, .LBB105_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB105_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB105_1
-; RV64I-NEXT: .LBB105_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB105_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB106_2
; RV32I-NEXT: .LBB106_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB106_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s1, a1, .LBB106_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB106_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB106_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB106_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB106_4
-; RV32I-NEXT: .LBB106_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s1, a1, .LBB106_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB106_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB106_1
-; RV32I-NEXT: .LBB106_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB106_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB106_2
; RV64I-NEXT: .LBB106_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB106_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s1, a1, .LBB106_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB106_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB106_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB106_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB106_4
-; RV64I-NEXT: .LBB106_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s1, a1, .LBB106_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB106_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB106_1
-; RV64I-NEXT: .LBB106_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB106_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB107_2
; RV32I-NEXT: .LBB107_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB107_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s1, a1, .LBB107_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB107_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB107_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB107_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB107_4
-; RV32I-NEXT: .LBB107_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s1, a1, .LBB107_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB107_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB107_1
-; RV32I-NEXT: .LBB107_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB107_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB107_2
; RV64I-NEXT: .LBB107_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB107_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s1, a1, .LBB107_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB107_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB107_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB107_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB107_4
-; RV64I-NEXT: .LBB107_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s1, a1, .LBB107_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB107_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB107_1
-; RV64I-NEXT: .LBB107_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB107_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB108_2
; RV32I-NEXT: .LBB108_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB108_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s1, a1, .LBB108_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB108_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB108_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB108_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB108_4
-; RV32I-NEXT: .LBB108_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s1, a1, .LBB108_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB108_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB108_1
-; RV32I-NEXT: .LBB108_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB108_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB108_2
; RV64I-NEXT: .LBB108_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB108_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s1, a1, .LBB108_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB108_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB108_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB108_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB108_4
-; RV64I-NEXT: .LBB108_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s1, a1, .LBB108_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB108_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB108_1
-; RV64I-NEXT: .LBB108_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB108_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: addi s0, a1, -1
; RV32I-NEXT: and s1, s2, s0
; RV32I-NEXT: addi s3, sp, 6
-; RV32I-NEXT: j .LBB109_2
; RV32I-NEXT: .LBB109_1: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB109_2 Depth=1
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: and a1, a0, s0
+; RV32I-NEXT: mv a2, a0
+; RV32I-NEXT: bgeu s1, a1, .LBB109_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB109_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: .LBB109_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB109_1 Depth=1
; RV32I-NEXT: sh a0, 6(sp)
; RV32I-NEXT: mv a0, s4
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_2
; RV32I-NEXT: mv a1, a0
; RV32I-NEXT: lh a0, 6(sp)
-; RV32I-NEXT: bnez a1, .LBB109_4
-; RV32I-NEXT: .LBB109_2: # %atomicrmw.start
-; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV32I-NEXT: and a1, a0, s0
-; RV32I-NEXT: mv a2, a0
-; RV32I-NEXT: bgeu s1, a1, .LBB109_1
-; RV32I-NEXT: # %bb.3: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB109_2 Depth=1
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: j .LBB109_1
-; RV32I-NEXT: .LBB109_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a1, .LBB109_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: lw s4, 8(sp)
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV64I-NEXT: addiw s0, a1, -1
; RV64I-NEXT: and s1, s2, s0
; RV64I-NEXT: addi s3, sp, 14
-; RV64I-NEXT: j .LBB109_2
; RV64I-NEXT: .LBB109_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB109_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: and a1, a0, s0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s1, a1, .LBB109_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB109_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB109_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB109_1 Depth=1
; RV64I-NEXT: sh a0, 14(sp)
; RV64I-NEXT: mv a0, s4
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_2
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lh a0, 14(sp)
-; RV64I-NEXT: bnez a1, .LBB109_4
-; RV64I-NEXT: .LBB109_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: and a1, a0, s0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s1, a1, .LBB109_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB109_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB109_1
-; RV64I-NEXT: .LBB109_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB109_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s4, 16(sp)
; RV64I-NEXT: ld s3, 24(sp)
; RV64I-NEXT: ld s2, 32(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB145_3
; RV32I-NEXT: .LBB145_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: blt s0, a2, .LBB145_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB145_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB145_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB145_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: mv a3, zero
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB145_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB145_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB145_1
-; RV32I-NEXT: .LBB145_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB145_1
-; RV32I-NEXT: .LBB145_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB145_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB145_2
; RV64I-NEXT: .LBB145_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB145_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB145_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB145_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB145_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB145_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB145_4
-; RV64I-NEXT: .LBB145_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB145_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB145_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB145_1
-; RV64I-NEXT: .LBB145_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB145_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB146_3
; RV32I-NEXT: .LBB146_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: blt s0, a2, .LBB146_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB146_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB146_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB146_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 2
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB146_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB146_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB146_1
-; RV32I-NEXT: .LBB146_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB146_1
-; RV32I-NEXT: .LBB146_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB146_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB146_2
; RV64I-NEXT: .LBB146_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB146_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB146_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB146_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB146_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB146_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB146_4
-; RV64I-NEXT: .LBB146_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB146_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB146_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB146_1
-; RV64I-NEXT: .LBB146_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB146_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB147_3
; RV32I-NEXT: .LBB147_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: blt s0, a2, .LBB147_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB147_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB147_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB147_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 3
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB147_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB147_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB147_1
-; RV32I-NEXT: .LBB147_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB147_1
-; RV32I-NEXT: .LBB147_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB147_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB147_2
; RV64I-NEXT: .LBB147_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB147_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB147_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB147_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB147_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB147_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB147_4
-; RV64I-NEXT: .LBB147_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB147_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB147_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB147_1
-; RV64I-NEXT: .LBB147_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB147_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB148_3
; RV32I-NEXT: .LBB148_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: blt s0, a2, .LBB148_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB148_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB148_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB148_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 4
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB148_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB148_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB148_1
-; RV32I-NEXT: .LBB148_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB148_1
-; RV32I-NEXT: .LBB148_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB148_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB148_2
; RV64I-NEXT: .LBB148_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB148_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB148_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB148_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB148_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB148_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB148_4
-; RV64I-NEXT: .LBB148_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB148_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB148_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB148_1
-; RV64I-NEXT: .LBB148_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB148_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB149_3
; RV32I-NEXT: .LBB149_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: blt s0, a2, .LBB149_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB149_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB149_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB149_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 5
; RV32I-NEXT: addi a4, zero, 5
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB149_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB149_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB149_1
-; RV32I-NEXT: .LBB149_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB149_1
-; RV32I-NEXT: .LBB149_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB149_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB149_2
; RV64I-NEXT: .LBB149_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB149_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: blt s0, a1, .LBB149_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB149_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB149_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB149_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB149_4
-; RV64I-NEXT: .LBB149_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: blt s0, a1, .LBB149_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB149_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB149_1
-; RV64I-NEXT: .LBB149_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB149_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB150_3
; RV32I-NEXT: .LBB150_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bge s0, a2, .LBB150_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB150_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB150_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB150_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: mv a3, zero
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB150_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB150_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB150_1
-; RV32I-NEXT: .LBB150_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB150_1
-; RV32I-NEXT: .LBB150_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB150_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB150_2
; RV64I-NEXT: .LBB150_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB150_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB150_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB150_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB150_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB150_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB150_4
-; RV64I-NEXT: .LBB150_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB150_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB150_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB150_1
-; RV64I-NEXT: .LBB150_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB150_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB151_3
; RV32I-NEXT: .LBB151_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bge s0, a2, .LBB151_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB151_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB151_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB151_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 2
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB151_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB151_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB151_1
-; RV32I-NEXT: .LBB151_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB151_1
-; RV32I-NEXT: .LBB151_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB151_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB151_2
; RV64I-NEXT: .LBB151_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB151_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB151_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB151_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB151_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB151_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB151_4
-; RV64I-NEXT: .LBB151_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB151_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB151_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB151_1
-; RV64I-NEXT: .LBB151_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB151_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB152_3
; RV32I-NEXT: .LBB152_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bge s0, a2, .LBB152_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB152_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB152_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB152_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 3
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB152_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB152_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB152_1
-; RV32I-NEXT: .LBB152_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB152_1
-; RV32I-NEXT: .LBB152_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB152_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB152_2
; RV64I-NEXT: .LBB152_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB152_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB152_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB152_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB152_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB152_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB152_4
-; RV64I-NEXT: .LBB152_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB152_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB152_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB152_1
-; RV64I-NEXT: .LBB152_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB152_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB153_3
; RV32I-NEXT: .LBB153_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bge s0, a2, .LBB153_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB153_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB153_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB153_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 4
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB153_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB153_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB153_1
-; RV32I-NEXT: .LBB153_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB153_1
-; RV32I-NEXT: .LBB153_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB153_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB153_2
; RV64I-NEXT: .LBB153_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB153_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB153_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB153_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB153_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB153_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB153_4
-; RV64I-NEXT: .LBB153_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB153_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB153_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB153_1
-; RV64I-NEXT: .LBB153_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB153_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: blt s0, a2, .LBB154_3
; RV32I-NEXT: .LBB154_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bge s0, a2, .LBB154_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB154_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB154_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB154_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 5
; RV32I-NEXT: addi a4, zero, 5
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB154_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB154_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bge s0, a2, .LBB154_1
-; RV32I-NEXT: .LBB154_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB154_1
-; RV32I-NEXT: .LBB154_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB154_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB154_2
; RV64I-NEXT: .LBB154_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB154_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bge s0, a1, .LBB154_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB154_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB154_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB154_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB154_4
-; RV64I-NEXT: .LBB154_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bge s0, a1, .LBB154_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB154_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB154_1
-; RV64I-NEXT: .LBB154_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB154_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB155_3
; RV32I-NEXT: .LBB155_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bltu s0, a2, .LBB155_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB155_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB155_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB155_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: mv a3, zero
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB155_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB155_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB155_1
-; RV32I-NEXT: .LBB155_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB155_1
-; RV32I-NEXT: .LBB155_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB155_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB155_2
; RV64I-NEXT: .LBB155_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB155_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB155_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB155_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB155_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB155_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB155_4
-; RV64I-NEXT: .LBB155_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB155_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB155_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB155_1
-; RV64I-NEXT: .LBB155_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB155_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB156_3
; RV32I-NEXT: .LBB156_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bltu s0, a2, .LBB156_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB156_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB156_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB156_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 2
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB156_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB156_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB156_1
-; RV32I-NEXT: .LBB156_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB156_1
-; RV32I-NEXT: .LBB156_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB156_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB156_2
; RV64I-NEXT: .LBB156_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB156_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB156_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB156_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB156_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB156_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB156_4
-; RV64I-NEXT: .LBB156_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB156_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB156_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB156_1
-; RV64I-NEXT: .LBB156_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB156_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB157_3
; RV32I-NEXT: .LBB157_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bltu s0, a2, .LBB157_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB157_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB157_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB157_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 3
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB157_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB157_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB157_1
-; RV32I-NEXT: .LBB157_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB157_1
-; RV32I-NEXT: .LBB157_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB157_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB157_2
; RV64I-NEXT: .LBB157_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB157_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB157_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB157_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB157_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB157_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB157_4
-; RV64I-NEXT: .LBB157_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB157_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB157_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB157_1
-; RV64I-NEXT: .LBB157_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB157_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB158_3
; RV32I-NEXT: .LBB158_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bltu s0, a2, .LBB158_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB158_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB158_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB158_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 4
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB158_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB158_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB158_1
-; RV32I-NEXT: .LBB158_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB158_1
-; RV32I-NEXT: .LBB158_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB158_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB158_2
; RV64I-NEXT: .LBB158_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB158_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB158_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB158_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB158_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB158_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB158_4
-; RV64I-NEXT: .LBB158_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB158_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB158_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB158_1
-; RV64I-NEXT: .LBB158_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB158_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB159_3
; RV32I-NEXT: .LBB159_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bltu s0, a2, .LBB159_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB159_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB159_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB159_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 5
; RV32I-NEXT: addi a4, zero, 5
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB159_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB159_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB159_1
-; RV32I-NEXT: .LBB159_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB159_1
-; RV32I-NEXT: .LBB159_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB159_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB159_2
; RV64I-NEXT: .LBB159_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB159_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bltu s0, a1, .LBB159_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB159_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB159_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB159_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB159_4
-; RV64I-NEXT: .LBB159_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bltu s0, a1, .LBB159_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB159_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB159_1
-; RV64I-NEXT: .LBB159_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB159_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB160_3
; RV32I-NEXT: .LBB160_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bgeu s0, a2, .LBB160_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB160_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB160_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB160_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: mv a3, zero
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB160_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB160_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB160_1
-; RV32I-NEXT: .LBB160_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB160_1
-; RV32I-NEXT: .LBB160_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB160_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB160_2
; RV64I-NEXT: .LBB160_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB160_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB160_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB160_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB160_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB160_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB160_4
-; RV64I-NEXT: .LBB160_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB160_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB160_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB160_1
-; RV64I-NEXT: .LBB160_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB160_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB161_3
; RV32I-NEXT: .LBB161_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bgeu s0, a2, .LBB161_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB161_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB161_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB161_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 2
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB161_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB161_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB161_1
-; RV32I-NEXT: .LBB161_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB161_1
-; RV32I-NEXT: .LBB161_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB161_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB161_2
; RV64I-NEXT: .LBB161_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB161_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB161_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB161_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB161_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB161_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB161_4
-; RV64I-NEXT: .LBB161_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB161_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB161_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB161_1
-; RV64I-NEXT: .LBB161_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB161_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB162_3
; RV32I-NEXT: .LBB162_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bgeu s0, a2, .LBB162_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB162_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB162_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB162_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 3
; RV32I-NEXT: mv a4, zero
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB162_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB162_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB162_1
-; RV32I-NEXT: .LBB162_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB162_1
-; RV32I-NEXT: .LBB162_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB162_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB162_2
; RV64I-NEXT: .LBB162_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB162_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB162_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB162_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB162_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB162_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB162_4
-; RV64I-NEXT: .LBB162_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB162_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB162_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB162_1
-; RV64I-NEXT: .LBB162_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB162_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB163_3
; RV32I-NEXT: .LBB163_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bgeu s0, a2, .LBB163_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB163_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB163_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB163_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 4
; RV32I-NEXT: addi a4, zero, 2
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB163_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB163_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB163_1
-; RV32I-NEXT: .LBB163_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB163_1
-; RV32I-NEXT: .LBB163_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB163_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB163_2
; RV64I-NEXT: .LBB163_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB163_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB163_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB163_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB163_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB163_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB163_4
-; RV64I-NEXT: .LBB163_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB163_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB163_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB163_1
-; RV64I-NEXT: .LBB163_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB163_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: mv s1, a0
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: addi s2, sp, 12
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bltu s0, a2, .LBB164_3
; RV32I-NEXT: .LBB164_1: # %atomicrmw.start
; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: sw a2, 12(sp)
+; RV32I-NEXT: bgeu s0, a2, .LBB164_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB164_1 Depth=1
+; RV32I-NEXT: mv a2, s0
+; RV32I-NEXT: .LBB164_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB164_1 Depth=1
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s2
; RV32I-NEXT: addi a3, zero, 5
; RV32I-NEXT: addi a4, zero, 5
; RV32I-NEXT: call __atomic_compare_exchange_4
; RV32I-NEXT: lw a2, 12(sp)
-; RV32I-NEXT: bnez a0, .LBB164_4
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: # in Loop: Header=BB164_1 Depth=1
-; RV32I-NEXT: sw a2, 12(sp)
-; RV32I-NEXT: bgeu s0, a2, .LBB164_1
-; RV32I-NEXT: .LBB164_3: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s0
-; RV32I-NEXT: j .LBB164_1
-; RV32I-NEXT: .LBB164_4: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB164_1
+; RV32I-NEXT: # %bb.4: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s2, 16(sp)
; RV32I-NEXT: lw s1, 20(sp)
; RV64I-NEXT: lwu a0, 0(a0)
; RV64I-NEXT: sext.w s0, a1
; RV64I-NEXT: addi s3, sp, 4
-; RV64I-NEXT: j .LBB164_2
; RV64I-NEXT: .LBB164_1: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB164_2 Depth=1
+; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sext.w a1, a0
+; RV64I-NEXT: mv a2, a0
+; RV64I-NEXT: bgeu s0, a1, .LBB164_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB164_1 Depth=1
+; RV64I-NEXT: mv a2, s2
+; RV64I-NEXT: .LBB164_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB164_1 Depth=1
; RV64I-NEXT: sw a0, 4(sp)
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s3
; RV64I-NEXT: call __atomic_compare_exchange_4
; RV64I-NEXT: mv a1, a0
; RV64I-NEXT: lw a0, 4(sp)
-; RV64I-NEXT: bnez a1, .LBB164_4
-; RV64I-NEXT: .LBB164_2: # %atomicrmw.start
-; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
-; RV64I-NEXT: sext.w a1, a0
-; RV64I-NEXT: mv a2, a0
-; RV64I-NEXT: bgeu s0, a1, .LBB164_1
-; RV64I-NEXT: # %bb.3: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB164_2 Depth=1
-; RV64I-NEXT: mv a2, s2
-; RV64I-NEXT: j .LBB164_1
-; RV64I-NEXT: .LBB164_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a1, .LBB164_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: ld s3, 8(sp)
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB200_3
-; RV32I-NEXT: j .LBB200_4
; RV32I-NEXT: .LBB200_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB200_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV32I-NEXT: slt a0, s0, a1
+; RV32I-NEXT: j .LBB200_4
+; RV32I-NEXT: .LBB200_3: # in Loop: Header=BB200_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB200_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB200_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB200_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB200_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB200_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB200_4
-; RV32I-NEXT: .LBB200_3: # %atomicrmw.start
-; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB200_5
-; RV32I-NEXT: .LBB200_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB200_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB200_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB200_1
-; RV32I-NEXT: .LBB200_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB200_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB200_3
-; RV32IA-NEXT: j .LBB200_4
; RV32IA-NEXT: .LBB200_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB200_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV32IA-NEXT: slt a0, s0, a1
+; RV32IA-NEXT: j .LBB200_4
+; RV32IA-NEXT: .LBB200_3: # in Loop: Header=BB200_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB200_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB200_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB200_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB200_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB200_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB200_4
-; RV32IA-NEXT: .LBB200_3: # %atomicrmw.start
-; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB200_5
-; RV32IA-NEXT: .LBB200_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB200_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB200_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB200_1
-; RV32IA-NEXT: .LBB200_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB200_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB200_3
; RV64I-NEXT: .LBB200_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: blt s0, a2, .LBB200_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB200_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB200_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB200_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: mv a3, zero
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB200_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB200_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB200_1
-; RV64I-NEXT: .LBB200_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB200_1
-; RV64I-NEXT: .LBB200_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB200_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB201_3
-; RV32I-NEXT: j .LBB201_4
; RV32I-NEXT: .LBB201_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB201_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV32I-NEXT: slt a0, s0, a1
+; RV32I-NEXT: j .LBB201_4
+; RV32I-NEXT: .LBB201_3: # in Loop: Header=BB201_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB201_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB201_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB201_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB201_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB201_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB201_4
-; RV32I-NEXT: .LBB201_3: # %atomicrmw.start
-; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB201_5
-; RV32I-NEXT: .LBB201_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB201_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB201_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB201_1
-; RV32I-NEXT: .LBB201_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB201_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB201_3
-; RV32IA-NEXT: j .LBB201_4
; RV32IA-NEXT: .LBB201_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB201_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV32IA-NEXT: slt a0, s0, a1
+; RV32IA-NEXT: j .LBB201_4
+; RV32IA-NEXT: .LBB201_3: # in Loop: Header=BB201_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB201_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB201_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB201_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB201_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB201_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB201_4
-; RV32IA-NEXT: .LBB201_3: # %atomicrmw.start
-; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB201_5
-; RV32IA-NEXT: .LBB201_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB201_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB201_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB201_1
-; RV32IA-NEXT: .LBB201_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB201_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB201_3
; RV64I-NEXT: .LBB201_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: blt s0, a2, .LBB201_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB201_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB201_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB201_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 2
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB201_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB201_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB201_1
-; RV64I-NEXT: .LBB201_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB201_1
-; RV64I-NEXT: .LBB201_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB201_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB202_3
-; RV32I-NEXT: j .LBB202_4
; RV32I-NEXT: .LBB202_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB202_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV32I-NEXT: slt a0, s0, a1
+; RV32I-NEXT: j .LBB202_4
+; RV32I-NEXT: .LBB202_3: # in Loop: Header=BB202_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB202_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB202_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB202_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB202_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB202_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB202_4
-; RV32I-NEXT: .LBB202_3: # %atomicrmw.start
-; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB202_5
-; RV32I-NEXT: .LBB202_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB202_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB202_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB202_1
-; RV32I-NEXT: .LBB202_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB202_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB202_3
-; RV32IA-NEXT: j .LBB202_4
; RV32IA-NEXT: .LBB202_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB202_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV32IA-NEXT: slt a0, s0, a1
+; RV32IA-NEXT: j .LBB202_4
+; RV32IA-NEXT: .LBB202_3: # in Loop: Header=BB202_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB202_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB202_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB202_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB202_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB202_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB202_4
-; RV32IA-NEXT: .LBB202_3: # %atomicrmw.start
-; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB202_5
-; RV32IA-NEXT: .LBB202_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB202_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB202_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB202_1
-; RV32IA-NEXT: .LBB202_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB202_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB202_3
; RV64I-NEXT: .LBB202_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: blt s0, a2, .LBB202_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB202_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB202_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB202_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 3
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB202_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB202_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB202_1
-; RV64I-NEXT: .LBB202_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB202_1
-; RV64I-NEXT: .LBB202_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB202_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB203_3
-; RV32I-NEXT: j .LBB203_4
; RV32I-NEXT: .LBB203_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB203_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV32I-NEXT: slt a0, s0, a1
+; RV32I-NEXT: j .LBB203_4
+; RV32I-NEXT: .LBB203_3: # in Loop: Header=BB203_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB203_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB203_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB203_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB203_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB203_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB203_4
-; RV32I-NEXT: .LBB203_3: # %atomicrmw.start
-; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB203_5
-; RV32I-NEXT: .LBB203_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB203_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB203_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB203_1
-; RV32I-NEXT: .LBB203_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB203_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB203_3
-; RV32IA-NEXT: j .LBB203_4
; RV32IA-NEXT: .LBB203_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB203_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV32IA-NEXT: slt a0, s0, a1
+; RV32IA-NEXT: j .LBB203_4
+; RV32IA-NEXT: .LBB203_3: # in Loop: Header=BB203_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB203_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB203_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB203_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB203_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB203_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB203_4
-; RV32IA-NEXT: .LBB203_3: # %atomicrmw.start
-; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB203_5
-; RV32IA-NEXT: .LBB203_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB203_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB203_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB203_1
-; RV32IA-NEXT: .LBB203_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB203_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB203_3
; RV64I-NEXT: .LBB203_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: blt s0, a2, .LBB203_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB203_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB203_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB203_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 4
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB203_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB203_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB203_1
-; RV64I-NEXT: .LBB203_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB203_1
-; RV64I-NEXT: .LBB203_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB203_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB204_3
-; RV32I-NEXT: j .LBB204_4
; RV32I-NEXT: .LBB204_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB204_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV32I-NEXT: slt a0, s0, a1
+; RV32I-NEXT: j .LBB204_4
+; RV32I-NEXT: .LBB204_3: # in Loop: Header=BB204_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB204_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB204_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB204_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB204_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB204_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB204_4
-; RV32I-NEXT: .LBB204_3: # %atomicrmw.start
-; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB204_5
-; RV32I-NEXT: .LBB204_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB204_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB204_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB204_1
-; RV32I-NEXT: .LBB204_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB204_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB204_3
-; RV32IA-NEXT: j .LBB204_4
; RV32IA-NEXT: .LBB204_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB204_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV32IA-NEXT: slt a0, s0, a1
+; RV32IA-NEXT: j .LBB204_4
+; RV32IA-NEXT: .LBB204_3: # in Loop: Header=BB204_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB204_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB204_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB204_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB204_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB204_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB204_4
-; RV32IA-NEXT: .LBB204_3: # %atomicrmw.start
-; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB204_5
-; RV32IA-NEXT: .LBB204_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB204_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB204_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB204_1
-; RV32IA-NEXT: .LBB204_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB204_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB204_3
; RV64I-NEXT: .LBB204_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: blt s0, a2, .LBB204_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB204_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB204_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB204_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 5
; RV64I-NEXT: addi a4, zero, 5
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB204_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB204_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB204_1
-; RV64I-NEXT: .LBB204_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB204_1
-; RV64I-NEXT: .LBB204_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB204_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB205_3
-; RV32I-NEXT: j .LBB205_4
; RV32I-NEXT: .LBB205_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: mv a4, zero
-; RV32I-NEXT: mv a5, zero
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB205_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB205_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB205_4
-; RV32I-NEXT: .LBB205_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB205_5
-; RV32I-NEXT: .LBB205_4:
+; RV32I-NEXT: j .LBB205_4
+; RV32I-NEXT: .LBB205_3: # in Loop: Header=BB205_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB205_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB205_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB205_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB205_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB205_1
-; RV32I-NEXT: .LBB205_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB205_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB205_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: mv a4, zero
+; RV32I-NEXT: mv a5, zero
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB205_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB205_3
-; RV32IA-NEXT: j .LBB205_4
; RV32IA-NEXT: .LBB205_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: mv a4, zero
-; RV32IA-NEXT: mv a5, zero
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB205_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB205_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB205_4
-; RV32IA-NEXT: .LBB205_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB205_5
-; RV32IA-NEXT: .LBB205_4:
+; RV32IA-NEXT: j .LBB205_4
+; RV32IA-NEXT: .LBB205_3: # in Loop: Header=BB205_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB205_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB205_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB205_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB205_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB205_1
-; RV32IA-NEXT: .LBB205_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB205_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB205_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: mv a4, zero
+; RV32IA-NEXT: mv a5, zero
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB205_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB205_3
; RV64I-NEXT: .LBB205_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bge s0, a2, .LBB205_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB205_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB205_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB205_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: mv a3, zero
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB205_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB205_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB205_1
-; RV64I-NEXT: .LBB205_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB205_1
-; RV64I-NEXT: .LBB205_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB205_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB206_3
-; RV32I-NEXT: j .LBB206_4
; RV32I-NEXT: .LBB206_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 2
-; RV32I-NEXT: addi a5, zero, 2
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB206_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB206_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB206_4
-; RV32I-NEXT: .LBB206_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB206_5
-; RV32I-NEXT: .LBB206_4:
+; RV32I-NEXT: j .LBB206_4
+; RV32I-NEXT: .LBB206_3: # in Loop: Header=BB206_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB206_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB206_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB206_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB206_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB206_1
-; RV32I-NEXT: .LBB206_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB206_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB206_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 2
+; RV32I-NEXT: addi a5, zero, 2
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB206_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB206_3
-; RV32IA-NEXT: j .LBB206_4
; RV32IA-NEXT: .LBB206_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 2
-; RV32IA-NEXT: addi a5, zero, 2
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB206_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB206_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB206_4
-; RV32IA-NEXT: .LBB206_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB206_5
-; RV32IA-NEXT: .LBB206_4:
+; RV32IA-NEXT: j .LBB206_4
+; RV32IA-NEXT: .LBB206_3: # in Loop: Header=BB206_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB206_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB206_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB206_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB206_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB206_1
-; RV32IA-NEXT: .LBB206_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB206_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB206_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 2
+; RV32IA-NEXT: addi a5, zero, 2
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB206_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB206_3
; RV64I-NEXT: .LBB206_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bge s0, a2, .LBB206_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB206_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB206_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB206_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 2
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB206_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB206_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB206_1
-; RV64I-NEXT: .LBB206_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB206_1
-; RV64I-NEXT: .LBB206_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB206_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB207_3
-; RV32I-NEXT: j .LBB207_4
; RV32I-NEXT: .LBB207_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 3
-; RV32I-NEXT: mv a5, zero
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB207_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB207_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB207_4
-; RV32I-NEXT: .LBB207_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB207_5
-; RV32I-NEXT: .LBB207_4:
+; RV32I-NEXT: j .LBB207_4
+; RV32I-NEXT: .LBB207_3: # in Loop: Header=BB207_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB207_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB207_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB207_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB207_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB207_1
-; RV32I-NEXT: .LBB207_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB207_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB207_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 3
+; RV32I-NEXT: mv a5, zero
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB207_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB207_3
-; RV32IA-NEXT: j .LBB207_4
; RV32IA-NEXT: .LBB207_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 3
-; RV32IA-NEXT: mv a5, zero
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB207_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB207_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB207_4
-; RV32IA-NEXT: .LBB207_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB207_5
-; RV32IA-NEXT: .LBB207_4:
+; RV32IA-NEXT: j .LBB207_4
+; RV32IA-NEXT: .LBB207_3: # in Loop: Header=BB207_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB207_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB207_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB207_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB207_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB207_1
-; RV32IA-NEXT: .LBB207_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB207_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB207_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 3
+; RV32IA-NEXT: mv a5, zero
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB207_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB207_3
; RV64I-NEXT: .LBB207_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bge s0, a2, .LBB207_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB207_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB207_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB207_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 3
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB207_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB207_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB207_1
-; RV64I-NEXT: .LBB207_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB207_1
-; RV64I-NEXT: .LBB207_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB207_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB208_3
-; RV32I-NEXT: j .LBB208_4
; RV32I-NEXT: .LBB208_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 4
-; RV32I-NEXT: addi a5, zero, 2
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB208_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB208_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB208_4
-; RV32I-NEXT: .LBB208_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB208_5
-; RV32I-NEXT: .LBB208_4:
+; RV32I-NEXT: j .LBB208_4
+; RV32I-NEXT: .LBB208_3: # in Loop: Header=BB208_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB208_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB208_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB208_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB208_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB208_1
-; RV32I-NEXT: .LBB208_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB208_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB208_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 4
+; RV32I-NEXT: addi a5, zero, 2
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB208_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB208_3
-; RV32IA-NEXT: j .LBB208_4
; RV32IA-NEXT: .LBB208_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 4
-; RV32IA-NEXT: addi a5, zero, 2
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB208_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB208_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB208_4
-; RV32IA-NEXT: .LBB208_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB208_5
-; RV32IA-NEXT: .LBB208_4:
+; RV32IA-NEXT: j .LBB208_4
+; RV32IA-NEXT: .LBB208_3: # in Loop: Header=BB208_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB208_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB208_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB208_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB208_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB208_1
-; RV32IA-NEXT: .LBB208_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB208_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB208_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 4
+; RV32IA-NEXT: addi a5, zero, 2
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB208_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB208_3
; RV64I-NEXT: .LBB208_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bge s0, a2, .LBB208_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB208_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB208_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB208_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 4
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB208_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB208_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB208_1
-; RV64I-NEXT: .LBB208_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB208_1
-; RV64I-NEXT: .LBB208_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB208_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB209_3
-; RV32I-NEXT: j .LBB209_4
; RV32I-NEXT: .LBB209_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 5
-; RV32I-NEXT: addi a5, zero, 5
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB209_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB209_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB209_4
-; RV32I-NEXT: .LBB209_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV32I-NEXT: slt a0, s0, a1
-; RV32I-NEXT: j .LBB209_5
-; RV32I-NEXT: .LBB209_4:
+; RV32I-NEXT: j .LBB209_4
+; RV32I-NEXT: .LBB209_3: # in Loop: Header=BB209_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB209_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB209_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB209_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB209_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB209_1
-; RV32I-NEXT: .LBB209_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB209_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB209_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 5
+; RV32I-NEXT: addi a5, zero, 5
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB209_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB209_3
-; RV32IA-NEXT: j .LBB209_4
; RV32IA-NEXT: .LBB209_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 5
-; RV32IA-NEXT: addi a5, zero, 5
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB209_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB209_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB209_4
-; RV32IA-NEXT: .LBB209_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV32IA-NEXT: slt a0, s0, a1
-; RV32IA-NEXT: j .LBB209_5
-; RV32IA-NEXT: .LBB209_4:
+; RV32IA-NEXT: j .LBB209_4
+; RV32IA-NEXT: .LBB209_3: # in Loop: Header=BB209_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB209_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB209_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB209_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB209_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB209_1
-; RV32IA-NEXT: .LBB209_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB209_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB209_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 5
+; RV32IA-NEXT: addi a5, zero, 5
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB209_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: blt s0, a2, .LBB209_3
; RV64I-NEXT: .LBB209_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bge s0, a2, .LBB209_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB209_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB209_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB209_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 5
; RV64I-NEXT: addi a4, zero, 5
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB209_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB209_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bge s0, a2, .LBB209_1
-; RV64I-NEXT: .LBB209_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB209_1
-; RV64I-NEXT: .LBB209_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB209_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB210_3
-; RV32I-NEXT: j .LBB210_4
; RV32I-NEXT: .LBB210_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB210_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV32I-NEXT: sltu a0, s0, a1
+; RV32I-NEXT: j .LBB210_4
+; RV32I-NEXT: .LBB210_3: # in Loop: Header=BB210_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB210_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB210_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB210_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB210_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB210_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB210_4
-; RV32I-NEXT: .LBB210_3: # %atomicrmw.start
-; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB210_5
-; RV32I-NEXT: .LBB210_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB210_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB210_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB210_1
-; RV32I-NEXT: .LBB210_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB210_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB210_3
-; RV32IA-NEXT: j .LBB210_4
; RV32IA-NEXT: .LBB210_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB210_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV32IA-NEXT: sltu a0, s0, a1
+; RV32IA-NEXT: j .LBB210_4
+; RV32IA-NEXT: .LBB210_3: # in Loop: Header=BB210_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB210_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB210_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB210_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB210_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB210_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB210_4
-; RV32IA-NEXT: .LBB210_3: # %atomicrmw.start
-; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB210_5
-; RV32IA-NEXT: .LBB210_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB210_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB210_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB210_1
-; RV32IA-NEXT: .LBB210_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB210_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB210_3
; RV64I-NEXT: .LBB210_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bltu s0, a2, .LBB210_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB210_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB210_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB210_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: mv a3, zero
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB210_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB210_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB210_1
-; RV64I-NEXT: .LBB210_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB210_1
-; RV64I-NEXT: .LBB210_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB210_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB211_3
-; RV32I-NEXT: j .LBB211_4
; RV32I-NEXT: .LBB211_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB211_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV32I-NEXT: sltu a0, s0, a1
+; RV32I-NEXT: j .LBB211_4
+; RV32I-NEXT: .LBB211_3: # in Loop: Header=BB211_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB211_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB211_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB211_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB211_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB211_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB211_4
-; RV32I-NEXT: .LBB211_3: # %atomicrmw.start
-; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB211_5
-; RV32I-NEXT: .LBB211_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB211_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB211_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB211_1
-; RV32I-NEXT: .LBB211_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB211_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB211_3
-; RV32IA-NEXT: j .LBB211_4
; RV32IA-NEXT: .LBB211_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB211_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV32IA-NEXT: sltu a0, s0, a1
+; RV32IA-NEXT: j .LBB211_4
+; RV32IA-NEXT: .LBB211_3: # in Loop: Header=BB211_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB211_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB211_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB211_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB211_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB211_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB211_4
-; RV32IA-NEXT: .LBB211_3: # %atomicrmw.start
-; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB211_5
-; RV32IA-NEXT: .LBB211_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB211_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB211_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB211_1
-; RV32IA-NEXT: .LBB211_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB211_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB211_3
; RV64I-NEXT: .LBB211_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bltu s0, a2, .LBB211_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB211_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB211_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB211_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 2
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB211_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB211_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB211_1
-; RV64I-NEXT: .LBB211_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB211_1
-; RV64I-NEXT: .LBB211_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB211_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB212_3
-; RV32I-NEXT: j .LBB212_4
; RV32I-NEXT: .LBB212_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 3
-; RV32I-NEXT: mv a5, zero
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB212_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB212_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB212_4
-; RV32I-NEXT: .LBB212_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB212_1 Depth=1
; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB212_5
-; RV32I-NEXT: .LBB212_4:
+; RV32I-NEXT: j .LBB212_4
+; RV32I-NEXT: .LBB212_3: # in Loop: Header=BB212_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB212_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB212_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB212_1 Depth=1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB212_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB212_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB212_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB212_1
-; RV32I-NEXT: .LBB212_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB212_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB212_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 3
+; RV32I-NEXT: mv a5, zero
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB212_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB212_3
-; RV32IA-NEXT: j .LBB212_4
; RV32IA-NEXT: .LBB212_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB212_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB212_1 Depth=1
+; RV32IA-NEXT: sltu a0, s0, a1
+; RV32IA-NEXT: j .LBB212_4
+; RV32IA-NEXT: .LBB212_3: # in Loop: Header=BB212_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB212_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB212_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB212_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB212_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB212_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB212_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB212_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB212_4
-; RV32IA-NEXT: .LBB212_3: # %atomicrmw.start
-; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB212_5
-; RV32IA-NEXT: .LBB212_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB212_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB212_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB212_1
-; RV32IA-NEXT: .LBB212_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB212_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB212_3
; RV64I-NEXT: .LBB212_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bltu s0, a2, .LBB212_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB212_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB212_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB212_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 3
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB212_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB212_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB212_1
-; RV64I-NEXT: .LBB212_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB212_1
-; RV64I-NEXT: .LBB212_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB212_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB213_3
-; RV32I-NEXT: j .LBB213_4
; RV32I-NEXT: .LBB213_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB213_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV32I-NEXT: sltu a0, s0, a1
+; RV32I-NEXT: j .LBB213_4
+; RV32I-NEXT: .LBB213_3: # in Loop: Header=BB213_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB213_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB213_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB213_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB213_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB213_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB213_4
-; RV32I-NEXT: .LBB213_3: # %atomicrmw.start
-; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB213_5
-; RV32I-NEXT: .LBB213_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB213_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB213_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB213_1
-; RV32I-NEXT: .LBB213_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB213_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB213_3
-; RV32IA-NEXT: j .LBB213_4
; RV32IA-NEXT: .LBB213_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB213_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV32IA-NEXT: sltu a0, s0, a1
+; RV32IA-NEXT: j .LBB213_4
+; RV32IA-NEXT: .LBB213_3: # in Loop: Header=BB213_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB213_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB213_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB213_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB213_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB213_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB213_4
-; RV32IA-NEXT: .LBB213_3: # %atomicrmw.start
-; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB213_5
-; RV32IA-NEXT: .LBB213_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB213_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB213_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB213_1
-; RV32IA-NEXT: .LBB213_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB213_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB213_3
; RV64I-NEXT: .LBB213_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bltu s0, a2, .LBB213_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB213_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB213_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB213_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 4
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB213_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB213_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB213_1
-; RV64I-NEXT: .LBB213_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB213_1
-; RV64I-NEXT: .LBB213_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB213_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB214_3
-; RV32I-NEXT: j .LBB214_4
; RV32I-NEXT: .LBB214_1: # %atomicrmw.start
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB214_3
+; RV32I-NEXT: # %bb.2: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV32I-NEXT: sltu a0, s0, a1
+; RV32I-NEXT: j .LBB214_4
+; RV32I-NEXT: .LBB214_3: # in Loop: Header=BB214_1 Depth=1
+; RV32I-NEXT: sltu a0, s2, a2
+; RV32I-NEXT: .LBB214_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV32I-NEXT: sw a2, 0(sp)
+; RV32I-NEXT: mv a3, a1
+; RV32I-NEXT: bnez a0, .LBB214_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV32I-NEXT: mv a2, s2
+; RV32I-NEXT: mv a3, s0
+; RV32I-NEXT: .LBB214_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB214_1 Depth=1
; RV32I-NEXT: sw a1, 4(sp)
; RV32I-NEXT: mv a0, s1
; RV32I-NEXT: mv a1, s3
; RV32I-NEXT: call __atomic_compare_exchange_8
; RV32I-NEXT: lw a1, 4(sp)
; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB214_7
-; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB214_4
-; RV32I-NEXT: .LBB214_3: # %atomicrmw.start
-; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB214_5
-; RV32I-NEXT: .LBB214_4:
-; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB214_5: # %atomicrmw.start
-; RV32I-NEXT: sw a2, 0(sp)
-; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB214_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
-; RV32I-NEXT: mv a2, s2
-; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB214_1
-; RV32I-NEXT: .LBB214_7: # %atomicrmw.end
+; RV32I-NEXT: beqz a0, .LBB214_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB214_3
-; RV32IA-NEXT: j .LBB214_4
; RV32IA-NEXT: .LBB214_1: # %atomicrmw.start
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB214_3
+; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV32IA-NEXT: sltu a0, s0, a1
+; RV32IA-NEXT: j .LBB214_4
+; RV32IA-NEXT: .LBB214_3: # in Loop: Header=BB214_1 Depth=1
+; RV32IA-NEXT: sltu a0, s2, a2
+; RV32IA-NEXT: .LBB214_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV32IA-NEXT: sw a2, 0(sp)
+; RV32IA-NEXT: mv a3, a1
+; RV32IA-NEXT: bnez a0, .LBB214_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV32IA-NEXT: mv a2, s2
+; RV32IA-NEXT: mv a3, s0
+; RV32IA-NEXT: .LBB214_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB214_1 Depth=1
; RV32IA-NEXT: sw a1, 4(sp)
; RV32IA-NEXT: mv a0, s1
; RV32IA-NEXT: mv a1, s3
; RV32IA-NEXT: call __atomic_compare_exchange_8
; RV32IA-NEXT: lw a1, 4(sp)
; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB214_7
-; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB214_4
-; RV32IA-NEXT: .LBB214_3: # %atomicrmw.start
-; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB214_5
-; RV32IA-NEXT: .LBB214_4:
-; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB214_5: # %atomicrmw.start
-; RV32IA-NEXT: sw a2, 0(sp)
-; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB214_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
-; RV32IA-NEXT: mv a2, s2
-; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB214_1
-; RV32IA-NEXT: .LBB214_7: # %atomicrmw.end
+; RV32IA-NEXT: beqz a0, .LBB214_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB214_3
; RV64I-NEXT: .LBB214_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bltu s0, a2, .LBB214_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB214_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB214_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB214_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 5
; RV64I-NEXT: addi a4, zero, 5
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB214_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB214_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB214_1
-; RV64I-NEXT: .LBB214_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB214_1
-; RV64I-NEXT: .LBB214_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB214_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB215_3
-; RV32I-NEXT: j .LBB215_4
; RV32I-NEXT: .LBB215_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: mv a4, zero
-; RV32I-NEXT: mv a5, zero
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB215_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB215_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB215_4
-; RV32I-NEXT: .LBB215_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB215_5
-; RV32I-NEXT: .LBB215_4:
+; RV32I-NEXT: j .LBB215_4
+; RV32I-NEXT: .LBB215_3: # in Loop: Header=BB215_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB215_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB215_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB215_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB215_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB215_1
-; RV32I-NEXT: .LBB215_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB215_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB215_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: mv a4, zero
+; RV32I-NEXT: mv a5, zero
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB215_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB215_3
-; RV32IA-NEXT: j .LBB215_4
; RV32IA-NEXT: .LBB215_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: mv a4, zero
-; RV32IA-NEXT: mv a5, zero
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB215_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB215_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB215_4
-; RV32IA-NEXT: .LBB215_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB215_5
-; RV32IA-NEXT: .LBB215_4:
+; RV32IA-NEXT: j .LBB215_4
+; RV32IA-NEXT: .LBB215_3: # in Loop: Header=BB215_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB215_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB215_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB215_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB215_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB215_1
-; RV32IA-NEXT: .LBB215_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB215_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB215_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: mv a4, zero
+; RV32IA-NEXT: mv a5, zero
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB215_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB215_3
; RV64I-NEXT: .LBB215_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bgeu s0, a2, .LBB215_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB215_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB215_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB215_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: mv a3, zero
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB215_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB215_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB215_1
-; RV64I-NEXT: .LBB215_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB215_1
-; RV64I-NEXT: .LBB215_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB215_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB216_3
-; RV32I-NEXT: j .LBB216_4
; RV32I-NEXT: .LBB216_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 2
-; RV32I-NEXT: addi a5, zero, 2
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB216_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB216_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB216_4
-; RV32I-NEXT: .LBB216_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB216_5
-; RV32I-NEXT: .LBB216_4:
+; RV32I-NEXT: j .LBB216_4
+; RV32I-NEXT: .LBB216_3: # in Loop: Header=BB216_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB216_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB216_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB216_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB216_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB216_1
-; RV32I-NEXT: .LBB216_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB216_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB216_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 2
+; RV32I-NEXT: addi a5, zero, 2
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB216_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB216_3
-; RV32IA-NEXT: j .LBB216_4
; RV32IA-NEXT: .LBB216_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 2
-; RV32IA-NEXT: addi a5, zero, 2
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB216_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB216_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB216_4
-; RV32IA-NEXT: .LBB216_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB216_5
-; RV32IA-NEXT: .LBB216_4:
+; RV32IA-NEXT: j .LBB216_4
+; RV32IA-NEXT: .LBB216_3: # in Loop: Header=BB216_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB216_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB216_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB216_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB216_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB216_1
-; RV32IA-NEXT: .LBB216_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB216_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB216_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 2
+; RV32IA-NEXT: addi a5, zero, 2
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB216_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB216_3
; RV64I-NEXT: .LBB216_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bgeu s0, a2, .LBB216_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB216_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB216_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB216_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 2
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB216_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB216_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB216_1
-; RV64I-NEXT: .LBB216_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB216_1
-; RV64I-NEXT: .LBB216_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB216_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB217_3
-; RV32I-NEXT: j .LBB217_4
; RV32I-NEXT: .LBB217_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 3
-; RV32I-NEXT: mv a5, zero
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB217_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB217_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB217_4
-; RV32I-NEXT: .LBB217_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB217_5
-; RV32I-NEXT: .LBB217_4:
+; RV32I-NEXT: j .LBB217_4
+; RV32I-NEXT: .LBB217_3: # in Loop: Header=BB217_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB217_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB217_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB217_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB217_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB217_1
-; RV32I-NEXT: .LBB217_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB217_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB217_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 3
+; RV32I-NEXT: mv a5, zero
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB217_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB217_3
-; RV32IA-NEXT: j .LBB217_4
; RV32IA-NEXT: .LBB217_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 3
-; RV32IA-NEXT: mv a5, zero
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB217_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB217_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB217_4
-; RV32IA-NEXT: .LBB217_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB217_5
-; RV32IA-NEXT: .LBB217_4:
+; RV32IA-NEXT: j .LBB217_4
+; RV32IA-NEXT: .LBB217_3: # in Loop: Header=BB217_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB217_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB217_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB217_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB217_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB217_1
-; RV32IA-NEXT: .LBB217_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB217_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB217_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 3
+; RV32IA-NEXT: mv a5, zero
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB217_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB217_3
; RV64I-NEXT: .LBB217_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bgeu s0, a2, .LBB217_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB217_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB217_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB217_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 3
; RV64I-NEXT: mv a4, zero
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB217_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB217_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB217_1
-; RV64I-NEXT: .LBB217_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB217_1
-; RV64I-NEXT: .LBB217_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB217_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB218_3
-; RV32I-NEXT: j .LBB218_4
; RV32I-NEXT: .LBB218_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 4
-; RV32I-NEXT: addi a5, zero, 2
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB218_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB218_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB218_4
-; RV32I-NEXT: .LBB218_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB218_5
-; RV32I-NEXT: .LBB218_4:
+; RV32I-NEXT: j .LBB218_4
+; RV32I-NEXT: .LBB218_3: # in Loop: Header=BB218_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB218_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB218_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB218_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB218_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB218_1
-; RV32I-NEXT: .LBB218_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB218_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB218_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 4
+; RV32I-NEXT: addi a5, zero, 2
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB218_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB218_3
-; RV32IA-NEXT: j .LBB218_4
; RV32IA-NEXT: .LBB218_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 4
-; RV32IA-NEXT: addi a5, zero, 2
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB218_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB218_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB218_4
-; RV32IA-NEXT: .LBB218_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB218_5
-; RV32IA-NEXT: .LBB218_4:
+; RV32IA-NEXT: j .LBB218_4
+; RV32IA-NEXT: .LBB218_3: # in Loop: Header=BB218_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB218_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB218_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB218_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB218_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB218_1
-; RV32IA-NEXT: .LBB218_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB218_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB218_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 4
+; RV32IA-NEXT: addi a5, zero, 2
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB218_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB218_3
; RV64I-NEXT: .LBB218_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bgeu s0, a2, .LBB218_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB218_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB218_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB218_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 4
; RV64I-NEXT: addi a4, zero, 2
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB218_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB218_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB218_1
-; RV64I-NEXT: .LBB218_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB218_1
-; RV64I-NEXT: .LBB218_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB218_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)
; RV32I-NEXT: lw a1, 4(a0)
; RV32I-NEXT: lw a2, 0(a0)
; RV32I-NEXT: mv s3, sp
-; RV32I-NEXT: bne a1, s0, .LBB219_3
-; RV32I-NEXT: j .LBB219_4
; RV32I-NEXT: .LBB219_1: # %atomicrmw.start
-; RV32I-NEXT: sw a1, 4(sp)
-; RV32I-NEXT: mv a0, s1
-; RV32I-NEXT: mv a1, s3
-; RV32I-NEXT: addi a4, zero, 5
-; RV32I-NEXT: addi a5, zero, 5
-; RV32I-NEXT: call __atomic_compare_exchange_8
-; RV32I-NEXT: lw a1, 4(sp)
-; RV32I-NEXT: lw a2, 0(sp)
-; RV32I-NEXT: bnez a0, .LBB219_7
+; RV32I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32I-NEXT: beq a1, s0, .LBB219_3
; RV32I-NEXT: # %bb.2: # %atomicrmw.start
-; RV32I-NEXT: beq a1, s0, .LBB219_4
-; RV32I-NEXT: .LBB219_3: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV32I-NEXT: sltu a0, s0, a1
-; RV32I-NEXT: j .LBB219_5
-; RV32I-NEXT: .LBB219_4:
+; RV32I-NEXT: j .LBB219_4
+; RV32I-NEXT: .LBB219_3: # in Loop: Header=BB219_1 Depth=1
; RV32I-NEXT: sltu a0, s2, a2
-; RV32I-NEXT: .LBB219_5: # %atomicrmw.start
+; RV32I-NEXT: .LBB219_4: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV32I-NEXT: xori a0, a0, 1
; RV32I-NEXT: sw a2, 0(sp)
; RV32I-NEXT: mv a3, a1
-; RV32I-NEXT: bnez a0, .LBB219_1
-; RV32I-NEXT: # %bb.6: # %atomicrmw.start
+; RV32I-NEXT: bnez a0, .LBB219_6
+; RV32I-NEXT: # %bb.5: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV32I-NEXT: mv a2, s2
; RV32I-NEXT: mv a3, s0
-; RV32I-NEXT: j .LBB219_1
-; RV32I-NEXT: .LBB219_7: # %atomicrmw.end
+; RV32I-NEXT: .LBB219_6: # %atomicrmw.start
+; RV32I-NEXT: # in Loop: Header=BB219_1 Depth=1
+; RV32I-NEXT: sw a1, 4(sp)
+; RV32I-NEXT: mv a0, s1
+; RV32I-NEXT: mv a1, s3
+; RV32I-NEXT: addi a4, zero, 5
+; RV32I-NEXT: addi a5, zero, 5
+; RV32I-NEXT: call __atomic_compare_exchange_8
+; RV32I-NEXT: lw a1, 4(sp)
+; RV32I-NEXT: lw a2, 0(sp)
+; RV32I-NEXT: beqz a0, .LBB219_1
+; RV32I-NEXT: # %bb.7: # %atomicrmw.end
; RV32I-NEXT: mv a0, a2
; RV32I-NEXT: lw s3, 12(sp)
; RV32I-NEXT: lw s2, 16(sp)
; RV32IA-NEXT: lw a1, 4(a0)
; RV32IA-NEXT: lw a2, 0(a0)
; RV32IA-NEXT: mv s3, sp
-; RV32IA-NEXT: bne a1, s0, .LBB219_3
-; RV32IA-NEXT: j .LBB219_4
; RV32IA-NEXT: .LBB219_1: # %atomicrmw.start
-; RV32IA-NEXT: sw a1, 4(sp)
-; RV32IA-NEXT: mv a0, s1
-; RV32IA-NEXT: mv a1, s3
-; RV32IA-NEXT: addi a4, zero, 5
-; RV32IA-NEXT: addi a5, zero, 5
-; RV32IA-NEXT: call __atomic_compare_exchange_8
-; RV32IA-NEXT: lw a1, 4(sp)
-; RV32IA-NEXT: lw a2, 0(sp)
-; RV32IA-NEXT: bnez a0, .LBB219_7
+; RV32IA-NEXT: # =>This Inner Loop Header: Depth=1
+; RV32IA-NEXT: beq a1, s0, .LBB219_3
; RV32IA-NEXT: # %bb.2: # %atomicrmw.start
-; RV32IA-NEXT: beq a1, s0, .LBB219_4
-; RV32IA-NEXT: .LBB219_3: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV32IA-NEXT: sltu a0, s0, a1
-; RV32IA-NEXT: j .LBB219_5
-; RV32IA-NEXT: .LBB219_4:
+; RV32IA-NEXT: j .LBB219_4
+; RV32IA-NEXT: .LBB219_3: # in Loop: Header=BB219_1 Depth=1
; RV32IA-NEXT: sltu a0, s2, a2
-; RV32IA-NEXT: .LBB219_5: # %atomicrmw.start
+; RV32IA-NEXT: .LBB219_4: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV32IA-NEXT: xori a0, a0, 1
; RV32IA-NEXT: sw a2, 0(sp)
; RV32IA-NEXT: mv a3, a1
-; RV32IA-NEXT: bnez a0, .LBB219_1
-; RV32IA-NEXT: # %bb.6: # %atomicrmw.start
+; RV32IA-NEXT: bnez a0, .LBB219_6
+; RV32IA-NEXT: # %bb.5: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV32IA-NEXT: mv a2, s2
; RV32IA-NEXT: mv a3, s0
-; RV32IA-NEXT: j .LBB219_1
-; RV32IA-NEXT: .LBB219_7: # %atomicrmw.end
+; RV32IA-NEXT: .LBB219_6: # %atomicrmw.start
+; RV32IA-NEXT: # in Loop: Header=BB219_1 Depth=1
+; RV32IA-NEXT: sw a1, 4(sp)
+; RV32IA-NEXT: mv a0, s1
+; RV32IA-NEXT: mv a1, s3
+; RV32IA-NEXT: addi a4, zero, 5
+; RV32IA-NEXT: addi a5, zero, 5
+; RV32IA-NEXT: call __atomic_compare_exchange_8
+; RV32IA-NEXT: lw a1, 4(sp)
+; RV32IA-NEXT: lw a2, 0(sp)
+; RV32IA-NEXT: beqz a0, .LBB219_1
+; RV32IA-NEXT: # %bb.7: # %atomicrmw.end
; RV32IA-NEXT: mv a0, a2
; RV32IA-NEXT: lw s3, 12(sp)
; RV32IA-NEXT: lw s2, 16(sp)
; RV64I-NEXT: mv s1, a0
; RV64I-NEXT: ld a2, 0(a0)
; RV64I-NEXT: addi s2, sp, 8
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bltu s0, a2, .LBB219_3
; RV64I-NEXT: .LBB219_1: # %atomicrmw.start
; RV64I-NEXT: # =>This Inner Loop Header: Depth=1
+; RV64I-NEXT: sd a2, 8(sp)
+; RV64I-NEXT: bgeu s0, a2, .LBB219_3
+; RV64I-NEXT: # %bb.2: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB219_1 Depth=1
+; RV64I-NEXT: mv a2, s0
+; RV64I-NEXT: .LBB219_3: # %atomicrmw.start
+; RV64I-NEXT: # in Loop: Header=BB219_1 Depth=1
; RV64I-NEXT: mv a0, s1
; RV64I-NEXT: mv a1, s2
; RV64I-NEXT: addi a3, zero, 5
; RV64I-NEXT: addi a4, zero, 5
; RV64I-NEXT: call __atomic_compare_exchange_8
; RV64I-NEXT: ld a2, 8(sp)
-; RV64I-NEXT: bnez a0, .LBB219_4
-; RV64I-NEXT: # %bb.2: # %atomicrmw.start
-; RV64I-NEXT: # in Loop: Header=BB219_1 Depth=1
-; RV64I-NEXT: sd a2, 8(sp)
-; RV64I-NEXT: bgeu s0, a2, .LBB219_1
-; RV64I-NEXT: .LBB219_3: # %atomicrmw.start
-; RV64I-NEXT: mv a2, s0
-; RV64I-NEXT: j .LBB219_1
-; RV64I-NEXT: .LBB219_4: # %atomicrmw.end
+; RV64I-NEXT: beqz a0, .LBB219_1
+; RV64I-NEXT: # %bb.4: # %atomicrmw.end
; RV64I-NEXT: mv a0, a2
; RV64I-NEXT: ld s2, 16(sp)
; RV64I-NEXT: ld s1, 24(sp)