-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Speed up Token::{ident,lifetime}
#96683
Speed up Token::{ident,lifetime}
#96683
Conversation
They're hot enough that the repeated matching done by `uninterpolate` has a measurable effect.
The comment on this function explains that it's a specialized version of `maybe_whole_expr`. But `maybe_whole_expr` doesn't do anything with `NtIdent`, so `is_whole_expr` also doesn't need to.
Some instruction counts results for
And for some benchmarks outside of rustc-perf:
|
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit 1d2e172 with merge 1def8abfd2755bd91a8833fa7c0e8b0a941c63a2... |
☀️ Try build successful - checks-actions |
Queued 1def8abfd2755bd91a8833fa7c0e8b0a941c63a2 with parent 086bf7a, future comparison URL. |
Finished benchmarking commit (1def8abfd2755bd91a8833fa7c0e8b0a941c63a2): comparison url. Summary:
If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf. @bors rollup=never Footnotes |
@bors r+ |
📌 Commit 1d2e172 has been approved by |
☀️ Test successful - checks-actions |
Finished benchmarking commit (343889b): comparison url. Summary:
If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. @rustbot label: -perf-regression Footnotes |
Some speed and cleanliness improvements.
r? @petrochenkov