-
Notifications
You must be signed in to change notification settings - Fork 13.8k
cg_llvm: Perform target-machine command-line quoting as bytes, not characters #146957
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
Conversation
This works because the only characters we care about escaping are ASCII characters, so forwarding non-ASCII UTF-8 bytes as-is still produces correct results.
rustbot has assigned @petrochenkov. Use |
I did make some tweaks since the original experiment (pre-computing a buffer size and re-validating the output), so let's do another perf run. @bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
cg_llvm: Perform target-machine command-line quoting as bytes, not characters
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (341189b): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary -1.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesThis benchmark run did not return any relevant results for this metric. Binary sizeResults (secondary -0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 470.741s -> 469.606s (-0.24%) |
Closing this while we see how #147022 shakes out. |
EDIT: There is now a proposal to remove the underlying code entirely, which would make this PR obsolete.
(Slightly modified version of the original experiment at #146804.)
This works because the only characters we care about escaping are ASCII characters, so forwarding non-ASCII UTF-8 bytes as-is still produces correct results.
A perf run at #146804 (comment) indicates that this has a big impact on several versions of the
large-workspace
benchmark.This PR doesn't address the underlying problem, which is that we're doing this quoting far too many times overall. Really we shouldn't be doing it more than once per process, but in practice we do it multiple times per CGU, which is bad news for incremental builds.
But these changes are basically a free win, so I'm happy to merge them anyway.