mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
radv/debug: dump ray tracing shaders in case of a hang
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22096>
This commit is contained in:
parent
163c97e6a7
commit
f5428a4181
1 changed files with 22 additions and 0 deletions
|
|
@ -499,6 +499,17 @@ radv_dump_queue_state(struct radv_queue *queue, const char *dump_dir, FILE *f)
|
|||
radv_dump_shader(device, &graphics_pipeline->base, graphics_pipeline->base.shaders[stage],
|
||||
stage, dump_dir, f);
|
||||
}
|
||||
} else if (pipeline->type == RADV_PIPELINE_RAY_TRACING) {
|
||||
struct radv_ray_tracing_pipeline *rt_pipeline = radv_pipeline_to_ray_tracing(pipeline);
|
||||
for (unsigned i = 0; i < rt_pipeline->stage_count; i++) {
|
||||
if (radv_ray_tracing_stage_is_compiled(&rt_pipeline->stages[i])) {
|
||||
struct radv_shader *shader =
|
||||
container_of(rt_pipeline->stages[i].shader, struct radv_shader, base);
|
||||
radv_dump_shader(device, pipeline, shader, shader->info.stage, dump_dir, f);
|
||||
}
|
||||
}
|
||||
radv_dump_shader(device, pipeline, pipeline->shaders[MESA_SHADER_INTERSECTION],
|
||||
MESA_SHADER_INTERSECTION, dump_dir, f);
|
||||
} else {
|
||||
struct radv_compute_pipeline *compute_pipeline =
|
||||
radv_pipeline_to_compute(pipeline);
|
||||
|
|
@ -526,6 +537,17 @@ radv_dump_queue_state(struct radv_queue *queue, const char *dump_dir, FILE *f)
|
|||
radv_dump_annotated_shader(graphics_pipeline->base.shaders[stage], stage, waves,
|
||||
num_waves, f);
|
||||
}
|
||||
} else if (pipeline->type == RADV_PIPELINE_RAY_TRACING) {
|
||||
struct radv_ray_tracing_pipeline *rt_pipeline = radv_pipeline_to_ray_tracing(pipeline);
|
||||
for (unsigned i = 0; i < rt_pipeline->stage_count; i++) {
|
||||
if (radv_ray_tracing_stage_is_compiled(&rt_pipeline->stages[i])) {
|
||||
struct radv_shader *shader =
|
||||
container_of(rt_pipeline->stages[i].shader, struct radv_shader, base);
|
||||
radv_dump_annotated_shader(shader, shader->info.stage, waves, num_waves, f);
|
||||
}
|
||||
}
|
||||
radv_dump_annotated_shader(pipeline->shaders[MESA_SHADER_INTERSECTION],
|
||||
MESA_SHADER_INTERSECTION, waves, num_waves, f);
|
||||
} else {
|
||||
struct radv_compute_pipeline *compute_pipeline =
|
||||
radv_pipeline_to_compute(pipeline);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue