radeonsi: avoid using hard-coded SI_NUM_RW_BUFFERS
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Sun, 16 Sep 2018 13:56:13 +0000 (15:56 +0200)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Wed, 19 Dec 2018 11:01:48 +0000 (12:01 +0100)
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/drivers/radeonsi/si_debug.c

index 22019741d808e31066728df885d06de62392344c..fe2970a0ea338f628cef98a004bbf07f66dcff08 100644 (file)
@@ -1071,7 +1071,8 @@ void si_log_draw_state(struct si_context *sctx, struct u_log_context *log)
 
        si_dump_descriptor_list(sctx->screen,
                                &sctx->descriptors[SI_DESCS_RW_BUFFERS],
-                               "", "RW buffers", 4, SI_NUM_RW_BUFFERS,
+                               "", "RW buffers", 4,
+                               sctx->descriptors[SI_DESCS_RW_BUFFERS].num_active_slots,
                                si_identity, log);
        si_dump_gfx_descriptors(sctx, &sctx->vs_shader, log);
        si_dump_gfx_descriptors(sctx, tcs_shader, log);