mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-21 18:22:53 +01:00
[Coroutines] Run coroutine passes by default
This patch make coroutine passes run by default in LLVM pipeline. Now the clang and opt could handle IR inputs containing coroutine intrinsics without special options. It should be fine. On the one hand, the coroutine passes seems to be stable since there are already many projects using coroutine feature. On the other hand, the coroutine passes should do nothing for IR who doesn't contain coroutine intrinsic. Test Plan: check-llvm Reviewed by: lxfind, aeubanks Differential Revision: https://reviews.llvm.org/D105877
This commit is contained in:
parent
b86b597e6c
commit
ca13ea7edf
@ -80,9 +80,6 @@ void LLVMPassBuilderOptionsSetLoopUnrolling(LLVMPassBuilderOptionsRef Options,
|
||||
void LLVMPassBuilderOptionsSetForgetAllSCEVInLoopUnroll(
|
||||
LLVMPassBuilderOptionsRef Options, LLVMBool ForgetAllSCEVInLoopUnroll);
|
||||
|
||||
void LLVMPassBuilderOptionsSetCoroutines(LLVMPassBuilderOptionsRef Options,
|
||||
LLVMBool Coroutines);
|
||||
|
||||
void LLVMPassBuilderOptionsSetLicmMssaOptCap(LLVMPassBuilderOptionsRef Options,
|
||||
unsigned LicmMssaOptCap);
|
||||
|
||||
|
@ -107,12 +107,6 @@ public:
|
||||
/// is that of the flag: `-forget-scev-loop-unroll`.
|
||||
bool ForgetAllSCEVInLoopUnroll;
|
||||
|
||||
/// Tuning option to enable/disable coroutine intrinsic lowering. Its default
|
||||
/// value is false. Frontends such as Clang may enable this conditionally. For
|
||||
/// example, Clang enables this option if the flags `-std=c++2a` or above, or
|
||||
/// `-fcoroutines-ts`, have been specified.
|
||||
bool Coroutines;
|
||||
|
||||
/// Tuning option to cap the number of calls to retrive clobbering accesses in
|
||||
/// MemorySSA, in LICM.
|
||||
unsigned LicmMssaOptCap;
|
||||
|
@ -283,7 +283,6 @@ PipelineTuningOptions::PipelineTuningOptions() {
|
||||
SLPVectorization = false;
|
||||
LoopUnrolling = true;
|
||||
ForgetAllSCEVInLoopUnroll = ForgetSCEVInLoopUnroll;
|
||||
Coroutines = false;
|
||||
LicmMssaOptCap = SetLicmMssaOptCap;
|
||||
LicmMssaNoAccForPromotionCap = SetLicmMssaNoAccForPromotionCap;
|
||||
CallGraphProfile = true;
|
||||
@ -649,8 +648,7 @@ PassBuilder::buildO1FunctionSimplificationPipeline(OptimizationLevel Level,
|
||||
FPM.addPass(InstCombinePass());
|
||||
invokePeepholeEPCallbacks(FPM, Level);
|
||||
|
||||
if (PTO.Coroutines)
|
||||
FPM.addPass(CoroElidePass());
|
||||
FPM.addPass(CoroElidePass());
|
||||
|
||||
for (auto &C : ScalarOptimizerLateEPCallbacks)
|
||||
C(FPM, Level);
|
||||
@ -847,8 +845,7 @@ PassBuilder::buildFunctionSimplificationPipeline(OptimizationLevel Level,
|
||||
LICMPass(PTO.LicmMssaOptCap, PTO.LicmMssaNoAccForPromotionCap),
|
||||
EnableMSSALoopDependency, /*UseBlockFrequencyInfo=*/true));
|
||||
|
||||
if (PTO.Coroutines)
|
||||
FPM.addPass(CoroElidePass());
|
||||
FPM.addPass(CoroElidePass());
|
||||
|
||||
for (auto &C : ScalarOptimizerLateEPCallbacks)
|
||||
C(FPM, Level);
|
||||
@ -1027,8 +1024,7 @@ PassBuilder::buildInlinerPipeline(OptimizationLevel Level,
|
||||
MainCGPipeline.addPass(createCGSCCToFunctionPassAdaptor(
|
||||
buildFunctionSimplificationPipeline(Level, Phase)));
|
||||
|
||||
if (PTO.Coroutines)
|
||||
MainCGPipeline.addPass(CoroSplitPass(Level != OptimizationLevel::O0));
|
||||
MainCGPipeline.addPass(CoroSplitPass(Level != OptimizationLevel::O0));
|
||||
|
||||
return MIWP;
|
||||
}
|
||||
@ -1083,8 +1079,7 @@ PassBuilder::buildModuleSimplificationPipeline(OptimizationLevel Level,
|
||||
EarlyFPM.addPass(SimplifyCFGPass());
|
||||
EarlyFPM.addPass(SROA());
|
||||
EarlyFPM.addPass(EarlyCSEPass());
|
||||
if (PTO.Coroutines)
|
||||
EarlyFPM.addPass(CoroEarlyPass());
|
||||
EarlyFPM.addPass(CoroEarlyPass());
|
||||
if (Level == OptimizationLevel::O3)
|
||||
EarlyFPM.addPass(CallSiteSplittingPass());
|
||||
|
||||
@ -1451,8 +1446,7 @@ PassBuilder::buildModuleOptimizationPipeline(OptimizationLevel Level,
|
||||
// resulted in single-entry-single-exit or empty blocks. Clean up the CFG.
|
||||
OptimizePM.addPass(SimplifyCFGPass());
|
||||
|
||||
if (PTO.Coroutines)
|
||||
OptimizePM.addPass(CoroCleanupPass());
|
||||
OptimizePM.addPass(CoroCleanupPass());
|
||||
|
||||
// Add the core optimizing pipeline.
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(std::move(OptimizePM)));
|
||||
@ -1562,8 +1556,7 @@ PassBuilder::buildThinLTOPreLinkDefaultPipeline(OptimizationLevel Level) {
|
||||
// Module simplification splits coroutines, but does not fully clean up
|
||||
// coroutine intrinsics. To ensure ThinLTO optimization passes don't trip up
|
||||
// on these, we schedule the cleanup here.
|
||||
if (PTO.Coroutines)
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(CoroCleanupPass()));
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(CoroCleanupPass()));
|
||||
|
||||
if (PGOOpt && PGOOpt->PseudoProbeForProfiling)
|
||||
MPM.addPass(PseudoProbeUpdatePass());
|
||||
@ -1937,10 +1930,8 @@ ModulePassManager PassBuilder::buildO0DefaultPipeline(OptimizationLevel Level,
|
||||
// which is just that always inlining occurs. Further, disable generating
|
||||
// lifetime intrinsics to avoid enabling further optimizations during
|
||||
// code generation.
|
||||
// However, we need to insert lifetime intrinsics to avoid invalid access
|
||||
// caused by multithreaded coroutines.
|
||||
MPM.addPass(AlwaysInlinerPass(
|
||||
/*InsertLifetimeIntrinsics=*/PTO.Coroutines));
|
||||
/*InsertLifetimeIntrinsics=*/false));
|
||||
|
||||
if (PTO.MergeFunctions)
|
||||
MPM.addPass(MergeFunctionsPass());
|
||||
@ -1989,15 +1980,11 @@ ModulePassManager PassBuilder::buildO0DefaultPipeline(OptimizationLevel Level,
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(std::move(FPM)));
|
||||
}
|
||||
|
||||
if (PTO.Coroutines) {
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(CoroEarlyPass()));
|
||||
|
||||
CGSCCPassManager CGPM;
|
||||
CGPM.addPass(CoroSplitPass());
|
||||
MPM.addPass(createModuleToPostOrderCGSCCPassAdaptor(std::move(CGPM)));
|
||||
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(CoroCleanupPass()));
|
||||
}
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(CoroEarlyPass()));
|
||||
CGSCCPassManager CGPM;
|
||||
CGPM.addPass(CoroSplitPass());
|
||||
MPM.addPass(createModuleToPostOrderCGSCCPassAdaptor(std::move(CGPM)));
|
||||
MPM.addPass(createModuleToFunctionPassAdaptor(CoroCleanupPass()));
|
||||
|
||||
for (auto &C : OptimizerLastEPCallbacks)
|
||||
C(MPM, Level);
|
||||
|
@ -118,11 +118,6 @@ void LLVMPassBuilderOptionsSetForgetAllSCEVInLoopUnroll(
|
||||
unwrap(Options)->PTO.ForgetAllSCEVInLoopUnroll = ForgetAllSCEVInLoopUnroll;
|
||||
}
|
||||
|
||||
void LLVMPassBuilderOptionsSetCoroutines(LLVMPassBuilderOptionsRef Options,
|
||||
LLVMBool Coroutines) {
|
||||
unwrap(Options)->PTO.Coroutines = Coroutines;
|
||||
}
|
||||
|
||||
void LLVMPassBuilderOptionsSetLicmMssaOptCap(LLVMPassBuilderOptionsRef Options,
|
||||
unsigned LicmMssaOptCap) {
|
||||
unwrap(Options)->PTO.LicmMssaOptCap = LicmMssaOptCap;
|
||||
|
@ -2189,7 +2189,11 @@ llvm::InlineResult llvm::InlineFunction(CallBase &CB, InlineFunctionInfo &IFI,
|
||||
|
||||
// Leave lifetime markers for the static alloca's, scoping them to the
|
||||
// function we just inlined.
|
||||
if (InsertLifetime && !IFI.StaticAllocas.empty()) {
|
||||
// We need to insert lifetime intrinsics even at O0 to avoid invalid
|
||||
// access caused by multithreaded coroutines. The check
|
||||
// `Caller->isPresplitCoroutine()` would affect AlwaysInliner at O0 only.
|
||||
if ((InsertLifetime || Caller->isPresplitCoroutine()) &&
|
||||
!IFI.StaticAllocas.empty()) {
|
||||
IRBuilder<> builder(&FirstNewBlock->front());
|
||||
for (unsigned ai = 0, ae = IFI.StaticAllocas.size(); ai != ae; ++ai) {
|
||||
AllocaInst *AI = IFI.StaticAllocas[ai];
|
||||
|
@ -9,19 +9,19 @@
|
||||
|
||||
; RUN: opt -disable-verify -verify-cfg-preserved=0 -debug-pass-manager \
|
||||
; RUN: -passes='default<O0>' -S %s 2>&1 \
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-CORO
|
||||
; RUN: opt -disable-verify -verify-cfg-preserved=0 -debug-pass-manager -enable-matrix \
|
||||
; RUN: -passes='default<O0>' -S %s 2>&1 \
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-MATRIX
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-MATRIX,CHECK-CORO
|
||||
; RUN: opt -disable-verify -verify-cfg-preserved=0 -debug-pass-manager -new-pm-debug-info-for-profiling \
|
||||
; RUN: -passes='default<O0>' -S %s 2>&1 \
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DIS
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DIS,CHECK-CORO
|
||||
; RUN: opt -disable-verify -verify-cfg-preserved=0 -debug-pass-manager \
|
||||
; RUN: -passes='thinlto-pre-link<O0>' -S %s 2>&1 \
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-PRE-LINK
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-PRE-LINK,CHECK-CORO
|
||||
; RUN: opt -disable-verify -verify-cfg-preserved=0 -debug-pass-manager \
|
||||
; RUN: -passes='lto-pre-link<O0>' -S %s 2>&1 \
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-PRE-LINK
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-DEFAULT,CHECK-PRE-LINK,CHECK-CORO
|
||||
; RUN: opt -disable-verify -verify-cfg-preserved=0 -debug-pass-manager \
|
||||
; RUN: -passes='thinlto<O0>' -S %s 2>&1 \
|
||||
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-THINLTO
|
||||
@ -38,6 +38,14 @@
|
||||
; CHECK-DEFAULT-NEXT: Running analysis: ProfileSummaryAnalysis
|
||||
; CHECK-MATRIX: Running pass: LowerMatrixIntrinsicsPass
|
||||
; CHECK-MATRIX-NEXT: Running analysis: TargetIRAnalysis
|
||||
; CHECK-CORO-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-CORO-NEXT: Running analysis: InnerAnalysisManagerProxy
|
||||
; CHECK-CORO-NEXT: Running analysis: LazyCallGraphAnalysis
|
||||
; CHECK-CORO-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-CORO-NEXT: Running analysis: FunctionAnalysisManagerCGSCCProxy
|
||||
; CHECK-CORO-NEXT: Running analysis: OuterAnalysisManagerProxy
|
||||
; CHECK-CORO-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-CORO-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-PRE-LINK: Running pass: CanonicalizeAliasesPass
|
||||
; CHECK-PRE-LINK-NEXT: Running pass: NameAnonGlobalPass
|
||||
; CHECK-THINLTO: Running pass: Annotation2MetadataPass
|
||||
@ -50,7 +58,7 @@
|
||||
; CHECK-LTO-NEXT: Running pass: LowerTypeTestsPass
|
||||
; CHECK-LTO-NEXT: Running pass: LowerTypeTestsPass
|
||||
; CHECK-LTO-NEXT: Running pass: AnnotationRemarksPass
|
||||
; CHECK-LTO-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-LTO-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-NEXT: Running pass: PrintModulePass
|
||||
|
||||
; Make sure we get the IR back out without changes when we print the module.
|
||||
|
@ -89,6 +89,7 @@
|
||||
; CHECK-O-NEXT: Running analysis: DominatorTreeAnalysis
|
||||
; CHECK-O-NEXT: Running pass: EarlyCSEPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-O-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-O3-NEXT: Running pass: CallSiteSplittingPass
|
||||
; CHECK-O-NEXT: Running pass: OpenMPOptPass
|
||||
; CHECK-EP-PIPELINE-EARLY-SIMPLIFICATION-NEXT: Running pass: NoOpModulePass
|
||||
@ -183,6 +184,7 @@
|
||||
; CHECK-O23SZ-NEXT: Running analysis: LazyValueAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
|
||||
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
|
||||
; CHECK-O1-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: ADCEPass
|
||||
; CHECK-O-NEXT: Running analysis: PostDominatorTreeAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: MemCpyOptPass
|
||||
@ -190,10 +192,12 @@
|
||||
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LICMPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-EP-SCALAR-LATE-NEXT: Running pass: NoOpFunctionPass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass
|
||||
; CHECK-EP-PEEPHOLE-NEXT: Running pass: NoOpFunctionPass
|
||||
; CHECK-O-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalDCEPass
|
||||
; CHECK-DEFAULT-NEXT: Running pass: EliminateAvailableExternallyPass
|
||||
@ -236,6 +240,7 @@
|
||||
; CHECK-O-NEXT: Running pass: InstSimplifyPass
|
||||
; CHECK-O-NEXT: Running pass: DivRemPairsPass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-EP-OPTIMIZER-LAST: Running pass: NoOpFunctionPass
|
||||
; CHECK-O-NEXT: Running pass: CGProfilePass
|
||||
; CHECK-O-NEXT: Running pass: GlobalDCEPass
|
||||
|
@ -70,6 +70,7 @@
|
||||
; CHECK-O-NEXT: Running analysis: DominatorTreeAnalysis
|
||||
; CHECK-O-NEXT: Running pass: EarlyCSEPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-O-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-O3-NEXT: Running pass: CallSiteSplittingPass
|
||||
; CHECK-O-NEXT: Running pass: OpenMPOptPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: LowerTypeTestsPass
|
||||
@ -170,6 +171,7 @@
|
||||
; CHECK-O23SZ-NEXT: Running analysis: LazyValueAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
|
||||
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
|
||||
; CHECK-O1-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: ADCEPass
|
||||
; CHECK-O-NEXT: Running analysis: PostDominatorTreeAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: MemCpyOptPass
|
||||
@ -177,8 +179,10 @@
|
||||
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LICMPass on Loop at depth 1 containing: %loop
|
||||
; CHECK-O23SZ-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass
|
||||
; CHECK-O-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-PRELINK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: GlobalDCEPass
|
||||
@ -217,6 +221,7 @@
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: InstSimplifyPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: DivRemPairsPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: CGProfilePass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: GlobalDCEPass
|
||||
; CHECK-POSTLINK-O-NEXT: Running pass: ConstantMergePass
|
||||
|
@ -40,6 +40,7 @@
|
||||
; CHECK-O-NEXT: Running analysis: DominatorTreeAnalysis
|
||||
; CHECK-O-NEXT: Running pass: EarlyCSEPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-O-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-O3-NEXT: Running pass: CallSiteSplittingPass
|
||||
; CHECK-O-NEXT: Running pass: OpenMPOptPass
|
||||
; CHECK-O-NEXT: Running pass: LowerTypeTestsPass
|
||||
@ -143,14 +144,17 @@
|
||||
; CHECK-O23SZ-NEXT: Running analysis: LazyValueAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
|
||||
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
|
||||
; CHECK-O1-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: ADCEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: MemCpyOptPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: DSEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LICMPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass
|
||||
; CHECK-O-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalDCEPass
|
||||
; CHECK-O-NEXT: Running pass: EliminateAvailableExternallyPass
|
||||
@ -186,6 +190,7 @@
|
||||
; CHECK-O-NEXT: Running pass: InstSimplifyPass
|
||||
; CHECK-O-NEXT: Running pass: DivRemPairsPass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-O-NEXT: Running pass: CGProfilePass
|
||||
; CHECK-O-NEXT: Running pass: GlobalDCEPass
|
||||
; CHECK-O-NEXT: Running pass: ConstantMergePass
|
||||
|
@ -42,6 +42,7 @@
|
||||
; CHECK-O-NEXT: Running analysis: DominatorTreeAnalysis
|
||||
; CHECK-O-NEXT: Running pass: EarlyCSEPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-O-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-O3-NEXT: Running pass: CallSiteSplittingPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass on foo
|
||||
; CHECK-O-NEXT: Running analysis: OptimizationRemarkEmitterAnalysis on foo
|
||||
@ -152,17 +153,20 @@
|
||||
; CHECK-O23SZ-NEXT: Running analysis: LazyValueAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
|
||||
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
|
||||
; CHECK-O1-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: ADCEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: MemCpyOptPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: DSEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LICMPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass
|
||||
; CHECK-O3-NEXT: Running pass: ControlHeightReductionPass on foo
|
||||
; CHECK-O3-NEXT: Running analysis: RegionInfoAnalysis on foo
|
||||
; CHECK-O3-NEXT: Running analysis: DominanceFrontierAnalysis on foo
|
||||
; CHECK-O-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalDCEPass
|
||||
; CHECK-O-NEXT: Running pass: EliminateAvailableExternallyPass
|
||||
@ -198,6 +202,7 @@
|
||||
; CHECK-O-NEXT: Running pass: InstSimplifyPass
|
||||
; CHECK-O-NEXT: Running pass: DivRemPairsPass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-O-NEXT: Running pass: CGProfilePass
|
||||
; CHECK-O-NEXT: Running pass: GlobalDCEPass
|
||||
; CHECK-O-NEXT: Running pass: ConstantMergePass
|
||||
|
@ -41,6 +41,7 @@
|
||||
; CHECK-O-NEXT: Running analysis: DominatorTreeAnalysis
|
||||
; CHECK-O-NEXT: Running pass: EarlyCSEPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-O-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-O3-NEXT: Running pass: CallSiteSplittingPass
|
||||
; CHECK-O-NEXT: Running pass: OpenMPOptPass
|
||||
; CHECK-O-NEXT: Running pass: IPSCCPPass
|
||||
@ -183,20 +184,24 @@
|
||||
; CHECK-O23SZ-NEXT: Running analysis: LazyValueAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
|
||||
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
|
||||
; CHECK-O1-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: ADCEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: MemCpyOptPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: DSEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LICMPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass
|
||||
; CHECK-O3-NEXT: Running pass: ControlHeightReductionPass on foo
|
||||
; CHECK-O3-NEXT: Running analysis: RegionInfoAnalysis on foo
|
||||
; CHECK-O3-NEXT: Running analysis: DominanceFrontierAnalysis on foo
|
||||
; CHECK-O-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis on bar
|
||||
; CHECK-EXT: Running pass: {{.*}}::Bye
|
||||
; CHECK-O-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-O-NEXT: Running pass: AnnotationRemarksPass on foo
|
||||
; CHECK-O-NEXT: Running pass: CanonicalizeAliasesPass
|
||||
; CHECK-O-NEXT: Running pass: NameAnonGlobalPass
|
||||
|
@ -40,6 +40,7 @@
|
||||
; CHECK-O-NEXT: Running analysis: DominatorTreeAnalysis
|
||||
; CHECK-O-NEXT: Running pass: EarlyCSEPass
|
||||
; CHECK-O-NEXT: Running analysis: TargetLibraryAnalysis
|
||||
; CHECK-O-NEXT: Running pass: CoroEarlyPass
|
||||
; CHECK-O3-NEXT: Running pass: CallSiteSplittingPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass on foo
|
||||
; CHECK-O-NEXT: Running analysis: OptimizationRemarkEmitterAnalysis on foo
|
||||
@ -146,18 +147,22 @@
|
||||
; CHECK-O23SZ-NEXT: Running analysis: LazyValueAnalysis
|
||||
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
|
||||
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
|
||||
; CHECK-O1-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: ADCEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: MemCpyOptPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: DSEPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: LICMPass
|
||||
; CHECK-O23SZ-NEXT: Running pass: CoroElidePass
|
||||
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
|
||||
; CHECK-O-NEXT: Running pass: InstCombinePass
|
||||
; CHECK-O3-NEXT: Running pass: ControlHeightReductionPass on foo
|
||||
; CHECK-O3-NEXT: Running analysis: RegionInfoAnalysis on foo
|
||||
; CHECK-O3-NEXT: Running analysis: DominanceFrontierAnalysis on foo
|
||||
; CHECK-O-NEXT: Running pass: CoroSplitPass
|
||||
; CHECK-O-NEXT: Running pass: GlobalOptPass
|
||||
; CHECK-O-NEXT: Running pass: CoroCleanupPass
|
||||
; CHECK-O-NEXT: Running pass: AnnotationRemarksPass on foo
|
||||
; CHECK-O-NEXT: Running pass: CanonicalizeAliasesPass
|
||||
; CHECK-O-NEXT: Running pass: NameAnonGlobalPass
|
||||
|
@ -241,7 +241,7 @@ bool llvm::runPassPipeline(StringRef Arg0, Module &M, TargetMachine *TM,
|
||||
bool ShouldPreserveAssemblyUseListOrder,
|
||||
bool ShouldPreserveBitcodeUseListOrder,
|
||||
bool EmitSummaryIndex, bool EmitModuleHash,
|
||||
bool EnableDebugify, bool Coroutines) {
|
||||
bool EnableDebugify) {
|
||||
bool VerifyEachPass = VK == VK_VerifyEachPass;
|
||||
|
||||
Optional<PGOOptions> P;
|
||||
@ -305,7 +305,6 @@ bool llvm::runPassPipeline(StringRef Arg0, Module &M, TargetMachine *TM,
|
||||
// to false above so we shouldn't necessarily need to check whether or not the
|
||||
// option has been enabled.
|
||||
PTO.LoopUnrolling = !DisableLoopUnrolling;
|
||||
PTO.Coroutines = Coroutines;
|
||||
PassBuilder PB(TM, PTO, P, &PIC);
|
||||
registerEPCallbacks(PB);
|
||||
|
||||
|
@ -73,7 +73,7 @@ bool runPassPipeline(StringRef Arg0, Module &M, TargetMachine *TM,
|
||||
bool ShouldPreserveAssemblyUseListOrder,
|
||||
bool ShouldPreserveBitcodeUseListOrder,
|
||||
bool EmitSummaryIndex, bool EmitModuleHash,
|
||||
bool EnableDebugify, bool Coroutines);
|
||||
bool EnableDebugify);
|
||||
} // namespace llvm
|
||||
|
||||
#endif
|
||||
|
@ -831,7 +831,7 @@ int main(int argc, char **argv) {
|
||||
ThinLinkOut.get(), RemarksFile.get(), PassPipeline,
|
||||
Passes, OK, VK, PreserveAssemblyUseListOrder,
|
||||
PreserveBitcodeUseListOrder, EmitSummaryIndex,
|
||||
EmitModuleHash, EnableDebugify, Coroutines)
|
||||
EmitModuleHash, EnableDebugify)
|
||||
? 0
|
||||
: 1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user