aboutsummaryrefslogtreecommitdiff
path: root/crates/profile/src/stop_watch.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/profile/src/stop_watch.rs')
-rw-r--r--crates/profile/src/stop_watch.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/profile/src/stop_watch.rs b/crates/profile/src/stop_watch.rs
index cb6915d45..112d03a9c 100644
--- a/crates/profile/src/stop_watch.rs
+++ b/crates/profile/src/stop_watch.rs
@@ -44,7 +44,7 @@ impl StopWatch {
44 } 44 }
45 pub fn memory(mut self, yes: bool) -> StopWatch { 45 pub fn memory(mut self, yes: bool) -> StopWatch {
46 if yes { 46 if yes {
47 self.memory = Some(MemoryUsage::current()); 47 self.memory = Some(MemoryUsage::now());
48 } 48 }
49 self 49 self
50 } 50 }
@@ -58,7 +58,7 @@ impl StopWatch {
58 #[cfg(not(target_os = "linux"))] 58 #[cfg(not(target_os = "linux"))]
59 let instructions = None; 59 let instructions = None;
60 60
61 let memory = self.memory.map(|it| MemoryUsage::current() - it); 61 let memory = self.memory.map(|it| MemoryUsage::now() - it);
62 StopWatchSpan { time, instructions, memory } 62 StopWatchSpan { time, instructions, memory }
63 } 63 }
64} 64}