nir: Add nir_alu_srcs_negative_equal

v2: Move bug fix in get_neg_instr from the next patch to this patch
(where it was intended to be in the first place).  Noticed by Caio.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Ian Romanick
2018-05-22 18:18:07 -07:00
parent be1cc3552b
commit c6ee46a753
3 changed files with 192 additions and 0 deletions

View File

@@ -997,6 +997,10 @@ bool nir_const_value_negative_equal(const nir_const_value *c1,
bool nir_alu_srcs_equal(const nir_alu_instr *alu1, const nir_alu_instr *alu2,
unsigned src1, unsigned src2);
bool nir_alu_srcs_negative_equal(const nir_alu_instr *alu1,
const nir_alu_instr *alu2,
unsigned src1, unsigned src2);
typedef enum {
nir_deref_type_var,
nir_deref_type_array,