diff --git a/src/coreclr/jit/fgprofilesynthesis.cpp b/src/coreclr/jit/fgprofilesynthesis.cpp index 4c1d6a72c2bd37..9ab3cf0001f90e 100644 --- a/src/coreclr/jit/fgprofilesynthesis.cpp +++ b/src/coreclr/jit/fgprofilesynthesis.cpp @@ -1039,29 +1039,28 @@ void ProfileSynthesis::AssignInputWeights(ProfileSynthesisOption option) // Determine input weight for EH regions, if any. // - weight_t exceptionScaleFactor = exceptionScale; + weight_t ehWeight = exceptionWeight; #ifdef DEBUG - if (JitConfig.JitSynthesisExceptionScale() != nullptr) + if (JitConfig.JitSynthesisExceptionWeight() != nullptr) { - ConfigDoubleArray JitSynthesisExceptionScaleArray; - JitSynthesisExceptionScaleArray.EnsureInit(JitConfig.JitSynthesisExceptionScale()); - weight_t newFactor = JitSynthesisExceptionScaleArray.GetData()[0]; + ConfigDoubleArray JitSynthesisExceptionWeightArray; + JitSynthesisExceptionWeightArray.EnsureInit(JitConfig.JitSynthesisExceptionWeight()); + weight_t newFactor = JitSynthesisExceptionWeightArray.GetData()[0]; if ((newFactor >= 0) && (newFactor <= 1.0)) { - exceptionScaleFactor = newFactor; + ehWeight = newFactor; } } #endif - JITDUMP("Synthesis: exception scale factor " FMT_WT "\n", exceptionScaleFactor); - const weight_t ehWeight = entryWeight * exceptionScaleFactor; + JITDUMP("Synthesis: exception weight " FMT_WT "\n", ehWeight); if (ehWeight != 0) { - // We can't inline methods with EH, also inlinees share the parent - // EH tab, so we can't rely on this being empty. + // We can't inline methods with EH. Inlinees share the parent + // EH tab, so we can't rely on the EH table being empty. // if (!m_comp->compIsForInlining()) { diff --git a/src/coreclr/jit/fgprofilesynthesis.h b/src/coreclr/jit/fgprofilesynthesis.h index 533c8fab2c007d..e704f291802e24 100644 --- a/src/coreclr/jit/fgprofilesynthesis.h +++ b/src/coreclr/jit/fgprofilesynthesis.h @@ -45,7 +45,7 @@ class ProfileSynthesis { } - static constexpr weight_t exceptionScale = 0.001; + static constexpr weight_t exceptionWeight = 0.00001; static constexpr weight_t initialBlendFactor = 0.05; static constexpr weight_t blendFactorGrowthRate = 3; static constexpr weight_t cappedLikelihood = 0.999; diff --git a/src/coreclr/jit/jitconfigvalues.h b/src/coreclr/jit/jitconfigvalues.h index b59e953839e501..23bfec85efd5be 100644 --- a/src/coreclr/jit/jitconfigvalues.h +++ b/src/coreclr/jit/jitconfigvalues.h @@ -719,9 +719,6 @@ CONFIG_INTEGER(JitRandomlyCollect64BitCounts, W("JitRandomlyCollect64BitCounts") // 3: profile synthesis for root methods, blend with existing PGO data CONFIG_INTEGER(JitSynthesizeCounts, W("JitSynthesizeCounts"), 0) -// Check if synthesis left consistent counts -CONFIG_INTEGER(JitCheckSynthesizedCounts, W("JitCheckSynthesizedCounts"), 0) - // If instrumenting the method, run synthesis and save the synthesis results // as edge or block profile data. Do not actually instrument. CONFIG_INTEGER(JitPropagateSynthesizedCountsToProfileData, W("JitPropagateSynthesizedCountsToProfileData"), 0) @@ -729,8 +726,8 @@ CONFIG_INTEGER(JitPropagateSynthesizedCountsToProfileData, W("JitPropagateSynthe // Use general (gauss-seidel) solver CONFIG_INTEGER(JitSynthesisUseSolver, W("JitSynthesisUseSolver"), 1) -// Relative likelihood of exceptions for synthesis -CONFIG_STRING(JitSynthesisExceptionScale, W("JitSynthesisExceptionScale")) +// Weight for exception regions for synthesis +CONFIG_STRING(JitSynthesisExceptionWeight, W("JitSynthesisExceptionWeight")) // Devirtualize virtual calls with getExactClasses (NativeAOT only for now) RELEASE_CONFIG_INTEGER(JitEnableExactDevirtualization, W("JitEnableExactDevirtualization"), 1)