[llvm] [NewPM][CodeGen] add TargetPassConfig like API (PR #70906)

Arthur Eubanks via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 21 10:02:26 PST 2023


================
@@ -17,6 +17,51 @@
 
 using namespace llvm;
 
+namespace {
+
+/// RAII class to replace addMachinePrePasses/addMachinePostPasses
+/// If we need more complex logics, consider add class like
+/// CodeGenInstrumentation
+// TODO: skip FreeMachineFunctionPass and AsmPrinter
+class PrePostPasses {
----------------
aeubanks wrote:

Can we defer the debugify stuff to a later patch and figure out a cleaner way of implementing it, and put the verifier stuff in pass instrumentation (can also do that in a separate change)? I'd really like to not have this `PrePostPasses` in the middle of `MachineFunctionPassManager::run`

https://github.com/llvm/llvm-project/pull/70906


More information about the llvm-commits mailing list