-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replay Binary Log Tool #72619
Merged
Merged
Replay Binary Log Tool #72619
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
d2448f6
Replay Binary Log Tool
jaredpar c1d2b2e
fixes
jaredpar 76191df
Apply suggestions from code review
jaredpar 15a8408
PR feedback
jaredpar 5373ee9
PR feedback
jaredpar 01ec280
Apply suggestions from code review
jaredpar 93335cd
Merge remote-tracking branch 'origin/main' into replay
jaredpar 546b39b
Merge remote-tracking branch 'jaredpar/replay' into replay
jaredpar 711858b
Apply suggestions from code review
jaredpar dd6af01
PR feedback
jaredpar File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Replay | ||
|
||
This is a tool for replaying the compilation events from a [binary log][binary-log] directly into the compiler server. This is very useful for profiling the compiler as it removes the overhead of msbuild from the logs. This gives a much simpler view of the compiler's performance. | ||
|
||
The other advantage is the tool allows for easy testing of performance changes to the compiler. Developers can have two branches of the code, one with performance changes and one without, then run `replay` against the same binary log and analyze the performance differences. | ||
|
||
Note: this is only supported for replaying binary logs on the same machine they were built. | ||
|
||
## Usage | ||
|
||
The first step is to run a build locally and collect a binary log. For example: | ||
|
||
```cmd | ||
e:\code\example> dotnet msbuild -bl -v:m -m Example.sln | ||
``` | ||
|
||
Then run the replay tool against that log. | ||
|
||
```cmd | ||
e:\code\roslyn> cd src\Tools\Replay | ||
e:\code\roslyn\src\Tools\Replay> dotnet run --framework net472 e:\code\example\msbuild.binlog -o e:\temp | ||
``` | ||
|
||
This runs all of the compilation events in the binary log against the compiler and outputs the results to `e:\temp`. | ||
|
||
[binary-log]: https://github.com/dotnet/msbuild/blob/main/documentation/wiki/Binary-Log.md |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no need for this anymore as part of our repo setup includes installing
pwsh
as a local tool.