Harness and replay player: count dispatches by the form their kernel reaches its buffers in

The harness's matrix counts gain bound_dispatches and address_dispatches, and the replay player's
executed counters gain those two with buffer_sets_written and buffer_sets_held, so a run shows
which form its dispatches took. Built only; the harness run is the Iris read that follows.
This commit is contained in:
Anees Iqbal committed 2026-11-26 05:04:54 -08:00
1 parent 7cb5beafe5
commit cf270fa34e
3 files changed
+14 -2

No files matched your search

+6 -1
View File
@@ -454,7 +454,10 @@ impl crate::Device for Device {
self.device.counters().metrics().pipelines_created
}
/// `Metrics`' passes (encoders), barriers, bytes copied and resolves.
/// `Metrics`' passes (encoders), barriers, bytes copied and resolves, and its dispatches by
/// the form their kernel reaches its buffers in: through set 0's storage buffers
/// (`Metrics::bound_dispatches`) or at their device addresses
/// (`Metrics::address_dispatches`).
fn counts(&self) -> Vec<(&'static str, u64)> {
let metrics = self.device.counters().metrics();
vec![
@@ -462,6 +465,8 @@ impl crate::Device for Device {
("barriers", metrics.barriers),
("bytes_copied", metrics.bytes_copied),
("resolves", metrics.resolves),
("bound_dispatches", metrics.bound_dispatches),
("address_dispatches", metrics.address_dispatches),
]
}
@@ -3137,6 +3137,10 @@ impl Backend for NewRuntime {
),
("dispatch_heap_barriers", metrics.dispatch_heap_barriers),
("dispatch_other_barriers", metrics.dispatch_other_barriers),
("bound_dispatches", metrics.bound_dispatches),
("address_dispatches", metrics.address_dispatches),
("buffer_sets_written", metrics.buffer_sets_written),
("buffer_sets_held", metrics.buffer_sets_held),
("segment_end_barriers", metrics.segment_end_barriers),
("upload_barriers", metrics.upload_barriers),
("other_barriers", metrics.other_barriers),
+4 -1
View File
@@ -739,7 +739,10 @@ records as text, and
`dispatch_write_after_read_barriers`, `dispatch_encoder_end_barriers`,
`dispatch_pass_end_barriers`, `dispatch_indirect_barriers`, `dispatch_unbound_barriers`,
`dispatch_arena_piece_barriers`, `dispatch_heap_barriers` and `dispatch_other_barriers`
(`Metrics::dispatch_after_write_barriers` and the rest). They differ between commits, and
(`Metrics::dispatch_after_write_barriers` and the rest), and the dispatches by the form their
kernel reaches its buffers in: through storage buffers of set 0 (`bound_dispatches`, with the
sets written for them, `buffer_sets_written`, and those that kept the set written last,
`buffer_sets_held`) or at their device addresses (`address_dispatches`). They differ between commits, and
between plays of one commit where what the runtime records depends on timing. Only the
stream's counts are compared between plays.