@@ -434,7 +434,7 @@ pub struct Env<'a, F: Function> {
434
434
// was to the approprate PReg.
435
435
pub multi_fixed_reg_fixups : Vec < MultiFixedRegFixup > ,
436
436
437
- pub inserted_moves : [ Vec < InsertedMove > ; InsertMovePrio :: Count as usize ] ,
437
+ pub inserted_moves : Vec < InsertedMove > ,
438
438
439
439
// Output:
440
440
pub edits : Vec < ( PosWithPrio , Edit ) > ,
@@ -636,41 +636,20 @@ impl LiveRangeSet {
636
636
637
637
#[ derive( Clone , Debug ) ]
638
638
pub struct InsertedMove {
639
- pub pos : ProgPoint ,
639
+ pub pos_prio : PosWithPrio ,
640
640
pub from_alloc : Allocation ,
641
641
pub to_alloc : Allocation ,
642
642
pub to_vreg : VReg ,
643
643
}
644
644
645
- /// Move priority levels, for resolving move dependency order.
646
- ///
647
- /// NOTE: new priority values should be added before `Count`, and `InsertMovePrio::all` should be
648
- /// updated to include the new priority.
649
645
#[ derive( Clone , Copy , Debug , PartialEq , Eq , PartialOrd , Ord ) ]
650
- #[ repr( u8 ) ]
651
646
pub enum InsertMovePrio {
652
647
InEdgeMoves ,
653
648
Regular ,
654
649
MultiFixedRegInitial ,
655
650
MultiFixedRegSecondary ,
656
651
ReusedInput ,
657
652
OutEdgeMoves ,
658
-
659
- /// The number of priorities, used to determine the length of the Env::inserted_moves array.
660
- Count ,
661
- }
662
-
663
- impl InsertMovePrio {
664
- pub fn all ( ) -> & ' static [ InsertMovePrio ] {
665
- & [
666
- InsertMovePrio :: InEdgeMoves ,
667
- InsertMovePrio :: Regular ,
668
- InsertMovePrio :: MultiFixedRegInitial ,
669
- InsertMovePrio :: MultiFixedRegSecondary ,
670
- InsertMovePrio :: ReusedInput ,
671
- InsertMovePrio :: OutEdgeMoves ,
672
- ]
673
- }
674
653
}
675
654
676
655
/// The fields in this struct are reversed in sort order so that the entire
0 commit comments