Uh oh!
There was an error while loading. Please reload this page.
Inline System.Boolean Parse helper methods - #64771
Conversation
- Profiling the boolean parse method showed that its helper methods weren't being inlined - Increases performance on the System.Tests.Perf_Boolean.Parse* microbenchmarks
ghost
commented
Feb 3, 2022
I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label. |
L2
commented
Feb 3, 2022
summary: No Slower results for the provided threshold = 5% and noise filter = 0.3ns.
|
danmoseley
commented
Feb 3, 2022
Thanks. It's unfortunately hard to make inlining decisions by running microbenchmarks - the microbenchmarks almost invariably get faster, but in a real app, the code can get significantly bigger. If it's helpful to inline these, perhaps we should consider why they're not getting inlined. |
stephentoub
commented
Feb 4, 2022
The implementations can be streamlined with fewer reads: |
L2
commented
Feb 4, 2022
Sounds good, I'll close this PR for now as @stephentoub 's implementation is the better way to go to extract more performance. Thanks again @danmoseley
@stephentoub , very nice! |
danmoseley
commented
Feb 4, 2022
Do appreciate the attempt though @L2. There are lots of issues marked up for grabs if you want to look at another. |
danmoseley
commented
Feb 4, 2022
And we appreciate the inspiration here! |
stephentoub
commented
Feb 4, 2022
Yeah I wouldn't have noticed if this PR didn't draw my eyes to it :-) |
helper methods weren't being inlined
microbenchmarks