Skip to content

Instantly share code, notes, and snippets.

@WhiteBlackGoose
Created November 12, 2021 14:22
Show Gist options
  • Save WhiteBlackGoose/dd2fcd088b3d45e117d1a47ded02f686 to your computer and use it in GitHub Desktop.
Save WhiteBlackGoose/dd2fcd088b3d45e117d1a47ded02f686 to your computer and use it in GitHub Desktop.
Difference between normal run and with dynamic PGO for AngouriMath

Dynamic PGO benefits

Benchmark results of library AngouriMath

Method Normal Dynamic PGO Ratio
ParseEasy 66,693.984 ns 61,165.195 ns 0.91
ParseHard 4,983,373.234 ns 4,274,219.847 ns 0.85
SimplifyEasy 70,949.222 ns 62,232.968 ns 0.87
SimplifyHard 4,052,418,866.667 ns 3,521,537,094.737 ns 0.86
Derivate 46,783.692 ns 37,550.129 ns 0.80
SolveEasy 33,933,340.947 ns 31,231,974.333 ns 0.92
SolveEasyMedium 82,131.507 ns 68,822.175 ns 0.83
SolveMedium 2,747,711.385 ns 2,336,371.176 ns 0.85
SolveMediumHard 344,247,729.787 ns 310,786,443.750 ns 0.90
SolveHard 2,938,525,818.280 ns 2,556,127,354.639 ns 0.86
EvalEasy 9.081 ns 7.142 ns 0.78

Both runs' setup:

BenchmarkDotNet=v0.13.0, OS=Windows 10.0.19042.1288 (20H2/October2020Update)
Intel Core i7-7700HQ CPU 2.80GHz (Kaby Lake), 1 CPU, 8 logical and 4 physical cores
.NET SDK=6.0.100
  [Host]     : .NET 6.0.0 (6.0.21.52210), X64 RyuJIT
  DefaultJob : .NET 6.0.0 (6.0.21.52210), X64 RyuJIT

Benchmarks can be found here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment