[llvm] [SHT_LLVM_BB_ADDR_MAP] Add an option to skip emitting bb entries (PR #114447)

Rahman Lavaee via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 13 09:37:26 PST 2024


================
@@ -1411,8 +1418,15 @@ getBBAddrMapFeature(const MachineFunction &MF, int NumMBBSectionRanges) {
   bool BrProbEnabled =
       AllFeatures ||
       (!NoFeatures && PgoAnalysisMapFeatures.isSet(PGOMapFeaturesEnum::BrProb));
+
+  if ((BBFreqEnabled || BrProbEnabled) && BBAddrMapSkipEmitBBEntries) {
+    MF.getFunction().getContext().emitError(
+        "BB entries info is required for BBFreq and BrProb "
----------------
rlavaee wrote:

Please add a test for this.

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


More information about the llvm-commits mailing list