[PATCH] D105650: Add AddDiscriminatorsPass to NPM default O0 pipeline
Yuanfang Chen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 8 16:37:50 PDT 2021
This revision was automatically updated to reflect the committed changes.
Closed by commit rG0eb2b13d609c: Add AddDiscriminatorsPass to NPM default O0 pipeline (authored by ychen).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105650/new/
https://reviews.llvm.org/D105650
Files:
llvm/lib/Passes/PassBuilder.cpp
llvm/test/Other/new-pm-O0-defaults.ll
Index: llvm/test/Other/new-pm-O0-defaults.ll
===================================================================
--- llvm/test/Other/new-pm-O0-defaults.ll
+++ llvm/test/Other/new-pm-O0-defaults.ll
@@ -13,6 +13,9 @@
; 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: 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: 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
@@ -26,6 +29,10 @@
; RUN: -passes='lto<O0>' -S %s 2>&1 \
; RUN: | FileCheck %s --check-prefixes=CHECK,CHECK-LTO
+; CHECK-DIS: Running analysis: InnerAnalysisManagerProxy
+; CHECK-DIS-NEXT: Running pass: AddDiscriminatorsPass
+; CHECK-DIS-NEXT: Running pass: AlwaysInlinerPass
+; CHECK-DIS-NEXT: Running analysis: ProfileSummaryAnalysis
; CHECK-DEFAULT: Running pass: AlwaysInlinerPass
; CHECK-DEFAULT-NEXT: Running analysis: InnerAnalysisManagerProxy
; CHECK-DEFAULT-NEXT: Running analysis: ProfileSummaryAnalysis
Index: llvm/lib/Passes/PassBuilder.cpp
===================================================================
--- llvm/lib/Passes/PassBuilder.cpp
+++ llvm/lib/Passes/PassBuilder.cpp
@@ -1922,6 +1922,10 @@
for (auto &C : PipelineStartEPCallbacks)
C(MPM, Level);
+
+ if (PGOOpt && PGOOpt->DebugInfoForProfiling)
+ MPM.addPass(createModuleToFunctionPassAdaptor(AddDiscriminatorsPass()));
+
for (auto &C : PipelineEarlySimplificationEPCallbacks)
C(MPM, Level);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D105650.357384.patch
Type: text/x-patch
Size: 1858 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210708/8c776370/attachment.bin>
More information about the llvm-commits
mailing list