Add a compilation pass timing facility.
Individual compilation passes call the corresponding timing::*() function and hold on to their timing token while they run. This causes nested per-pass timing information to be recorded in thread-local storage. The --time-passes command line option prints a pass timing report to stdout.
This commit is contained in:
@@ -18,6 +18,7 @@ use std::cmp::Ordering;
|
||||
use std::iter::Peekable;
|
||||
use std::mem;
|
||||
use isa::{TargetIsa, EncInfo};
|
||||
use timing;
|
||||
|
||||
/// Dominator forest.
|
||||
///
|
||||
@@ -282,6 +283,7 @@ impl Coalescing {
|
||||
liveness: &mut Liveness,
|
||||
virtregs: &mut VirtRegs,
|
||||
) {
|
||||
let _tt = timing::ra_cssa();
|
||||
dbg!("Coalescing for:\n{}", func.display(isa));
|
||||
let mut context = Context {
|
||||
isa,
|
||||
|
||||
Reference in New Issue
Block a user