File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed
Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -457,7 +457,7 @@ class TargetPassConfig : public ImmutablePass {
457457
458458 // / Add a CodeGen pass at this point in the pipeline after checking overrides.
459459 // / Return the pass that was added, or zero if no pass was added.
460- AnalysisID addPass (IdentifyingPassPtr PassID);
460+ AnalysisID addPass (AnalysisID PassID);
461461
462462 // / Add a pass to the PassManager if that pass is supposed to be run, as
463463 // / determined by the StartAfter and StopAfter options. Takes ownership of the
Original file line number Diff line number Diff line change @@ -745,9 +745,7 @@ void TargetPassConfig::addPass(Pass *P) {
745745// /
746746// / addPass cannot return a pointer to the pass instance because is internal the
747747// / PassManager and the instance we create here may already be freed.
748- AnalysisID TargetPassConfig::addPass (IdentifyingPassPtr PassPtr) {
749- AnalysisID PassID = PassPtr.isInstance () ? PassPtr.getInstance ()->getPassID ()
750- : PassPtr.getID ();
748+ AnalysisID TargetPassConfig::addPass (AnalysisID PassID) {
751749 IdentifyingPassPtr TargetID = getPassSubstitution (PassID);
752750 IdentifyingPassPtr FinalPtr = overridePass (PassID, TargetID);
753751 if (!FinalPtr.isValid ())
@@ -1515,7 +1513,8 @@ void TargetPassConfig::addMachineLateOptimization() {
15151513 // Cleanup of redundant immediate/address loads.
15161514 addPass (&MachineLateInstrsCleanupID);
15171515
1518- addPass (IdentifyingPassPtr (createBranchFolderPass (getEnableTailMerge ())));
1516+ // Branch folding must be run after regalloc and prolog/epilog insertion.
1517+ addPass (createBranchFolderPass (getEnableTailMerge ()));
15191518
15201519 // Tail duplication.
15211520 // Note that duplicating tail just increases code size and degrades
You can’t perform that action at this time.
0 commit comments