#[repr(C)]pub struct DroppedRecordStats {
pub first_dropped: zx_instant_boot_ticks_t,
pub last_dropped: zx_instant_boot_ticks_t,
pub num_dropped: u32,
pub bytes_dropped: u32,
pub has_dropped: bool,
pub __bindgen_padding_0: [u8; 7],
}Expand description
This struct keeps track of the duration, number, and size of trace records dropped when the buffer is full. These statistics are emitted to the trace buffer as a duration as soon as space is available to do so, at which point the values are reset to 0, or false in the case of has_dropped.
Fields§
§first_dropped: zx_instant_boot_ticks_t§last_dropped: zx_instant_boot_ticks_t§num_dropped: u32By storing num_dropped and bytes_dropped in 32-bit values, we ensure that they can each be stored in a single 64-bit word in the FXT record we emit when space is available.
bytes_dropped: u32§has_dropped: bool§__bindgen_padding_0: [u8; 7]Implementations§
Source§impl DroppedRecordStats
impl DroppedRecordStats
Sourcepub fn track(&mut self, now: zx_instant_boot_ticks_t, size: u32)
pub fn track(&mut self, now: zx_instant_boot_ticks_t, size: u32)
Records a dropped trace record of size bytes at timestamp now.
Sourcepub const fn has_dropped(&self) -> bool
pub const fn has_dropped(&self) -> bool
Returns true if any records have been dropped since the last reset.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for percpu_writer_DroppedRecordStats
impl RefUnwindSafe for percpu_writer_DroppedRecordStats
impl Send for percpu_writer_DroppedRecordStats
impl Sync for percpu_writer_DroppedRecordStats
impl Unpin for percpu_writer_DroppedRecordStats
impl UnsafeUnpin for percpu_writer_DroppedRecordStats
impl UnwindSafe for percpu_writer_DroppedRecordStats
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more