diff options
author | Ilia Mirkin <[email protected]> | 2015-09-23 00:30:23 -0400 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2015-09-24 00:19:55 -0400 |
commit | 1614c39a8fc205d7b1cb5b16737c233fbcc5b678 (patch) | |
tree | aa0c3f5959cec3a5d8afa7e381929cd5af115585 | |
parent | 827d7948340f4cbc7de2d02971e4f36fbd52f7a8 (diff) |
st/mesa: keep track of saturated writes when eliminating dead code
It doesn't matter whether a write is saturated or not, in another
implementation it might even have been a separate opcode. This code was
most likely copied from the copy-propagation pass (where one does have
to distinguish saturation).
Signed-off-by: Ilia Mirkin <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
-rw-r--r-- | src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index c3a8c119b1e..5896f6518b5 100644 --- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp +++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp @@ -4144,8 +4144,7 @@ glsl_to_tgsi_visitor::eliminate_dead_code(void) */ for (unsigned i = 0; i < ARRAY_SIZE(inst->dst); i++) { if (inst->dst[i].file == PROGRAM_TEMPORARY && - !inst->dst[i].reladdr && - !inst->saturate) { + !inst->dst[i].reladdr) { for (int c = 0; c < 4; c++) { if (inst->dst[i].writemask & (1 << c)) { if (writes[4 * inst->dst[i].index + c]) { |