diff options
author | Ian Romanick <[email protected]> | 2018-09-09 14:06:43 -0700 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2018-10-09 13:56:42 -0700 |
commit | b44c9292b7e5a24e6b06a197d4e72b43a8799d09 (patch) | |
tree | 792b8f4d5eacf172a0ff552d9476b1b3e43101dd /src/intel/compiler/brw_fs_nir.cpp | |
parent | a68dd47b911053995ae387afcdc7fffe82e57420 (diff) |
intel/compiler: Don't handle fsign.sat
No shader-db or CI changes on any Intel platform.
Signed-off-by: Ian Romanick <[email protected]>
Reviewed-by: Thomas Helland <[email protected]>
Diffstat (limited to 'src/intel/compiler/brw_fs_nir.cpp')
-rw-r--r-- | src/intel/compiler/brw_fs_nir.cpp | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/src/intel/compiler/brw_fs_nir.cpp b/src/intel/compiler/brw_fs_nir.cpp index 7f453d75b64..12b087a5ec0 100644 --- a/src/intel/compiler/brw_fs_nir.cpp +++ b/src/intel/compiler/brw_fs_nir.cpp @@ -842,6 +842,7 @@ fs_visitor::nir_emit_alu(const fs_builder &bld, nir_alu_instr *instr) break; case nir_op_fsign: { + assert(!instr->dest.saturate); if (op[0].abs) { /* Straightforward since the source can be assumed to be either * strictly >= 0 or strictly <= 0 depending on the setting of the @@ -854,10 +855,6 @@ fs_visitor::nir_emit_alu(const fs_builder &bld, nir_alu_instr *instr) : bld.MOV(result, brw_imm_f(1.0f)); set_predicate(BRW_PREDICATE_NORMAL, inst); - - if (instr->dest.saturate) - inst->saturate = true; - } else if (type_sz(op[0].type) < 8) { /* AND(val, 0x80000000) gives the sign bit. * @@ -873,10 +870,6 @@ fs_visitor::nir_emit_alu(const fs_builder &bld, nir_alu_instr *instr) inst = bld.OR(result_int, result_int, brw_imm_ud(0x3f800000u)); inst->predicate = BRW_PREDICATE_NORMAL; - if (instr->dest.saturate) { - inst = bld.MOV(result, result); - inst->saturate = true; - } } else { /* For doubles we do the same but we need to consider: * @@ -897,11 +890,6 @@ fs_visitor::nir_emit_alu(const fs_builder &bld, nir_alu_instr *instr) set_predicate(BRW_PREDICATE_NORMAL, bld.OR(r, r, brw_imm_ud(0x3ff00000u))); - - if (instr->dest.saturate) { - inst = bld.MOV(result, result); - inst->saturate = true; - } } break; } |