pub struct CallstackSampling {
pub scope: Option<Scope>,
pub kernel_frames: Option<bool>,
pub user_frames: Option<i32>,
}
Fields§
§scope: Option<Scope>
Defines a set of processes for which samples are retained/skipped. If unset, all samples are kept, but beware that it will be very heavy on the stack unwinder, which might start dropping samples due to overload.
kernel_frames: Option<bool>
If true, callstacks will include the kernel-space frames. Such frames can be identified by a magical “kernel” string as their mapping name. Requires traced_perf to be running as root, or kptr_restrict to have been manually unrestricted. On Android, the platform should do the right thing on debug builds. This does not disclose KASLR, as only the function names are emitted.
user_frames: Option<i32>
Whether to record and unwind userspace callstacks. If unset, defaults to including userspace (UNWIND_DWARF) both for backwards compatibility and as the most common default (this defaulting is only applicable if the outer CallstackSampling message is explicitly set).
Implementations§
Source§impl CallstackSampling
impl CallstackSampling
Sourcepub fn kernel_frames(&self) -> bool
pub fn kernel_frames(&self) -> bool
Returns the value of kernel_frames
, or the default value if kernel_frames
is unset.
Sourcepub fn user_frames(&self) -> UnwindMode
pub fn user_frames(&self) -> UnwindMode
Returns the enum value of user_frames
, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_user_frames(&mut self, value: UnwindMode)
pub fn set_user_frames(&mut self, value: UnwindMode)
Sets user_frames
to the provided enum value.
Trait Implementations§
Source§impl Clone for CallstackSampling
impl Clone for CallstackSampling
Source§fn clone(&self) -> CallstackSampling
fn clone(&self) -> CallstackSampling
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for CallstackSampling
impl Debug for CallstackSampling
Source§impl Default for CallstackSampling
impl Default for CallstackSampling
Source§impl Message for CallstackSampling
impl Message for CallstackSampling
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
.Source§impl PartialEq for CallstackSampling
impl PartialEq for CallstackSampling
impl StructuralPartialEq for CallstackSampling
Auto Trait Implementations§
impl Freeze for CallstackSampling
impl RefUnwindSafe for CallstackSampling
impl Send for CallstackSampling
impl Sync for CallstackSampling
impl Unpin for CallstackSampling
impl UnwindSafe for CallstackSampling
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)