summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJose Maria Casanova Crespo <jmcasanova@igalia.com>2020-06-14 01:48:39 +0200
committerMarge Bot <eric+marge@anholt.net>2020-06-16 02:48:18 +0000
commitbe16833d9674ff3795b420a73b8ae2e1367bb0e2 (patch)
treefe0129b9c929be80cb69863b19a5c693fbd745bb
parentc148dbe07e77f5146cf558afe03649a1146bf490 (diff)
vc4: don't relay on intr->num_components for non-vectorized intrinsics
Signed-off-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
-rw-r--r--src/gallium/drivers/vc4/vc4_program.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/vc4/vc4_program.c b/src/gallium/drivers/vc4/vc4_program.c
index 2d16c479313..4bf7e367213 100644
--- a/src/gallium/drivers/vc4/vc4_program.c
+++ b/src/gallium/drivers/vc4/vc4_program.c
@@ -1775,7 +1775,7 @@ ntq_emit_intrinsic(struct vc4_compile *c, nir_intrinsic_instr *instr)
break;
case nir_intrinsic_load_user_clip_plane:
- for (int i = 0; i < instr->num_components; i++) {
+ for (int i = 0; i < nir_intrinsic_dest_components(instr); i++) {
ntq_store_dest(c, &instr->dest, i,
qir_uniform(c, QUNIFORM_USER_CLIP_PLANE,
nir_intrinsic_ucp_id(instr) *