diff options
author | Jason Ekstrand <[email protected]> | 2014-12-12 20:37:04 -0800 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2015-01-15 07:20:21 -0800 |
commit | b3fd098e7daa491637d66d03366b67c989937a1f (patch) | |
tree | 000f2453d4fe1d914008a484811c1c672589d3c8 /src/glsl/nir/nir_lower_variables.c | |
parent | 295faf9462cba88250d8581f65611996eba5e389 (diff) |
nir: Make bcsel a fully vector operation
Previously, the condition was a scalar that applied to all components
simultaneously. As of this commit, the condition is a vector and each
component is switched seperately.
Reviewed-by: Connor Abbott <[email protected]>
Diffstat (limited to 'src/glsl/nir/nir_lower_variables.c')
-rw-r--r-- | src/glsl/nir/nir_lower_variables.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/glsl/nir/nir_lower_variables.c b/src/glsl/nir/nir_lower_variables.c index b8961f85ce8..64682056ddc 100644 --- a/src/glsl/nir/nir_lower_variables.c +++ b/src/glsl/nir/nir_lower_variables.c @@ -836,6 +836,7 @@ lower_deref_to_ssa_block(nir_block *block, void *void_state) mov = nir_alu_instr_create(state->mem_ctx, nir_op_bcsel); mov->src[0].src = nir_src_copy(intrin->predicate, state->mem_ctx); + /* Splat the condition to all channels */ memset(mov->src[0].swizzle, 0, sizeof mov->src[0].swizzle); mov->src[1].src.is_ssa = true; |