-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Optimize std::count
even more for vector<👻>
#2203
Conversation
remove reference to enable more optimization
Moving back to WIP until #2201 is merged, to avoid any confusion for maintainers. (This is just so we'll be able to review a simpler diff; no concerns with the actual changes at this time.) |
Also from our weekly meeting: |
# Conflicts: # stl/inc/limits
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.
These look good, still a bit frustrated the optimizer can't figure this out.
I was able to convey how to reproduce the optimizer bug, from DevCom-1527995 :
It is in Under investigation status now. So maybe it will be fixed, and we may avoid some of the tricks. |
yeah, I wish the compiler was better at hoisting the checks out of the loops by itself, oh well. |
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.
Looks good, I'll push a small comment change!
I'm mirroring this to an MSVC-internal PR; please notify me if any further changes are pushed. |
Thanks for this haunted PR! 👻 🦇 😸 |
Co-authored-by: Stephan T. Lavavej <[email protected]>
Continuation of #2201
Benchmark (compare run with and without changes):