Add EntryRegDiversions to record diversions for each block entry.
This commit is contained in:
committed by
Nicolas B. Pierron
parent
9eb1847d80
commit
bb87f1a54a
@@ -20,7 +20,9 @@ pub fn shrink_instructions(func: &mut Function, isa: &dyn TargetIsa) {
|
||||
let mut divert = RegDiversions::new();
|
||||
|
||||
for ebb in func.layout.ebbs() {
|
||||
divert.clear();
|
||||
// Load diversions from predecessors.
|
||||
divert.at_ebb(&func.entry_diversions, ebb);
|
||||
|
||||
for inst in func.layout.ebb_insts(ebb) {
|
||||
let enc = func.encodings[inst];
|
||||
if enc.is_legal() {
|
||||
|
||||
Reference in New Issue
Block a user