IPA split is now running before auto-profile annotation. Changing it
after annotation as it is done for PGO.
gcc/ChangeLog:
2025-07-21 Kugan Vivekanandarajah <kvivekananda@nvidia.com>
* ipa-split.cc (pass_split_functions::gate): Do not run when
flag_auto_profile.
(pass_feedback_split_functions::gate): Run when flag_auto_profile.
/* When doing profile feedback, we want to execute the pass after profiling
is read. So disable one in early optimization. */
return (flag_partial_inlining
- && !profile_arc_flag && !flag_branch_probabilities);
+ && !profile_arc_flag
+ && !flag_branch_probabilities
+ && !flag_auto_profile);
}
} // anon namespace
/* We don't need to split when profiling at all, we are producing
lousy code anyway. */
return (flag_partial_inlining
- && flag_branch_probabilities);
+ && (flag_branch_probabilities || flag_auto_profile));
}
} // anon namespace