diff options
author | Ian Romanick <[email protected]> | 2016-04-12 17:38:23 -0700 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2016-05-10 09:22:18 -0700 |
commit | f7328f9afd13a1862259128713ea39757e175a84 (patch) | |
tree | 7da874dc3faa893b55341d6b73f8d0287ba4f207 /src/mesa/drivers | |
parent | fd63e779986c59c1e2d93ec366abd7cf9fb36d2c (diff) |
prog: Delete all remains of OPCODE_SNE, OPCODE_SEQ, OPCODE_SGT, and OPCODE_SLE
There is nothing left that can generate them. These used to be
generated by ir_to_mesa or by the assembler for various NV extensions
that have been removed.
Signed-off-by: Ian Romanick <[email protected]>
Reviewed-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/dri/i915/i915_fragprog.c | 148 |
1 files changed, 0 insertions, 148 deletions
diff --git a/src/mesa/drivers/dri/i915/i915_fragprog.c b/src/mesa/drivers/dri/i915/i915_fragprog.c index 691bae359fb..1944b3db0a2 100644 --- a/src/mesa/drivers/dri/i915/i915_fragprog.c +++ b/src/mesa/drivers/dri/i915/i915_fragprog.c @@ -789,68 +789,6 @@ upload_program(struct i915_fragment_program *p) } break; - case OPCODE_SEQ: - tmp = i915_get_utemp(p); - flags = get_result_flags(inst); - dst = get_result_vector(p, inst); - - /* If both operands are uniforms or constants, we get 5 instructions - * like: - * - * U[1] = MOV CONST[1] - * U[0].xyz = SGE CONST[0].xxxx, U[1] - * U[1] = MOV CONST[1].-x-y-z-w - * R[0].xyz = SGE CONST[0].-x-x-x-x, U[1] - * R[0].xyz = MUL R[0], U[0] - * - * This code is stupid. Instead of having the individual calls to - * i915_emit_arith generate the moves to utemps, do it in the caller. - * This results in code like: - * - * U[1] = MOV CONST[1] - * U[0].xyz = SGE CONST[0].xxxx, U[1] - * R[0].xyz = SGE CONST[0].-x-x-x-x, U[1].-x-y-z-w - * R[0].xyz = MUL R[0], U[0] - */ - src0 = src_vector(p, &inst->SrcReg[0], program); - src1 = src_vector(p, &inst->SrcReg[1], program); - - if (GET_UREG_TYPE(src0) == REG_TYPE_CONST - && GET_UREG_TYPE(src1) == REG_TYPE_CONST) { - unsigned tmp = i915_get_utemp(p); - - i915_emit_arith(p, A0_MOV, tmp, A0_DEST_CHANNEL_ALL, 0, - src1, 0, 0); - - src1 = tmp; - } - - /* tmp = src1 >= src2 */ - i915_emit_arith(p, - A0_SGE, - tmp, - flags, 0, - src0, - src1, - 0); - /* dst = src1 <= src2 */ - i915_emit_arith(p, - A0_SGE, - dst, - flags, 0, - negate(src0, 1, 1, 1, 1), - negate(src1, 1, 1, 1, 1), - 0); - /* dst = tmp && dst */ - i915_emit_arith(p, - A0_MUL, - dst, - flags, 0, - dst, - tmp, - 0); - break; - case OPCODE_SIN: src0 = src_vector(p, &inst->SrcReg[0], program); tmp = i915_get_utemp(p); @@ -939,96 +877,10 @@ upload_program(struct i915_fragment_program *p) EMIT_2ARG_ARITH(A0_SGE); break; - case OPCODE_SGT: - i915_emit_arith(p, - A0_SLT, - get_result_vector( p, inst ), - get_result_flags( inst ), 0, - negate(src_vector( p, &inst->SrcReg[0], program), - 1, 1, 1, 1), - negate(src_vector( p, &inst->SrcReg[1], program), - 1, 1, 1, 1), - 0); - break; - - case OPCODE_SLE: - i915_emit_arith(p, - A0_SGE, - get_result_vector( p, inst ), - get_result_flags( inst ), 0, - negate(src_vector( p, &inst->SrcReg[0], program), - 1, 1, 1, 1), - negate(src_vector( p, &inst->SrcReg[1], program), - 1, 1, 1, 1), - 0); - break; - case OPCODE_SLT: EMIT_2ARG_ARITH(A0_SLT); break; - case OPCODE_SNE: - tmp = i915_get_utemp(p); - flags = get_result_flags(inst); - dst = get_result_vector(p, inst); - - /* If both operands are uniforms or constants, we get 5 instructions - * like: - * - * U[1] = MOV CONST[1] - * U[0].xyz = SLT CONST[0].xxxx, U[1] - * U[1] = MOV CONST[1].-x-y-z-w - * R[0].xyz = SLT CONST[0].-x-x-x-x, U[1] - * R[0].xyz = MUL R[0], U[0] - * - * This code is stupid. Instead of having the individual calls to - * i915_emit_arith generate the moves to utemps, do it in the caller. - * This results in code like: - * - * U[1] = MOV CONST[1] - * U[0].xyz = SLT CONST[0].xxxx, U[1] - * R[0].xyz = SLT CONST[0].-x-x-x-x, U[1].-x-y-z-w - * R[0].xyz = MUL R[0], U[0] - */ - src0 = src_vector(p, &inst->SrcReg[0], program); - src1 = src_vector(p, &inst->SrcReg[1], program); - - if (GET_UREG_TYPE(src0) == REG_TYPE_CONST - && GET_UREG_TYPE(src1) == REG_TYPE_CONST) { - unsigned tmp = i915_get_utemp(p); - - i915_emit_arith(p, A0_MOV, tmp, A0_DEST_CHANNEL_ALL, 0, - src1, 0, 0); - - src1 = tmp; - } - - /* tmp = src1 < src2 */ - i915_emit_arith(p, - A0_SLT, - tmp, - flags, 0, - src0, - src1, - 0); - /* dst = src1 > src2 */ - i915_emit_arith(p, - A0_SLT, - dst, - flags, 0, - negate(src0, 1, 1, 1, 1), - negate(src1, 1, 1, 1, 1), - 0); - /* dst = tmp || dst */ - i915_emit_arith(p, - A0_ADD, - dst, - flags | A0_DEST_SATURATE, 0, - dst, - tmp, - 0); - break; - case OPCODE_SSG: dst = get_result_vector(p, inst); flags = get_result_flags(inst); |