Mesa (main): intel/decode: handle gen4/5 WM state fragment shaders
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sun Jun 13 22:39:12 UTC 2021
Module: Mesa
Branch: main
Commit: 4de8ba15b47593eec7d11990e8b0e1a5ca9d58f8
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=4de8ba15b47593eec7d11990e8b0e1a5ca9d58f8
Author: Dave Airlie <airlied at redhat.com>
Date: Thu Jun 10 07:01:21 2021 +1000
intel/decode: handle gen4/5 WM state fragment shaders
Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11146>
---
src/intel/common/intel_batch_decoder.c | 19 ++++++++++++++++---
1 file changed, 16 insertions(+), 3 deletions(-)
diff --git a/src/intel/common/intel_batch_decoder.c b/src/intel/common/intel_batch_decoder.c
index f9655c7c474..12ed17f6fef 100644
--- a/src/intel/common/intel_batch_decoder.c
+++ b/src/intel/common/intel_batch_decoder.c
@@ -611,10 +611,10 @@ decode_single_ksp(struct intel_batch_decode_ctx *ctx, const uint32_t *p)
}
static void
-decode_ps_kernels(struct intel_batch_decode_ctx *ctx, const uint32_t *p)
+decode_ps_kern(struct intel_batch_decode_ctx *ctx,
+ struct intel_group *inst, const uint32_t *p)
{
- struct intel_group *inst = intel_ctx_find_instruction(ctx, p);
-
+ bool single_ksp = ctx->devinfo.ver == 4;
uint64_t ksp[3] = {0, 0, 0};
bool enabled[3] = {false, false, false};
@@ -634,6 +634,9 @@ decode_ps_kernels(struct intel_batch_decode_ctx *ctx, const uint32_t *p)
}
}
+ if (single_ksp)
+ ksp[1] = ksp[2] = ksp[0];
+
/* Reorder KSPs to be [8, 16, 32] instead of the hardware order. */
if (enabled[0] + enabled[1] + enabled[2] == 1) {
if (enabled[1]) {
@@ -660,6 +663,14 @@ decode_ps_kernels(struct intel_batch_decode_ctx *ctx, const uint32_t *p)
fprintf(ctx->fp, "\n");
}
+static void
+decode_ps_kernels(struct intel_batch_decode_ctx *ctx,
+ const uint32_t *p)
+{
+ struct intel_group *inst = intel_ctx_find_instruction(ctx, p);
+ decode_ps_kern(ctx, inst, p);
+}
+
static void
decode_3dstate_constant_all(struct intel_batch_decode_ctx *ctx, const uint32_t *p)
{
@@ -1092,6 +1103,8 @@ decode_wm_state(struct intel_batch_decode_ctx *ctx, uint32_t offset)
}
ctx_print_group(ctx, strct, offset, bind_bo.map);
+
+ decode_ps_kern(ctx, strct, bind_bo.map);
}
static void
More information about the mesa-commit
mailing list