remove dead_stores_better.rs
As we discussed, it is identical with dead_stores_79191
This commit is contained in:
parent
109870df2c
commit
76dc555dc9
3 changed files with 0 additions and 75 deletions
|
|
@ -1,26 +0,0 @@
|
|||
// MIR for `f` after CopyProp
|
||||
|
||||
fn f(_1: usize) -> usize {
|
||||
debug a => _1;
|
||||
let mut _0: usize;
|
||||
let _2: usize;
|
||||
let mut _3: usize;
|
||||
let mut _4: usize;
|
||||
scope 1 {
|
||||
debug b => _2;
|
||||
}
|
||||
|
||||
bb0: {
|
||||
_2 = copy _1;
|
||||
_1 = const 5_usize;
|
||||
_1 = copy _2;
|
||||
StorageLive(_4);
|
||||
_4 = copy _1;
|
||||
_0 = id::<usize>(move _4) -> [return: bb1, unwind unreachable];
|
||||
}
|
||||
|
||||
bb1: {
|
||||
StorageDead(_4);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,26 +0,0 @@
|
|||
// MIR for `f` after CopyProp
|
||||
|
||||
fn f(_1: usize) -> usize {
|
||||
debug a => _1;
|
||||
let mut _0: usize;
|
||||
let _2: usize;
|
||||
let mut _3: usize;
|
||||
let mut _4: usize;
|
||||
scope 1 {
|
||||
debug b => _2;
|
||||
}
|
||||
|
||||
bb0: {
|
||||
_2 = copy _1;
|
||||
_1 = const 5_usize;
|
||||
_1 = copy _2;
|
||||
StorageLive(_4);
|
||||
_4 = copy _1;
|
||||
_0 = id::<usize>(move _4) -> [return: bb1, unwind continue];
|
||||
}
|
||||
|
||||
bb1: {
|
||||
StorageDead(_4);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
// skip-filecheck
|
||||
// EMIT_MIR_FOR_EACH_PANIC_STRATEGY
|
||||
// This is a copy of the `dead_stores_79191` test, except that we turn on DSE. This demonstrates
|
||||
// that that pass enables this one to do more optimizations.
|
||||
|
||||
//@ test-mir-pass: CopyProp
|
||||
//@ compile-flags: -Zmir-enable-passes=+DeadStoreElimination
|
||||
|
||||
fn id<T>(x: T) -> T {
|
||||
x
|
||||
}
|
||||
|
||||
// EMIT_MIR dead_stores_better.f.CopyProp.after.mir
|
||||
pub fn f(mut a: usize) -> usize {
|
||||
let b = a;
|
||||
a = 5;
|
||||
a = b;
|
||||
id(a)
|
||||
}
|
||||
|
||||
fn main() {
|
||||
f(0);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue