1
Fork 0

Do not remove unused definitions inside GVN.

This commit is contained in:
Camille GILLOT 2023-09-16 17:13:30 +00:00
parent 2e4e2a8f28
commit d28405972f
28 changed files with 1348 additions and 1126 deletions

View file

@ -366,6 +366,7 @@ pub fn remove_dead_blocks(body: &mut Body<'_>) {
pub enum SimplifyLocals {
BeforeConstProp,
AfterGVN,
Final,
}
@ -373,6 +374,7 @@ impl<'tcx> MirPass<'tcx> for SimplifyLocals {
fn name(&self) -> &'static str {
match &self {
SimplifyLocals::BeforeConstProp => "SimplifyLocals-before-const-prop",
SimplifyLocals::AfterGVN => "SimplifyLocals-after-value-numbering",
SimplifyLocals::Final => "SimplifyLocals-final",
}
}