Created
February 28, 2019 08:42
-
-
Save jgouly/3379d3b042daa5c0bf14318e34295676 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/cranelift-codegen/src/timing.rs b/cranelift-codegen/src/timing.rs | |
index 16f729f7..51d500fe 100644 | |
--- a/cranelift-codegen/src/timing.rs | |
+++ b/cranelift-codegen/src/timing.rs | |
@@ -189,7 +189,7 @@ mod details { | |
let prev = CURRENT_PASS.with(|p| p.replace(pass)); | |
debug!("timing: Starting {}, (during {})", pass, prev); | |
TimingToken { | |
- start: Instant::now(), | |
+ start: unsafe { std::mem::transmute(0u128) },//Instant::now(), | |
pass, | |
prev, | |
} | |
@@ -198,7 +198,7 @@ mod details { | |
/// Dropping a timing token indicated the end of the pass. | |
impl Drop for TimingToken { | |
fn drop(&mut self) { | |
- let duration = self.start.elapsed(); | |
+ let duration = unsafe { std::mem::transmute(1u128) };//self.start.elapsed(); | |
debug!("timing: Ending {}", self.pass); | |
let old_cur = CURRENT_PASS.with(|p| p.replace(self.prev)); | |
debug_assert_eq!(self.pass, old_cur, "Timing tokens dropped out of order"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment