Skip to content

Conversation

@ladipro
Copy link
Member

@ladipro ladipro commented Apr 10, 2024

Fixes: AB#2014670

Description

A change was made in 8.0.2xx to register MSBuildSdkResolver for NGEN (#17732), against both devenv.exe and MSBuild.exe. Later a bug was found in the way MSBuild.exe loads the resolver so the change was reverted in 8.0.3xx (#19112). However, because the change had a measurable positive perf effect, the revert was effectively a regression for devenv.exe and got flagged so by PerfDDRITs.

This PR is a re-do of the original change, only this time with MSBuild.exe omitted, i.e. we're NGENing the resolver only for the default architecture of devenv.exe.

Customer Impact

Startup perf regression, about 5% more methods JITted in scenarios measured by Visual Studio PerfDDRITs.

Regression

Yes, perf regression in VS 17.10.

Risk

Low

github-actions bot and others added 2 commits April 10, 2024 15:22
…nd its dependencies (dotnet#17750)

Backport of dotnet#17732 to release/8.0.2xx

MSBuild.exe currently spends a significant amount of time JITting `Microsoft.DotNet.MSBuildSdkResolver` and its dependencies, see dotnet/msbuild#9303 for details.

This PR makes Visual Studio installer add these assemblies to the NGEN queue, which is a necessary condition for eliminating JITting. Just like `Microsoft.Build.*` assemblies, we need to NGEN these with two configurations: vsn.exe so it works in the devenv process, and MSBuild.exe so it works in MSBuild satellite processes.
@ladipro ladipro requested review from davkean and joeloff April 10, 2024 13:42
@ladipro ladipro added this to the 8.0.3 milestone Apr 10, 2024
@ladipro ladipro self-assigned this Apr 11, 2024
@ladipro
Copy link
Member Author

ladipro commented Apr 11, 2024

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@leecow leecow modified the milestones: 8.0.3, 8.0.5 Apr 11, 2024
@ladipro ladipro enabled auto-merge (squash) April 12, 2024 13:46
@ladipro ladipro merged commit 2e4e62f into dotnet:release/8.0.3xx Apr 12, 2024
@ladipro ladipro deleted the ngen-sdkresolver-devenv-only branch May 2, 2024 07:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants