diff options
author | Marek Olšák <[email protected]> | 2015-09-10 18:31:33 +0200 |
---|---|---|
committer | Emil Velikov <[email protected]> | 2015-10-07 14:39:14 +0100 |
commit | 10382380f042a88877bf5c9df671a64179549ea7 (patch) | |
tree | 6e2b349f2c82273ccbec74fde3e1c8166240b1f2 /src/gallium | |
parent | 815b595b5f2c8b3d0b558b1fc112c8e003b2ec03 (diff) |
radeonsi: handle fixed-func TCS shader create failure
Cc: 11.0 <[email protected]>
Acked-by: Christian König <[email protected]>
Reviewed-by: Michel Dänzer <[email protected]>
(cherry picked from commit 9b6d9dd7d8d2779e2bd08787c26f51512b84f6d2)
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_state_shaders.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state_shaders.c b/src/gallium/drivers/radeonsi/si_state_shaders.c index c9319390aea..4d536571966 100644 --- a/src/gallium/drivers/radeonsi/si_state_shaders.c +++ b/src/gallium/drivers/radeonsi/si_state_shaders.c @@ -1324,7 +1324,6 @@ static void si_generate_fixed_func_tcs(struct si_context *sctx) sctx->fixed_func_tcs_shader = ureg_create_shader_and_destroy(ureg, &sctx->b.b); - assert(sctx->fixed_func_tcs_shader); } static void si_update_vgt_shader_config(struct si_context *sctx) @@ -1393,8 +1392,12 @@ bool si_update_shaders(struct si_context *sctx) si_shader_select(ctx, sctx->tcs_shader); si_pm4_bind_state(sctx, hs, sctx->tcs_shader->current->pm4); } else { - if (!sctx->fixed_func_tcs_shader) + if (!sctx->fixed_func_tcs_shader) { si_generate_fixed_func_tcs(sctx); + if (!sctx->fixed_func_tcs_shader) + return false; + } + si_shader_select(ctx, sctx->fixed_func_tcs_shader); si_pm4_bind_state(sctx, hs, sctx->fixed_func_tcs_shader->current->pm4); |