Add a value location verifier.
This is a verification pass that can be run after register allocation. It verifies that value locations are consistent with constraints on their uses, and that the register diversions are consistent. Make it clear that register diversions are local to an EBB only. This affects what branch relaxation is allowed to do. The verify_locations() takes an optional Liveness parameter which is used to check that no diverted values are live across CFG edges.
This commit is contained in:
@@ -72,8 +72,9 @@ use std::collections::BTreeSet;
|
||||
use std::cmp::Ordering;
|
||||
use iterators::IteratorExtras;
|
||||
|
||||
pub use self::liveness::verify_liveness;
|
||||
pub use self::cssa::verify_cssa;
|
||||
pub use self::liveness::verify_liveness;
|
||||
pub use self::locations::verify_locations;
|
||||
|
||||
// Create an `Err` variant of `Result<X>` from a location and `format!` arguments.
|
||||
macro_rules! err {
|
||||
@@ -94,6 +95,7 @@ macro_rules! err {
|
||||
|
||||
mod cssa;
|
||||
mod liveness;
|
||||
mod locations;
|
||||
|
||||
/// A verifier error.
|
||||
#[derive(Debug, PartialEq, Eq)]
|
||||
|
||||
Reference in New Issue
Block a user