Skip to content

Commit eb1d655

Browse files
committed
[Pass] Rename callbrprepare -> callbr-prepare
1 parent 811bc56 commit eb1d655

File tree

5 files changed

+12
-7
lines changed

5 files changed

+12
-7
lines changed

llvm/include/llvm/CodeGen/MachinePassRegistry.def

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ FUNCTION_ANALYSIS("targetir", TargetIRAnalysis,
3636
#ifndef FUNCTION_PASS
3737
#define FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
3838
#endif
39-
FUNCTION_PASS("callbrprepare", CallBrPreparePass, ())
39+
FUNCTION_PASS("callbr-prepare", CallBrPreparePass, ())
4040
FUNCTION_PASS("consthoist", ConstantHoistingPass, ())
4141
FUNCTION_PASS("ee-instrument", EntryExitInstrumenterPass, (false))
4242
FUNCTION_PASS("expand-large-div-rem", ExpandLargeDivRemPass, ())

llvm/lib/CodeGen/CallBrPrepare.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252

5353
using namespace llvm;
5454

55-
#define DEBUG_TYPE "callbrprepare"
55+
#define DEBUG_TYPE "callbr-prepare"
5656

5757
static bool SplitCriticalEdges(ArrayRef<CallBrInst *> CBRs, DominatorTree &DT);
5858
static bool InsertIntrinsicCalls(ArrayRef<CallBrInst *> CBRs,
@@ -94,9 +94,11 @@ PreservedAnalyses CallBrPreparePass::run(Function &Fn,
9494
}
9595

9696
char CallBrPrepare::ID = 0;
97-
INITIALIZE_PASS_BEGIN(CallBrPrepare, DEBUG_TYPE, "Prepare callbr", false, false)
97+
INITIALIZE_PASS_BEGIN(CallBrPrepare, "callbrprepare", "Prepare callbr", false,
98+
false)
9899
INITIALIZE_PASS_DEPENDENCY(DominatorTreeWrapperPass)
99-
INITIALIZE_PASS_END(CallBrPrepare, DEBUG_TYPE, "Prepare callbr", false, false)
100+
INITIALIZE_PASS_END(CallBrPrepare, "callbrprepare", "Prepare callbr", false,
101+
false)
100102

101103
FunctionPass *llvm::createCallBrPass() { return new CallBrPrepare(); }
102104

llvm/lib/Passes/PassBuilder.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1295,7 +1295,10 @@ static bool isLoopPassName(StringRef Name, CallbacksT &Callbacks,
12951295
}
12961296

12971297
static StringRef convertToNewPassName(StringRef OldName) {
1298-
static StringMap<StringRef> NameMap = {{"loweratomic", "lower-atomic"},
1298+
static StringMap<StringRef> NameMap = {{"callbrprepare", "callbr-prepare"},
1299+
{"dwarfehprepare", "dwarf-eh-prepare"},
1300+
{"flattencfg", "flatten-cfg"},
1301+
{"loweratomic", "lower-atomic"},
12991302
{"lowerinvoke", "lower-invoke"},
13001303
{"lowerswitch", "lower-switch"}};
13011304

llvm/lib/Passes/PassRegistry.def

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ FUNCTION_PASS("assume-simplify", AssumeSimplifyPass())
283283
FUNCTION_PASS("bdce", BDCEPass())
284284
FUNCTION_PASS("bounds-checking", BoundsCheckingPass())
285285
FUNCTION_PASS("break-crit-edges", BreakCriticalEdgesPass())
286-
FUNCTION_PASS("callbrprepare", CallBrPreparePass())
286+
FUNCTION_PASS("callbr-prepare", CallBrPreparePass())
287287
FUNCTION_PASS("callsite-splitting", CallSiteSplittingPass())
288288
FUNCTION_PASS("chr", ControlHeightReductionPass())
289289
FUNCTION_PASS("consthoist", ConstantHoistingPass())

llvm/test/CodeGen/AArch64/callbr-prepare.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
22
; RUN: opt %s -callbrprepare -S -o - | FileCheck %s
3-
; RUN: opt %s -passes=callbrprepare -S -o - | FileCheck %s
3+
; RUN: opt %s -passes=callbr-prepare -S -o - | FileCheck %s
44

55
define i32 @test0() {
66
; CHECK-LABEL: @test0(

0 commit comments

Comments
 (0)