From d38553ca82b23c85be3dcf202a4ae03b584b17a8 Mon Sep 17 00:00:00 2001 From: oli Date: Mon, 25 Jan 2021 09:34:33 +0000 Subject: [PATCH] Ignore a test on wasm, because that changes landing pads --- src/test/mir-opt/inline/cycle.f.Inline.diff | 38 +++++++++---------- src/test/mir-opt/inline/cycle.g.Inline.diff | 18 ++++----- .../mir-opt/inline/cycle.main.Inline.diff | 18 ++++----- src/test/mir-opt/inline/cycle.rs | 2 + 4 files changed, 39 insertions(+), 37 deletions(-) diff --git a/src/test/mir-opt/inline/cycle.f.Inline.diff b/src/test/mir-opt/inline/cycle.f.Inline.diff index 4f7924170b4..54dd545dfb9 100644 --- a/src/test/mir-opt/inline/cycle.f.Inline.diff +++ b/src/test/mir-opt/inline/cycle.f.Inline.diff @@ -2,41 +2,41 @@ + // MIR for `f` after Inline fn f(_1: impl Fn()) -> () { - debug g => _1; // in scope 0 at $DIR/cycle.rs:3:6: 3:7 - let mut _0: (); // return place in scope 0 at $DIR/cycle.rs:3:20: 3:20 - let _2: (); // in scope 0 at $DIR/cycle.rs:4:5: 4:8 - let mut _3: &impl Fn(); // in scope 0 at $DIR/cycle.rs:4:5: 4:6 - let mut _4: (); // in scope 0 at $DIR/cycle.rs:4:5: 4:8 + debug g => _1; // in scope 0 at $DIR/cycle.rs:5:6: 5:7 + let mut _0: (); // return place in scope 0 at $DIR/cycle.rs:5:20: 5:20 + let _2: (); // in scope 0 at $DIR/cycle.rs:6:5: 6:8 + let mut _3: &impl Fn(); // in scope 0 at $DIR/cycle.rs:6:5: 6:6 + let mut _4: (); // in scope 0 at $DIR/cycle.rs:6:5: 6:8 bb0: { - StorageLive(_2); // scope 0 at $DIR/cycle.rs:4:5: 4:8 - StorageLive(_3); // scope 0 at $DIR/cycle.rs:4:5: 4:6 - _3 = &_1; // scope 0 at $DIR/cycle.rs:4:5: 4:6 - StorageLive(_4); // scope 0 at $DIR/cycle.rs:4:5: 4:8 - _2 = >::call(move _3, move _4) -> [return: bb1, unwind: bb3]; // scope 0 at $DIR/cycle.rs:4:5: 4:8 + StorageLive(_2); // scope 0 at $DIR/cycle.rs:6:5: 6:8 + StorageLive(_3); // scope 0 at $DIR/cycle.rs:6:5: 6:6 + _3 = &_1; // scope 0 at $DIR/cycle.rs:6:5: 6:6 + StorageLive(_4); // scope 0 at $DIR/cycle.rs:6:5: 6:8 + _2 = >::call(move _3, move _4) -> [return: bb1, unwind: bb3]; // scope 0 at $DIR/cycle.rs:6:5: 6:8 // mir::Constant - // + span: $DIR/cycle.rs:4:5: 4:6 + // + span: $DIR/cycle.rs:6:5: 6:6 // + literal: Const { ty: for<'r> extern "rust-call" fn(&'r impl Fn(), ()) -> >::Output {>::call}, val: Value(Scalar()) } } bb1: { - StorageDead(_4); // scope 0 at $DIR/cycle.rs:4:7: 4:8 - StorageDead(_3); // scope 0 at $DIR/cycle.rs:4:7: 4:8 - StorageDead(_2); // scope 0 at $DIR/cycle.rs:4:8: 4:9 - _0 = const (); // scope 0 at $DIR/cycle.rs:3:20: 5:2 - drop(_1) -> [return: bb2, unwind: bb4]; // scope 0 at $DIR/cycle.rs:5:1: 5:2 + StorageDead(_4); // scope 0 at $DIR/cycle.rs:6:7: 6:8 + StorageDead(_3); // scope 0 at $DIR/cycle.rs:6:7: 6:8 + StorageDead(_2); // scope 0 at $DIR/cycle.rs:6:8: 6:9 + _0 = const (); // scope 0 at $DIR/cycle.rs:5:20: 7:2 + drop(_1) -> [return: bb2, unwind: bb4]; // scope 0 at $DIR/cycle.rs:7:1: 7:2 } bb2: { - return; // scope 0 at $DIR/cycle.rs:5:2: 5:2 + return; // scope 0 at $DIR/cycle.rs:7:2: 7:2 } bb3 (cleanup): { - drop(_1) -> bb4; // scope 0 at $DIR/cycle.rs:5:1: 5:2 + drop(_1) -> bb4; // scope 0 at $DIR/cycle.rs:7:1: 7:2 } bb4 (cleanup): { - resume; // scope 0 at $DIR/cycle.rs:3:1: 5:2 + resume; // scope 0 at $DIR/cycle.rs:5:1: 7:2 } } diff --git a/src/test/mir-opt/inline/cycle.g.Inline.diff b/src/test/mir-opt/inline/cycle.g.Inline.diff index 4fbdce3eb0a..46f5e5e2065 100644 --- a/src/test/mir-opt/inline/cycle.g.Inline.diff +++ b/src/test/mir-opt/inline/cycle.g.Inline.diff @@ -2,24 +2,24 @@ + // MIR for `g` after Inline fn g() -> () { - let mut _0: (); // return place in scope 0 at $DIR/cycle.rs:9:8: 9:8 - let _1: (); // in scope 0 at $DIR/cycle.rs:10:5: 10:12 + let mut _0: (); // return place in scope 0 at $DIR/cycle.rs:11:8: 11:8 + let _1: (); // in scope 0 at $DIR/cycle.rs:12:5: 12:12 bb0: { - StorageLive(_1); // scope 0 at $DIR/cycle.rs:10:5: 10:12 - _1 = f::(main) -> bb1; // scope 0 at $DIR/cycle.rs:10:5: 10:12 + StorageLive(_1); // scope 0 at $DIR/cycle.rs:12:5: 12:12 + _1 = f::(main) -> bb1; // scope 0 at $DIR/cycle.rs:12:5: 12:12 // mir::Constant - // + span: $DIR/cycle.rs:10:5: 10:6 + // + span: $DIR/cycle.rs:12:5: 12:6 // + literal: Const { ty: fn(fn() {main}) {f::}, val: Value(Scalar()) } // mir::Constant - // + span: $DIR/cycle.rs:10:7: 10:11 + // + span: $DIR/cycle.rs:12:7: 12:11 // + literal: Const { ty: fn() {main}, val: Value(Scalar()) } } bb1: { - StorageDead(_1); // scope 0 at $DIR/cycle.rs:10:12: 10:13 - _0 = const (); // scope 0 at $DIR/cycle.rs:9:8: 11:2 - return; // scope 0 at $DIR/cycle.rs:11:2: 11:2 + StorageDead(_1); // scope 0 at $DIR/cycle.rs:12:12: 12:13 + _0 = const (); // scope 0 at $DIR/cycle.rs:11:8: 13:2 + return; // scope 0 at $DIR/cycle.rs:13:2: 13:2 } } diff --git a/src/test/mir-opt/inline/cycle.main.Inline.diff b/src/test/mir-opt/inline/cycle.main.Inline.diff index 3c7dfc2494e..c8d1448d949 100644 --- a/src/test/mir-opt/inline/cycle.main.Inline.diff +++ b/src/test/mir-opt/inline/cycle.main.Inline.diff @@ -2,24 +2,24 @@ + // MIR for `main` after Inline fn main() -> () { - let mut _0: (); // return place in scope 0 at $DIR/cycle.rs:14:11: 14:11 - let _1: (); // in scope 0 at $DIR/cycle.rs:15:5: 15:9 + let mut _0: (); // return place in scope 0 at $DIR/cycle.rs:16:11: 16:11 + let _1: (); // in scope 0 at $DIR/cycle.rs:17:5: 17:9 bb0: { - StorageLive(_1); // scope 0 at $DIR/cycle.rs:15:5: 15:9 - _1 = f::(g) -> bb1; // scope 0 at $DIR/cycle.rs:15:5: 15:9 + StorageLive(_1); // scope 0 at $DIR/cycle.rs:17:5: 17:9 + _1 = f::(g) -> bb1; // scope 0 at $DIR/cycle.rs:17:5: 17:9 // mir::Constant - // + span: $DIR/cycle.rs:15:5: 15:6 + // + span: $DIR/cycle.rs:17:5: 17:6 // + literal: Const { ty: fn(fn() {g}) {f::}, val: Value(Scalar()) } // mir::Constant - // + span: $DIR/cycle.rs:15:7: 15:8 + // + span: $DIR/cycle.rs:17:7: 17:8 // + literal: Const { ty: fn() {g}, val: Value(Scalar()) } } bb1: { - StorageDead(_1); // scope 0 at $DIR/cycle.rs:15:9: 15:10 - _0 = const (); // scope 0 at $DIR/cycle.rs:14:11: 16:2 - return; // scope 0 at $DIR/cycle.rs:16:2: 16:2 + StorageDead(_1); // scope 0 at $DIR/cycle.rs:17:9: 17:10 + _0 = const (); // scope 0 at $DIR/cycle.rs:16:11: 18:2 + return; // scope 0 at $DIR/cycle.rs:18:2: 18:2 } } diff --git a/src/test/mir-opt/inline/cycle.rs b/src/test/mir-opt/inline/cycle.rs index 0be6fec99dd..9e8950d8a3d 100644 --- a/src/test/mir-opt/inline/cycle.rs +++ b/src/test/mir-opt/inline/cycle.rs @@ -1,3 +1,5 @@ +// ignore-wasm32-bare compiled with panic=abort by default + // EMIT_MIR cycle.f.Inline.diff #[inline(always)] fn f(g: impl Fn()) {