Skip to content
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

small perf changes #889

Merged
merged 2 commits into from
Feb 2, 2021
Merged

small perf changes #889

merged 2 commits into from
Feb 2, 2021

Conversation

Wraith2
Copy link
Contributor

@Wraith2 Wraith2 commented Jan 26, 2021

I did a memory profile of the test case in #659 and noted some easy to fix issues:

Untitled

The ConnectionState change was using .Equals(object) which caused boxing, it's just changed to state value capture and a direct comparison. The ConcurrentQueueSemaphore simply changes a delegate instantiation and context capture to a static delegate and state object parameter invocation as we've used elsewhere to reduce allocations.

@cheenamalhotra cheenamalhotra added the 📈 Performance Issues that are targeted to performance improvements. label Feb 1, 2021
@cheenamalhotra cheenamalhotra merged commit 83584a1 into dotnet:master Feb 2, 2021
@Wraith2 Wraith2 mentioned this pull request Feb 3, 2021
@Wraith2 Wraith2 deleted the perf10 branch February 5, 2021 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📈 Performance Issues that are targeted to performance improvements.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants