Loading...
Loading...
Diagnose MSBuild build performance bottlenecks using binary log analysis. Only activate in MSBuild/.NET build context. USE FOR: identifying why builds are slow by analyzing binlog performance summaries, detecting ResolveAssemblyReference (RAR) taking >5s, Roslyn analyzers consuming >30% of Csc time, single targets dominating >50% of build time, node utilization below 80%, excessive Copy tasks, NuGet restore running every build. Covers timeline analysis, Target/Task Performance Summary interpretation, and 7 common bottleneck categories. Use after build-perf-baseline has established measurements. DO NOT USE FOR: establishing initial baselines (use build-perf-baseline first), fixing incremental build issues (use incremental-build), parallelism tuning (use build-parallelism), non-MSBuild build systems. INVOKES: dotnet msbuild binlog replay with performancesummary, grep for analysis.
npx skill4agent add dotnet/skills build-perf-diagnosticsdotnet build /bl:{} -mdotnet msbuild build.binlog -noconlog -fl -flp:v=diag;logfile=full.log;performancesummaryfull.loggrep "Target Performance Summary\|Task Performance Summary" -A 50 full.loggrep -i "node.*assigned\|building with\|scheduler" full.log | head -30grep -i "analyzer.*elapsed\|Total analyzer execution time\|CompilerAnalyzerDriver" full.log<DesignTimeBuild>false</DesignTimeBuild><ResolveAssemblyReferencesSilent>true</ResolveAssemblyReferencesSilent><DesignTimeBuild><ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch><DisableTransitiveProjectReferences>true</DisableTransitiveProjectReferences>ReferenceOutputAssembly="false"/p:RunAnalyzers=false<RunAnalyzers Condition="'$(ContinuousIntegrationBuild)' != 'true'">false</RunAnalyzers><RunAnalyzers Condition="'$(Configuration)' == 'Debug'">false</RunAnalyzers><EnforceCodeStyleInBuild Condition="'$(ContinuousIntegrationBuild)' == 'true'">true</EnforceCodeStyleInBuild>GlobalPackageReferenceDirectory.Packages.propstrueDirectory.Build.propsContinuousIntegrationBuildBuildInParallel<CreateHardLinksForCopyFilesToOutputDirectoryIfPossible>true</CreateHardLinksForCopyFilesToOutputDirectoryIfPossible><UseCommonOutputDirectory>true</UseCommonOutputDirectory><SkipCopyUnchangedFiles>true</SkipCopyUnchangedFiles>--artifacts-path<EnableDefaultItems>false</EnableDefaultItems>eval-performancedotnet restoredotnet build --no-restore<RestoreUseStaticGraphEvaluation>true</RestoreUseStaticGraphEvaluation>/graphdotnet msbuild build.binlog -noconlog -fl -flp:v=diag;logfile=full.log;performancesummaryfull.loggrep "Target Performance Summary\|Task Performance Summary" -A 50 full.loggrep "done building project\|Project Performance Summary" full.loggrep -i "node.*assigned\|RequiresLeadingNewline\|Building with" full.log | head -30grep -i "Total analyzer execution time\|analyzer.*elapsed\|CompilerAnalyzerDriver" full.loggrep 'Target "CoreCompile"\|Target "ResolveAssemblyReferences"' full.log/maxcpucount-mdotnet restoredotnet build --no-restore<RestoreUseStaticGraphEvaluation>true</RestoreUseStaticGraphEvaluation><CreateHardLinksForCopyFilesToOutputDirectoryIfPossible>true</CreateHardLinksForCopyFilesToOutputDirectoryIfPossible><RunAnalyzers Condition="'$(ContinuousIntegrationBuild)' != 'true'">false</RunAnalyzers><ProduceReferenceAssembly>true</ProduceReferenceAssembly>incremental-buildcheck-bin-obj-clash/graph--artifacts-path