Skip to content

Commit

Permalink
upgrade pprof-rs to 0.6.1 (tikv#39)
Browse files Browse the repository at this point in the history
  • Loading branch information
hehechen authored Nov 26, 2021
1 parent 177cfbf commit 9f558a1
Show file tree
Hide file tree
Showing 3 changed files with 141 additions and 43 deletions.
177 changes: 136 additions & 41 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ pd_client = { path = "components/pd_client", default-features = false }
pin-project = "1.0"
pnet_datalink = "0.23"
prost = "0.7"
pprof = { version = "^0.4", default-features = false, features = ["flamegraph", "protobuf", "cpp"] }
pprof = { version = "^0.6", default-features = false, features = ["flamegraph", "protobuf", "cpp"] }
protobuf = "2.8"
raft = { version = "0.6.0-alpha", default-features = false }
raftstore = { path = "components/raftstore", default-features = false }
Expand Down
5 changes: 4 additions & 1 deletion src/server/status_server/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,10 @@ where
}

pub async fn dump_rsprof(seconds: u64, frequency: i32) -> pprof::Result<pprof::Report> {
let guard = pprof::ProfilerGuard::new(frequency)?;
let guard = pprof::ProfilerGuardBuilder::default()
.frequency(frequency)
.blocklist(&["libc", "libgcc", "pthread"])
.build()?;
info!(
"start profiling {} seconds with frequency {} /s",
seconds, frequency
Expand Down

0 comments on commit 9f558a1

Please sign in to comment.