diff options
author | Eric Anholt <[email protected]> | 2014-09-23 17:25:43 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2014-09-24 00:25:07 -0700 |
commit | bf4aecfb2acc8d0dc815105d2f36eccbc97c284b (patch) | |
tree | b3b799eb7fb6ae095f476f1c042ee6032d95d087 /src/gallium/drivers/vc4/vc4_screen.c | |
parent | 45b104e0a228595142ed4bc62bbc8948100b9325 (diff) |
vc4: Drop maximum number of varyings down to 8.
There are only 32 bits in the flatshade flags (which are 1 bit per
component), the simulator crashes when you use more than about this many
varyings, and the original Broadcom code drop only exposed 8 as well.
Fixes 26 piglit tests in the varying-packing group, and makes many others
go from crash to fail (due to not checking their varying counts and
treating link failures as failures). Regresses ARB_fp/minmax (due to 8
varyings instead of 10).
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_screen.c')
-rw-r--r-- | src/gallium/drivers/vc4/vc4_screen.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/drivers/vc4/vc4_screen.c b/src/gallium/drivers/vc4/vc4_screen.c index 4a5ce4feee7..81a29a5ef2e 100644 --- a/src/gallium/drivers/vc4/vc4_screen.c +++ b/src/gallium/drivers/vc4/vc4_screen.c @@ -276,7 +276,10 @@ vc4_screen_get_shader_param(struct pipe_screen *pscreen, unsigned shader, case PIPE_SHADER_CAP_MAX_CONTROL_FLOW_DEPTH: return 0; case PIPE_SHADER_CAP_MAX_INPUTS: - return 16; + if (shader == PIPE_SHADER_FRAGMENT) + return 8; + else + return 16; case PIPE_SHADER_CAP_MAX_TEMPS: return 256; /* GL_MAX_PROGRAM_TEMPORARIES_ARB */ case PIPE_SHADER_CAP_MAX_CONST_BUFFER_SIZE: |