1pub mod error;
16
17#[cfg(not(windows))]
18mod jemalloc;
19#[cfg(not(windows))]
20pub use jemalloc::{
21 activate_heap_profile, deactivate_heap_profile, dump_flamegraph, dump_pprof, dump_profile,
22 is_heap_profile_active,
23};
24
25#[cfg(windows)]
26pub async fn dump_profile() -> error::Result<Vec<u8>> {
27 error::ProfilingNotSupportedSnafu.fail()
28}
29
30#[cfg(windows)]
31pub async fn dump_pprof() -> error::Result<Vec<u8>> {
32 error::ProfilingNotSupportedSnafu.fail()
33}
34
35#[cfg(windows)]
36pub async fn dump_flamegraph() -> error::Result<Vec<u8>> {
37 error::ProfilingNotSupportedSnafu.fail()
38}
39
40#[cfg(windows)]
41pub fn activate_heap_profile() -> error::Result<()> {
42 error::ProfilingNotSupportedSnafu.fail()
43}
44
45#[cfg(windows)]
46pub fn deactivate_heap_profile() -> error::Result<()> {
47 error::ProfilingNotSupportedSnafu.fail()
48}
49
50#[cfg(windows)]
51pub fn is_heap_profile_active() -> error::Result<bool> {
52 error::ProfilingNotSupportedSnafu.fail()
53}