[llvm] [PGO] Sampled instrumentation in PGO to speed up instrumentation binary (PR #69535)
    via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Fri Oct 20 11:16:49 PDT 2023
    
    
  
================
@@ -805,6 +808,10 @@ void PassBuilder::addPGOInstrPasses(ModulePassManager &MPM,
   // Do counter promotion at Level greater than O0.
   Options.DoCounterPromotion = true;
   Options.UseBFIInPromotion = IsCS;
+  if (EnableSampledInstr) {
+    Options.Sampling = true;
+    Options.DoCounterPromotion = false;
----------------
xur-llvm wrote:
The reason is mentioned in InstrProfling.C:400.
https://github.com/llvm/llvm-project/pull/69535
    
    
More information about the llvm-commits
mailing list