File tree Expand file tree Collapse file tree 4 files changed +23
-28
lines changed Expand file tree Collapse file tree 4 files changed +23
-28
lines changed Original file line number Diff line number Diff line change @@ -3572,7 +3572,7 @@ bool MachineBlockPlacement::runOnMachineFunction(MachineFunction &MF) {
3572
3572
if (UseExtTspForPerf || UseExtTspForSize) {
3573
3573
assert (
3574
3574
!(UseExtTspForPerf && UseExtTspForSize) &&
3575
- " UseExtTspForPerf and UseExtTspForSize can not be set simultaneosly " );
3575
+ " UseExtTspForPerf and UseExtTspForSize can not be set simultaneously " );
3576
3576
applyExtTsp (/* OptForSize=*/ UseExtTspForSize);
3577
3577
createCFGChainExtTsp ();
3578
3578
}
@@ -3745,11 +3745,6 @@ void MachineBlockPlacement::assignBlockOrder(
3745
3745
continue ;
3746
3746
MBB.updateTerminator (FTMBB);
3747
3747
}
3748
-
3749
- #ifndef NDEBUG
3750
- // Make sure we correctly constructed all branches.
3751
- F->verify (this , " After optimized block reordering" , &errs ());
3752
- #endif
3753
3748
}
3754
3749
3755
3750
void MachineBlockPlacement::createCFGChainExtTsp () {
Original file line number Diff line number Diff line change 1
1
;; See also llvm/unittests/Transforms/Utils/CodeLayoutTest.cpp
2
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -enable-ext-tsp-block-placement=1 < %s | FileCheck %s
2
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs - enable-ext-tsp-block-placement < %s | FileCheck %s
3
3
4
4
define void @func1a () {
5
5
; Test that the algorithm positions the most likely successor first
Original file line number Diff line number Diff line change 1
1
; REQUIRES: asserts
2
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -enable-ext-tsp-block-placement=1 -ext-tsp-chain-split-threshold=128 -debug-only=block-placement < %s 2>&1 | FileCheck %s
3
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -enable-ext-tsp-block-placement=1 -ext-tsp-chain-split-threshold=1 -debug-only=block-placement < %s 2>&1 | FileCheck %s -check-prefix=CHECK2
4
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -enable-ext-tsp-block-placement=0 -debug-only=block-placement < %s 2>&1 | FileCheck %s -check-prefix=CHECK3
5
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -enable-ext-tsp-block-placement=1 -ext-tsp-block-placement-max-blocks=8 -debug-only=block-placement < %s 2>&1 | FileCheck %s -check-prefix=CHECK4
2
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs - enable-ext-tsp-block-placement -ext-tsp-chain-split-threshold=128 -debug-only=block-placement < %s 2>&1 | FileCheck %s
3
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs - enable-ext-tsp-block-placement -ext-tsp-chain-split-threshold=1 -debug-only=block-placement < %s 2>&1 | FileCheck %s -check-prefix=CHECK2
4
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs -debug-only=block-placement < %s 2>&1 | FileCheck %s -check-prefix=CHECK3
5
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs - enable-ext-tsp-block-placement -ext-tsp-block-placement-max-blocks=8 -debug-only=block-placement < %s 2>&1 | FileCheck %s -check-prefix=CHECK4
6
6
7
7
@yydebug = dso_local global i32 0 , align 4
8
8
Original file line number Diff line number Diff line change 1
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -apply-ext-tsp-for-size=true < %s | FileCheck %s -check-prefix=CHECK-PERF
2
- ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -apply-ext-tsp-for-size=false < %s | FileCheck %s -check-prefix=CHECK-SIZE
1
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs - apply-ext-tsp-for-size < %s | FileCheck %s -check-prefix=CHECK-SIZE
2
+ ; RUN: llc -mcpu=corei7 -mtriple=x86_64-linux -verify-machineinstrs < %s | FileCheck %s -check-prefix=CHECK-PERF
3
3
4
4
define void @func1 () minsize {
5
5
;
@@ -19,15 +19,15 @@ define void @func1() minsize {
19
19
; | b2 | <+
20
20
; +-----+
21
21
;
22
- ; CHECK-PERF-LABEL: func1:
23
- ; CHECK-PERF: %b0
24
- ; CHECK-PERF: %b1
25
- ; CHECK-PERF: %b2
26
- ;
27
22
; CHECK-SIZE-LABEL: func1:
28
23
; CHECK-SIZE: %b0
29
- ; CHECK-SIZE: %b2
30
24
; CHECK-SIZE: %b1
25
+ ; CHECK-SIZE: %b2
26
+ ;
27
+ ; CHECK-PERF-LABEL: func1:
28
+ ; CHECK-PERF: %b0
29
+ ; CHECK-PERF: %b2
30
+ ; CHECK-PERF: %b1
31
31
32
32
b0:
33
33
%call = call zeroext i1 @a ()
@@ -75,21 +75,21 @@ define void @func_loop() minsize !prof !9 {
75
75
; | end |
76
76
; +--------+
77
77
;
78
- ; CHECK-PERF-LABEL: func_loop:
79
- ; CHECK-PERF: %entry
80
- ; CHECK-PERF: %header
81
- ; CHECK-PERF: %if.then
82
- ; CHECK-PERF: %if.else
83
- ; CHECK-PERF: %if.end
84
- ; CHECK-PERF: %end
85
- ;
86
78
; CHECK-SIZE-LABEL: func_loop:
87
79
; CHECK-SIZE: %entry
88
80
; CHECK-SIZE: %header
81
+ ; CHECK-SIZE: %if.then
89
82
; CHECK-SIZE: %if.else
90
83
; CHECK-SIZE: %if.end
91
- ; CHECK-SIZE: %if.then
92
84
; CHECK-SIZE: %end
85
+ ;
86
+ ; CHECK-PERF-LABEL: func_loop:
87
+ ; CHECK-PERF: %entry
88
+ ; CHECK-PERF: %header
89
+ ; CHECK-PERF: %if.else
90
+ ; CHECK-PERF: %if.end
91
+ ; CHECK-PERF: %if.then
92
+ ; CHECK-PERF: %end
93
93
94
94
entry:
95
95
br label %header
You can’t perform that action at this time.
0 commit comments