From 218caa410aa38c29984be31a5229b9fa717560ee Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:19:13 +0200 Subject: Merging upstream version 1.68.2+dfsg1. Signed-off-by: Daniel Baumann --- ...lower_intrinsics.non_const.LowerIntrinsics.diff | 31 ++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 tests/mir-opt/lower_intrinsics.non_const.LowerIntrinsics.diff (limited to 'tests/mir-opt/lower_intrinsics.non_const.LowerIntrinsics.diff') diff --git a/tests/mir-opt/lower_intrinsics.non_const.LowerIntrinsics.diff b/tests/mir-opt/lower_intrinsics.non_const.LowerIntrinsics.diff new file mode 100644 index 000000000..d8cd5f59a --- /dev/null +++ b/tests/mir-opt/lower_intrinsics.non_const.LowerIntrinsics.diff @@ -0,0 +1,31 @@ +- // MIR for `non_const` before LowerIntrinsics ++ // MIR for `non_const` after LowerIntrinsics + + fn non_const() -> usize { + let mut _0: usize; // return place in scope 0 at $DIR/lower_intrinsics.rs:+0:26: +0:31 + let _1: extern "rust-intrinsic" fn() -> usize {std::intrinsics::size_of::}; // in scope 0 at $DIR/lower_intrinsics.rs:+2:9: +2:18 + let mut _2: extern "rust-intrinsic" fn() -> usize {std::intrinsics::size_of::}; // in scope 0 at $DIR/lower_intrinsics.rs:+3:5: +3:14 + scope 1 { + debug size_of_t => _1; // in scope 1 at $DIR/lower_intrinsics.rs:+2:9: +2:18 + } + + bb0: { + StorageLive(_1); // scope 0 at $DIR/lower_intrinsics.rs:+2:9: +2:18 + _1 = std::intrinsics::size_of::; // scope 0 at $DIR/lower_intrinsics.rs:+2:21: +2:51 + // mir::Constant + // + span: $DIR/lower_intrinsics.rs:37:21: 37:51 + // + literal: Const { ty: extern "rust-intrinsic" fn() -> usize {std::intrinsics::size_of::}, val: Value() } + StorageLive(_2); // scope 1 at $DIR/lower_intrinsics.rs:+3:5: +3:14 + _2 = _1; // scope 1 at $DIR/lower_intrinsics.rs:+3:5: +3:14 +- _0 = move _2() -> bb1; // scope 1 at $DIR/lower_intrinsics.rs:+3:5: +3:16 ++ _0 = SizeOf(T); // scope 1 at $DIR/lower_intrinsics.rs:+3:5: +3:16 ++ goto -> bb1; // scope 1 at $DIR/lower_intrinsics.rs:+3:5: +3:16 + } + + bb1: { + StorageDead(_2); // scope 1 at $DIR/lower_intrinsics.rs:+3:15: +3:16 + StorageDead(_1); // scope 0 at $DIR/lower_intrinsics.rs:+4:1: +4:2 + return; // scope 0 at $DIR/lower_intrinsics.rs:+4:2: +4:2 + } + } + -- cgit v1.2.3