diff options
author | Antia Puentes <[email protected]> | 2015-06-17 10:10:44 +0200 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2015-08-03 09:40:50 -0700 |
commit | 9b4a6fa4c09d36e0e5c00309e6ea37300ea38f78 (patch) | |
tree | 8c9c491e46f1aedf0b2240c3db2ae39531d1ec68 /src/mesa/drivers/dri/i965/brw_vec4_nir.cpp | |
parent | 16072834babc487f78472f7e7b59d35249a3aac8 (diff) |
i965/nir/vec4: Mark as unreachable ops that should be already lowered
NIR ALU operations:
* nir_op_fabs
* nir_op_iabs
* nir_op_fneg
* nir_op_ineg
* nir_op_fsat
should be lowered by lower_source mods
* nir_op_fdiv
should be lowered in the compiler by DIV_TO_MUL_RCP.
* nir_op_fmod
should be lowered in the compiler by MOD_TO_FLOOR.
* nir_op_fsub
* nir_op_isub
should be handled by ir_sub_to_add_neg.
Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_vec4_nir.cpp')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4_nir.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp index a586f902f67..049edbdf099 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp @@ -1242,6 +1242,23 @@ vec4_visitor::nir_emit_alu(nir_alu_instr *instr) break; } + case nir_op_fabs: + case nir_op_iabs: + case nir_op_fneg: + case nir_op_ineg: + case nir_op_fsat: + unreachable("not reached: should be lowered by lower_source mods"); + + case nir_op_fdiv: + unreachable("not reached: should be lowered by DIV_TO_MUL_RCP in the compiler"); + + case nir_op_fmod: + unreachable("not reached: should be lowered by MOD_TO_FLOOR in the compiler"); + + case nir_op_fsub: + case nir_op_isub: + unreachable("not reached: should be handled by ir_sub_to_add_neg"); + default: unreachable("Unimplemented ALU operation"); } |