diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-30 03:57:31 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-30 03:57:31 +0000 |
commit | dc0db358abe19481e475e10c32149b53370f1a1c (patch) | |
tree | ab8ce99c4b255ce46f99ef402c27916055b899ee /tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir | |
parent | Releasing progress-linux version 1.71.1+dfsg1-2~progress7.99u1. (diff) | |
download | rustc-dc0db358abe19481e475e10c32149b53370f1a1c.tar.xz rustc-dc0db358abe19481e475e10c32149b53370f1a1c.zip |
Merging upstream version 1.72.1+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir')
-rw-r--r-- | tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir | 84 |
1 files changed, 84 insertions, 0 deletions
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 new file mode 100644 index 000000000..70461b445 --- /dev/null +++ b/tests/mir-opt/pre-codegen/checked_ops.checked_shl.PreCodegen.after.mir @@ -0,0 +1,84 @@ +// MIR for `checked_shl` after PreCodegen + +fn checked_shl(_1: u32, _2: u32) -> Option<u32> { + debug x => _1; + debug rhs => _2; + let mut _0: std::option::Option<u32>; + scope 1 (inlined core::num::<impl u32>::checked_shl) { + debug self => _1; + debug rhs => _2; + let mut _7: (u32, bool); + let _8: u32; + let _9: bool; + let mut _10: bool; + scope 2 { + debug a => _8; + debug b => _9; + } + scope 3 (inlined core::num::<impl u32>::overflowing_shl) { + debug self => _1; + debug rhs => _2; + let mut _5: u32; + let mut _6: bool; + scope 4 (inlined core::num::<impl u32>::wrapping_shl) { + debug self => _1; + debug rhs => _2; + let mut _3: u32; + let mut _4: u32; + scope 5 { + scope 6 (inlined core::num::<impl u32>::unchecked_shl) { + debug self => _1; + debug rhs => _4; + scope 7 { + } + } + } + } + } + } + + bb0: { + StorageLive(_8); + StorageLive(_9); + StorageLive(_7); + StorageLive(_5); + StorageLive(_4); + StorageLive(_3); + _3 = const 31_u32; + _4 = BitAnd(_2, move _3); + StorageDead(_3); + _5 = ShlUnchecked(_1, _4); + StorageDead(_4); + StorageLive(_6); + _6 = Ge(_2, const _); + _7 = (move _5, move _6); + StorageDead(_6); + StorageDead(_5); + _8 = (_7.0: u32); + _9 = (_7.1: bool); + StorageDead(_7); + StorageLive(_10); + _10 = unlikely(_9) -> [return: bb1, unwind unreachable]; + } + + bb1: { + switchInt(move _10) -> [0: bb2, otherwise: bb3]; + } + + bb2: { + _0 = Option::<u32>::Some(_8); + goto -> bb4; + } + + bb3: { + _0 = Option::<u32>::None; + goto -> bb4; + } + + bb4: { + StorageDead(_10); + StorageDead(_9); + StorageDead(_8); + return; + } +} |