mirror of
https://github.com/tiagovignatti/intel-gpu-tools.git
synced 2025-06-11 09:56:22 +00:00
gem_stress: some stats about incoherencies
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
parent
1007956680
commit
336f85dafb
@ -95,6 +95,11 @@ static unsigned num_total_tiles = 0;
|
|||||||
int fence_storm = 0;
|
int fence_storm = 0;
|
||||||
static int gpu_busy_load = 10;
|
static int gpu_busy_load = 10;
|
||||||
|
|
||||||
|
struct {
|
||||||
|
unsigned num_failed;
|
||||||
|
unsigned max_failed_reads;
|
||||||
|
} stats;
|
||||||
|
|
||||||
static void tile2xy(struct scratch_buf *buf, unsigned tile, unsigned *x, unsigned *y)
|
static void tile2xy(struct scratch_buf *buf, unsigned tile, unsigned *x, unsigned *y)
|
||||||
{
|
{
|
||||||
assert(tile < buf->num_tiles);
|
assert(tile < buf->num_tiles);
|
||||||
@ -193,7 +198,7 @@ static void cpucpy2d(uint32_t *src, unsigned src_stride, unsigned src_x, unsigne
|
|||||||
logical_tile_no, i*options.tile_size + j, tmp, expect, (int) tmp - expect);
|
logical_tile_no, i*options.tile_size + j, tmp, expect, (int) tmp - expect);
|
||||||
if (options.trace_tile >= 0 && options.fail)
|
if (options.trace_tile >= 0 && options.fail)
|
||||||
exit(1);
|
exit(1);
|
||||||
failed = 1;
|
failed++;
|
||||||
}
|
}
|
||||||
/* when not aborting, correct any errors */
|
/* when not aborting, correct any errors */
|
||||||
dst[dst_ofs] = expect;
|
dst[dst_ofs] = expect;
|
||||||
@ -201,6 +206,11 @@ static void cpucpy2d(uint32_t *src, unsigned src_stride, unsigned src_x, unsigne
|
|||||||
}
|
}
|
||||||
if (failed && options.fail)
|
if (failed && options.fail)
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
||||||
|
if (failed > stats.max_failed_reads)
|
||||||
|
stats.max_failed_reads = failed;
|
||||||
|
if (failed)
|
||||||
|
stats.num_failed++;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void cpu_copyfunc(struct scratch_buf *src, unsigned src_x, unsigned src_y,
|
static void cpu_copyfunc(struct scratch_buf *src, unsigned src_x, unsigned src_y,
|
||||||
@ -917,6 +927,9 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
fan_in_and_check();
|
fan_in_and_check();
|
||||||
|
|
||||||
|
fprintf(stderr, "num failed tiles %u, max incoherent bytes %lu\n",
|
||||||
|
stats.num_failed, stats.max_failed_reads*sizeof(uint32_t));
|
||||||
|
|
||||||
intel_batchbuffer_free(batch);
|
intel_batchbuffer_free(batch);
|
||||||
drm_intel_bufmgr_destroy(bufmgr);
|
drm_intel_bufmgr_destroy(bufmgr);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user