Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,22 @@ public static void AssemblyInitialize(TestContext context)
{
NuGetGlobalPackagesFolder = new(".packages");
Environment.SetEnvironmentVariable("MSBUILDDISABLENODEREUSE", "1");

// Our MSTest/MTP integration tests run lots of builds via 'dotnet build' in child processes.
// Profiling that, we noticed lots of time is spent jitting.
// In one of the investigated occurrences, we saw this data:
// Process CPU time 21.11 seconds.
// 58.2% of that is jitting, which is roughly 12.28 seconds.
// From the trace:
// - Jitting trigger: Foreground -> 2.65 seconds.
// - Jitting trigger: Tiered Compilation Background -> 9.63 seconds
//
// Above was running:
// <RepoRoot>/.dotnet/dotnet.exe" build <RepoRoot>\artifacts\tmp\Debug\testsuite\Umx6q\DataRowTests -c Release -p:MSBuildTreatWarningsAsErrors=true -p:TreatWarningsAsErrors=true -p:SuppressNETCoreSdkPreviewMessage=true -bl:"<RepoRoot>\artifacts\tmp\Debug\testsuite\DataRowTests-87.binlog
//
// The whole MSTest.Acceptance.IntegrationTests run when running with tiered compilation enabled locally was roughly 30 minutes.
// After disabling tiered compilation, it went down to 20 minutes locally.
Environment.SetEnvironmentVariable("DOTNET_TieredCompilation", "0");
}

[AssemblyCleanup]
Expand Down
Loading