Skip to content

Commit f22af66

Browse files
committed
Fixes
1 parent 5e49854 commit f22af66

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

crates/ra_prof/src/stop_watch.rs

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! Like `std::time::Instant`, but also measures memory & CPU cycles.
12
use std::{
23
fmt,
34
time::{Duration, Instant},
@@ -76,14 +77,3 @@ impl fmt::Display for StopWatchSpan {
7677
Ok(())
7778
}
7879
}
79-
80-
// Unclear if we need this:
81-
// https://github.com/jimblandy/perf-event/issues/8
82-
impl Drop for StopWatch {
83-
fn drop(&mut self) {
84-
#[cfg(target_os = "linux")]
85-
if let Some(mut counter) = self.counter.take() {
86-
let _ = counter.disable();
87-
}
88-
}
89-
}

0 commit comments

Comments
 (0)