diff options
Diffstat (limited to 'tests')
174 files changed, 631 insertions, 1180 deletions
diff --git a/tests/incremental/hashes/function_interfaces.rs b/tests/incremental/hashes/function_interfaces.rs index 4fa2762099c..ab4d578458d 100644 --- a/tests/incremental/hashes/function_interfaces.rs +++ b/tests/incremental/hashes/function_interfaces.rs @@ -104,17 +104,17 @@ pub fn order_of_parameters(p2: i64, p1: i32) {} // Unsafe ---------------------------------------------------------------------- #[cfg(any(cfail1,cfail4))] -pub fn make_unsafe() {} +pub fn make_unsafe() {} #[cfg(not(any(cfail1,cfail4)))] #[rustc_clean( cfg = "cfail2", - except = "opt_hir_owner_nodes, optimized_mir, typeck, fn_sig" + except = "opt_hir_owner_nodes, typeck, fn_sig" )] #[rustc_clean(cfg = "cfail3")] #[rustc_clean( cfg = "cfail5", - except = "opt_hir_owner_nodes, optimized_mir, typeck, fn_sig" + except = "opt_hir_owner_nodes, typeck, fn_sig" )] #[rustc_clean(cfg = "cfail6")] pub unsafe fn make_unsafe() {} diff --git a/tests/incremental/hashes/inherent_impls.rs b/tests/incremental/hashes/inherent_impls.rs index 2b0de1edc0c..caea394977a 100644 --- a/tests/incremental/hashes/inherent_impls.rs +++ b/tests/incremental/hashes/inherent_impls.rs @@ -348,9 +348,9 @@ impl Foo { // Make method unsafe ---------------------------------------------------------- #[cfg(any(cfail1,cfail4))] impl Foo { - //------------------------------------------------------------------------------------ + //---------------------------------------------------------------------- //-------------------------- - //------------------------------------------------------------------------------------ + //---------------------------------------------------------------------- //-------------------------- pub fn make_method_unsafe(&self) { } } @@ -361,9 +361,9 @@ impl Foo { #[rustc_clean(cfg="cfail5")] #[rustc_clean(cfg="cfail6")] impl Foo { - #[rustc_clean(cfg="cfail2", except="opt_hir_owner_nodes,fn_sig,typeck,optimized_mir")] + #[rustc_clean(cfg="cfail2", except="opt_hir_owner_nodes,fn_sig,typeck")] #[rustc_clean(cfg="cfail3")] - #[rustc_clean(cfg="cfail5", except="opt_hir_owner_nodes,fn_sig,typeck,optimized_mir")] + #[rustc_clean(cfg="cfail5", except="opt_hir_owner_nodes,fn_sig,typeck")] #[rustc_clean(cfg="cfail6")] pub unsafe fn make_method_unsafe(&self) { } } diff --git a/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-abort.mir b/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-abort.mir index 3b7c4b8796e..ef51b07827f 100644 --- a/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-abort.mir +++ b/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-abort.mir @@ -17,8 +17,6 @@ fn main() -> () { let _3: *mut usize; scope 3 { debug z => _3; - scope 4 { - } } } } diff --git a/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-unwind.mir b/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-unwind.mir index 3dcddea0353..d1aa9382a2c 100644 --- a/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-unwind.mir +++ b/tests/mir-opt/array_index_is_temporary.main.SimplifyCfg-pre-optimizations.after.panic-unwind.mir @@ -17,8 +17,6 @@ fn main() -> () { let _3: *mut usize; scope 3 { debug z => _3; - scope 4 { - } } } } diff --git a/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir b/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir index 6c3128f8c36..005b3ee3b24 100644 --- a/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir +++ b/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir @@ -3,8 +3,6 @@ fn main() -> () { let mut _0: (); let _1: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/box_expr.main.ElaborateDrops.diff b/tests/mir-opt/box_expr.main.ElaborateDrops.diff index 88b12f19e64..ec40fac2894 100644 --- a/tests/mir-opt/box_expr.main.ElaborateDrops.diff +++ b/tests/mir-opt/box_expr.main.ElaborateDrops.diff @@ -15,8 +15,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/building/async_await.b-{closure#0}.coroutine_resume.0.mir b/tests/mir-opt/building/async_await.b-{closure#0}.coroutine_resume.0.mir index d697ea49231..d2a0fb0cb3c 100644 --- a/tests/mir-opt/building/async_await.b-{closure#0}.coroutine_resume.0.mir +++ b/tests/mir-opt/building/async_await.b-{closure#0}.coroutine_resume.0.mir @@ -93,17 +93,13 @@ fn b::{closure#0}(_1: Pin<&mut {async fn body of b()}>, _2: &mut Context<'_>) -> debug __awaitee => (((*(_1.0: &mut {async fn body of b()})) as variant#3).0: {async fn body of a()}); let _17: (); scope 2 { - } - scope 3 { debug result => _17; } } - scope 4 { + scope 3 { debug __awaitee => (((*(_1.0: &mut {async fn body of b()})) as variant#4).0: {async fn body of a()}); let _33: (); - scope 5 { - } - scope 6 { + scope 4 { debug result => _33; } } diff --git a/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir b/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir index 128af9c5602..db758368a13 100644 --- a/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir +++ b/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir @@ -16,14 +16,10 @@ fn move_out_by_subslice() -> () { scope 1 { debug a => _1; let _12: [std::boxed::Box<i32>; 2]; - scope 4 { + scope 2 { debug _y => _12; } } - scope 2 { - } - scope 3 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir b/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir index d50a6872a41..84cd557715c 100644 --- a/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir +++ b/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir @@ -16,14 +16,10 @@ fn move_out_from_end() -> () { scope 1 { debug a => _1; let _12: std::boxed::Box<i32>; - scope 4 { + scope 2 { debug _y => _12; } } - scope 2 { - } - scope 3 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_promotion_extern_static.FOO.PromoteTemps.diff b/tests/mir-opt/const_promotion_extern_static.FOO.PromoteTemps.diff index 3596671f614..bfefd2b8c95 100644 --- a/tests/mir-opt/const_promotion_extern_static.FOO.PromoteTemps.diff +++ b/tests/mir-opt/const_promotion_extern_static.FOO.PromoteTemps.diff @@ -9,8 +9,6 @@ let mut _4: &i32; let _5: *const i32; + let mut _6: &[&i32; 1]; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff b/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff index a044cfc62e2..3f4958f60e8 100644 --- a/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff +++ b/tests/mir-opt/const_prop/address_of_pair.fn0.GVN.diff @@ -14,8 +14,6 @@ debug ptr => _3; let _5: bool; scope 3 { - } - scope 4 { debug ret => _5; } } diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff index 20fda589c39..826f4c34277 100644 --- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff +++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-abort.diff @@ -13,11 +13,9 @@ let mut _9: &[i32; 3]; scope 1 { debug a => _1; + let _5: i32; scope 2 { - let _5: i32; - scope 3 { - debug _b => _5; - } + debug _b => _5; } } diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff index f1b90c28e72..0e2ec65652f 100644 --- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff +++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.32bit.panic-unwind.diff @@ -13,11 +13,9 @@ let mut _9: &[i32; 3]; scope 1 { debug a => _1; + let _5: i32; scope 2 { - let _5: i32; - scope 3 { - debug _b => _5; - } + debug _b => _5; } } diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff index 20fda589c39..826f4c34277 100644 --- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff +++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-abort.diff @@ -13,11 +13,9 @@ let mut _9: &[i32; 3]; scope 1 { debug a => _1; + let _5: i32; scope 2 { - let _5: i32; - scope 3 { - debug _b => _5; - } + debug _b => _5; } } diff --git a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff index f1b90c28e72..0e2ec65652f 100644 --- a/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff +++ b/tests/mir-opt/const_prop/bad_op_unsafe_oob_for_slices.main.GVN.64bit.panic-unwind.diff @@ -13,11 +13,9 @@ let mut _9: &[i32; 3]; scope 1 { debug a => _1; + let _5: i32; scope 2 { - let _5: i32; - scope 3 { - debug _b => _5; - } + debug _b => _5; } } diff --git a/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff b/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff index 59ee38f5a2b..a408c197fd1 100644 --- a/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff +++ b/tests/mir-opt/const_prop/boxes.main.GVN.panic-abort.diff @@ -15,8 +15,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff b/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff index 9d87bd809d1..5706a739602 100644 --- a/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff +++ b/tests/mir-opt/const_prop/boxes.main.GVN.panic-unwind.diff @@ -15,8 +15,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff b/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff index b389080c497..99a6ba7d08a 100644 --- a/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff +++ b/tests/mir-opt/const_prop/indirect_mutation.bar.GVN.diff @@ -11,8 +11,6 @@ debug v => _1; let _4: bool; scope 2 { - } - scope 3 { debug y => _4; } } diff --git a/tests/mir-opt/const_prop/invalid_constant.main.GVN.diff b/tests/mir-opt/const_prop/invalid_constant.main.GVN.diff index da5bf1cf42c..f5041365604 100644 --- a/tests/mir-opt/const_prop/invalid_constant.main.GVN.diff +++ b/tests/mir-opt/const_prop/invalid_constant.main.GVN.diff @@ -12,24 +12,18 @@ scope 1 { debug _invalid_char => _1; let _3: [E; 1]; - scope 3 { + scope 2 { debug _invalid_tag => _3; let _6: [Empty; 1]; - scope 5 { + scope 3 { debug _enum_without_variants => const [ZeroSized: Empty]; let _9: main::Str<"���">; - scope 7 { + scope 4 { debug _non_utf8_str => const Str::<"���">; } } - scope 6 { - } - } - scope 4 { } } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/invalid_constant.main.RemoveZsts.diff b/tests/mir-opt/const_prop/invalid_constant.main.RemoveZsts.diff index 455c2375eff..6e5ad8d6b81 100644 --- a/tests/mir-opt/const_prop/invalid_constant.main.RemoveZsts.diff +++ b/tests/mir-opt/const_prop/invalid_constant.main.RemoveZsts.diff @@ -12,26 +12,20 @@ scope 1 { debug _invalid_char => _1; let _3: [E; 1]; - scope 3 { + scope 2 { debug _invalid_tag => _3; let _6: [Empty; 1]; - scope 5 { + scope 3 { - debug _enum_without_variants => _6; + debug _enum_without_variants => const [ZeroSized: Empty]; let _9: main::Str<"���">; - scope 7 { + scope 4 { - debug _non_utf8_str => _9; + debug _non_utf8_str => const Str::<"���">; } } - scope 6 { - } - } - scope 4 { } } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff b/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff index e113f43a56e..31c839f6749 100644 --- a/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff +++ b/tests/mir-opt/const_prop/mutable_variable_no_prop.main.GVN.diff @@ -11,8 +11,6 @@ debug x => _1; let _5: u32; scope 2 { - } - scope 3 { debug y => _5; } } diff --git a/tests/mir-opt/const_prop/transmute.from_char.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.from_char.GVN.32bit.diff index 47dfb421ebc..2b38e88ae4c 100644 --- a/tests/mir-opt/const_prop/transmute.from_char.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.from_char.GVN.32bit.diff @@ -3,8 +3,6 @@ fn from_char() -> i32 { let mut _0: i32; - scope 1 { - } bb0: { - _0 = const 'R' as i32 (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.from_char.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.from_char.GVN.64bit.diff index 47dfb421ebc..2b38e88ae4c 100644 --- a/tests/mir-opt/const_prop/transmute.from_char.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.from_char.GVN.64bit.diff @@ -3,8 +3,6 @@ fn from_char() -> i32 { let mut _0: i32; - scope 1 { - } bb0: { - _0 = const 'R' as i32 (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.32bit.diff index f0c6f55f775..45c48e9046e 100644 --- a/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.32bit.diff @@ -3,8 +3,6 @@ fn invalid_bool() -> bool { let mut _0: bool; - scope 1 { - } bb0: { - _0 = const -1_i8 as bool (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.64bit.diff index f0c6f55f775..45c48e9046e 100644 --- a/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.invalid_bool.GVN.64bit.diff @@ -3,8 +3,6 @@ fn invalid_bool() -> bool { let mut _0: bool; - scope 1 { - } bb0: { - _0 = const -1_i8 as bool (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.invalid_char.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.invalid_char.GVN.32bit.diff index 03a7706401f..b4fe64d0aff 100644 --- a/tests/mir-opt/const_prop/transmute.invalid_char.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.invalid_char.GVN.32bit.diff @@ -3,8 +3,6 @@ fn invalid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const core::num::<impl i32>::MAX as char (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.invalid_char.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.invalid_char.GVN.64bit.diff index 03a7706401f..b4fe64d0aff 100644 --- a/tests/mir-opt/const_prop/transmute.invalid_char.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.invalid_char.GVN.64bit.diff @@ -3,8 +3,6 @@ fn invalid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const core::num::<impl i32>::MAX as char (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.32bit.diff index 5e0c076b981..ab3481a3be5 100644 --- a/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.32bit.diff @@ -4,8 +4,6 @@ fn less_as_i8() -> i8 { let mut _0: i8; let mut _1: std::cmp::Ordering; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.64bit.diff index 5e0c076b981..ab3481a3be5 100644 --- a/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.less_as_i8.GVN.64bit.diff @@ -4,8 +4,6 @@ fn less_as_i8() -> i8 { let mut _0: i8; let mut _1: std::cmp::Ordering; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.32bit.diff index c6a428019d8..febb6bfb0a4 100644 --- a/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.32bit.diff @@ -5,8 +5,6 @@ let mut _0: u32; let mut _1: undef_union_as_integer::Union32; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.64bit.diff index c6a428019d8..febb6bfb0a4 100644 --- a/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.undef_union_as_integer.GVN.64bit.diff @@ -5,8 +5,6 @@ let mut _0: u32; let mut _1: undef_union_as_integer::Union32; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.32bit.diff index 2ef83abfac0..7a289563c50 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.32bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.64bit.diff index 2ef83abfac0..7a289563c50 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_box.GVN.64bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.32bit.diff index b2e91014625..3364782022d 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.32bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.64bit.diff index b2e91014625..3364782022d 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_direct.GVN.64bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff index 0ff31b1a981..a7020793237 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.32bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff index 0ff31b1a981..a7020793237 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_mut.GVN.64bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.32bit.diff index 430d16c97a6..d44b0872035 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.32bit.diff @@ -7,8 +7,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.64bit.diff index 430d16c97a6..d44b0872035 100644 --- a/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.unreachable_ref.GVN.64bit.diff @@ -7,8 +7,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/const_prop/transmute.valid_char.GVN.32bit.diff b/tests/mir-opt/const_prop/transmute.valid_char.GVN.32bit.diff index f9d002f96ab..069ff906ec5 100644 --- a/tests/mir-opt/const_prop/transmute.valid_char.GVN.32bit.diff +++ b/tests/mir-opt/const_prop/transmute.valid_char.GVN.32bit.diff @@ -3,8 +3,6 @@ fn valid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const 82_u32 as char (Transmute); diff --git a/tests/mir-opt/const_prop/transmute.valid_char.GVN.64bit.diff b/tests/mir-opt/const_prop/transmute.valid_char.GVN.64bit.diff index f9d002f96ab..069ff906ec5 100644 --- a/tests/mir-opt/const_prop/transmute.valid_char.GVN.64bit.diff +++ b/tests/mir-opt/const_prop/transmute.valid_char.GVN.64bit.diff @@ -3,8 +3,6 @@ fn valid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const 82_u32 as char (Transmute); diff --git a/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-abort.diff b/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-abort.diff index ffb0c4b23fb..ef30ac2fc8c 100644 --- a/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-abort.diff +++ b/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-abort.diff @@ -14,13 +14,11 @@ scope 2 { debug b => _3; let _5: *mut u8; - scope 4 { + scope 3 { - debug c => _5; + debug c => _2; } } - scope 3 { - } } bb0: { diff --git a/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-unwind.diff b/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-unwind.diff index 66a0f49cfb9..a743a3e829a 100644 --- a/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-unwind.diff +++ b/tests/mir-opt/copy-prop/reborrow.demiraw.CopyProp.panic-unwind.diff @@ -14,13 +14,11 @@ scope 2 { debug b => _3; let _5: *mut u8; - scope 4 { + scope 3 { - debug c => _5; + debug c => _2; } } - scope 3 { - } } bb0: { diff --git a/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-abort.diff b/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-abort.diff index 0777a913523..2de6f85ce64 100644 --- a/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-abort.diff +++ b/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-abort.diff @@ -13,13 +13,11 @@ scope 2 { debug b => _3; let _4: *mut u8; - scope 4 { + scope 3 { - debug c => _4; + debug c => _2; } } - scope 3 { - } } bb0: { diff --git a/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-unwind.diff b/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-unwind.diff index f5a512b8995..2afec4898bc 100644 --- a/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-unwind.diff +++ b/tests/mir-opt/copy-prop/reborrow.miraw.CopyProp.panic-unwind.diff @@ -13,13 +13,11 @@ scope 2 { debug b => _3; let _4: *mut u8; - scope 4 { + scope 3 { - debug c => _4; + debug c => _2; } } - scope 3 { - } } bb0: { diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff index 21cf745b680..44e73b56098 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-abort.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff index ee58a974480..6cef8b692ba 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.32bit.panic-unwind.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff index 9fc9c8ed409..6efccded993 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-abort.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff index 30d93347afd..a705d0064cb 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.DataflowConstProp.64bit.panic-unwind.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff index 3a46edbc849..f9c854ca3f4 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-abort.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff index 3c71214c35f..333726689d7 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.32bit.panic-unwind.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff index 4557e7b26d6..e1841760077 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-abort.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff index 5ab2d5e0fdc..7aa02556ec5 100644 --- a/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff +++ b/tests/mir-opt/dataflow-const-prop/default_boxed_slice.main.GVN.64bit.panic-unwind.diff @@ -17,33 +17,27 @@ scope 4 (inlined Unique::<[bool; 0]>::dangling) { let mut _5: std::ptr::NonNull<[bool; 0]>; scope 5 (inlined NonNull::<[bool; 0]>::dangling) { + let _6: *mut [bool; 0]; scope 6 { - let _6: *mut [bool; 0]; - scope 7 { + debug ptr => _6; + scope 10 (inlined NonNull::<[bool; 0]>::new_unchecked) { debug ptr => _6; - scope 12 (inlined NonNull::<[bool; 0]>::new_unchecked) { - debug ptr => _6; - let mut _8: bool; - let _9: (); - let mut _10: *mut (); - let mut _11: *const [bool; 0]; - scope 13 { - scope 14 (inlined core::ub_checks::check_language_ub) { - scope 15 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + let mut _8: bool; + let _9: (); + let mut _10: *mut (); + let mut _11: *const [bool; 0]; + scope 11 (inlined core::ub_checks::check_language_ub) { + scope 12 (inlined core::ub_checks::check_language_ub::runtime) { } } } - scope 8 (inlined dangling_mut::<[bool; 0]>) { - let mut _7: usize; - scope 9 (inlined align_of::<[bool; 0]>) { - } - scope 10 (inlined without_provenance_mut::<[bool; 0]>) { - debug addr => _7; - scope 11 { - } - } + } + scope 7 (inlined dangling_mut::<[bool; 0]>) { + let mut _7: usize; + scope 8 (inlined align_of::<[bool; 0]>) { + } + scope 9 (inlined without_provenance_mut::<[bool; 0]>) { + debug addr => _7; } } } diff --git a/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-abort.diff index 9b0093c454e..a5e40990751 100644 --- a/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-abort.diff +++ b/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-abort.diff @@ -9,14 +9,12 @@ let mut _5: *mut u8; scope 1 { debug x => _1; + let _3: *mut u8; let _6: u8; scope 2 { - let _3: *mut u8; - scope 3 { - debug p => _3; - } + debug p => _3; } - scope 4 { + scope 3 { debug x1 => _6; } } diff --git a/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-unwind.diff b/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-unwind.diff index 635a214251b..ce2178ddbee 100644 --- a/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-unwind.diff +++ b/tests/mir-opt/dataflow-const-prop/sibling_ptr.main.DataflowConstProp.panic-unwind.diff @@ -9,14 +9,12 @@ let mut _5: *mut u8; scope 1 { debug x => _1; + let _3: *mut u8; let _6: u8; scope 2 { - let _3: *mut u8; - scope 3 { - debug p => _3; - } + debug p => _3; } - scope 4 { + scope 3 { debug x1 => _6; } } diff --git a/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.32bit.diff index 52f096ac0e4..a5529253762 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.32bit.diff @@ -3,8 +3,6 @@ fn from_char() -> i32 { let mut _0: i32; - scope 1 { - } bb0: { - _0 = const 'R' as i32 (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.64bit.diff index 52f096ac0e4..a5529253762 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.from_char.DataflowConstProp.64bit.diff @@ -3,8 +3,6 @@ fn from_char() -> i32 { let mut _0: i32; - scope 1 { - } bb0: { - _0 = const 'R' as i32 (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.32bit.diff index 3972eb209a1..a66d8dbe844 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.32bit.diff @@ -3,8 +3,6 @@ fn invalid_bool() -> bool { let mut _0: bool; - scope 1 { - } bb0: { - _0 = const -1_i8 as bool (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.64bit.diff index 3972eb209a1..a66d8dbe844 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.invalid_bool.DataflowConstProp.64bit.diff @@ -3,8 +3,6 @@ fn invalid_bool() -> bool { let mut _0: bool; - scope 1 { - } bb0: { - _0 = const -1_i8 as bool (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.32bit.diff index dd737017ffd..4f3f3e03d75 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.32bit.diff @@ -3,8 +3,6 @@ fn invalid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const core::num::<impl i32>::MAX as char (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.64bit.diff index dd737017ffd..4f3f3e03d75 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.invalid_char.DataflowConstProp.64bit.diff @@ -3,8 +3,6 @@ fn invalid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const core::num::<impl i32>::MAX as char (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.32bit.diff index 6091e169e8e..44dd4017409 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.32bit.diff @@ -4,8 +4,6 @@ fn less_as_i8() -> i8 { let mut _0: i8; let mut _1: std::cmp::Ordering; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.64bit.diff index 6091e169e8e..44dd4017409 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.less_as_i8.DataflowConstProp.64bit.diff @@ -4,8 +4,6 @@ fn less_as_i8() -> i8 { let mut _0: i8; let mut _1: std::cmp::Ordering; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.32bit.diff index fb28aa8f6d9..14a34a1ce38 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.32bit.diff @@ -5,8 +5,6 @@ let mut _0: u32; let mut _1: undef_union_as_integer::Union32; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.64bit.diff index fb28aa8f6d9..14a34a1ce38 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.undef_union_as_integer.DataflowConstProp.64bit.diff @@ -5,8 +5,6 @@ let mut _0: u32; let mut _1: undef_union_as_integer::Union32; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.32bit.diff index 5d17c47ae66..258e2b454eb 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.32bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.64bit.diff index 5d17c47ae66..258e2b454eb 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_box.DataflowConstProp.64bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.32bit.diff index c8d4d6edba1..a0b4fb2f5e4 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.32bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.64bit.diff index c8d4d6edba1..a0b4fb2f5e4 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_direct.DataflowConstProp.64bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.32bit.diff index 2ffaeea72db..ef461423c32 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.32bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.64bit.diff index 2ffaeea72db..ef461423c32 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_mut.DataflowConstProp.64bit.diff @@ -8,8 +8,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.32bit.diff index 31fcaafc5bc..c8910029a03 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.32bit.diff @@ -7,8 +7,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.64bit.diff index 31fcaafc5bc..c8910029a03 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.unreachable_ref.DataflowConstProp.64bit.diff @@ -7,8 +7,6 @@ scope 1 { debug x => _1; } - scope 2 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.32bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.32bit.diff index 402ef754a64..580c5044bb8 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.32bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.32bit.diff @@ -3,8 +3,6 @@ fn valid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const 82_u32 as char (Transmute); diff --git a/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.64bit.diff b/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.64bit.diff index 402ef754a64..580c5044bb8 100644 --- a/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.64bit.diff +++ b/tests/mir-opt/dataflow-const-prop/transmute.valid_char.DataflowConstProp.64bit.diff @@ -3,8 +3,6 @@ fn valid_char() -> char { let mut _0: char; - scope 1 { - } bb0: { - _0 = const 82_u32 as char (Transmute); diff --git a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff index 0af3faf28f0..570ec129f06 100644 --- a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff +++ b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-abort.diff @@ -8,13 +8,11 @@ let mut _3: u32; scope 1 { debug un => _1; - scope 2 { - } - scope 4 (inlined std::mem::drop::<u32>) { + scope 3 (inlined std::mem::drop::<u32>) { debug _x => _3; } } - scope 3 (inlined val) { + scope 2 (inlined val) { } bb0: { diff --git a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff index 0af3faf28f0..570ec129f06 100644 --- a/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff +++ b/tests/mir-opt/dest-prop/union.main.DestinationPropagation.panic-unwind.diff @@ -8,13 +8,11 @@ let mut _3: u32; scope 1 { debug un => _1; - scope 2 { - } - scope 4 (inlined std::mem::drop::<u32>) { + scope 3 (inlined std::mem::drop::<u32>) { debug _x => _3; } } - scope 3 (inlined val) { + scope 2 (inlined val) { } bb0: { diff --git a/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff b/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff index 46bf13985da..906835530d8 100644 --- a/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff +++ b/tests/mir-opt/gvn.dereferences.GVN.panic-abort.diff @@ -37,17 +37,9 @@ debug z => _8; let _13: *mut u32; scope 2 { - } - scope 3 { - } - scope 4 { debug z => _13; let _18: &u32; - scope 5 { - } - scope 6 { - } - scope 7 { + scope 3 { debug z => _18; } } diff --git a/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff b/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff index 3e731ead859..006b5da646c 100644 --- a/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff +++ b/tests/mir-opt/gvn.dereferences.GVN.panic-unwind.diff @@ -37,17 +37,9 @@ debug z => _8; let _13: *mut u32; scope 2 { - } - scope 3 { - } - scope 4 { debug z => _13; let _18: &u32; - scope 5 { - } - scope 6 { - } - scope 7 { + scope 3 { debug z => _18; } } diff --git a/tests/mir-opt/gvn.slices.GVN.panic-abort.diff b/tests/mir-opt/gvn.slices.GVN.panic-abort.diff index f3f9073909e..2389d98b5b3 100644 --- a/tests/mir-opt/gvn.slices.GVN.panic-abort.diff +++ b/tests/mir-opt/gvn.slices.GVN.panic-abort.diff @@ -69,17 +69,15 @@ debug u => _29; let _41: &*const u8; let _42: &*const u8; - scope 7 { + scope 6 { debug left_val => _41; debug right_val => _42; let _47: core::panicking::AssertKind; - scope 8 { + scope 7 { debug kind => _47; } } } - scope 6 { - } } } diff --git a/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff b/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff index 383152cce5e..50715d748e7 100644 --- a/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff +++ b/tests/mir-opt/gvn.slices.GVN.panic-unwind.diff @@ -69,17 +69,15 @@ debug u => _29; let _41: &*const u8; let _42: &*const u8; - scope 7 { + scope 6 { debug left_val => _41; debug right_val => _42; let _47: core::panicking::AssertKind; - scope 8 { + scope 7 { debug kind => _47; } } } - scope 6 { - } } } diff --git a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff index 3ecd4650d81..ba9e507560d 100644 --- a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff +++ b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-abort.diff @@ -175,18 +175,16 @@ let _135: &mut u64; scope 2 { debug b => _135; + let _145: *const u64; let _163: &u64; scope 3 { - let _145: *const u64; + debug c => _145; + let _154: *mut u64; scope 4 { - debug c => _145; - let _154: *mut u64; - scope 5 { - debug d => _154; - } + debug d => _154; } } - scope 6 { + scope 5 { debug e => _163; } } diff --git a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff index bf448280b1e..41c01536130 100644 --- a/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff +++ b/tests/mir-opt/gvn.subexpression_elimination.GVN.panic-unwind.diff @@ -175,18 +175,16 @@ let _135: &mut u64; scope 2 { debug b => _135; + let _145: *const u64; let _163: &u64; scope 3 { - let _145: *const u64; + debug c => _145; + let _154: *mut u64; scope 4 { - debug c => _145; - let _154: *mut u64; - scope 5 { - debug d => _154; - } + debug d => _154; } } - scope 6 { + scope 5 { debug e => _163; } } diff --git a/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-abort.diff b/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-abort.diff index 11cd43fc0e0..07c4c7663c1 100644 --- a/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-abort.diff +++ b/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-abort.diff @@ -33,13 +33,9 @@ scope 1 { debug a => _1; let _3: *const [u8]; - scope 3 { + scope 2 { debug b => _3; } - scope 4 { - } - } - scope 2 { } bb0: { diff --git a/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-unwind.diff b/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-unwind.diff index c77cd07c60c..df0f93f1077 100644 --- a/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-unwind.diff +++ b/tests/mir-opt/gvn.wide_ptr_integer.GVN.panic-unwind.diff @@ -33,13 +33,9 @@ scope 1 { debug a => _1; let _3: *const [u8]; - scope 3 { + scope 2 { debug b => _3; } - scope 4 { - } - } - scope 2 { } bb0: { diff --git a/tests/mir-opt/gvn_uninhabited.f.GVN.panic-abort.diff b/tests/mir-opt/gvn_uninhabited.f.GVN.panic-abort.diff index 86e6aae1191..c5ee0d9c44d 100644 --- a/tests/mir-opt/gvn_uninhabited.f.GVN.panic-abort.diff +++ b/tests/mir-opt/gvn_uninhabited.f.GVN.panic-abort.diff @@ -7,12 +7,10 @@ let mut _2: E; let mut _3: &U; let _4: U; + let mut _5: &U; scope 1 { debug i => _1; } - scope 2 { - let mut _5: &U; - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/gvn_uninhabited.f.GVN.panic-unwind.diff b/tests/mir-opt/gvn_uninhabited.f.GVN.panic-unwind.diff index 86e6aae1191..c5ee0d9c44d 100644 --- a/tests/mir-opt/gvn_uninhabited.f.GVN.panic-unwind.diff +++ b/tests/mir-opt/gvn_uninhabited.f.GVN.panic-unwind.diff @@ -7,12 +7,10 @@ let mut _2: E; let mut _3: &U; let _4: U; + let mut _5: &U; scope 1 { debug i => _1; } - scope 2 { - let mut _5: &U; - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff b/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff index ea9c360aa7b..dc0004105a7 100644 --- a/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff @@ -8,8 +8,6 @@ + let _2: D; + scope 2 { + debug _d => const D; -+ scope 3 { -+ } + } + } diff --git a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff index a38b8246bde..859082c3111 100644 --- a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff +++ b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-abort.diff @@ -15,13 +15,11 @@ + } + scope 3 (inlined Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}>::new) { + debug pointer => _3; -+ scope 4 { -+ scope 5 (inlined Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}>::new_unchecked) { -+ debug pointer => _3; -+ } ++ scope 4 (inlined Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}>::new_unchecked) { ++ debug pointer => _3; + } + } -+ scope 6 (inlined g::{closure#0}) { ++ scope 5 (inlined g::{closure#0}) { + debug a => _5; + let mut _6: &mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}; + let mut _7: u32; diff --git a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff index dc6628ab44c..44b06c34972 100644 --- a/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline/inline_coroutine.main.Inline.panic-unwind.diff @@ -15,13 +15,11 @@ + } + scope 3 (inlined Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}>::new) { + debug pointer => _3; -+ scope 4 { -+ scope 5 (inlined Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}>::new_unchecked) { -+ debug pointer => _3; -+ } ++ scope 4 (inlined Pin::<&mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}>::new_unchecked) { ++ debug pointer => _3; + } + } -+ scope 6 (inlined g::{closure#0}) { ++ scope 5 (inlined g::{closure#0}) { + debug a => _5; + let mut _6: &mut {coroutine@$DIR/inline_coroutine.rs:19:5: 19:8}; + let mut _7: u32; diff --git a/tests/mir-opt/inline/inline_instruction_set.default.Inline.diff b/tests/mir-opt/inline/inline_instruction_set.default.Inline.diff index e38daba27fc..158cc973779 100644 --- a/tests/mir-opt/inline/inline_instruction_set.default.Inline.diff +++ b/tests/mir-opt/inline/inline_instruction_set.default.Inline.diff @@ -10,8 +10,6 @@ + scope 1 (inlined instruction_set_default) { + } + scope 2 (inlined inline_always_and_using_inline_asm) { -+ scope 3 { -+ } + } bb0: { diff --git a/tests/mir-opt/inline/inline_shims.drop.Inline.panic-abort.diff b/tests/mir-opt/inline/inline_shims.drop.Inline.panic-abort.diff index 4fcd49994f0..2a36ccaab11 100644 --- a/tests/mir-opt/inline/inline_shims.drop.Inline.panic-abort.diff +++ b/tests/mir-opt/inline/inline_shims.drop.Inline.panic-abort.diff @@ -8,18 +8,14 @@ let _3: (); let mut _4: *mut std::vec::Vec<A>; let mut _5: *mut std::option::Option<B>; - scope 1 { -+ scope 3 (inlined std::ptr::drop_in_place::<Vec<A>> - shim(Some(Vec<A>))) { -+ let mut _6: &mut std::vec::Vec<A>; -+ let mut _7: (); -+ } - } - scope 2 { -+ scope 4 (inlined std::ptr::drop_in_place::<Option<B>> - shim(Some(Option<B>))) { -+ let mut _8: isize; -+ let mut _9: isize; -+ } - } ++ scope 1 (inlined std::ptr::drop_in_place::<Vec<A>> - shim(Some(Vec<A>))) { ++ let mut _6: &mut std::vec::Vec<A>; ++ let mut _7: (); ++ } ++ scope 2 (inlined std::ptr::drop_in_place::<Option<B>> - shim(Some(Option<B>))) { ++ let mut _8: isize; ++ let mut _9: isize; ++ } bb0: { StorageLive(_3); diff --git a/tests/mir-opt/inline/inline_shims.drop.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_shims.drop.Inline.panic-unwind.diff index 4270ae00b66..e11561076e6 100644 --- a/tests/mir-opt/inline/inline_shims.drop.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline/inline_shims.drop.Inline.panic-unwind.diff @@ -8,14 +8,10 @@ let _3: (); let mut _4: *mut std::vec::Vec<A>; let mut _5: *mut std::option::Option<B>; - scope 1 { - } - scope 2 { -+ scope 3 (inlined std::ptr::drop_in_place::<Option<B>> - shim(Some(Option<B>))) { -+ let mut _6: isize; -+ let mut _7: isize; -+ } - } ++ scope 1 (inlined std::ptr::drop_in_place::<Option<B>> - shim(Some(Option<B>))) { ++ let mut _6: isize; ++ let mut _7: isize; ++ } bb0: { StorageLive(_3); diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-abort.diff b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-abort.diff index 51e506142a9..cc1b8b9b70f 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-abort.diff +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-abort.diff @@ -10,8 +10,6 @@ + scope 1 (inlined core::num::<impl u16>::unchecked_shl) { + debug self => _3; + debug rhs => _4; -+ scope 2 { -+ } + } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-unwind.diff b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-unwind.diff index 053ccc077a4..f244f378bce 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.Inline.panic-unwind.diff @@ -10,8 +10,6 @@ + scope 1 (inlined core::num::<impl u16>::unchecked_shl) { + debug self => _3; + debug rhs => _4; -+ scope 2 { -+ } + } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-abort.mir b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-abort.mir index 2be887e9b5a..c96983c18cb 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-abort.mir @@ -7,8 +7,6 @@ fn unchecked_shl_unsigned_smaller(_1: u16, _2: u32) -> u16 { scope 1 (inlined core::num::<impl u16>::unchecked_shl) { debug self => _1; debug rhs => _2; - scope 2 { - } } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-unwind.mir index 2be887e9b5a..c96983c18cb 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shl_unsigned_smaller.PreCodegen.after.panic-unwind.mir @@ -7,8 +7,6 @@ fn unchecked_shl_unsigned_smaller(_1: u16, _2: u32) -> u16 { scope 1 (inlined core::num::<impl u16>::unchecked_shl) { debug self => _1; debug rhs => _2; - scope 2 { - } } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-abort.diff b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-abort.diff index 816d03b4405..74518db370f 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-abort.diff +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-abort.diff @@ -10,8 +10,6 @@ + scope 1 (inlined core::num::<impl i64>::unchecked_shr) { + debug self => _3; + debug rhs => _4; -+ scope 2 { -+ } + } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-unwind.diff b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-unwind.diff index d4121f89baf..aab04624f6c 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.Inline.panic-unwind.diff @@ -10,8 +10,6 @@ + scope 1 (inlined core::num::<impl i64>::unchecked_shr) { + debug self => _3; + debug rhs => _4; -+ scope 2 { -+ } + } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-abort.mir b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-abort.mir index 4696112175e..1dd8cb27314 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-abort.mir @@ -7,8 +7,6 @@ fn unchecked_shr_signed_bigger(_1: i64, _2: u32) -> i64 { scope 1 (inlined core::num::<impl i64>::unchecked_shr) { debug self => _1; debug rhs => _2; - scope 2 { - } } bb0: { diff --git a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-unwind.mir index 4696112175e..1dd8cb27314 100644 --- a/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/inline/unchecked_shifts.unchecked_shr_signed_bigger.PreCodegen.after.panic-unwind.mir @@ -7,8 +7,6 @@ fn unchecked_shr_signed_bigger(_1: i64, _2: u32) -> i64 { scope 1 (inlined core::num::<impl i64>::unchecked_shr) { debug self => _1; debug rhs => _2; - scope 2 { - } } bb0: { diff --git a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-abort.diff b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-abort.diff index 028040edc85..814eda10459 100644 --- a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-abort.diff +++ b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-abort.diff @@ -11,15 +11,11 @@ + scope 2 { + debug val => _0; + } -+ scope 3 { -+ scope 4 (inlined unreachable_unchecked) { -+ let mut _4: bool; -+ let _5: (); -+ scope 5 { -+ } -+ scope 6 (inlined core::ub_checks::check_language_ub) { -+ scope 7 (inlined core::ub_checks::check_language_ub::runtime) { -+ } ++ scope 3 (inlined unreachable_unchecked) { ++ let mut _4: bool; ++ let _5: (); ++ scope 4 (inlined core::ub_checks::check_language_ub) { ++ scope 5 (inlined core::ub_checks::check_language_ub::runtime) { + } + } + } diff --git a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-unwind.diff b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-unwind.diff index 484fd37248c..d5d69074382 100644 --- a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.Inline.panic-unwind.diff @@ -11,15 +11,11 @@ + scope 2 { + debug val => _0; + } -+ scope 3 { -+ scope 4 (inlined unreachable_unchecked) { -+ let mut _4: bool; -+ let _5: (); -+ scope 5 { -+ } -+ scope 6 (inlined core::ub_checks::check_language_ub) { -+ scope 7 (inlined core::ub_checks::check_language_ub::runtime) { -+ } ++ scope 3 (inlined unreachable_unchecked) { ++ let mut _4: bool; ++ let _5: (); ++ scope 4 (inlined core::ub_checks::check_language_ub) { ++ scope 5 (inlined core::ub_checks::check_language_ub::runtime) { + } + } + } diff --git a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir index d629336d385..7c24a97166c 100644 --- a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-abort.mir @@ -9,13 +9,9 @@ fn unwrap_unchecked(_1: Option<T>) -> T { scope 2 { debug val => _0; } - scope 3 { - scope 4 (inlined unreachable_unchecked) { - scope 5 { - } - scope 6 (inlined core::ub_checks::check_language_ub) { - scope 7 (inlined core::ub_checks::check_language_ub::runtime) { - } + scope 3 (inlined unreachable_unchecked) { + scope 4 (inlined core::ub_checks::check_language_ub) { + scope 5 (inlined core::ub_checks::check_language_ub::runtime) { } } } diff --git a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir index d629336d385..7c24a97166c 100644 --- a/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/inline/unwrap_unchecked.unwrap_unchecked.PreCodegen.after.panic-unwind.mir @@ -9,13 +9,9 @@ fn unwrap_unchecked(_1: Option<T>) -> T { scope 2 { debug val => _0; } - scope 3 { - scope 4 (inlined unreachable_unchecked) { - scope 5 { - } - scope 6 (inlined core::ub_checks::check_language_ub) { - scope 7 (inlined core::ub_checks::check_language_ub::runtime) { - } + scope 3 (inlined unreachable_unchecked) { + scope 4 (inlined core::ub_checks::check_language_ub) { + scope 5 (inlined core::ub_checks::check_language_ub::runtime) { } } } diff --git a/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-abort.diff b/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-abort.diff index 0243e31cb1a..f8cceacd7e6 100644 --- a/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-abort.diff +++ b/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-abort.diff @@ -18,9 +18,9 @@ let _4: std::pin::Pin<&mut {async fn body of ActionPermit<'_, T>::perform()}>; scope 2 { debug fut => _4; - scope 4 { + scope 3 { } -+ scope 7 (inlined ActionPermit::<'_, T>::perform::{closure#0}) { ++ scope 6 (inlined ActionPermit::<'_, T>::perform::{closure#0}) { + debug _task_context => _31; + debug self => ((*(_8.0: &mut {async fn body of ActionPermit<'_, T>::perform()})).0: ActionPermit<'_, T>); + let _11: ActionPermit<'_, T>; @@ -51,32 +51,28 @@ + let mut _38: &mut {async fn body of ActionPermit<'_, T>::perform()}; + let mut _39: &mut {async fn body of ActionPermit<'_, T>::perform()}; + let mut _40: &mut {async fn body of ActionPermit<'_, T>::perform()}; -+ scope 8 { ++ scope 7 { + debug self => (((*(_8.0: &mut {async fn body of ActionPermit<'_, T>::perform()})) as variant#3).0: ActionPermit<'_, T>); + let mut _15: std::future::Ready<()>; -+ scope 9 { ++ scope 8 { + debug __awaitee => (((*(_8.0: &mut {async fn body of ActionPermit<'_, T>::perform()})) as variant#3).1: std::future::Ready<()>); + let _26: (); -+ scope 10 { -+ } -+ scope 11 { ++ scope 9 { + debug result => _26; + } + } -+ scope 12 (inlined ready::<()>) { ++ scope 10 (inlined ready::<()>) { + debug t => _14; + let mut _41: std::option::Option<()>; + } + } + } } - scope 3 { -+ scope 6 (inlined Pin::<&mut {async fn body of ActionPermit<'_, T>::perform()}>::new_unchecked) { -+ debug pointer => _5; -+ } - } ++ scope 5 (inlined Pin::<&mut {async fn body of ActionPermit<'_, T>::perform()}>::new_unchecked) { ++ debug pointer => _5; ++ } } -+ scope 5 (inlined ActionPermit::<'_, T>::perform) { ++ scope 4 (inlined ActionPermit::<'_, T>::perform) { + debug self => _3; + } diff --git a/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-unwind.diff b/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-unwind.diff index 96a93cdda3d..fd080d22d3a 100644 --- a/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-unwind.diff +++ b/tests/mir-opt/inline_coroutine_body.run2-{closure#0}.Inline.panic-unwind.diff @@ -18,9 +18,9 @@ let _4: std::pin::Pin<&mut {async fn body of ActionPermit<'_, T>::perform()}>; scope 2 { debug fut => _4; - scope 4 { + scope 3 { } -+ scope 7 (inlined ActionPermit::<'_, T>::perform::{closure#0}) { ++ scope 6 (inlined ActionPermit::<'_, T>::perform::{closure#0}) { + debug _task_context => _31; + debug self => ((*(_8.0: &mut {async fn body of ActionPermit<'_, T>::perform()})).0: ActionPermit<'_, T>); + let _11: ActionPermit<'_, T>; @@ -53,32 +53,28 @@ + let mut _40: &mut {async fn body of ActionPermit<'_, T>::perform()}; + let mut _41: &mut {async fn body of ActionPermit<'_, T>::perform()}; + let mut _42: &mut {async fn body of ActionPermit<'_, T>::perform()}; -+ scope 8 { ++ scope 7 { + debug self => (((*(_8.0: &mut {async fn body of ActionPermit<'_, T>::perform()})) as variant#3).0: ActionPermit<'_, T>); + let mut _15: std::future::Ready<()>; -+ scope 9 { ++ scope 8 { + debug __awaitee => (((*(_8.0: &mut {async fn body of ActionPermit<'_, T>::perform()})) as variant#3).1: std::future::Ready<()>); + let _26: (); -+ scope 10 { -+ } -+ scope 11 { ++ scope 9 { + debug result => _26; + } + } -+ scope 12 (inlined ready::<()>) { ++ scope 10 (inlined ready::<()>) { + debug t => _14; + let mut _43: std::option::Option<()>; + } + } + } } - scope 3 { -+ scope 6 (inlined Pin::<&mut {async fn body of ActionPermit<'_, T>::perform()}>::new_unchecked) { -+ debug pointer => _5; -+ } - } ++ scope 5 (inlined Pin::<&mut {async fn body of ActionPermit<'_, T>::perform()}>::new_unchecked) { ++ debug pointer => _5; ++ } } -+ scope 5 (inlined ActionPermit::<'_, T>::perform) { ++ scope 4 (inlined ActionPermit::<'_, T>::perform) { + debug self => _3; + } diff --git a/tests/mir-opt/instsimplify/ub_check.unwrap_unchecked.InstSimplify.diff b/tests/mir-opt/instsimplify/ub_check.unwrap_unchecked.InstSimplify.diff index f3402fde05b..6d6c9c9a7a1 100644 --- a/tests/mir-opt/instsimplify/ub_check.unwrap_unchecked.InstSimplify.diff +++ b/tests/mir-opt/instsimplify/ub_check.unwrap_unchecked.InstSimplify.diff @@ -5,23 +5,17 @@ debug x => _1; let mut _0: i32; let mut _2: std::option::Option<i32>; - scope 1 { - scope 2 (inlined #[track_caller] Option::<i32>::unwrap_unchecked) { - debug self => _2; - let mut _3: isize; - scope 3 { - debug val => _0; - } - scope 4 { - scope 5 (inlined unreachable_unchecked) { - let mut _4: bool; - let _5: (); - scope 6 { - } - scope 7 (inlined core::ub_checks::check_language_ub) { - scope 8 (inlined core::ub_checks::check_language_ub::runtime) { - } - } + scope 1 (inlined #[track_caller] Option::<i32>::unwrap_unchecked) { + debug self => _2; + let mut _3: isize; + scope 2 { + debug val => _0; + } + scope 3 (inlined unreachable_unchecked) { + let mut _4: bool; + let _5: (); + scope 4 (inlined core::ub_checks::check_language_ub) { + scope 5 (inlined core::ub_checks::check_language_ub::runtime) { } } } diff --git a/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-abort.mir b/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-abort.mir index b4f21240939..53912adc003 100644 --- a/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-abort.mir +++ b/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-abort.mir @@ -4,8 +4,6 @@ fn main() -> () { let mut _0: (); let mut _1: !; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-unwind.mir b/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-unwind.mir index 1851747f0a6..50416300094 100644 --- a/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-unwind.mir +++ b/tests/mir-opt/issue_104451_unwindable_intrinsics.main.AbortUnwindingCalls.after.panic-unwind.mir @@ -4,8 +4,6 @@ fn main() -> () { let mut _0: (); let mut _1: !; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir index 91dee82fde0..3104baa5fdb 100644 --- a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir +++ b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir @@ -15,15 +15,13 @@ fn test() -> Option<Box<u32>> { let mut _11: std::option::Option<std::convert::Infallible>; let _12: u32; scope 1 { - } - scope 2 { debug residual => _9; - scope 3 { + scope 2 { } } - scope 4 { + scope 3 { debug val => _12; - scope 5 { + scope 4 { } } diff --git a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir index ff7fc74ff61..da33c830115 100644 --- a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir +++ b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir @@ -15,15 +15,13 @@ fn test() -> Option<Box<u32>> { let mut _11: std::option::Option<std::convert::Infallible>; let _12: u32; scope 1 { - } - scope 2 { debug residual => _9; - scope 3 { + scope 2 { } } - scope 4 { + scope 3 { debug val => _12; - scope 5 { + scope 4 { } } diff --git a/tests/mir-opt/issue_72181.main.built.after.mir b/tests/mir-opt/issue_72181.main.built.after.mir index cff20702bf7..fa101512d72 100644 --- a/tests/mir-opt/issue_72181.main.built.after.mir +++ b/tests/mir-opt/issue_72181.main.built.after.mir @@ -15,8 +15,6 @@ fn main() -> () { debug f => _2; scope 3 { } - scope 4 { - } } } diff --git a/tests/mir-opt/issue_72181_1.main.built.after.mir b/tests/mir-opt/issue_72181_1.main.built.after.mir index d35aada95f8..ae0dc9a0b6a 100644 --- a/tests/mir-opt/issue_72181_1.main.built.after.mir +++ b/tests/mir-opt/issue_72181_1.main.built.after.mir @@ -14,8 +14,6 @@ fn main() -> () { scope 1 { debug v => _2; } - scope 2 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/issues/issue_75439.foo.MatchBranchSimplification.diff b/tests/mir-opt/issues/issue_75439.foo.MatchBranchSimplification.diff index f11c993340f..25ed1b4d0c7 100644 --- a/tests/mir-opt/issues/issue_75439.foo.MatchBranchSimplification.diff +++ b/tests/mir-opt/issues/issue_75439.foo.MatchBranchSimplification.diff @@ -10,15 +10,11 @@ let mut _6: u32; scope 1 { debug dwords => _2; - scope 3 { + scope 2 { debug ip => _4; let _4: u32; - scope 4 { - } } } - scope 2 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-abort.diff b/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-abort.diff index 80a42263643..e9d4352014f 100644 --- a/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-abort.diff +++ b/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-abort.diff @@ -12,8 +12,6 @@ let _2: *mut i32; scope 2 { debug a => _2; - scope 3 { - } } } diff --git a/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-unwind.diff b/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-unwind.diff index 80a42263643..e9d4352014f 100644 --- a/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-unwind.diff +++ b/tests/mir-opt/jump_threading.mutable_ref.JumpThreading.panic-unwind.diff @@ -12,8 +12,6 @@ let _2: *mut i32; scope 2 { debug a => _2; - scope 3 { - } } } diff --git a/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-abort.diff b/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-abort.diff index f9f73bf991d..633a344a2ed 100644 --- a/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-abort.diff +++ b/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-abort.diff @@ -14,8 +14,6 @@ let _5: *const [u8]; scope 2 { debug arr => _5; - scope 3 { - } } } diff --git a/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-unwind.diff b/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-unwind.diff index f9f73bf991d..633a344a2ed 100644 --- a/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-unwind.diff +++ b/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.panic-unwind.diff @@ -14,8 +14,6 @@ let _5: *const [u8]; scope 2 { debug arr => _5; - scope 3 { - } } } diff --git a/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-abort.diff index 79635f23e8e..6c1f457cb5f 100644 --- a/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-abort.diff @@ -4,8 +4,6 @@ fn assume() -> () { let mut _0: (); let _1: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-unwind.diff index 79635f23e8e..6c1f457cb5f 100644 --- a/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.assume.LowerIntrinsics.panic-unwind.diff @@ -4,8 +4,6 @@ fn assume() -> () { let mut _0: (); let _1: (); - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-abort.diff index 6de5f2c4f07..96b66af66a2 100644 --- a/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-abort.diff @@ -18,8 +18,6 @@ let mut _2: (); scope 2 { debug dst => _2; - scope 3 { - } } } diff --git a/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-unwind.diff index 6de5f2c4f07..96b66af66a2 100644 --- a/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.f_copy_nonoverlapping.LowerIntrinsics.panic-unwind.diff @@ -18,8 +18,6 @@ let mut _2: (); scope 2 { debug dst => _2; - scope 3 { - } } } diff --git a/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-abort.diff index 147c48a3c01..781104be290 100644 --- a/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-abort.diff @@ -5,8 +5,6 @@ debug r => _1; let mut _0: i32; let mut _2: *const i32; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-unwind.diff index 147c48a3c01..781104be290 100644 --- a/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.read_via_copy_primitive.LowerIntrinsics.panic-unwind.diff @@ -5,8 +5,6 @@ debug r => _1; let mut _0: i32; let mut _2: *const i32; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-abort.diff index b2cf3cc1cca..56c357b3776 100644 --- a/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-abort.diff @@ -5,8 +5,6 @@ debug r => _1; let mut _0: Never; let mut _2: *const Never; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-unwind.diff index b2cf3cc1cca..56c357b3776 100644 --- a/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.read_via_copy_uninhabited.LowerIntrinsics.panic-unwind.diff @@ -5,8 +5,6 @@ debug r => _1; let mut _0: Never; let mut _2: *const Never; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-abort.diff index 3b4051e4ae2..6e542c4b5a7 100644 --- a/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-abort.diff @@ -5,8 +5,6 @@ debug c => _1; let mut _0: i8; let mut _2: std::cmp::Ordering; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-unwind.diff index 3b4051e4ae2..6e542c4b5a7 100644 --- a/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.transmute_inhabited.LowerIntrinsics.panic-unwind.diff @@ -5,8 +5,6 @@ debug c => _1; let mut _0: i8; let mut _2: std::cmp::Ordering; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-abort.diff index 91276a1b5c4..ab4646370f1 100644 --- a/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-abort.diff @@ -5,8 +5,6 @@ debug u => _1; let mut _0: *const T; let mut _2: &T; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-unwind.diff index 91276a1b5c4..ab4646370f1 100644 --- a/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.transmute_ref_dst.LowerIntrinsics.panic-unwind.diff @@ -5,8 +5,6 @@ debug u => _1; let mut _0: *const T; let mut _2: &T; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-abort.diff index 792c77d575b..6d3ad348988 100644 --- a/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-abort.diff @@ -5,8 +5,6 @@ debug u => _1; let mut _0: Never; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-unwind.diff index 792c77d575b..6d3ad348988 100644 --- a/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.transmute_uninhabited.LowerIntrinsics.panic-unwind.diff @@ -5,8 +5,6 @@ debug u => _1; let mut _0: Never; let mut _2: (); - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-abort.diff index f5646e7f1e9..2b715ac1d63 100644 --- a/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-abort.diff @@ -5,8 +5,6 @@ let mut _0: !; let _1: (); let mut _2: !; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-unwind.diff index f5646e7f1e9..2b715ac1d63 100644 --- a/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.unreachable.LowerIntrinsics.panic-unwind.diff @@ -5,8 +5,6 @@ let mut _0: !; let _1: (); let mut _2: !; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-abort.diff b/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-abort.diff index ddc8cf9a3d9..cc9177c9002 100644 --- a/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-abort.diff +++ b/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-abort.diff @@ -7,8 +7,6 @@ let mut _0: (); let mut _3: *mut std::string::String; let mut _4: std::string::String; - scope 1 { - } bb0: { StorageLive(_3); diff --git a/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-unwind.diff b/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-unwind.diff index ddc8cf9a3d9..cc9177c9002 100644 --- a/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-unwind.diff +++ b/tests/mir-opt/lower_intrinsics.write_via_move_string.LowerIntrinsics.panic-unwind.diff @@ -7,8 +7,6 @@ let mut _0: (); let mut _3: *mut std::string::String; let mut _4: std::string::String; - scope 1 { - } bb0: { StorageLive(_3); diff --git a/tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir index 656934fce42..845673601b2 100644 --- a/tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir +++ b/tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir @@ -21,13 +21,9 @@ fn checked_shl(_1: u32, _2: u32) -> Option<u32> { debug self => _1; debug rhs => _2; let mut _3: u32; - scope 5 { - scope 6 (inlined core::num::<impl u32>::unchecked_shl) { - debug self => _1; - debug rhs => _3; - scope 7 { - } - } + scope 5 (inlined core::num::<impl u32>::unchecked_shl) { + debug self => _1; + debug rhs => _3; } } } diff --git a/tests/mir-opt/pre-codegen/duplicate_switch_targets.ub_if_b.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/duplicate_switch_targets.ub_if_b.PreCodegen.after.mir index ebe846e8a51..518fedffc16 100644 --- a/tests/mir-opt/pre-codegen/duplicate_switch_targets.ub_if_b.PreCodegen.after.mir +++ b/tests/mir-opt/pre-codegen/duplicate_switch_targets.ub_if_b.PreCodegen.after.mir @@ -5,10 +5,8 @@ fn ub_if_b(_1: Thing) -> Thing { let mut _0: Thing; let mut _2: isize; scope 1 (inlined unreachable_unchecked) { - scope 2 { - } - scope 3 (inlined core::ub_checks::check_language_ub) { - scope 4 (inlined core::ub_checks::check_language_ub::runtime) { + scope 2 (inlined core::ub_checks::check_language_ub) { + scope 3 (inlined core::ub_checks::check_language_ub::runtime) { } } } diff --git a/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir index 0b5ed6ee169..cdb7eea74fb 100644 --- a/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir +++ b/tests/mir-opt/pre-codegen/loops.int_range.PreCodegen.after.mir @@ -26,10 +26,8 @@ fn int_range(_1: usize, _2: usize) -> () { let mut _12: usize; scope 6 { debug old => _11; - scope 7 { - } } - scope 8 (inlined std::cmp::impls::<impl PartialOrd for usize>::lt) { + scope 7 (inlined std::cmp::impls::<impl PartialOrd for usize>::lt) { debug self => _6; debug other => _7; let mut _8: usize; diff --git a/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-abort.mir index 26919dd98dd..c744787fce2 100644 --- a/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-abort.mir @@ -8,21 +8,15 @@ fn mem_replace(_1: &mut u32, _2: u32) -> u32 { debug dest => _1; debug src => _2; scope 2 { - scope 3 { - debug result => _0; - scope 6 (inlined std::ptr::write::<u32>) { - debug dst => _1; - debug src => _2; - scope 7 { - } - } - } - scope 4 (inlined std::ptr::read::<u32>) { - debug src => _1; - scope 5 { - } + debug result => _0; + scope 4 (inlined std::ptr::write::<u32>) { + debug dst => _1; + debug src => _2; } } + scope 3 (inlined std::ptr::read::<u32>) { + debug src => _1; + } } bb0: { diff --git a/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-unwind.mir index 26919dd98dd..c744787fce2 100644 --- a/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/mem_replace.mem_replace.PreCodegen.after.panic-unwind.mir @@ -8,21 +8,15 @@ fn mem_replace(_1: &mut u32, _2: u32) -> u32 { debug dest => _1; debug src => _2; scope 2 { - scope 3 { - debug result => _0; - scope 6 (inlined std::ptr::write::<u32>) { - debug dst => _1; - debug src => _2; - scope 7 { - } - } - } - scope 4 (inlined std::ptr::read::<u32>) { - debug src => _1; - scope 5 { - } + debug result => _0; + scope 4 (inlined std::ptr::write::<u32>) { + debug dst => _1; + debug src => _2; } } + scope 3 (inlined std::ptr::read::<u32>) { + debug src => _1; + } } bb0: { diff --git a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir index ed965770adb..002d55ad9d9 100644 --- a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-abort.mir @@ -29,10 +29,8 @@ fn forward_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () { let mut _13: u32; scope 6 { debug old => _12; - scope 7 { - } } - scope 8 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { + scope 7 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { debug self => _7; debug other => _8; let mut _9: u32; diff --git a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir index a7ee9be19bd..d5021ac84d2 100644 --- a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir @@ -29,10 +29,8 @@ fn forward_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () { let mut _13: u32; scope 6 { debug old => _12; - scope 7 { - } } - scope 8 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { + scope 7 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { debug self => _7; debug other => _8; let mut _9: u32; diff --git a/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-abort.mir index f674f6a3009..7faae1d863c 100644 --- a/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-abort.mir @@ -14,10 +14,8 @@ fn range_iter_next(_1: &mut std::ops::Range<u32>) -> Option<u32> { let mut _8: u32; scope 3 { debug old => _7; - scope 4 { - } } - scope 5 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { + scope 4 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { debug self => _2; debug other => _3; let mut _4: u32; diff --git a/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-unwind.mir index a5029dcad3a..37f00533b60 100644 --- a/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/range_iter.range_iter_next.PreCodegen.after.panic-unwind.mir @@ -14,10 +14,8 @@ fn range_iter_next(_1: &mut std::ops::Range<u32>) -> Option<u32> { let mut _8: u32; scope 3 { debug old => _7; - scope 4 { - } } - scope 5 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { + scope 4 (inlined std::cmp::impls::<impl PartialOrd for u32>::lt) { debug self => _2; debug other => _3; let mut _4: u32; diff --git a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir index bcc540ae6fc..e5490955a36 100644 --- a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-abort.mir @@ -9,8 +9,6 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) -> debug index => _2; let mut _3: *mut [u32]; let mut _4: *mut [u32]; - scope 2 { - } } bb0: { diff --git a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir index 1fe7da7d2fd..810fee9a149 100644 --- a/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir @@ -9,8 +9,6 @@ fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) -> debug index => _2; let mut _3: *mut [u32]; let mut _4: *mut [u32]; - scope 2 { - } } bb0: { diff --git a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir index f698e15d302..1ec85906385 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-abort.mir @@ -37,52 +37,42 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () { let _7: std::ptr::NonNull<T>; scope 6 { debug ptr => _7; + let _11: *const T; scope 7 { - let _11: *const T; - scope 8 { - debug end_or_len => _11; - } - scope 14 (inlined without_provenance::<T>) { - debug addr => _3; - scope 15 { - } - } - scope 16 (inlined NonNull::<T>::as_ptr) { - debug self => _7; - } - scope 17 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { - debug self => _9; - debug count => _3; - scope 18 { - } - } + debug end_or_len => _11; + } + scope 11 (inlined without_provenance::<T>) { + debug addr => _3; + } + scope 12 (inlined NonNull::<T>::as_ptr) { + debug self => _7; + } + scope 13 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { + debug self => _9; + debug count => _3; } } - scope 9 (inlined <NonNull<[T]> as From<&[T]>>::from) { + scope 8 (inlined <NonNull<[T]> as From<&[T]>>::from) { debug reference => _1; let mut _4: *const [T]; - scope 10 { - } } - scope 11 (inlined NonNull::<[T]>::cast::<T>) { + scope 9 (inlined NonNull::<[T]>::cast::<T>) { debug self => _5; let mut _6: *const T; - scope 12 { - scope 13 (inlined NonNull::<[T]>::as_ptr) { - debug self => _5; - } + scope 10 (inlined NonNull::<[T]>::as_ptr) { + debug self => _5; } } } } } - scope 19 (inlined <std::slice::Iter<'_, T> as Iterator>::enumerate) { + scope 14 (inlined <std::slice::Iter<'_, T> as Iterator>::enumerate) { debug self => _13; - scope 20 (inlined Enumerate::<std::slice::Iter<'_, T>>::new) { + scope 15 (inlined Enumerate::<std::slice::Iter<'_, T>>::new) { debug iter => _13; } } - scope 21 (inlined <Enumerate<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { + scope 16 (inlined <Enumerate<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { debug self => _14; } diff --git a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir index eae9f5909e6..70cdf3f41c2 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir @@ -37,52 +37,42 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () { let _7: std::ptr::NonNull<T>; scope 6 { debug ptr => _7; + let _11: *const T; scope 7 { - let _11: *const T; - scope 8 { - debug end_or_len => _11; - } - scope 14 (inlined without_provenance::<T>) { - debug addr => _3; - scope 15 { - } - } - scope 16 (inlined NonNull::<T>::as_ptr) { - debug self => _7; - } - scope 17 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { - debug self => _9; - debug count => _3; - scope 18 { - } - } + debug end_or_len => _11; + } + scope 11 (inlined without_provenance::<T>) { + debug addr => _3; + } + scope 12 (inlined NonNull::<T>::as_ptr) { + debug self => _7; + } + scope 13 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { + debug self => _9; + debug count => _3; } } - scope 9 (inlined <NonNull<[T]> as From<&[T]>>::from) { + scope 8 (inlined <NonNull<[T]> as From<&[T]>>::from) { debug reference => _1; let mut _4: *const [T]; - scope 10 { - } } - scope 11 (inlined NonNull::<[T]>::cast::<T>) { + scope 9 (inlined NonNull::<[T]>::cast::<T>) { debug self => _5; let mut _6: *const T; - scope 12 { - scope 13 (inlined NonNull::<[T]>::as_ptr) { - debug self => _5; - } + scope 10 (inlined NonNull::<[T]>::as_ptr) { + debug self => _5; } } } } } - scope 19 (inlined <std::slice::Iter<'_, T> as Iterator>::enumerate) { + scope 14 (inlined <std::slice::Iter<'_, T> as Iterator>::enumerate) { debug self => _13; - scope 20 (inlined Enumerate::<std::slice::Iter<'_, T>>::new) { + scope 15 (inlined Enumerate::<std::slice::Iter<'_, T>>::new) { debug iter => _13; } } - scope 21 (inlined <Enumerate<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { + scope 16 (inlined <Enumerate<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { debug self => _14; } diff --git a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir index 158ae0de890..d8252e7267a 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-abort.mir @@ -34,46 +34,36 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () { let _7: std::ptr::NonNull<T>; scope 6 { debug ptr => _7; + let _11: *const T; scope 7 { - let _11: *const T; - scope 8 { - debug end_or_len => _11; - } - scope 14 (inlined without_provenance::<T>) { - debug addr => _3; - scope 15 { - } - } - scope 16 (inlined NonNull::<T>::as_ptr) { - debug self => _7; - } - scope 17 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { - debug self => _9; - debug count => _3; - scope 18 { - } - } + debug end_or_len => _11; + } + scope 11 (inlined without_provenance::<T>) { + debug addr => _3; + } + scope 12 (inlined NonNull::<T>::as_ptr) { + debug self => _7; + } + scope 13 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { + debug self => _9; + debug count => _3; } } - scope 9 (inlined <NonNull<[T]> as From<&[T]>>::from) { + scope 8 (inlined <NonNull<[T]> as From<&[T]>>::from) { debug reference => _1; let mut _4: *const [T]; - scope 10 { - } } - scope 11 (inlined NonNull::<[T]>::cast::<T>) { + scope 9 (inlined NonNull::<[T]>::cast::<T>) { debug self => _5; let mut _6: *const T; - scope 12 { - scope 13 (inlined NonNull::<[T]>::as_ptr) { - debug self => _5; - } + scope 10 (inlined NonNull::<[T]>::as_ptr) { + debug self => _5; } } } } } - scope 19 (inlined <std::slice::Iter<'_, T> as IntoIterator>::into_iter) { + scope 14 (inlined <std::slice::Iter<'_, T> as IntoIterator>::into_iter) { debug self => _13; } diff --git a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir index ac9e31a0da8..b3904dc70a6 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir @@ -34,46 +34,36 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () { let _7: std::ptr::NonNull<T>; scope 6 { debug ptr => _7; + let _11: *const T; scope 7 { - let _11: *const T; - scope 8 { - debug end_or_len => _11; - } - scope 14 (inlined without_provenance::<T>) { - debug addr => _3; - scope 15 { - } - } - scope 16 (inlined NonNull::<T>::as_ptr) { - debug self => _7; - } - scope 17 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { - debug self => _9; - debug count => _3; - scope 18 { - } - } + debug end_or_len => _11; + } + scope 11 (inlined without_provenance::<T>) { + debug addr => _3; + } + scope 12 (inlined NonNull::<T>::as_ptr) { + debug self => _7; + } + scope 13 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { + debug self => _9; + debug count => _3; } } - scope 9 (inlined <NonNull<[T]> as From<&[T]>>::from) { + scope 8 (inlined <NonNull<[T]> as From<&[T]>>::from) { debug reference => _1; let mut _4: *const [T]; - scope 10 { - } } - scope 11 (inlined NonNull::<[T]>::cast::<T>) { + scope 9 (inlined NonNull::<[T]>::cast::<T>) { debug self => _5; let mut _6: *const T; - scope 12 { - scope 13 (inlined NonNull::<[T]>::as_ptr) { - debug self => _5; - } + scope 10 (inlined NonNull::<[T]>::as_ptr) { + debug self => _5; } } } } } - scope 19 (inlined <std::slice::Iter<'_, T> as IntoIterator>::into_iter) { + scope 14 (inlined <std::slice::Iter<'_, T> as IntoIterator>::into_iter) { debug self => _13; } diff --git a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir index 543e8918e39..5ab88c9b855 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-abort.mir @@ -35,10 +35,8 @@ fn range_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () { let mut _13: usize; scope 7 { debug old => _12; - scope 8 { - } } - scope 9 (inlined std::cmp::impls::<impl PartialOrd for usize>::lt) { + scope 8 (inlined std::cmp::impls::<impl PartialOrd for usize>::lt) { debug self => _7; debug other => _8; let mut _9: usize; diff --git a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir index a16e9cd9e51..513651090a8 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir @@ -35,10 +35,8 @@ fn range_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () { let mut _13: usize; scope 7 { debug old => _12; - scope 8 { - } } - scope 9 (inlined std::cmp::impls::<impl PartialOrd for usize>::lt) { + scope 8 (inlined std::cmp::impls::<impl PartialOrd for usize>::lt) { debug self => _7; debug other => _8; let mut _9: usize; diff --git a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir index 9550df012f8..091c8a0e968 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-abort.mir @@ -19,7 +19,7 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () { scope 2 { debug x => _20; } - scope 22 (inlined <Rev<std::slice::Iter<'_, T>> as Iterator>::next) { + scope 17 (inlined <Rev<std::slice::Iter<'_, T>> as Iterator>::next) { debug self => _16; let mut _17: &mut std::slice::Iter<'_, T>; } @@ -39,52 +39,42 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () { let _7: std::ptr::NonNull<T>; scope 6 { debug ptr => _7; + let _11: *const T; scope 7 { - let _11: *const T; - scope 8 { - debug end_or_len => _11; - } - scope 14 (inlined without_provenance::<T>) { - debug addr => _3; - scope 15 { - } - } - scope 16 (inlined NonNull::<T>::as_ptr) { - debug self => _7; - } - scope 17 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { - debug self => _9; - debug count => _3; - scope 18 { - } - } + debug end_or_len => _11; + } + scope 11 (inlined without_provenance::<T>) { + debug addr => _3; + } + scope 12 (inlined NonNull::<T>::as_ptr) { + debug self => _7; + } + scope 13 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { + debug self => _9; + debug count => _3; } } - scope 9 (inlined <NonNull<[T]> as From<&[T]>>::from) { + scope 8 (inlined <NonNull<[T]> as From<&[T]>>::from) { debug reference => _1; let mut _4: *const [T]; - scope 10 { - } } - scope 11 (inlined NonNull::<[T]>::cast::<T>) { + scope 9 (inlined NonNull::<[T]>::cast::<T>) { debug self => _5; let mut _6: *const T; - scope 12 { - scope 13 (inlined NonNull::<[T]>::as_ptr) { - debug self => _5; - } + scope 10 (inlined NonNull::<[T]>::as_ptr) { + debug self => _5; } } } } } - scope 19 (inlined <std::slice::Iter<'_, T> as Iterator>::rev) { + scope 14 (inlined <std::slice::Iter<'_, T> as Iterator>::rev) { debug self => _13; - scope 20 (inlined Rev::<std::slice::Iter<'_, T>>::new) { + scope 15 (inlined Rev::<std::slice::Iter<'_, T>>::new) { debug iter => _13; } } - scope 21 (inlined <Rev<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { + scope 16 (inlined <Rev<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { debug self => _14; } diff --git a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir index d75aabd12fc..1873d452f34 100644 --- a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir +++ b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir @@ -19,7 +19,7 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () { scope 2 { debug x => _20; } - scope 22 (inlined <Rev<std::slice::Iter<'_, T>> as Iterator>::next) { + scope 17 (inlined <Rev<std::slice::Iter<'_, T>> as Iterator>::next) { debug self => _16; let mut _17: &mut std::slice::Iter<'_, T>; } @@ -39,52 +39,42 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () { let _7: std::ptr::NonNull<T>; scope 6 { debug ptr => _7; + let _11: *const T; scope 7 { - let _11: *const T; - scope 8 { - debug end_or_len => _11; - } - scope 14 (inlined without_provenance::<T>) { - debug addr => _3; - scope 15 { - } - } - scope 16 (inlined NonNull::<T>::as_ptr) { - debug self => _7; - } - scope 17 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { - debug self => _9; - debug count => _3; - scope 18 { - } - } + debug end_or_len => _11; + } + scope 11 (inlined without_provenance::<T>) { + debug addr => _3; + } + scope 12 (inlined NonNull::<T>::as_ptr) { + debug self => _7; + } + scope 13 (inlined std::ptr::mut_ptr::<impl *mut T>::add) { + debug self => _9; + debug count => _3; } } - scope 9 (inlined <NonNull<[T]> as From<&[T]>>::from) { + scope 8 (inlined <NonNull<[T]> as From<&[T]>>::from) { debug reference => _1; let mut _4: *const [T]; - scope 10 { - } } - scope 11 (inlined NonNull::<[T]>::cast::<T>) { + scope 9 (inlined NonNull::<[T]>::cast::<T>) { debug self => _5; let mut _6: *const T; - scope 12 { - scope 13 (inlined NonNull::<[T]>::as_ptr) { - debug self => _5; - } + scope 10 (inlined NonNull::<[T]>::as_ptr) { + debug self => _5; } } } } } - scope 19 (inlined <std::slice::Iter<'_, T> as Iterator>::rev) { + scope 14 (inlined <std::slice::Iter<'_, T> as Iterator>::rev) { debug self => _13; - scope 20 (inlined Rev::<std::slice::Iter<'_, T>>::new) { + scope 15 (inlined Rev::<std::slice::Iter<'_, T>>::new) { debug iter => _13; } } - scope 21 (inlined <Rev<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { + scope 16 (inlined <Rev<std::slice::Iter<'_, T>> as IntoIterator>::into_iter) { debug self => _14; } diff --git a/tests/mir-opt/reference_prop.mut_raw_then_mut_shr.ReferencePropagation.diff b/tests/mir-opt/reference_prop.mut_raw_then_mut_shr.ReferencePropagation.diff index 747028e128f..859097d3966 100644 --- a/tests/mir-opt/reference_prop.mut_raw_then_mut_shr.ReferencePropagation.diff +++ b/tests/mir-opt/reference_prop.mut_raw_then_mut_shr.ReferencePropagation.diff @@ -25,8 +25,6 @@ let _7: i32; scope 5 { debug a => _7; - scope 6 { - } } } } diff --git a/tests/mir-opt/reference_prop.reference_propagation_const_ptr.ReferencePropagation.diff b/tests/mir-opt/reference_prop.reference_propagation_const_ptr.ReferencePropagation.diff index ce5ddbfdd12..1e6a168f756 100644 --- a/tests/mir-opt/reference_prop.reference_propagation_const_ptr.ReferencePropagation.diff +++ b/tests/mir-opt/reference_prop.reference_propagation_const_ptr.ReferencePropagation.diff @@ -6,218 +6,196 @@ debug multiple => _2; let mut _0: (); let _3: (); + let _4: usize; let _7: (); let mut _8: (); let _9: (); + let _10: usize; let mut _13: *const usize; let _15: (); let mut _16: (); let _17: (); + let _18: usize; let _22: (); let mut _23: &*const usize; let _24: (); + let _25: usize; let _29: (); let mut _30: *mut *const usize; let _31: (); + let _32: usize; let _35: (); let mut _36: *const usize; let _37: (); + let _38: usize; let _44: (); let mut _45: *const usize; let _46: (); + let _47: *const T; let _49: (); let mut _50: (); let _51: (); + let _52: *const T; let mut _53: *const T; let _55: (); let mut _56: (); let _57: (); + let _58: usize; let _62: (); let mut _63: (); let _64: (); + let _65: usize; let _69: (); let mut _70: (); + let _71: usize; let _75: (); let mut _76: (); scope 1 { - let _4: usize; + debug a => _4; + let _5: *const usize; scope 2 { - debug a => _4; - let _5: *const usize; + debug b => _5; + let _6: usize; scope 3 { - debug b => _5; - let _6: usize; - scope 4 { - debug c => _6; - } + debug c => _6; } } } - scope 5 { - let _10: usize; - scope 6 { - debug a => _10; - let _11: usize; - scope 7 { - debug a2 => _11; - let mut _12: *const usize; - scope 8 { - debug b => _12; - let _14: usize; - scope 9 { - debug c => _14; - } + scope 4 { + debug a => _10; + let _11: usize; + scope 5 { + debug a2 => _11; + let mut _12: *const usize; + scope 6 { + debug b => _12; + let _14: usize; + scope 7 { + debug c => _14; } } } } - scope 10 { - let _18: usize; - scope 11 { - debug a => _18; - let _19: *const usize; - scope 12 { - debug b => _19; - let _20: &*const usize; - scope 13 { - debug d => _20; - let _21: usize; - scope 14 { - debug c => _21; - } + scope 8 { + debug a => _18; + let _19: *const usize; + scope 9 { + debug b => _19; + let _20: &*const usize; + scope 10 { + debug d => _20; + let _21: usize; + scope 11 { + debug c => _21; } } } } - scope 15 { - let _25: usize; - scope 16 { - debug a => _25; - let mut _26: *const usize; - scope 17 { - debug b => _26; - let _27: *mut *const usize; - scope 18 { - debug d => _27; - let _28: usize; - scope 19 { - debug c => _28; - } + scope 12 { + debug a => _25; + let mut _26: *const usize; + scope 13 { + debug b => _26; + let _27: *mut *const usize; + scope 14 { + debug d => _27; + let _28: usize; + scope 15 { + debug c => _28; } } } } - scope 20 { - let _32: usize; - scope 21 { - debug a => _32; - let _33: *const usize; - scope 22 { - debug b => _33; - let _34: usize; - scope 23 { - debug c => _34; - } + scope 16 { + debug a => _32; + let _33: *const usize; + scope 17 { + debug b => _33; + let _34: usize; + scope 18 { + debug c => _34; } } } - scope 24 { - let _38: usize; - scope 25 { - debug a => _38; - let _39: *const usize; - scope 26 { - debug b1 => _39; - let _40: usize; - scope 27 { - debug c => _40; - let _41: *const usize; - scope 28 { - debug b2 => _41; - let _42: usize; - scope 29 { - debug c2 => _42; - let _43: *const usize; - scope 30 { - debug b3 => _43; - } + scope 19 { + debug a => _38; + let _39: *const usize; + scope 20 { + debug b1 => _39; + let _40: usize; + scope 21 { + debug c => _40; + let _41: *const usize; + scope 22 { + debug b2 => _41; + let _42: usize; + scope 23 { + debug c2 => _42; + let _43: *const usize; + scope 24 { + debug b3 => _43; } } } } } } - scope 31 { - let _47: *const T; - scope 32 { -- debug a => _47; -+ debug a => _1; - let _48: T; - scope 33 { - debug b => _48; - } + scope 25 { +- debug a => _47; ++ debug a => _1; + let _48: T; + scope 26 { + debug b => _48; } } - scope 34 { - let _52: *const T; - scope 35 { - debug a => _52; - let _54: T; - scope 36 { - debug b => _54; - } + scope 27 { + debug a => _52; + let _54: T; + scope 28 { + debug b => _54; } } - scope 37 { - let _58: usize; - scope 38 { - debug a => _58; - let _59: *const usize; - scope 39 { - debug b => _59; - let _60: *const usize; - scope 40 { - debug c => _60; - let _61: usize; - scope 41 { - debug e => _61; - } + scope 29 { + debug a => _58; + let _59: *const usize; + scope 30 { + debug b => _59; + let _60: *const usize; + scope 31 { + debug c => _60; + let _61: usize; + scope 32 { + debug e => _61; } } } } - scope 42 { - let _65: usize; - scope 43 { - debug a => _65; - let _66: *const usize; - scope 44 { - debug b => _66; - let _67: &*const usize; - scope 45 { - debug d => _67; - let _68: usize; - scope 46 { - debug c => _68; - } + scope 33 { + debug a => _65; + let _66: *const usize; + scope 34 { + debug b => _66; + let _67: &*const usize; + scope 35 { + debug d => _67; + let _68: usize; + scope 36 { + debug c => _68; } } } } - scope 47 { - let _71: usize; - scope 48 { - debug a => _71; - let mut _72: *const usize; - scope 49 { - debug b => _72; - let _73: &mut *const usize; - scope 50 { - debug d => _73; - let _74: usize; - scope 51 { - debug c => _74; - } + scope 37 { + debug a => _71; + let mut _72: *const usize; + scope 38 { + debug b => _72; + let _73: &mut *const usize; + scope 39 { + debug d => _73; + let _74: usize; + scope 40 { + debug c => _74; } } } diff --git a/tests/mir-opt/reference_prop.reference_propagation_mut_ptr.ReferencePropagation.diff b/tests/mir-opt/reference_prop.reference_propagation_mut_ptr.ReferencePropagation.diff index b6b2acc0b43..5629d04f1b1 100644 --- a/tests/mir-opt/reference_prop.reference_propagation_mut_ptr.ReferencePropagation.diff +++ b/tests/mir-opt/reference_prop.reference_propagation_mut_ptr.ReferencePropagation.diff @@ -6,197 +6,177 @@ debug multiple => _2; let mut _0: (); let _3: (); + let mut _4: usize; let _7: (); let mut _8: (); let _9: (); + let mut _10: usize; let mut _13: *mut usize; let _15: (); let mut _16: (); let _17: (); + let mut _18: usize; let _22: (); let mut _23: &*mut usize; let _24: (); + let mut _25: usize; let _29: (); let mut _30: *mut *mut usize; let _31: (); + let mut _32: usize; let _35: (); let mut _36: *mut usize; let _37: (); + let mut _38: usize; let _44: (); let mut _45: *mut usize; let _46: (); + let _47: *mut T; let _49: (); let mut _50: (); let _51: (); + let _52: *mut T; let mut _53: *mut T; let _55: (); let mut _56: (); let _57: (); + let mut _58: usize; let _62: (); let mut _63: (); + let mut _64: usize; let _68: (); let mut _69: (); scope 1 { - let mut _4: usize; + debug a => _4; + let _5: *mut usize; scope 2 { - debug a => _4; - let _5: *mut usize; + debug b => _5; + let _6: usize; scope 3 { - debug b => _5; - let _6: usize; - scope 4 { - debug c => _6; - } + debug c => _6; } } } - scope 5 { - let mut _10: usize; - scope 6 { - debug a => _10; - let mut _11: usize; - scope 7 { - debug a2 => _11; - let mut _12: *mut usize; - scope 8 { - debug b => _12; - let _14: usize; - scope 9 { - debug c => _14; - } + scope 4 { + debug a => _10; + let mut _11: usize; + scope 5 { + debug a2 => _11; + let mut _12: *mut usize; + scope 6 { + debug b => _12; + let _14: usize; + scope 7 { + debug c => _14; } } } } - scope 10 { - let mut _18: usize; - scope 11 { - debug a => _18; - let _19: *mut usize; - scope 12 { - debug b => _19; - let _20: &*mut usize; - scope 13 { - debug d => _20; - let _21: usize; - scope 14 { - debug c => _21; - } + scope 8 { + debug a => _18; + let _19: *mut usize; + scope 9 { + debug b => _19; + let _20: &*mut usize; + scope 10 { + debug d => _20; + let _21: usize; + scope 11 { + debug c => _21; } } } } - scope 15 { - let mut _25: usize; - scope 16 { - debug a => _25; - let mut _26: *mut usize; - scope 17 { - debug b => _26; - let _27: *mut *mut usize; - scope 18 { - debug d => _27; - let _28: usize; - scope 19 { - debug c => _28; - } + scope 12 { + debug a => _25; + let mut _26: *mut usize; + scope 13 { + debug b => _26; + let _27: *mut *mut usize; + scope 14 { + debug d => _27; + let _28: usize; + scope 15 { + debug c => _28; } } } } - scope 20 { - let mut _32: usize; - scope 21 { - debug a => _32; - let _33: *mut usize; - scope 22 { - debug b => _33; - let _34: usize; - scope 23 { - debug c => _34; - } + scope 16 { + debug a => _32; + let _33: *mut usize; + scope 17 { + debug b => _33; + let _34: usize; + scope 18 { + debug c => _34; } } } - scope 24 { - let mut _38: usize; - scope 25 { - debug a => _38; - let _39: *mut usize; - scope 26 { - debug b1 => _39; - let _40: usize; - scope 27 { - debug c => _40; - let _41: *mut usize; - scope 28 { - debug b2 => _41; - let _42: usize; - scope 29 { - debug c2 => _42; - let _43: *mut usize; - scope 30 { - debug b3 => _43; - } + scope 19 { + debug a => _38; + let _39: *mut usize; + scope 20 { + debug b1 => _39; + let _40: usize; + scope 21 { + debug c => _40; + let _41: *mut usize; + scope 22 { + debug b2 => _41; + let _42: usize; + scope 23 { + debug c2 => _42; + let _43: *mut usize; + scope 24 { + debug b3 => _43; } } } } } } - scope 31 { - let _47: *mut T; - scope 32 { -- debug a => _47; -+ debug a => _1; - let _48: T; - scope 33 { - debug b => _48; - } + scope 25 { +- debug a => _47; ++ debug a => _1; + let _48: T; + scope 26 { + debug b => _48; } } - scope 34 { - let _52: *mut T; - scope 35 { - debug a => _52; - let _54: T; - scope 36 { - debug b => _54; - } + scope 27 { + debug a => _52; + let _54: T; + scope 28 { + debug b => _54; } } - scope 37 { - let mut _58: usize; - scope 38 { - debug a => _58; - let _59: *mut usize; - scope 39 { - debug b => _59; - let _60: &*mut usize; - scope 40 { - debug d => _60; - let _61: usize; - scope 41 { - debug c => _61; - } + scope 29 { + debug a => _58; + let _59: *mut usize; + scope 30 { + debug b => _59; + let _60: &*mut usize; + scope 31 { + debug d => _60; + let _61: usize; + scope 32 { + debug c => _61; } } } } - scope 42 { - let mut _64: usize; - scope 43 { - debug a => _64; - let mut _65: *mut usize; - scope 44 { - debug b => _65; - let _66: &mut *mut usize; - scope 45 { - debug d => _66; - let _67: usize; - scope 46 { - debug c => _67; - } + scope 33 { + debug a => _64; + let mut _65: *mut usize; + scope 34 { + debug b => _65; + let _66: &mut *mut usize; + scope 35 { + debug d => _66; + let _67: usize; + scope 36 { + debug c => _67; } } } diff --git a/tests/mir-opt/reference_prop.unique_with_copies.ReferencePropagation.diff b/tests/mir-opt/reference_prop.unique_with_copies.ReferencePropagation.diff index b4912a918ba..a5427cea1f8 100644 --- a/tests/mir-opt/reference_prop.unique_with_copies.ReferencePropagation.diff +++ b/tests/mir-opt/reference_prop.unique_with_copies.ReferencePropagation.diff @@ -12,16 +12,12 @@ scope 1 { - debug y => _1; + debug y => _3; - scope 5 { - } } scope 2 { debug a => _2; let _3: *mut i32; scope 3 { debug x => _3; - scope 4 { - } } } diff --git a/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-abort.mir b/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-abort.mir index 7124b4c1cd8..f9d58ea60a3 100644 --- a/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-abort.mir +++ b/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-abort.mir @@ -36,22 +36,18 @@ fn array_casts() -> () { debug p => _2; let _8: [usize; 2]; scope 3 { - } - scope 4 { debug x => _8; let _9: *const usize; - scope 5 { + scope 4 { debug p => _9; let _20: &usize; let _21: &usize; let mut _34: &usize; - scope 6 { - } - scope 7 { + scope 5 { debug left_val => _20; debug right_val => _21; let _26: core::panicking::AssertKind; - scope 8 { + scope 6 { debug kind => _26; } } diff --git a/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-unwind.mir b/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-unwind.mir index be04757f2a3..b0b70cd5d91 100644 --- a/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-unwind.mir +++ b/tests/mir-opt/retag.array_casts.SimplifyCfg-pre-optimizations.after.panic-unwind.mir @@ -36,22 +36,18 @@ fn array_casts() -> () { debug p => _2; let _8: [usize; 2]; scope 3 { - } - scope 4 { debug x => _8; let _9: *const usize; - scope 5 { + scope 4 { debug p => _9; let _20: &usize; let _21: &usize; let mut _34: &usize; - scope 6 { - } - scope 7 { + scope 5 { debug left_val => _20; debug right_val => _21; let _26: core::panicking::AssertKind; - scope 8 { + scope 6 { debug kind => _26; } } diff --git a/tests/mir-opt/simplify_locals.t1.SimplifyLocals-before-const-prop.diff b/tests/mir-opt/simplify_locals.t1.SimplifyLocals-before-const-prop.diff index a903e8d789e..526ff2f25cf 100644 --- a/tests/mir-opt/simplify_locals.t1.SimplifyLocals-before-const-prop.diff +++ b/tests/mir-opt/simplify_locals.t1.SimplifyLocals-before-const-prop.diff @@ -5,8 +5,6 @@ let mut _0: (); - let _1: u32; - let mut _2: *mut u32; - scope 1 { - } bb0: { - StorageLive(_1); diff --git a/tests/mir-opt/simplify_locals.t2.SimplifyLocals-before-const-prop.diff b/tests/mir-opt/simplify_locals.t2.SimplifyLocals-before-const-prop.diff index e72e71a13a2..a88f6d40115 100644 --- a/tests/mir-opt/simplify_locals.t2.SimplifyLocals-before-const-prop.diff +++ b/tests/mir-opt/simplify_locals.t2.SimplifyLocals-before-const-prop.diff @@ -5,8 +5,6 @@ let mut _0: (); - let _1: &mut u32; - let mut _2: *mut u32; - scope 1 { - } bb0: { - StorageLive(_1); diff --git a/tests/mir-opt/simplify_locals.t3.SimplifyLocals-before-const-prop.diff b/tests/mir-opt/simplify_locals.t3.SimplifyLocals-before-const-prop.diff index 37c367c82ca..5d45d7ac781 100644 --- a/tests/mir-opt/simplify_locals.t3.SimplifyLocals-before-const-prop.diff +++ b/tests/mir-opt/simplify_locals.t3.SimplifyLocals-before-const-prop.diff @@ -6,8 +6,6 @@ - let _1: u32; - let mut _2: &mut u32; - let mut _3: *mut u32; - scope 1 { - } bb0: { - StorageLive(_1); diff --git a/tests/mir-opt/simplify_locals.t4.SimplifyLocals-before-const-prop.diff b/tests/mir-opt/simplify_locals.t4.SimplifyLocals-before-const-prop.diff index 006e3c4232d..4f4855dbaaf 100644 --- a/tests/mir-opt/simplify_locals.t4.SimplifyLocals-before-const-prop.diff +++ b/tests/mir-opt/simplify_locals.t4.SimplifyLocals-before-const-prop.diff @@ -5,8 +5,6 @@ let mut _0: u32; let mut _1: u32; let mut _2: *mut u32; - scope 1 { - } bb0: { StorageLive(_1); diff --git a/tests/mir-opt/sroa/structs.unions.ScalarReplacementOfAggregates.diff b/tests/mir-opt/sroa/structs.unions.ScalarReplacementOfAggregates.diff index 6c99d3efd29..2f8dfcc5d63 100644 --- a/tests/mir-opt/sroa/structs.unions.ScalarReplacementOfAggregates.diff +++ b/tests/mir-opt/sroa/structs.unions.ScalarReplacementOfAggregates.diff @@ -6,8 +6,6 @@ let mut _0: u32; let mut _2: unions::Repr; let mut _3: f32; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/mir-opt/tls_access.main.PreCodegen.after.mir b/tests/mir-opt/tls_access.main.PreCodegen.after.mir index 43c7051f027..1c59e938423 100644 --- a/tests/mir-opt/tls_access.main.PreCodegen.after.mir +++ b/tests/mir-opt/tls_access.main.PreCodegen.after.mir @@ -3,12 +3,10 @@ fn main() -> () { let mut _0: (); let _1: *mut u8; + let _2: &u8; let mut _3: *mut u8; scope 1 { - let _2: &u8; - scope 2 { - debug a => _2; - } + debug a => _2; } bb0: { diff --git a/tests/mir-opt/uninhabited_enum.process_never.SimplifyLocals-final.after.mir b/tests/mir-opt/uninhabited_enum.process_never.SimplifyLocals-final.after.mir index 89f7016fee4..240f409817d 100644 --- a/tests/mir-opt/uninhabited_enum.process_never.SimplifyLocals-final.after.mir +++ b/tests/mir-opt/uninhabited_enum.process_never.SimplifyLocals-final.after.mir @@ -7,8 +7,6 @@ fn process_never(_1: *const !) -> () { scope 1 { debug _input => _2; } - scope 2 { - } bb0: { unreachable; diff --git a/tests/mir-opt/uninhabited_enum.process_void.SimplifyLocals-final.after.mir b/tests/mir-opt/uninhabited_enum.process_void.SimplifyLocals-final.after.mir index 51905f982b8..51514ba5e5d 100644 --- a/tests/mir-opt/uninhabited_enum.process_void.SimplifyLocals-final.after.mir +++ b/tests/mir-opt/uninhabited_enum.process_void.SimplifyLocals-final.after.mir @@ -6,8 +6,6 @@ fn process_void(_1: *const Void) -> () { scope 1 { debug _input => _1; } - scope 2 { - } bb0: { return; diff --git a/tests/mir-opt/unnamed-fields/field_access.bar.SimplifyCfg-initial.after.mir b/tests/mir-opt/unnamed-fields/field_access.bar.SimplifyCfg-initial.after.mir index 8edc7b5df88..f0311422c17 100644 --- a/tests/mir-opt/unnamed-fields/field_access.bar.SimplifyCfg-initial.after.mir +++ b/tests/mir-opt/unnamed-fields/field_access.bar.SimplifyCfg-initial.after.mir @@ -11,8 +11,6 @@ fn bar(_1: Bar) -> () { let mut _7: bool; let _8: (); let mut _9: [u8; 1]; - scope 1 { - } bb0: { StorageLive(_2); diff --git a/tests/ui/asm/x86_64/goto.rs b/tests/ui/asm/x86_64/goto.rs index 6a567efbb2c..6c14bb57ac6 100644 --- a/tests/ui/asm/x86_64/goto.rs +++ b/tests/ui/asm/x86_64/goto.rs @@ -1,8 +1,6 @@ //@ only-x86_64 //@ run-pass //@ needs-asm-support -//@ revisions: mirunsafeck thirunsafeck -//@ [thirunsafeck]compile-flags: -Z thir-unsafeck #![deny(unreachable_code)] #![feature(asm_goto)] diff --git a/tests/ui/asm/x86_64/goto.mirunsafeck.stderr b/tests/ui/asm/x86_64/goto.stderr index fe189c14f0a..27e227d71a5 100644 --- a/tests/ui/asm/x86_64/goto.mirunsafeck.stderr +++ b/tests/ui/asm/x86_64/goto.stderr @@ -1,5 +1,5 @@ warning: unreachable statement - --> $DIR/goto.rs:99:9 + --> $DIR/goto.rs:97:9 | LL | / asm!( LL | | "jmp {}", @@ -13,7 +13,7 @@ LL | unreachable!(); | ^^^^^^^^^^^^^^ unreachable statement | note: the lint level is defined here - --> $DIR/goto.rs:89:8 + --> $DIR/goto.rs:87:8 | LL | #[warn(unreachable_code)] | ^^^^^^^^^^^^^^^^ diff --git a/tests/ui/asm/x86_64/goto.thirunsafeck.stderr b/tests/ui/asm/x86_64/goto.thirunsafeck.stderr deleted file mode 100644 index fe189c14f0a..00000000000 --- a/tests/ui/asm/x86_64/goto.thirunsafeck.stderr +++ /dev/null @@ -1,23 +0,0 @@ -warning: unreachable statement - --> $DIR/goto.rs:99:9 - | -LL | / asm!( -LL | | "jmp {}", -LL | | label { -LL | | return; -LL | | }, -LL | | options(noreturn) -LL | | ); - | |_________- any code following this expression is unreachable -LL | unreachable!(); - | ^^^^^^^^^^^^^^ unreachable statement - | -note: the lint level is defined here - --> $DIR/goto.rs:89:8 - | -LL | #[warn(unreachable_code)] - | ^^^^^^^^^^^^^^^^ - = note: this warning originates in the macro `unreachable` (in Nightly builds, run with -Z macro-backtrace for more info) - -warning: 1 warning emitted - |
