[PATCH] D88138: [NPM] Add target specific hook to add passes for New Pass Manager

Arthur Eubanks via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 24 22:33:19 PDT 2020


aeubanks added a comment.

I think I'm still missing how exactly this will fit into the pipeline. As in where is `registerPassBuilderCallbacks()` going to be called?

And a test like llvm/test/CodeGen/AMDGPU/opt-pipeline.ll for the new pass manager route would be nice to make sure this actually works.
something like `RUN: opt -passes='default<O0>' -mtriple=... -disable-output -disable-verify -debug-pass-manager`. Maybe checking all the normal passes isn't necessary like in the existing opt-pipeline.ll isn't necessary, just need to check that the custom passes (e.g. `HexagonVectorLoopCarriedReusePass`) are actually added.



================
Comment at: llvm/lib/Target/Hexagon/HexagonTargetMachine.cpp:278
+void HexagonTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
+  PB.registerOptimizerLastEPCallback([](ModulePassManager &mpm,
+                                        PassBuilder::OptimizationLevel Level) {
----------------
this is typically fully capitalized


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D88138/new/

https://reviews.llvm.org/D88138



More information about the llvm-commits mailing list