Skip to content

Conversation

@Zalathar
Copy link
Member

If we make sure that compute_fn in the query's vtable is actually named __rust_begin_short_backtrace, we can avoid the need for some additional intermediate functions and stack frames.

This is similar to how the get_query_incr and get_query_non_incr functions are actually named __rust_end_short_backtrace.


If we make sure that `compute_fn` in the query's vtable is actually named
`__rust_begin_short_backtrace`, we can avoid the need for some additional
intermediate functions and stack frames.

This is similar to how the `get_query_incr` and `get_query_non_incr` functions
are actually named `__rust_end_short_backtrace`.
@rustbot rustbot added A-query-system Area: The rustc query system (https://rustc-dev-guide.rust-lang.org/query.html) S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Jan 27, 2026
@rustbot
Copy link
Collaborator

rustbot commented Jan 27, 2026

r? @fee1-dead

rustbot has assigned @fee1-dead.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@Zalathar
Copy link
Member Author

Let's have another perf run for the non-draft PR:

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rust-bors

This comment has been minimized.

rust-bors bot pushed a commit that referenced this pull request Jan 27, 2026
Use fewer intermediate functions for short backtraces in queries
@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 27, 2026
@rust-bors
Copy link
Contributor

rust-bors bot commented Jan 27, 2026

☀️ Try build successful (CI)
Build commit: 21dc8d7 (21dc8d7b26dfebb8e4647a138974547b9b201161, parent: 78df2f92de1da3601d967dc8beb9f9cea267e45f)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (21dc8d7): comparison URL.

Overall result: ❌✅ regressions and improvements - no action needed

Benchmarking 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
@rustbot label: -S-waiting-on-perf -perf-regression

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.0% [0.0%, 0.1%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.1% [-0.2%, -0.0%] 4
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -1.6%, secondary -2.2%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.6% [-1.9%, -1.3%] 2
Improvements ✅
(secondary)
-2.2% [-3.3%, -1.7%] 3
All ❌✅ (primary) -1.6% [-1.9%, -1.3%] 2

Cycles

Results (secondary 1.2%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
4.7% [2.7%, 6.4%] 4
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-3.6% [-3.8%, -3.4%] 3
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 472.873s -> 474.195s (0.28%)
Artifact size: 385.68 MiB -> 383.56 MiB (-0.55%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-query-system Area: The rustc query system (https://rustc-dev-guide.rust-lang.org/query.html) S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants