diff options
author | Alyssa Rosenzweig <[email protected]> | 2020-05-01 12:05:01 -0400 |
---|---|---|
committer | Alyssa Rosenzweig <[email protected]> | 2020-05-04 11:08:14 -0400 |
commit | 30f07e0d843935fcb34fc28e62bc4c832219c06b (patch) | |
tree | 7eae819e63294866acbab7910df7621d402abd34 /src/gallium | |
parent | 89a41dae7702731bee298288f3acbcbd56096b30 (diff) |
panfrost: Setup gl_FragCoord as sysval on Bifrost
..rather than a varying.
Signed-off-by: Alyssa Rosenzweig <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4883>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/panfrost/pan_cmdstream.c | 2 | ||||
-rw-r--r-- | src/gallium/drivers/panfrost/pan_screen.c | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/gallium/drivers/panfrost/pan_cmdstream.c b/src/gallium/drivers/panfrost/pan_cmdstream.c index 89d038f2e22..c99469a82d9 100644 --- a/src/gallium/drivers/panfrost/pan_cmdstream.c +++ b/src/gallium/drivers/panfrost/pan_cmdstream.c @@ -1810,7 +1810,7 @@ panfrost_emit_varying_descriptor(struct panfrost_batch *batch, varyings[gl_FragCoord].elements = MALI_VARYING_FRAG_COORD; struct panfrost_device *device = pan_device(ctx->base.screen); - assert(!(device->quirks & IS_BIFROST) || !(reads_point_coord || fs->reads_face || fs->reads_frag_coord)); + assert(!(device->quirks & IS_BIFROST) || !(reads_point_coord)); /* Let's go ahead and link varying meta to the buffer in question, now * that that information is available. VARYING_SLOT_POS is mapped to diff --git a/src/gallium/drivers/panfrost/pan_screen.c b/src/gallium/drivers/panfrost/pan_screen.c index 866c23adc93..ecfac6cddb0 100644 --- a/src/gallium/drivers/panfrost/pan_screen.c +++ b/src/gallium/drivers/panfrost/pan_screen.c @@ -93,6 +93,7 @@ panfrost_get_param(struct pipe_screen *screen, enum pipe_cap param) { /* We expose in-dev stuff for dEQP that we don't want apps to use yet */ bool is_deqp = pan_debug & PAN_DBG_DEQP; + struct panfrost_device *dev = pan_device(screen); /* Our GLES3 implementation is WIP */ bool is_gles3 = pan_debug & PAN_DBG_GLES3; @@ -195,10 +196,10 @@ panfrost_get_param(struct pipe_screen *screen, enum pipe_cap param) case PIPE_CAP_GENERATE_MIPMAP: return 1; - /* We would prefer varyings */ + /* We would prefer varyings on Midgard, but proper sysvals on Bifrost */ case PIPE_CAP_TGSI_FS_FACE_IS_INTEGER_SYSVAL: case PIPE_CAP_TGSI_FS_POSITION_IS_SYSVAL: - return 0; + return dev->quirks & IS_BIFROST; /* I really don't want to set this CAP but let's not swim against the * tide.. */ |