microsoft: Use nir_test_mask instead of i2b(iand)
Signed-off-by: Konstantin Seurer <konstantin.seurer@gmail.com> Reviewed-by: Jesse Natalie <jenatali@microsoft.com> Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17242>
This commit is contained in:

committed by
Marge Bot

parent
85da294bfe
commit
39abd90d9e
@@ -328,14 +328,14 @@ lower_yz_flip(struct nir_builder *builder, nir_instr *instr,
|
||||
/* TODO: Multi-viewport */
|
||||
|
||||
if (y_flip_mask) {
|
||||
nir_ssa_def *flip = nir_ieq_imm(builder, nir_iand_imm(builder, y_flip_mask, 1), 1);
|
||||
nir_ssa_def *flip = nir_test_mask(builder, y_flip_mask, 1);
|
||||
|
||||
// Z-flip => pos.y = -pos.y
|
||||
y_pos = nir_bcsel(builder, flip, nir_fneg(builder, y_pos), y_pos);
|
||||
}
|
||||
|
||||
if (z_flip_mask) {
|
||||
nir_ssa_def *flip = nir_ieq_imm(builder, nir_iand_imm(builder, z_flip_mask, 1), 1);
|
||||
nir_ssa_def *flip = nir_test_mask(builder, z_flip_mask, 1);
|
||||
|
||||
// Z-flip => pos.z = -pos.z + 1.0f
|
||||
z_pos = nir_bcsel(builder, flip,
|
||||
|
Reference in New Issue
Block a user