-
Notifications
You must be signed in to change notification settings - Fork 1.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
ResolveAssemblyReference CPU optimizations #8916
Merged
Merged
Conversation
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
JanKrivanek
approved these changes
Jun 21, 2023
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.
Simple and effective - I do not have anything to criticize here
rainersigwald
approved these changes
Jun 21, 2023
Co-authored-by: Rainer Sigwald <raines@microsoft.com>
8 tasks
JaynieBai
added a commit
that referenced
this pull request
Jul 12, 2023
This reverts commit 1ff019a.
JaynieBai
added a commit
that referenced
this pull request
Jul 14, 2023
This reverts commit 1ff019a. Fixes # VS Insertion, C++ Project System - PR: VC.ProjectSystem.VCProject.CachedProjectAutomation fails since these changes. https://devdiv.visualstudio.com/DefaultCollection/DevDiv/_git/VS/pullRequest/483186#1689247828 So far I know the problem is in 1ff019a#diff-20c3f77300d596d35264f7f9351652e233cb3455c3f7a7262df4842d437fe8efR1407-R1414 but let's revert for now to unblock insertions. Thank you!
ladipro
added a commit
to ladipro/msbuild
that referenced
this pull request
Jul 17, 2023
…)" (dotnet#9037)" This reverts commit 4989625.
YuliiaKovalova
pushed a commit
to YuliiaKovalova/msbuild
that referenced
this pull request
Jul 18, 2023
### Context Low-hanging fruit is showing in RAR performance profiles. ### Changes Made 1. Avoided constructing `AssemblyName` on a hot path as the constructor makes expensive Fusion calls on .NET Framework. The problematic code was introduced in dotnet#8688. 2. Added a metadata bulk-set operation to the internal `IMetadataContainer` interface. Calling `SetMetadata` for more than a couple of metadata is slow if `ImmutableDictionary` is used as its backing storage. RAR is heavy on metadata manipulation and switching to the new operation saves about 10% of RAR run-time when building OrchardCore. ### Testing Existing and new unit tests. Measured the perf impact by building OC. --------- Co-authored-by: Rainer Sigwald <raines@microsoft.com>
YuliiaKovalova
pushed a commit
to YuliiaKovalova/msbuild
that referenced
this pull request
Jul 18, 2023
…tnet#9037) This reverts commit 1ff019a. Fixes # VS Insertion, C++ Project System - PR: VC.ProjectSystem.VCProject.CachedProjectAutomation fails since these changes. https://devdiv.visualstudio.com/DefaultCollection/DevDiv/_git/VS/pullRequest/483186#1689247828 So far I know the problem is in 1ff019a#diff-20c3f77300d596d35264f7f9351652e233cb3455c3f7a7262df4842d437fe8efR1407-R1414 but let's revert for now to unblock insertions. Thank you!
JaynieBai
pushed a commit
that referenced
this pull request
Jul 27, 2023
#8916 broke some .NET Framework scenarios and was reverted. This PR is a redo of the change with the bug fixed. It turned out that the destination of the optimized CopyMetadataTo may be a transparent proxy, typically a TaskItem object living in another appdomain, which does not work well with Linq. The fix and the test coverage are in their own commits. Context Low-hanging fruit is showing in RAR performance profiles. Changes Made Avoided constructing AssemblyName on a hot path as the constructor makes expensive Fusion calls on .NET Framework. The problematic code was introduced in [RAR] Don't do I/O on SDK-provided references #8688. Added a metadata bulk-set operation to the internal IMetadataContainer interface. Calling SetMetadata for more than a couple of metadata is slow if ImmutableDictionary is used as its backing storage. RAR is heavy on metadata manipulation and switching to the new operation saves about 10% of RAR run-time when building OrchardCore. Testing Existing and new unit tests. Measured the perf impact by building OC.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Context
Low-hanging fruit is showing in RAR performance profiles.
Changes Made
Avoided constructing
AssemblyName
on a hot path as the constructor makes expensive Fusion calls on .NET Framework. The problematic code was introduced in [RAR] Don't do I/O on SDK-provided references #8688.Added a metadata bulk-set operation to the internal
IMetadataContainer
interface. CallingSetMetadata
for more than a couple of metadata is slow ifImmutableDictionary
is used as its backing storage. RAR is heavy on metadata manipulation and switching to the new operation saves about 10% of RAR run-time when building OrchardCore.Testing
Existing and new unit tests. Measured the perf impact by building OC.