rust/tests
bors 1ead4761e9 Auto merge of #119878 - scottmcm:inline-always-unwrap, r=workingjubilee
Tune the inlinability of `unwrap`

Fixes #115463
cc `@thomcc`

This tweaks `unwrap` on ~~`Option` &~~ `Result` to be two parts:
- `#[inline(always)]` for checking the discriminant
- `#[cold]` for actually panicking

The idea here is that checking the discriminant on a `Result` ~~or `Option`~~ should always be trivial enough to be worth inlining, even in `opt-level=z`, especially compared to passing it to a function.

As seen in the issue and codegen test, this will hopefully help particularly for things like `.try_into().unwrap()`s that are actually infallible, but in a way that's only visible with the inlining.

EDIT: I've restricted this to `Result` to avoid combining effects
2024-01-15 09:20:46 +00:00
..
assembly Support reg_addr register class in s390x inline assembly 2024-01-03 18:00:37 +09:00
auxiliary
codegen Auto merge of #119878 - scottmcm:inline-always-unwrap, r=workingjubilee 2024-01-15 09:20:46 +00:00
codegen-units Adjust compiler tests for unused_tuple_struct_fields -> dead_code 2024-01-02 15:34:37 -05:00
coverage coverage: llvm-cov expects column numbers to be bytes, not code points 2024-01-08 21:58:46 +11:00
coverage-run-rustdoc
debuginfo update debuginfo tests on Windows 2024-01-12 08:50:14 +01:00
incremental Disable opt in incremental test. 2023-12-24 20:08:58 +00:00
mir-opt Rollup merge of #119842 - Zalathar:kind, r=oli-obk 2024-01-11 19:42:51 +01:00
pretty Delegation implementation: step 1 2024-01-12 14:11:16 +03:00
run-make Revert "Auto merge of #113923 - DianQK:restore-no-builtins-lto, r=pnkfelix" 2024-01-12 18:23:04 +08:00
run-make-fulldeps Auto merge of #118899 - veera-sivarajan:fix-makefile, r=Mark-Simulacrum 2024-01-05 07:42:03 +00:00
run-pass-valgrind
rustdoc Rollup merge of #119561 - notriddle:master, r=fmease 2024-01-14 20:17:23 +01:00
rustdoc-gui rustdoc ui: adjust tooltip z-index to be above sidebar 2023-12-31 20:31:56 +01:00
rustdoc-js Rollup merge of #118194 - notriddle:notriddle/tuple-unit, r=GuillaumeGomez 2024-01-06 16:07:46 +01:00
rustdoc-js-std Rollup merge of #118194 - notriddle:notriddle/tuple-unit, r=GuillaumeGomez 2024-01-06 16:07:46 +01:00
rustdoc-json Add regression test for is_object_safe field on traits 2023-12-23 19:00:17 +01:00
rustdoc-ui Rollup merge of #119561 - notriddle:master, r=fmease 2024-01-14 20:17:23 +01:00
ui Rollup merge of #119944 - compiler-errors:no-match-due-to-gat-bounds, r=fmease 2024-01-14 14:02:28 +01:00
ui-fulldeps Bless tests 2024-01-13 12:46:58 -05:00
COMPILER_TESTS.md