|
| 1 | +# 2025-06-09 Triage Log |
| 2 | + |
| 3 | +Mostly positive week, with a lot of improvements in the type system, especially in new solver and one big win in caching code. Regressions come from new warnings, with outsized impact on one benchmark with a lot of generated code. |
| 4 | + |
| 5 | +Triage done by **@panstromek**. |
| 6 | +Revision range: [2fc3deed..c31cccb7](https://perf.rust-lang.org/?start=2fc3deed9fcb8762ad57191e0195f06f7543e4a5&end=c31cccb7b5cc098b1a8c1794ed38d7fdbec0ccb0&absolute=false&stat=instructions%3Au) |
| 7 | + |
| 8 | +**Summary**: |
| 9 | + |
| 10 | +| (instructions:u) | mean | range | count | |
| 11 | +|:----------------------------------:|:-----:|:---------------:|:-----:| |
| 12 | +| Regressions ❌ <br /> (primary) | 3.1% | [0.3%, 8.5%] | 22 | |
| 13 | +| Regressions ❌ <br /> (secondary) | 0.6% | [0.2%, 0.9%] | 3 | |
| 14 | +| Improvements ✅ <br /> (primary) | -1.0% | [-3.4%, -0.2%] | 151 | |
| 15 | +| Improvements ✅ <br /> (secondary) | -3.5% | [-66.5%, -0.2%] | 146 | |
| 16 | +| All ❌✅ (primary) | -0.4% | [-3.4%, 8.5%] | 173 | |
| 17 | + |
| 18 | + |
| 19 | +3 Regressions, 6 Improvements, 5 Mixed; 2 of them in rollups |
| 20 | +45 artifact comparisons made in total |
| 21 | + |
| 22 | +#### Regressions |
| 23 | + |
| 24 | +Use ccache for stage0 tool builds [#136942](https://github.com/rust-lang/rust/pull/136942) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=2f176126aaf3fd316fc5ced3d9a111a48797b52c&end=aae43c4532690153af7465227816c93036bb1604&stat=instructions:u) |
| 25 | + |
| 26 | +| (instructions:u) | mean | range | count | |
| 27 | +|:----------------------------------:|:----:|:------------:|:-----:| |
| 28 | +| Regressions ❌ <br /> (primary) | 2.9% | [2.9%, 2.9%] | 1 | |
| 29 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 30 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 31 | +| Improvements ✅ <br /> (secondary) | - | - | 0 | |
| 32 | +| All ❌✅ (primary) | 2.9% | [2.9%, 2.9%] | 1 | |
| 33 | + |
| 34 | +The regression is spurious, the affected benchmark is bi-modal. |
| 35 | + |
| 36 | +Move placeholder handling to a proper preprocessing step [#140466](https://github.com/rust-lang/rust/pull/140466) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=81a964c23ea4fe9ab52b4449bb166bf280035797&end=425e142686242c7e73f5e32c79071ae266f0f355&stat=instructions:u) |
| 37 | + |
| 38 | +| (instructions:u) | mean | range | count | |
| 39 | +|:----------------------------------:|:----:|:------------:|:-----:| |
| 40 | +| Regressions ❌ <br /> (primary) | 0.1% | [0.1%, 0.1%] | 1 | |
| 41 | +| Regressions ❌ <br /> (secondary) | 0.2% | [0.2%, 0.3%] | 8 | |
| 42 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 43 | +| Improvements ✅ <br /> (secondary) | - | - | 0 | |
| 44 | +| All ❌✅ (primary) | 0.1% | [0.1%, 0.1%] | 1 | |
| 45 | + |
| 46 | + |
| 47 | +These regressions look real. One tiny regression in Cargo and two secondary benchmarks - `coercions` and `ucd`, which are both based on giant static tables and are somewhat artificial. |
| 48 | + |
| 49 | +According to a [comment by author](https://github.com/rust-lang/rust/pull/140466#issuecomment-2955437404), this PR doesn't change runtime behavour, so those are probably just spurious. Most of the benchmarks improved since then and some of them are a bit noisy at times. |
| 50 | + |
| 51 | +This is a piece of larger important work (Polonius) and the regressions are pretty limited. [#130227](https://github.com/rust-lang/rust/pull/130227) (which this PR is part of) does have a bit different perf results, so I guess it will also make more sense asses the perf impact of this work when more pieces of it lands. |
| 52 | + |
| 53 | +Add a new `mismatched-lifetime-syntaxes` lint [#138677](https://github.com/rust-lang/rust/pull/138677) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=076ec59ff1dcf538b9d3a0b8e0d7f4edd0559959&end=ccf3198de316b488ee17441935182e9d5292b4d3&stat=instructions:u) |
| 54 | + |
| 55 | +| (instructions:u) | mean | range | count | |
| 56 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 57 | +| Regressions ❌ <br /> (primary) | 1.6% | [0.2%, 9.7%] | 72 | |
| 58 | +| Regressions ❌ <br /> (secondary) | 0.3% | [0.2%, 0.5%] | 11 | |
| 59 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 60 | +| Improvements ✅ <br /> (secondary) | -0.1% | [-0.1%, -0.1%] | 1 | |
| 61 | +| All ❌✅ (primary) | 1.6% | [0.2%, 9.7%] | 72 | |
| 62 | + |
| 63 | +Large regression on many benchmarks, most notably on `stm32f4`. Mostly caused by emitting more warnings. Author justified the regression in [an comment on the PR](https://github.com/rust-lang/rust/pull/138677#issuecomment-2940461051). Results and next steps are discussed in [dedicated zulip channel](https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/Perf.20regression.20for.20warn-by-default.20lint). |
| 64 | + |
| 65 | +#### Improvements |
| 66 | + |
| 67 | +Change per-module naked fn checks to happen during typeck instead [#141774](https://github.com/rust-lang/rust/pull/141774) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=9f0e5d963d05ebcf7ae1ca1f4bda3668c702acda&end=44f415c1d617ebc7b931a243b7b321ef8a6ca47c&stat=instructions:u) |
| 68 | + |
| 69 | +| (instructions:u) | mean | range | count | |
| 70 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 71 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 72 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 73 | +| Improvements ✅ <br /> (primary) | -0.1% | [-0.1%, -0.1%] | 11 | |
| 74 | +| Improvements ✅ <br /> (secondary) | -0.3% | [-0.4%, -0.2%] | 11 | |
| 75 | +| All ❌✅ (primary) | -0.1% | [-0.1%, -0.1%] | 11 | |
| 76 | + |
| 77 | + |
| 78 | +Rollup of 11 pull requests [#142133](https://github.com/rust-lang/rust/pull/142133) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=868bf2da31d1c6ead7016d5ee52eacfd2e2fd158&end=775e0c8aeb8f63192854b27156f8b05a06b51814&stat=instructions:u) |
| 79 | + |
| 80 | +| (instructions:u) | mean | range | count | |
| 81 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 82 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 83 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 84 | +| Improvements ✅ <br /> (primary) | -0.2% | [-0.2%, -0.2%] | 4 | |
| 85 | +| Improvements ✅ <br /> (secondary) | -0.3% | [-0.4%, -0.2%] | 8 | |
| 86 | +| All ❌✅ (primary) | -0.2% | [-0.2%, -0.2%] | 4 | |
| 87 | + |
| 88 | + |
| 89 | +Clear nested candidates in select if certainty is yes [#141927](https://github.com/rust-lang/rust/pull/141927) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=5e0bdaa9dde845b8e44fd93bf0c09d21ca60daa1&end=2f2c8c3512e82e4315db83bbb53eb79e2c566270&stat=instructions:u) |
| 90 | + |
| 91 | +| (instructions:u) | mean | range | count | |
| 92 | +|:----------------------------------:|:-----:|:---------------:|:-----:| |
| 93 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 94 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 95 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 96 | +| Improvements ✅ <br /> (secondary) | -3.5% | [-20.7%, -0.4%] | 11 | |
| 97 | +| All ❌✅ (primary) | - | - | 0 | |
| 98 | + |
| 99 | + |
| 100 | +Remove CollectItemTypesVisitor [#142074](https://github.com/rust-lang/rust/pull/142074) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=a5584a8fe16037dc01782064fa41424a6dbe9987&end=0b65d0db5f77c44bf37b4a25489562d68c14aecf&stat=instructions:u) |
| 101 | + |
| 102 | +| (instructions:u) | mean | range | count | |
| 103 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 104 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 105 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 106 | +| Improvements ✅ <br /> (primary) | -0.1% | [-0.1%, -0.1%] | 1 | |
| 107 | +| Improvements ✅ <br /> (secondary) | -0.2% | [-0.4%, -0.1%] | 8 | |
| 108 | +| All ❌✅ (primary) | -0.1% | [-0.1%, -0.1%] | 1 | |
| 109 | + |
| 110 | + |
| 111 | +Filter out universals and lifetimes from `stalled_vars` [#142088](https://github.com/rust-lang/rust/pull/142088) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=8072811356a178dbdf8ca09b1635cfafd4661971&end=244bbfc60ee8593db96892468eee876240cb7ba1&stat=instructions:u) |
| 112 | + |
| 113 | +| (instructions:u) | mean | range | count | |
| 114 | +|:----------------------------------:|:------:|:---------------:|:-----:| |
| 115 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 116 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 117 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 118 | +| Improvements ✅ <br /> (secondary) | -10.2% | [-29.8%, -0.1%] | 15 | |
| 119 | +| All ❌✅ (primary) | - | - | 0 | |
| 120 | + |
| 121 | + |
| 122 | +Simplify and optimize `VecCache`'s `SlotIndex::from_index` [#142095](https://github.com/rust-lang/rust/pull/142095) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=244bbfc60ee8593db96892468eee876240cb7ba1&end=fb644e6a1a7d34c6bbb5ecfe5c185f8c977d6bb3&stat=instructions:u) |
| 123 | + |
| 124 | +| (instructions:u) | mean | range | count | |
| 125 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 126 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 127 | +| Regressions ❌ <br /> (secondary) | 0.3% | [0.2%, 0.4%] | 4 | |
| 128 | +| Improvements ✅ <br /> (primary) | -0.8% | [-3.4%, -0.2%] | 184 | |
| 129 | +| Improvements ✅ <br /> (secondary) | -1.0% | [-4.8%, -0.2%] | 112 | |
| 130 | +| All ❌✅ (primary) | -0.8% | [-3.4%, -0.2%] | 184 | |
| 131 | + |
| 132 | + |
| 133 | +#### Mixed |
| 134 | + |
| 135 | +Merge coroutine obligation checking into borrowck parallel loop [#141773](https://github.com/rust-lang/rust/pull/141773) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=2fc3deed9fcb8762ad57191e0195f06f7543e4a5&end=91fad92585b2dafc52a074e502b2a6c1f093ca35&stat=instructions:u) |
| 136 | + |
| 137 | +| (instructions:u) | mean | range | count | |
| 138 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 139 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 140 | +| Regressions ❌ <br /> (secondary) | 0.4% | [0.3%, 0.5%] | 2 | |
| 141 | +| Improvements ✅ <br /> (primary) | -2.9% | [-2.9%, -2.9%] | 1 | |
| 142 | +| Improvements ✅ <br /> (secondary) | - | - | 0 | |
| 143 | +| All ❌✅ (primary) | -2.9% | [-2.9%, -2.9%] | 1 | |
| 144 | + |
| 145 | +Looks like noise, the affected benchmarks keep following similar pattern (`clap-derive` is bimodal, the other two secondary benchmarks are noisy). |
| 146 | + |
| 147 | +Rollup of 8 pull requests [#141944](https://github.com/rust-lang/rust/pull/141944) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=b17dba45186c454576d0fc8fb93ecc65eb1a763a&end=c68032fd4c442d275f4daa571ba19c076106b490&stat=instructions:u) |
| 148 | + |
| 149 | +| (instructions:u) | mean | range | count | |
| 150 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 151 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 152 | +| Regressions ❌ <br /> (secondary) | 0.2% | [0.2%, 0.3%] | 5 | |
| 153 | +| Improvements ✅ <br /> (primary) | -0.6% | [-1.1%, -0.2%] | 3 | |
| 154 | +| Improvements ✅ <br /> (secondary) | - | - | 0 | |
| 155 | +| All ❌✅ (primary) | -0.6% | [-1.1%, -0.2%] | 3 | |
| 156 | + |
| 157 | +Few regressions in unused-warnings. This looks like noise to me for the most part - check and opt builds don't agree on whether frontend times regressed or not and the benchmark since returned to previous state (partly in another rollup). |
| 158 | + |
| 159 | +I would suspect #141741 to be the cause, because it touched use statements and unused-warnings is a large list of use statements, but that one had different pre-merge results. I don't think this is worth digging into, though. |
| 160 | + |
| 161 | +Rework `collect_and_apply` to not rely on size hint for optimization [#141652](https://github.com/rust-lang/rust/pull/141652) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=792fc2b033aea7ea7b766e38bdc40f7d6bdce8c3&end=d9a739363878a06633eb912e44f02a3c5d6ba08c&stat=instructions:u) |
| 162 | + |
| 163 | +| (instructions:u) | mean | range | count | |
| 164 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 165 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 166 | +| Regressions ❌ <br /> (secondary) | 0.3% | [0.3%, 0.4%] | 6 | |
| 167 | +| Improvements ✅ <br /> (primary) | -0.2% | [-0.4%, -0.1%] | 9 | |
| 168 | +| Improvements ✅ <br /> (secondary) | -0.5% | [-1.0%, -0.2%] | 49 | |
| 169 | +| All ❌✅ (primary) | -0.2% | [-0.4%, -0.1%] | 9 | |
| 170 | + |
| 171 | +Improvements outweigh regressions. Regressions are limited to `wg-grammar`. Also justified by [review comment](https://github.com/rust-lang/rust/pull/141652#issuecomment-2936239135). |
| 172 | + |
| 173 | +Fast path for stalled obligations on self ty [#141681](https://github.com/rust-lang/rust/pull/141681) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=f315e6145802e091ff9fceab6db627a4b4ec2b86&end=9f0e5d963d05ebcf7ae1ca1f4bda3668c702acda&stat=instructions:u) |
| 174 | + |
| 175 | +| (instructions:u) | mean | range | count | |
| 176 | +|:----------------------------------:|:-----:|:---------------:|:-----:| |
| 177 | +| Regressions ❌ <br /> (primary) | 0.2% | [0.2%, 0.2%] | 1 | |
| 178 | +| Regressions ❌ <br /> (secondary) | 0.6% | [0.1%, 1.3%] | 14 | |
| 179 | +| Improvements ✅ <br /> (primary) | -0.2% | [-0.3%, -0.1%] | 25 | |
| 180 | +| Improvements ✅ <br /> (secondary) | -4.3% | [-50.3%, -0.0%] | 43 | |
| 181 | +| All ❌✅ (primary) | -0.2% | [-0.3%, 0.2%] | 26 | |
| 182 | + |
| 183 | +Improvements outweigh regressions, those are mostly on stress tests. Some regressions also don't seem to be related, they just return back to state before [#141652](https://github.com/rust-lang/rust/pull/141652). |
| 184 | + |
| 185 | +Don't walk into `Certainty::Yes` goals [#142085](https://github.com/rust-lang/rust/pull/142085) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=0b65d0db5f77c44bf37b4a25489562d68c14aecf&end=8072811356a178dbdf8ca09b1635cfafd4661971&stat=instructions:u) |
| 186 | + |
| 187 | +| (instructions:u) | mean | range | count | |
| 188 | +|:----------------------------------:|:-----:|:---------------:|:-----:| |
| 189 | +| Regressions ❌ <br /> (primary) | 1.4% | [1.4%, 1.4%] | 1 | |
| 190 | +| Regressions ❌ <br /> (secondary) | 1.4% | [1.4%, 1.4%] | 1 | |
| 191 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 192 | +| Improvements ✅ <br /> (secondary) | -8.7% | [-17.9%, -0.8%] | 6 | |
| 193 | +| All ❌✅ (primary) | 1.4% | [1.4%, 1.4%] | 1 | |
| 194 | + |
| 195 | +Syn regression is spurious, it's just returning to the default state in bimodal pattern. |
| 196 | + |
| 197 | +Secondary regression is limited to new solver benchmark. New solver is not enabled by default, yet. |
0 commit comments