From 0930082ffdd99e6930b848c82129116e80735b47 Mon Sep 17 00:00:00 2001 From: Roland Scheidegger Date: Tue, 13 Aug 2013 01:10:59 +0200 Subject: tgsi: implement new float comparison instructions returning integer masks Also while here add a bunch of other forgotten (integer) instructions to tgsi_util_get_inst_usage_mask() (which isn't used for much except optimizing away unused input components), though it may still be incomplete. Reviewed-by: Zack Rusin --- src/gallium/auxiliary/tgsi/tgsi_info.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'src/gallium/auxiliary/tgsi/tgsi_info.c') diff --git a/src/gallium/auxiliary/tgsi/tgsi_info.c b/src/gallium/auxiliary/tgsi/tgsi_info.c index 7e930288f55..7a5d18f59c5 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_info.c +++ b/src/gallium/auxiliary/tgsi/tgsi_info.c @@ -145,10 +145,10 @@ static const struct tgsi_opcode_info opcode_info[TGSI_OPCODE_LAST] = { 0, 0, 0, 0, 0, 0, NONE, "", 105 }, /* removed */ { 0, 0, 0, 0, 0, 0, NONE, "", 106 }, /* removed */ { 0, 0, 0, 0, 0, 0, NONE, "NOP", TGSI_OPCODE_NOP }, - { 0, 0, 0, 0, 0, 0, NONE, "", 108 }, /* removed */ - { 0, 0, 0, 0, 0, 0, NONE, "", 109 }, /* removed */ - { 0, 0, 0, 0, 0, 0, NONE, "", 110 }, /* removed */ - { 0, 0, 0, 0, 0, 0, NONE, "", 111 }, /* removed */ + { 1, 2, 0, 0, 0, 0, COMP, "FSEQ", TGSI_OPCODE_FSEQ }, + { 1, 2, 0, 0, 0, 0, COMP, "FSGE", TGSI_OPCODE_FSGE }, + { 1, 2, 0, 0, 0, 0, COMP, "FSLT", TGSI_OPCODE_FSLT }, + { 1, 2, 0, 0, 0, 0, COMP, "FSNE", TGSI_OPCODE_FSNE }, { 1, 1, 0, 0, 0, 0, REPL, "NRM4", TGSI_OPCODE_NRM4 }, { 0, 1, 0, 0, 0, 0, NONE, "CALLNZ", TGSI_OPCODE_CALLNZ }, { 0, 1, 0, 0, 0, 0, NONE, "", 114 }, /* removed */ @@ -302,6 +302,10 @@ tgsi_opcode_infer_type( uint opcode ) case TGSI_OPCODE_ARR: case TGSI_OPCODE_MOD: case TGSI_OPCODE_F2I: + case TGSI_OPCODE_FSEQ: + case TGSI_OPCODE_FSGE: + case TGSI_OPCODE_FSLT: + case TGSI_OPCODE_FSNE: case TGSI_OPCODE_IDIV: case TGSI_OPCODE_IMAX: case TGSI_OPCODE_IMIN: @@ -343,6 +347,10 @@ tgsi_opcode_infer_src_type( uint opcode ) case TGSI_OPCODE_TXQ_LZ: case TGSI_OPCODE_F2I: case TGSI_OPCODE_F2U: + case TGSI_OPCODE_FSEQ: + case TGSI_OPCODE_FSGE: + case TGSI_OPCODE_FSLT: + case TGSI_OPCODE_FSNE: case TGSI_OPCODE_UCMP: return TGSI_TYPE_FLOAT; default: -- cgit v1.2.3