Rollup of 4 perf-sensitive pull requests - #162859
Conversation
Because it is derived from `PerOwnerLoweringState::owner`.
They are constants but they don't look like it because they are stored in fields. This commit makes them statics. `allow_gen_future` becomes a method because its value depends on `async_fn_track_caller`.
Cache block seeking results for initialized_at_terminator and _exit Caching the block values post-seek results in significant performance wins (especially on pathological benchmarks). These wins extend to NLL, too. Possibly, this caching could be done further up the stack (more generically), but figured this is a "safer" approach - rather than dealing with other potential fallout. r? lqd
…ient-crates, r=petrochenkov [rustc_resolve] Correctly keep all reexports in `ModChild::reexport_chain` Fixes rust-lang#81893. First commit comes from rust-lang#161872 and it's the base I used for the fix in the second commit (which also reverts basically everything from the first commit, not sure if I should keep it...). In short, `NameResolution` only seems to have access to local reexports and to the final reexported item. So instead, we keep the information in `DeclKind` (which cannot implement `Drop` because it's part of `DeclData` which is stored in `ResolverArenas::dropless` so I kept a slice instead of a `SmallVec`. Guess how I found out? Lots of `panic`s :') ) and we use this information in `reexport_chain`. r? @petrochenkov
…ker-first-context, r=petrochenkov perf: Keep the first macro syntax-context mapping inline
…pastorino Lowering cleanups Details in the individual commits. r? @spastorino
This comment has been minimized.
This comment has been minimized.
Rollup of 4 pull requests try-job: dist-various-1 try-job: test-various try-job: test-x86_64-gnu-aux try-job: test-x86_64-gnu-llvm-21-3 try-job: test-x86_64-msvc-1 try-job: test-aarch64-apple-1 try-job: test-aarch64-apple-2 try-job: test-x86_64-mingw-1 try-job: test-i686-msvc try-job: test-armhf-gnu
This comment has been minimized.
This comment has been minimized.
…uwer Rollup of 4 perf-sensitive pull requests Successful merges: - #162450 (Cache block seeking results for initialized_at_terminator and _exit) - #162543 ([rustc_resolve] Correctly keep all reexports in `ModChild::reexport_chain`) - #162712 (perf: Keep the first macro syntax-context mapping inline) - #162747 (Lowering cleanups)
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
💔 Test for bb1f487 failed: CI. Failed job:
|
This comment has been minimized.
This comment has been minimized.
…uwer Rollup of 4 perf-sensitive pull requests Successful merges: - #162450 (Cache block seeking results for initialized_at_terminator and _exit) - #162543 ([rustc_resolve] Correctly keep all reexports in `ModChild::reexport_chain`) - #162712 (perf: Keep the first macro syntax-context mapping inline) - #162747 (Lowering cleanups)
|
Let's also do a try job in parallel to get a second opinion. @bors try jobs=test-aarch64-msvc-1 |
This comment has been minimized.
This comment has been minimized.
Rollup of 4 perf-sensitive pull requests try-job: test-aarch64-msvc-1
|
💔 Test for eec2d1e failed: CI. Failed job:
|
|
Couldn’t get logs, so the failure is probably bogus. @bors retry |
This comment has been minimized.
This comment has been minimized.
What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing 923c95c (parent) -> c999cef (this PR) Test differencesShow 7 test diffsStage 1
Stage 2
Additionally, 5 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard c999cef531ea9059e189e82fe0e82c5daf249bc9 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
Finished benchmarking commit (c999cef): comparison URL. Overall result: ❌✅ regressions and improvements - please read:Our benchmarks found a performance regression caused by this PR. Next Steps:
@rustbot label: +perf-regression 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 2.3%, secondary 1.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesThis perf run didn't have relevant results for this metric. Binary sizeThis perf run didn't have relevant results for this metric. Bootstrap: 497.899s -> 500.132s (0.45%) |
|
📌 Perf builds for each rolled up PR:
parent commit: 923c95cdf5 In the case of a perf regression, run the following command with the SHAs of each PR you suspect might be the cause: |
|
@rust-timer triage all |
Running triage with 31 benchmarksTriage only executes the benchmarks on rollup members, that were changed significantly on the rollup.
#162450 89b0093 Cache block seeking results for initialized_at_terminator and _exitInstruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary -3.1%, secondary 3.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 0.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis perf run didn't have relevant results for this metric. #162543 a289e4f [rustc_resolve] Correctly keep all reexports in
|
| mean | range | count | |
|---|---|---|---|
| Regressions ❌ (primary) |
0.4% | [0.2%, 0.8%] | 11 |
| Regressions ❌ (secondary) |
0.4% | [0.3%, 0.7%] | 5 |
| Improvements ✅ (primary) |
- | - | 0 |
| Improvements ✅ (secondary) |
-0.8% | [-0.8%, -0.8%] | 3 |
| All ❌✅ (primary) | 0.4% | [0.2%, 0.8%] | 11 |
Max RSS (memory usage)
Results (primary -0.2%, secondary -1.6%)
A less reliable metric. May be of interest, but not used to determine the overall result above.
| mean | range | count | |
|---|---|---|---|
| Regressions ❌ (primary) |
2.0% | [2.0%, 2.0%] | 1 |
| Regressions ❌ (secondary) |
3.4% | [1.0%, 5.2%] | 3 |
| Improvements ✅ (primary) |
-2.4% | [-2.4%, -2.4%] | 1 |
| Improvements ✅ (secondary) |
-4.7% | [-5.5%, -4.1%] | 5 |
| All ❌✅ (primary) | -0.2% | [-2.4%, 2.0%] | 2 |
Cycles
Results (primary 2.1%)
A less reliable metric. May be of interest, but not used to determine the overall result above.
| mean | range | count | |
|---|---|---|---|
| Regressions ❌ (primary) |
2.1% | [2.1%, 2.1%] | 1 |
| Regressions ❌ (secondary) |
- | - | 0 |
| Improvements ✅ (primary) |
- | - | 0 |
| Improvements ✅ (secondary) |
- | - | 0 |
| All ❌✅ (primary) | 2.1% | [2.1%, 2.1%] | 1 |
Binary size
This perf run didn't have relevant results for this metric.
#162712 4395c62 perf: Keep the first macro syntax-context mapping inline
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.1% | [0.1%, 0.2%] | 5 |
| Improvements ✅ (primary) |
-0.4% | [-0.9%, -0.2%] | 38 |
| Improvements ✅ (secondary) |
-0.5% | [-0.9%, -0.2%] | 17 |
| All ❌✅ (primary) | -0.4% | [-0.9%, -0.2%] | 38 |
Max RSS (memory usage)
Results (primary -1.2%, secondary -1.3%)
A less reliable metric. May be of interest, but not used to determine the overall result above.
| mean | range | count | |
|---|---|---|---|
| Regressions ❌ (primary) |
1.0% | [1.0%, 1.0%] | 1 |
| Regressions ❌ (secondary) |
2.7% | [1.1%, 4.7%] | 3 |
| Improvements ✅ (primary) |
-2.3% | [-2.3%, -2.3%] | 2 |
| Improvements ✅ (secondary) |
-4.4% | [-4.6%, -4.1%] | 4 |
| All ❌✅ (primary) | -1.2% | [-2.3%, 1.0%] | 3 |
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#162747 4da6ef7 Lowering cleanups
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.2% | [0.1%, 0.2%] | 3 |
| Improvements ✅ (primary) |
-0.3% | [-0.5%, -0.1%] | 67 |
| Improvements ✅ (secondary) |
-0.6% | [-1.5%, -0.2%] | 46 |
| All ❌✅ (primary) | -0.3% | [-0.5%, -0.1%] | 67 |
Max RSS (memory usage)
Results (primary -2.6%, secondary -2.0%)
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) |
3.4% | [2.3%, 4.5%] | 2 |
| Improvements ✅ (primary) |
-2.6% | [-2.6%, -2.6%] | 1 |
| Improvements ✅ (secondary) |
-4.7% | [-5.1%, -4.1%] | 4 |
| All ❌✅ (primary) | -2.6% | [-2.6%, -2.6%] | 1 |
Cycles
Results (secondary -2.6%)
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) |
- | - | 0 |
| Improvements ✅ (secondary) |
-2.6% | [-2.6%, -2.6%] | 1 |
| All ❌✅ (primary) | - | - | 0 |
Binary size
This perf run didn't have relevant results for this metric.
|
#162543 (comment) should be the source of the regression |
|
I'm aware, the goal of the triage run is to verify that the actual performance effect of the member PRs of this rollup matches the expected one from earlier perf runs |
View all comments
Successful merges:
ModChild::reexport_chain#162543 ([rustc_resolve] Correctly keep all reexports inModChild::reexport_chain)r? @ghost
Create a similar rollup