Fix a regression in Intel Gfx6 and clean up some GLSL lowering
GLSL IR opcodes generated for bitfieldExtract
and bitfieldInsert
are lowered by lower_instructions
. 4dff3ff0 ("nir/opt_algebraic:
Optimize open coded bfm.") adds an optimization that can rematerialize nir_op_bfm
that was prevented by the GLSL IR lowering.
It appears that every piece of hardware, except older Intel GPUS, that has real integers (i.e., lower_bitops
is not set) also sets lower_bitfield_extract_to_shifts
and lower_bitfield_insert_to_shifts
. The first commit modifies the Intel compiler to do this for Gfx6 and older.
With that in place, several of the lowering operations performed by lower_instructions
are unnecessary, so several other commits in the series remove them.