[llvm] [CodeGen] Preserve branch weights from PGO profile during instruction selection at -O0 (PR #161620)
Grigory Pastukhov via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 6 11:17:18 PDT 2025
================
@@ -229,6 +229,17 @@ static bool dontUseFastISelFor(const Function &Fn) {
});
}
+static bool shouldRegisterPGOPasses(const TargetMachine &TM,
+ CodeGenOptLevel OptLevel) {
+ bool RegisterPGOPasses = OptLevel != CodeGenOptLevel::None;
----------------
grigorypas wrote:
If I make this change it breaks a lot of test cases (1024 tests). Some of the test cases use PGO information embedded in IR without setting PGOOptions flags.
https://github.com/llvm/llvm-project/pull/161620
More information about the llvm-commits
mailing list