Skip to content

Anyway to isolate Dynamic PGO impact? #2332

Answered by aalmada
davepcallan asked this question in Q&A
Discussion options

You must be logged in to vote

You can turn on the PGO flags using a configuration. To turn on for all benchmarks, use the following config as a parameter for your BenchmarkSwitcher:

 var config = DefaultConfig.Instance
   .AddJob(Job.Default
        .WithRuntime(CoreRuntime.Core60)
        .WithEnvironmentVariables(
            new EnvironmentVariable("DOTNET_ReadyToRun", "0"), // Disable AOT
            new EnvironmentVariable("DOTNET_TC_QuickJitForLoops", "1"), // Enable Quick Jit for loop
            new EnvironmentVariable("DOTNET_TieredPGO", "1")) // Turn on layered PGO
        .WithId(".NET 6 PGO");

The flags are set as specified at https://devblogs.microsoft.com/dotnet/performance-improvements-in-net-6/

Replies: 4 comments 4 replies

Comment options

You must be logged in to vote
2 replies
@davepcallan
Comment options

@aalmada
Comment options

Answer selected by davepcallan
Comment options

You must be logged in to vote
1 reply
@AndyAyersMS
Comment options

Comment options

You must be logged in to vote
1 reply
@AndyAyersMS
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants