mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 04:38:03 +02:00
st/mesa: Use nir_const_value_for_bool() in ATIFS
Fixes: 0a179bb6e2 ("st/mesa: Generate NIR for ATI_fragment_shader instead of TGSI.")
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19689>
This commit is contained in:
parent
e6de164e03
commit
49d86200e5
1 changed files with 3 additions and 3 deletions
|
|
@ -407,10 +407,10 @@ compile_instruction(struct st_translate *t,
|
|||
result = emit_dstmod(t, result, inst->DstReg[optype].dstMod);
|
||||
|
||||
/* Do the writemask */
|
||||
nir_const_value wrmask[4] = { 0 };
|
||||
nir_const_value wrmask[4];
|
||||
for (int i = 0; i < 4; i++) {
|
||||
if (inst->DstReg[optype].dstMask & (1 << i))
|
||||
wrmask[i].b = 1;
|
||||
bool bit = inst->DstReg[optype].dstMask & (1 << i);
|
||||
wrmask[i] = nir_const_value_for_bool(bit, 1);
|
||||
}
|
||||
|
||||
t->temps[dstreg] = nir_bcsel(t->b,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue