Skip to content

Commit b0b5c52

Browse files
committed
fix param in codegenpassbuilder
1 parent 40e3029 commit b0b5c52

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

llvm/include/llvm/Passes/CodeGenPassBuilder.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1222,7 +1222,7 @@ void CodeGenPassBuilder<Derived, TargetMachineT>::addMachineLateOptimization(
12221222
template <typename Derived, typename TargetMachineT>
12231223
void CodeGenPassBuilder<Derived, TargetMachineT>::addBlockPlacement(
12241224
AddMachinePass &addPass) const {
1225-
addPass(MachineBlockPlacementPass());
1225+
addPass(MachineBlockPlacementPass(Opt.EnableTailMerge));
12261226
// Run a separate pass to collect block placement statistics.
12271227
if (Opt.EnableBlockPlacementStats)
12281228
addPass(MachineBlockPlacementStatsPass());

llvm/include/llvm/Target/CGPassBuilderOption.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ struct CGPassBuilderOption {
5050
bool EnableGlobalMergeFunc = false;
5151
bool EnableMachineFunctionSplitter = false;
5252
bool EnableSinkAndFold = false;
53+
bool EnableTailMerge = true;
5354
bool MISchedPostRA = false;
5455
bool EarlyLiveIntervals = false;
5556
bool GCEmptyBlocks = false;

0 commit comments

Comments
 (0)