rust/tests/mir-opt/inline
bors 22a7a19f93 Auto merge of #98112 - saethlin:mir-alignment-checks, r=oli-obk
Insert alignment checks for pointer dereferences when debug assertions are enabled

Closes https://github.com/rust-lang/rust/issues/54915

- [x] Jake tells me this sounds like a place to use `MirPatch`, but I can't figure out how to insert a new basic block with a new terminator in the middle of an existing basic block, using `MirPatch`. (if nobody else backs up this point I'm checking this as "not actually a good idea" because the code looks pretty clean to me after rearranging it a bit)
- [x] Using `CastKind::PointerExposeAddress` is definitely wrong, we don't want to expose. Calling a function to get the pointer address seems quite excessive. ~I'll see if I can add a new `CastKind`.~ `CastKind::Transmute` to the rescue!
- [x] Implement a more helpful panic message like slice bounds checking.

r? `@oli-obk`
2023-03-31 08:50:35 +00:00
..
asm_unwind.main.Inline.diff Generalize operation. 2023-03-13 18:22:55 +00:00
asm_unwind.rs
caller_with_trivial_bound.foo.Inline.diff
caller_with_trivial_bound.rs
cycle.f.Inline.diff
cycle.g.Inline.diff Generalize operation. 2023-03-13 18:22:55 +00:00
cycle.main.Inline.diff Generalize operation. 2023-03-13 18:22:55 +00:00
cycle.rs
dyn_trait.get_query.Inline.diff
dyn_trait.mk_cycle.Inline.diff
dyn_trait.rs
dyn_trait.try_execute_query.Inline.diff
exponential_runtime.main.Inline.diff Generalize operation. 2023-03-13 18:22:55 +00:00
exponential_runtime.rs
inline_any_operand.bar.Inline.after.mir
inline_any_operand.rs
inline_async.rs
inline_closure_borrows_arg.foo.Inline.after.mir
inline_closure_borrows_arg.rs
inline_closure_captures.foo.Inline.after.mir
inline_closure_captures.rs
inline_closure.foo.Inline.after.mir
inline_closure.rs
inline_compatibility.inlined_no_sanitize.Inline.diff
inline_compatibility.inlined_target_feature.Inline.diff
inline_compatibility.not_inlined_c_variadic.Inline.diff
inline_compatibility.not_inlined_no_sanitize.Inline.diff
inline_compatibility.not_inlined_target_feature.Inline.diff
inline_compatibility.rs
inline_cycle_generic.main.Inline.diff
inline_cycle_generic.rs
inline_cycle.one.Inline.diff
inline_cycle.rs
inline_cycle.two.Inline.diff Generalize operation. 2023-03-13 18:22:55 +00:00
inline_diverging.f.Inline.diff
inline_diverging.g.Inline.diff Generalize operation. 2023-03-13 18:22:55 +00:00
inline_diverging.h.Inline.diff Replace ZST operands and debuginfo by constants. 2023-03-13 18:19:57 +00:00
inline_diverging.rs
inline_generator.main.Inline.diff
inline_generator.rs
inline_instruction_set.default.Inline.diff
inline_instruction_set.rs
inline_instruction_set.t32.Inline.diff
inline_into_box_place.main.Inline.diff A MIR transform that checks pointers are aligned 2023-03-23 18:23:06 -04:00
inline_into_box_place.rs A MIR transform that checks pointers are aligned 2023-03-23 18:23:06 -04:00
inline_options.main.Inline.after.mir Generalize operation. 2023-03-13 18:22:55 +00:00
inline_options.rs
inline_retag.bar.Inline.after.mir
inline_retag.rs
inline_shims.clone.Inline.diff
inline_shims.drop.Inline.diff
inline_shims.rs
inline_specialization.main.Inline.diff
inline_specialization.rs
inline_trait_method_2.rs
inline_trait_method_2.test2.Inline.after.mir
inline_trait_method.rs
inline_trait_method.test.Inline.after.mir
issue_58867_inline_as_ref_as_mut.a.Inline.after.mir
issue_58867_inline_as_ref_as_mut.b.Inline.after.mir
issue_58867_inline_as_ref_as_mut.c.Inline.after.mir
issue_58867_inline_as_ref_as_mut.d.Inline.after.mir
issue_58867_inline_as_ref_as_mut.rs
issue_76997_inline_scopes_parenting.main.Inline.after.mir Replace ZST operands and debuginfo by constants. 2023-03-13 18:19:57 +00:00
issue_76997_inline_scopes_parenting.rs
issue_78442.bar.Inline.diff
issue_78442.bar.RevealAll.diff
issue_78442.rs
issue_106141.outer.Inline.diff
issue_106141.rs
polymorphic_recursion.rs
unchecked_shifts.rs Enable inlining of diverging functions 2023-03-18 14:29:13 -04:00
unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.diff Enable inlining of diverging functions 2023-03-18 14:29:13 -04:00
unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.mir Enable inlining of diverging functions 2023-03-18 14:29:13 -04:00
unchecked_shifts.unchecked_shr_signed_smaller.Inline.diff Enable inlining of diverging functions 2023-03-18 14:29:13 -04:00
unchecked_shifts.unchecked_shr_signed_smaller.PreCodegen.after.mir Enable inlining of diverging functions 2023-03-18 14:29:13 -04:00
unwrap_unchecked.rs Ignore the unwrap_unchecked test on wasm32-unknown-unknown 2023-03-25 19:33:19 -04:00
unwrap_unchecked.unwrap_unchecked.Inline.diff Ignore the unwrap_unchecked test on wasm32-unknown-unknown 2023-03-25 19:33:19 -04:00
unwrap_unchecked.unwrap_unchecked.PreCodegen.after.mir Ignore the unwrap_unchecked test on wasm32-unknown-unknown 2023-03-25 19:33:19 -04:00