[PATCH] D152577: Part 2 of Fine tune MachineFunctionSplitPass (MFS) for FSAFDO.
Rong Xu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 9 13:10:51 PDT 2023
xur added inline comments.
================
Comment at: llvm/lib/CodeGen/TargetPassConfig.cpp:1255
+ addPass(createMIRAddFSDiscriminatorsPass(
+ sampleprof::FSDiscriminatorPass::Pass3));
+
----------------
It seems that you use Pass3 to replace PassLast. Should we use PassLast here? This way we can still save Pass3 for others.
I don't think we will have other discriminator pass after this.
================
Comment at: llvm/lib/CodeGen/TargetPassConfig.cpp:1279
+ }
+ addPass(createMachineFunctionSplitterPass(HasAccureateSampleProfile));
}
----------------
The intention here is to use FSAFDO with improved discriminator for MFS.
I would suggest a warning (or even a hard error) here if we detect otherwise AFDO mode is used.
This would helpful to user mistakes (especially that we know MFS + AFDO can degrade the performance).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D152577/new/
https://reviews.llvm.org/D152577
More information about the llvm-commits
mailing list