pub struct FtraceStats {
pub phase: Option<i32>,
pub cpu_stats: Vec<FtraceCpuStats>,
pub kernel_symbols_parsed: Option<u32>,
pub kernel_symbols_mem_kb: Option<u32>,
pub atrace_errors: Option<String>,
pub unknown_ftrace_events: Vec<String>,
pub failed_ftrace_events: Vec<String>,
pub preserve_ftrace_buffer: Option<bool>,
pub ftrace_parse_errors: Vec<i32>,
}Expand description
Errors and kernel buffer stats for the ftrace data source.
Fields§
§phase: Option<i32>A pair of FtraceStats is written on every trace flush:
- START_OF_TRACE - stats recorded at the beginning of the trace.
- END_OF_TRACE - stats recorded during the flush. In other words shortly before this packet was written. For simple traces this will be once at the end of the trace.
cpu_stats: Vec<FtraceCpuStats>Per-CPU stats (one entry for each CPU).
kernel_symbols_parsed: Option<u32>When FtraceConfig.symbolize_ksyms = true, this records the number of symbols parsed from /proc/kallsyms, whether they have been seen in the trace or not. It can be used to debug kptr_restrict or security-related errors. Note: this will be valid only when phase = END_OF_TRACE. The symbolizer is initialized. When START_OF_TRACE is emitted it is not ready yet.
kernel_symbols_mem_kb: Option<u32>The memory used by the kernel symbolizer (KernelSymbolMap.size_bytes()).
atrace_errors: Option<String>Atrace errors (even non-fatal ones) are reported here. A typical example is one or more atrace categories not available on the device.
unknown_ftrace_events: Vec<String>Ftrace events requested by the config but not present on device.
failed_ftrace_events: Vec<String>Ftrace events requested by the config and present on device, but which we failed to enable due to permissions, or due to a conflicting option (currently FtraceConfig.disable_generic_events).
preserve_ftrace_buffer: Option<bool>The data source was configured to preserve existing events in the ftrace buffer before the start of the trace.
ftrace_parse_errors: Vec<i32>Unique errors encountered during reading and parsing of the raw ftrace data. Ring buffer ABI related errors will also be recorded in the affected FtraceEventBundles with a timestamp. Any traces with entries in this field should be investigated, as they indicate a bug in perfetto or the kernel.
Implementations§
Source§impl FtraceStats
impl FtraceStats
Sourcepub fn phase(&self) -> Phase
pub fn phase(&self) -> Phase
Returns the enum value of phase, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn kernel_symbols_parsed(&self) -> u32
pub fn kernel_symbols_parsed(&self) -> u32
Returns the value of kernel_symbols_parsed, or the default value if kernel_symbols_parsed is unset.
Sourcepub fn kernel_symbols_mem_kb(&self) -> u32
pub fn kernel_symbols_mem_kb(&self) -> u32
Returns the value of kernel_symbols_mem_kb, or the default value if kernel_symbols_mem_kb is unset.
Sourcepub fn atrace_errors(&self) -> &str
pub fn atrace_errors(&self) -> &str
Returns the value of atrace_errors, or the default value if atrace_errors is unset.
Sourcepub fn preserve_ftrace_buffer(&self) -> bool
pub fn preserve_ftrace_buffer(&self) -> bool
Returns the value of preserve_ftrace_buffer, or the default value if preserve_ftrace_buffer is unset.
Sourcepub fn ftrace_parse_errors(
&self,
) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<FtraceParseStatus>>
pub fn ftrace_parse_errors( &self, ) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<FtraceParseStatus>>
Returns an iterator which yields the valid enum values contained in ftrace_parse_errors.
Sourcepub fn push_ftrace_parse_errors(&mut self, value: FtraceParseStatus)
pub fn push_ftrace_parse_errors(&mut self, value: FtraceParseStatus)
Appends the provided enum value to ftrace_parse_errors.
Trait Implementations§
Source§impl Clone for FtraceStats
impl Clone for FtraceStats
Source§fn clone(&self) -> FtraceStats
fn clone(&self) -> FtraceStats
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FtraceStats
impl Debug for FtraceStats
Source§impl Default for FtraceStats
impl Default for FtraceStats
Source§fn default() -> FtraceStats
fn default() -> FtraceStats
Source§impl Message for FtraceStats
impl Message for FtraceStats
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
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(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
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(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl PartialEq for FtraceStats
impl PartialEq for FtraceStats
impl StructuralPartialEq for FtraceStats
Auto Trait Implementations§
impl Freeze for FtraceStats
impl RefUnwindSafe for FtraceStats
impl Send for FtraceStats
impl Sync for FtraceStats
impl Unpin for FtraceStats
impl UnwindSafe for FtraceStats
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].