|
tess 1.0.0
Performance-first tile and path simulation substrate
|
#include <tess/diagnostics/export.h>
Public Attributes | |
| PathCounters | path |
| AllocationCounters | allocation |
| QueuedPhaseCounters | queued |
| TimingSnapshot | timing |
| std::array< TraceRecord, diagnostics_snapshot_trace_capacity > | trace_records {} |
| std::size_t | trace_record_count = 0 |
| std::uint64_t | trace_records_dropped = 0 |
Value snapshot of the counters and timings commonly rendered together.
Every counter and timing is a copy and outlives the corresponding sinks. TraceRecord::label is the exception: it is a std::string_view, so a snapshot only outlives its sink to the extent the labels do. The trace API already requires a label to outlive every reader of the buffer (see diagnostics/trace.h), which a string literal satisfies – but a dynamically built label handed to another thread through this snapshot is a dangling read, and this comment previously promised it was not.