@@ -268,8 +268,8 @@ define void @test7(i1 %a, i1 %b) {
268
268
; CHECK-LABEL: @test7(
269
269
; CHECK-NEXT: entry:
270
270
; CHECK-NEXT: [[C:%.*]] = or i1 [[B:%.*]], false
271
- ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[A:%.*]], i1 true, i1 [[C]]
272
- ; CHECK-NEXT: br i1 [[BRMERGE]], label [[Y:%.*]], label [[Z:%.*]], !prof [[PROF6:![0-9]+ ]]
271
+ ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[A:%.*]], i1 true, i1 [[C]], !prof [[PROF6:![0-9]+]]
272
+ ; CHECK-NEXT: br i1 [[BRMERGE]], label [[Y:%.*]], label [[Z:%.*]], !prof [[PROF6]]
273
273
; CHECK: common.ret:
274
274
; CHECK-NEXT: ret void
275
275
; CHECK: Y:
@@ -557,9 +557,9 @@ return:
557
557
define i32 @SimplifyCondBranchToCondBranch (i1 %cmpa , i1 %cmpb ) {
558
558
; CHECK-LABEL: @SimplifyCondBranchToCondBranch(
559
559
; CHECK-NEXT: block1:
560
- ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[CMPA:%.*]], i1 true, i1 [[CMPB:%.*]]
561
- ; CHECK-NEXT: [[DOTMUX:%.*]] = select i1 [[CMPA]], i32 0, i32 2, !prof [[PROF13 :![0-9]+]]
562
- ; CHECK-NEXT: [[OUTVAL:%.*]] = select i1 [[BRMERGE]], i32 [[DOTMUX]], i32 1, !prof [[PROF14:![0-9]+ ]]
560
+ ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[CMPA:%.*]], i1 true, i1 [[CMPB:%.*]], !prof [[PROF13:![0-9]+]]
561
+ ; CHECK-NEXT: [[DOTMUX:%.*]] = select i1 [[CMPA]], i32 0, i32 2, !prof [[PROF14 :![0-9]+]]
562
+ ; CHECK-NEXT: [[OUTVAL:%.*]] = select i1 [[BRMERGE]], i32 [[DOTMUX]], i32 1, !prof [[PROF13 ]]
563
563
; CHECK-NEXT: ret i32 [[OUTVAL]]
564
564
;
565
565
block1:
@@ -584,9 +584,9 @@ define i32 @SimplifyCondBranchToCondBranchSwap(i1 %cmpa, i1 %cmpb) {
584
584
; CHECK-NEXT: block1:
585
585
; CHECK-NEXT: [[CMPA_NOT:%.*]] = xor i1 [[CMPA:%.*]], true
586
586
; CHECK-NEXT: [[CMPB_NOT:%.*]] = xor i1 [[CMPB:%.*]], true
587
- ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[CMPA_NOT]], i1 true, i1 [[CMPB_NOT]]
588
- ; CHECK-NEXT: [[DOTMUX:%.*]] = select i1 [[CMPA_NOT]], i32 0, i32 2, !prof [[PROF15 :![0-9]+]]
589
- ; CHECK-NEXT: [[OUTVAL:%.*]] = select i1 [[BRMERGE]], i32 [[DOTMUX]], i32 1, !prof [[PROF16:![0-9]+ ]]
587
+ ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[CMPA_NOT]], i1 true, i1 [[CMPB_NOT]], !prof [[PROF15:![0-9]+]]
588
+ ; CHECK-NEXT: [[DOTMUX:%.*]] = select i1 [[CMPA_NOT]], i32 0, i32 2, !prof [[PROF16 :![0-9]+]]
589
+ ; CHECK-NEXT: [[OUTVAL:%.*]] = select i1 [[BRMERGE]], i32 [[DOTMUX]], i32 1, !prof [[PROF15 ]]
590
590
; CHECK-NEXT: ret i32 [[OUTVAL]]
591
591
;
592
592
block1:
@@ -609,9 +609,9 @@ define i32 @SimplifyCondBranchToCondBranchSwapMissingWeight(i1 %cmpa, i1 %cmpb)
609
609
; CHECK-NEXT: block1:
610
610
; CHECK-NEXT: [[CMPA_NOT:%.*]] = xor i1 [[CMPA:%.*]], true
611
611
; CHECK-NEXT: [[CMPB_NOT:%.*]] = xor i1 [[CMPB:%.*]], true
612
- ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[CMPA_NOT]], i1 true, i1 [[CMPB_NOT]]
613
- ; CHECK-NEXT: [[DOTMUX:%.*]] = select i1 [[CMPA_NOT]], i32 0, i32 2, !prof [[PROF17 :![0-9]+]]
614
- ; CHECK-NEXT: [[OUTVAL:%.*]] = select i1 [[BRMERGE]], i32 [[DOTMUX]], i32 1, !prof [[PROF18:![0-9]+ ]]
612
+ ; CHECK-NEXT: [[BRMERGE:%.*]] = select i1 [[CMPA_NOT]], i1 true, i1 [[CMPB_NOT]], !prof [[PROF17:![0-9]+]]
613
+ ; CHECK-NEXT: [[DOTMUX:%.*]] = select i1 [[CMPA_NOT]], i32 0, i32 2, !prof [[PROF18 :![0-9]+]]
614
+ ; CHECK-NEXT: [[OUTVAL:%.*]] = select i1 [[BRMERGE]], i32 [[DOTMUX]], i32 1, !prof [[PROF17 ]]
615
615
; CHECK-NEXT: ret i32 [[OUTVAL]]
616
616
;
617
617
block1:
@@ -1114,12 +1114,12 @@ exit:
1114
1114
; CHECK: [[PROF10]] = !{!"branch_weights", i32 8, i32 33}
1115
1115
; CHECK: [[PROF11]] = !{!"branch_weights", i32 112017436, i32 -735157296}
1116
1116
; CHECK: [[PROF12]] = !{!"branch_weights", i32 3, i32 5}
1117
- ; CHECK: [[PROF13]] = !{!"branch_weights", i32 22 , i32 12 }
1118
- ; CHECK: [[PROF14]] = !{!"branch_weights", i32 34 , i32 21 }
1119
- ; CHECK: [[PROF15]] = !{!"branch_weights", i32 33 , i32 14 }
1120
- ; CHECK: [[PROF16]] = !{!"branch_weights", i32 47 , i32 8 }
1121
- ; CHECK: [[PROF17]] = !{!"branch_weights", i32 6 , i32 2}
1122
- ; CHECK: [[PROF18]] = !{!"branch_weights", i32 8 , i32 2}
1117
+ ; CHECK: [[PROF13]] = !{!"branch_weights", i32 34 , i32 21 }
1118
+ ; CHECK: [[PROF14]] = !{!"branch_weights", i32 22 , i32 12 }
1119
+ ; CHECK: [[PROF15]] = !{!"branch_weights", i32 47 , i32 8 }
1120
+ ; CHECK: [[PROF16]] = !{!"branch_weights", i32 33 , i32 14 }
1121
+ ; CHECK: [[PROF17]] = !{!"branch_weights", i32 8 , i32 2}
1122
+ ; CHECK: [[PROF18]] = !{!"branch_weights", i32 6 , i32 2}
1123
1123
; CHECK: [[PROF19]] = !{!"branch_weights", i32 99, i32 1}
1124
1124
; CHECK: [[PROF20]] = !{!"branch_weights", i32 1, i32 99}
1125
1125
; CHECK: [[PROF21]] = !{!"branch_weights", i32 199, i32 1}
0 commit comments