The flag setting ScavengeRootsInCode=2 causes the JIT to inline more constants. This is generally a good thing for performance, but can cause bugs in compiled code.
In the attached code, there is a crash when the second benchmark runs. (The first benchmark completes with doubled speed, compared with the default setting of ScavengeRootsInCode=1.)
By fixing this bug and similar blocking bugs, we should be able to turn ScavengeRootsInCode=2 by default.