diff options
author | Nicolai Hähnle <[email protected]> | 2017-09-15 18:47:52 +0200 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2017-09-29 12:07:59 +0200 |
commit | 2b0bfc51de148147b7a822bb022a7ee2a1c2a28f (patch) | |
tree | 3ff8283b7f84dead8df3d265f8ef480c363d592e /src/gallium/auxiliary/tgsi | |
parent | 5cf279bf7e7c16dbaf1bd15bf7c65cd3cfa67728 (diff) |
tgsi: infer that dst[1] of DFRACEXP is an integer
Reviewed-by: Marek Olšák <[email protected]>
Tested-by: Dieter Nützel <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/tgsi')
-rw-r--r-- | src/gallium/auxiliary/tgsi/tgsi_info.c | 5 | ||||
-rw-r--r-- | src/gallium/auxiliary/tgsi/tgsi_info.h | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/tgsi/tgsi_info.c b/src/gallium/auxiliary/tgsi/tgsi_info.c index 36be463dc84..62b41c031b3 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_info.c +++ b/src/gallium/auxiliary/tgsi/tgsi_info.c @@ -312,7 +312,10 @@ tgsi_opcode_infer_src_type(uint opcode, uint src_idx) * infer the destination type of a TGSI opcode. */ enum tgsi_opcode_type -tgsi_opcode_infer_dst_type( uint opcode ) +tgsi_opcode_infer_dst_type( uint opcode, uint dst_idx ) { + if (dst_idx == 1 && opcode == TGSI_OPCODE_DFRACEXP) + return TGSI_TYPE_SIGNED; + return tgsi_opcode_infer_type(opcode); } diff --git a/src/gallium/auxiliary/tgsi/tgsi_info.h b/src/gallium/auxiliary/tgsi/tgsi_info.h index f3ef46fb4a8..8d32f4774be 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_info.h +++ b/src/gallium/auxiliary/tgsi/tgsi_info.h @@ -114,7 +114,7 @@ enum tgsi_opcode_type tgsi_opcode_infer_src_type( uint opcode, uint src_idx ); enum tgsi_opcode_type -tgsi_opcode_infer_dst_type( uint opcode ); +tgsi_opcode_infer_dst_type( uint opcode, uint dst_idx ); #if defined __cplusplus } |