summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeonsi/radeonsi_shader.c
diff options
context:
space:
mode:
authorMichel Dänzer <[email protected]>2012-09-27 16:39:26 +0200
committerMichel Dänzer <[email protected]>2012-10-02 17:53:47 +0200
commit82e38ac91f60e4ca242814ad36a5eecb82156cc6 (patch)
tree16c680a87577daf6ee0dd262c15b92491f79695f /src/gallium/drivers/radeonsi/radeonsi_shader.c
parentc3db19efba8ccdf8df94ab357cf675ba8728f81c (diff)
radeonsi: Fix double compilation of shader variants.
Fixes crash in piglit glsl-max-varyings. Signed-off-by: Michel Dänzer <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/radeonsi_shader.c')
-rw-r--r--src/gallium/drivers/radeonsi/radeonsi_shader.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/radeonsi_shader.c b/src/gallium/drivers/radeonsi/radeonsi_shader.c
index a48234a17ca..f65e69210cf 100644
--- a/src/gallium/drivers/radeonsi/radeonsi_shader.c
+++ b/src/gallium/drivers/radeonsi/radeonsi_shader.c
@@ -698,6 +698,10 @@ int si_pipe_shader_create(
dump = debug_get_bool_option("RADEON_DUMP_SHADERS", FALSE);
+ assert(shader->shader.noutput == 0);
+ assert(shader->shader.ninterp == 0);
+ assert(shader->shader.ninput == 0);
+
memset(&si_shader_ctx, 0, sizeof(si_shader_ctx));
radeon_llvm_context_init(&si_shader_ctx.radeon_bld);
bld_base = &si_shader_ctx.radeon_bld.soa.bld_base;