|
| 1 | +# 2025-02-25 Triage Log |
| 2 | + |
| 3 | +Fairly quiet week with the exception of an improvement to the very often used Iter::next function which can now be inlined leading to a myriad of performance improvements. |
| 4 | + |
| 5 | +Triage done by **@rylev**. |
| 6 | +Revision range: [ce36a966..f5729cfe](https://perf.rust-lang.org/?start=ce36a966c79e109dabeef7a47fe68e5294c6d71e&end=f5729cfed3c45e061e8a443677fc1d5ef9277df7&absolute=false&stat=instructions%3Au) |
| 7 | + |
| 8 | +**Summary**: |
| 9 | + |
| 10 | +| (instructions:u) | mean | range | count | |
| 11 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 12 | +| Regressions ❌ <br /> (primary) | 0.4% | [0.2%, 1.0%] | 37 | |
| 13 | +| Regressions ❌ <br /> (secondary) | 0.7% | [0.2%, 8.6%] | 54 | |
| 14 | +| Improvements ✅ <br /> (primary) | -0.5% | [-1.4%, -0.1%] | 88 | |
| 15 | +| Improvements ✅ <br /> (secondary) | -0.6% | [-2.3%, -0.1%] | 87 | |
| 16 | +| All ❌✅ (primary) | -0.2% | [-1.4%, 1.0%] | 125 | |
| 17 | + |
| 18 | + |
| 19 | +1 Regression, 1 Improvement, 7 Mixed; 2 of them in rollups |
| 20 | +40 artifact comparisons made in total |
| 21 | + |
| 22 | +#### Regressions |
| 23 | + |
| 24 | +Remove `NtVis` and `NtTy` [#133436](https://github.com/rust-lang/rust/pull/133436) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=b87eda7fdf8034c52b3abef52b443b8573484eda&end=b6d3be4948e92fce0236cbbe22b55c55f6950269&stat=instructions:u) |
| 25 | + |
| 26 | +| (instructions:u) | mean | range | count | |
| 27 | +|:----------------------------------:|:----:|:------------:|:-----:| |
| 28 | +| Regressions ❌ <br /> (primary) | 0.4% | [0.2%, 1.0%] | 18 | |
| 29 | +| Regressions ❌ <br /> (secondary) | 0.6% | [0.3%, 0.9%] | 11 | |
| 30 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 31 | +| Improvements ✅ <br /> (secondary) | - | - | 0 | |
| 32 | +| All ❌✅ (primary) | 0.4% | [0.2%, 1.0%] | 18 | |
| 33 | +- [Necessary perf hit](https://github.com/rust-lang/rust/pull/133436#issuecomment-2502075751) |
| 34 | + |
| 35 | + |
| 36 | +#### Improvements |
| 37 | + |
| 38 | +librustdoc: Use `pulldown-cmark-escape` for HTML escaping [#137285](https://github.com/rust-lang/rust/pull/137285) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=e0be1a02626abef2878cb7f4aaef7ae409477112&end=f43e549b88698568581a9d329c7582e3708ac187&stat=instructions:u) |
| 39 | + |
| 40 | +| (instructions:u) | mean | range | count | |
| 41 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 42 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 43 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 44 | +| Improvements ✅ <br /> (primary) | -0.3% | [-0.6%, -0.2%] | 14 | |
| 45 | +| Improvements ✅ <br /> (secondary) | -0.5% | [-1.5%, -0.1%] | 5 | |
| 46 | +| All ❌✅ (primary) | -0.3% | [-0.6%, -0.2%] | 14 | |
| 47 | + |
| 48 | + |
| 49 | +#### Mixed |
| 50 | + |
| 51 | +improve cold_path() [#133852](https://github.com/rust-lang/rust/pull/133852) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=aaa861493456e8a10e552dd208f85486de772007&end=3b022d8ceea570db9730be34d964f0cc663a567f&stat=instructions:u) |
| 52 | + |
| 53 | +| (instructions:u) | mean | range | count | |
| 54 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 55 | +| Regressions ❌ <br /> (primary) | 0.4% | [0.1%, 0.9%] | 7 | |
| 56 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 57 | +| Improvements ✅ <br /> (primary) | -0.7% | [-0.7%, -0.7%] | 1 | |
| 58 | +| Improvements ✅ <br /> (secondary) | - | - | 0 | |
| 59 | +| All ❌✅ (primary) | 0.2% | [-0.7%, 0.9%] | 8 | |
| 60 | +- Expected perf regressions that were [deemed worth it](https://github.com/rust-lang/rust/pull/133852#issuecomment-2657312984) |
| 61 | + |
| 62 | + |
| 63 | +Rollup of 9 pull requests [#137295](https://github.com/rust-lang/rust/pull/137295) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=4e1356b95972c1a52acb9f0dd078687132ec02be&end=6d3c050de81c8858e28b0e59cc9398d840edfbff&stat=instructions:u) |
| 64 | + |
| 65 | +| (instructions:u) | mean | range | count | |
| 66 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 67 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 68 | +| Regressions ❌ <br /> (secondary) | 1.0% | [1.0%, 1.0%] | 1 | |
| 69 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 70 | +| Improvements ✅ <br /> (secondary) | -0.3% | [-0.3%, -0.3%] | 1 | |
| 71 | +| All ❌✅ (primary) | - | - | 0 | |
| 72 | +- Perf results are too small for this to be worth investigating. |
| 73 | + |
| 74 | + |
| 75 | +Emit `trunc nuw` for unchecked shifts and `to_immediate_scalar` [#137058](https://github.com/rust-lang/rust/pull/137058) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=eeb9035117dc85fa4abe8e2abb09285fd65b0263&end=c62239aeb3ba7781a6d7f7055523c1e8c22b409c&stat=instructions:u) |
| 76 | + |
| 77 | +| (instructions:u) | mean | range | count | |
| 78 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 79 | +| Regressions ❌ <br /> (primary) | - | - | 0 | |
| 80 | +| Regressions ❌ <br /> (secondary) | 0.7% | [0.4%, 1.3%] | 16 | |
| 81 | +| Improvements ✅ <br /> (primary) | -0.5% | [-0.8%, -0.4%] | 4 | |
| 82 | +| Improvements ✅ <br /> (secondary) | -0.1% | [-0.1%, -0.1%] | 1 | |
| 83 | +| All ❌✅ (primary) | -0.5% | [-0.8%, -0.4%] | 4 | |
| 84 | +- Usually small changes in stress tests don't necessarily lead to perf investigations. |
| 85 | +- Asked the author for insight on whether this is worth investigating. |
| 86 | + |
| 87 | + |
| 88 | +Simplify `slice::Iter::next` enough that it inlines [#136771](https://github.com/rust-lang/rust/pull/136771) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=28b83ee59698ae069f5355b8e03f976406f410f5&end=f04bbc60f8c353ee5ba0677bc583ac4a88b2c180&stat=instructions:u) |
| 89 | + |
| 90 | +| (instructions:u) | mean | range | count | |
| 91 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 92 | +| Regressions ❌ <br /> (primary) | 0.4% | [0.4%, 0.4%] | 2 | |
| 93 | +| Regressions ❌ <br /> (secondary) | 8.8% | [8.8%, 8.8%] | 1 | |
| 94 | +| Improvements ✅ <br /> (primary) | -0.4% | [-1.4%, -0.1%] | 123 | |
| 95 | +| Improvements ✅ <br /> (secondary) | -0.5% | [-2.3%, -0.1%] | 70 | |
| 96 | +| All ❌✅ (primary) | -0.4% | [-1.4%, 0.4%] | 125 | |
| 97 | +- Perf improvements vastly outweigh the regressions |
| 98 | + |
| 99 | + |
| 100 | +Update host LLVM to 20.1 on CI [#137189](https://github.com/rust-lang/rust/pull/137189) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=46420c96070b4c4bd8242f16d5806b8f26a57016&end=07697360aee0cebcb4e304236ba1884d8dde5469&stat=instructions:u) |
| 101 | + |
| 102 | +| (instructions:u) | mean | range | count | |
| 103 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 104 | +| Regressions ❌ <br /> (primary) | 0.1% | [0.1%, 0.1%] | 1 | |
| 105 | +| Regressions ❌ <br /> (secondary) | - | - | 0 | |
| 106 | +| Improvements ✅ <br /> (primary) | -0.3% | [-0.3%, -0.2%] | 7 | |
| 107 | +| Improvements ✅ <br /> (secondary) | -0.4% | [-0.4%, -0.4%] | 1 | |
| 108 | +| All ❌✅ (primary) | -0.2% | [-0.3%, 0.1%] | 8 | |
| 109 | +- This is actually quite small perf difference for an LLVM change |
| 110 | + |
| 111 | + |
| 112 | +New attribute parsing infrastructure [#135726](https://github.com/rust-lang/rust/pull/135726) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=617aad8c2e8783f6df8e5d1f8bb1e4bcdc70aa7b&end=7d8c6e781d347e087c7d30ea393d7dcd725ed623&stat=instructions:u) |
| 113 | + |
| 114 | +| (instructions:u) | mean | range | count | |
| 115 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 116 | +| Regressions ❌ <br /> (primary) | 0.4% | [0.2%, 0.8%] | 38 | |
| 117 | +| Regressions ❌ <br /> (secondary) | 0.6% | [0.3%, 1.3%] | 43 | |
| 118 | +| Improvements ✅ <br /> (primary) | -4.1% | [-4.1%, -4.1%] | 1 | |
| 119 | +| Improvements ✅ <br /> (secondary) | -0.7% | [-2.4%, -0.3%] | 8 | |
| 120 | +| All ❌✅ (primary) | 0.3% | [-4.1%, 0.8%] | 39 | |
| 121 | +- See [here](https://github.com/rust-lang/rust/pull/137610#issuecomment-2682489608) for explanation for why there was a perf regression here. |
| 122 | + |
| 123 | + |
| 124 | +Rollup of 11 pull requests [#137573](https://github.com/rust-lang/rust/pull/137573) [(Comparison Link)](https://perf.rust-lang.org/compare.html?start=7d8c6e781d347e087c7d30ea393d7dcd725ed623&end=f5729cfed3c45e061e8a443677fc1d5ef9277df7&stat=instructions:u) |
| 125 | + |
| 126 | +| (instructions:u) | mean | range | count | |
| 127 | +|:----------------------------------:|:-----:|:--------------:|:-----:| |
| 128 | +| Regressions ❌ <br /> (primary) | 0.5% | [0.3%, 0.7%] | 3 | |
| 129 | +| Regressions ❌ <br /> (secondary) | 1.0% | [1.0%, 1.0%] | 1 | |
| 130 | +| Improvements ✅ <br /> (primary) | - | - | 0 | |
| 131 | +| Improvements ✅ <br /> (secondary) | -0.4% | [-0.4%, -0.4%] | 1 | |
| 132 | +| All ❌✅ (primary) | 0.5% | [0.3%, 0.7%] | 3 | |
| 133 | +- Results are too small to warrant an investigation. |
| 134 | + |
0 commit comments