From 4fa02c5c8e60a2ae13165563fb0d3b4c69155b21 Mon Sep 17 00:00:00 2001 From: Danylo Piliaiev Date: Mon, 10 Jul 2023 16:28:41 +0200 Subject: [PATCH] freedreno/cffdec: Decode CP_DRAW_AUTO Signed-off-by: Danylo Piliaiev Part-of: --- src/freedreno/decode/cffdec.c | 12 ++++++++++++ src/freedreno/registers/adreno/adreno_pm4.xml | 14 ++++++++++++++ 2 files changed, 26 insertions(+) diff --git a/src/freedreno/decode/cffdec.c b/src/freedreno/decode/cffdec.c index 6989eef..57d8a66 100644 --- a/src/freedreno/decode/cffdec.c +++ b/src/freedreno/decode/cffdec.c @@ -2203,6 +2203,17 @@ cp_draw_indirect_multi(uint32_t *dwords, uint32_t sizedwords, int level) } static void +cp_draw_auto(uint32_t *dwords, uint32_t sizedwords, int level) +{ + uint32_t prim_type = dwords[0] & 0x1f; + + do_query(rnn_enumname(rnn, "pc_di_primtype", prim_type), 0); + print_mode(level); + + dump_register_summary(level); +} + +static void cp_run_cl(uint32_t *dwords, uint32_t sizedwords, int level) { do_query("COMPUTE", 1); @@ -2928,6 +2939,7 @@ static const struct type3_op { CP(SET_MODE, cp_set_mode), CP(SET_MARKER, cp_set_marker), CP(REG_WRITE, cp_reg_write), + CP(DRAW_AUTO, cp_draw_auto, {.load_all_groups = true}), CP(SET_CTXSWITCH_IB, cp_set_ctxswitch_ib), diff --git a/src/freedreno/registers/adreno/adreno_pm4.xml b/src/freedreno/registers/adreno/adreno_pm4.xml index 8ab7b43..2450929 100644 --- a/src/freedreno/registers/adreno/adreno_pm4.xml +++ b/src/freedreno/registers/adreno/adreno_pm4.xml @@ -1018,6 +1018,20 @@ opcode: CP_LOAD_STATE4 (30) (4 dwords) + + + + + + + + + + + + + + -- 2.7.4