diff options
author | Kenneth Graunke <[email protected]> | 2010-10-14 14:31:54 -0700 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2010-10-14 15:59:47 -0700 |
commit | f157812bbbcf9caac1f84988e738fc9d1e051056 (patch) | |
tree | 5401c2fb05f18ec7ce53b773554aa29660ab499b /src | |
parent | 6dc204c5dc723bbf9337aa7787cd6cc309a24285 (diff) |
i965: Add support for ir_unop_round_even via the RNDE instruction.
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_eu.h | 1 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_eu_emit.c | 1 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_fs.cpp | 6 |
3 files changed, 8 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_eu.h b/src/mesa/drivers/dri/i965/brw_eu.h index c16613e3df5..7cac4a72e4a 100644 --- a/src/mesa/drivers/dri/i965/brw_eu.h +++ b/src/mesa/drivers/dri/i965/brw_eu.h @@ -820,6 +820,7 @@ ALU2(LINE) ALU2(PLN) ROUND(RNDZ) +ROUND(RNDE) #undef ALU1 #undef ALU2 diff --git a/src/mesa/drivers/dri/i965/brw_eu_emit.c b/src/mesa/drivers/dri/i965/brw_eu_emit.c index 68c6c47763b..a1fead0a4fa 100644 --- a/src/mesa/drivers/dri/i965/brw_eu_emit.c +++ b/src/mesa/drivers/dri/i965/brw_eu_emit.c @@ -700,6 +700,7 @@ ALU2(PLN) ROUND(RNDZ) +ROUND(RNDE) struct brw_instruction *brw_ADD(struct brw_compile *p, diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp index d220c79a8e4..e372f3a13da 100644 --- a/src/mesa/drivers/dri/i965/brw_fs.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs.cpp @@ -874,6 +874,9 @@ fs_visitor::visit(ir_expression *ir) case ir_unop_fract: inst = emit(fs_inst(BRW_OPCODE_FRC, this->result, op[0])); break; + case ir_unop_round_even: + emit(fs_inst(BRW_OPCODE_RNDE, this->result, op[0])); + break; case ir_binop_min: inst = emit(fs_inst(BRW_OPCODE_CMP, this->result, op[0], op[1])); @@ -3016,6 +3019,9 @@ fs_visitor::generate_code() case BRW_OPCODE_RNDD: brw_RNDD(p, dst, src[0]); break; + case BRW_OPCODE_RNDE: + brw_RNDE(p, dst, src[0]); + break; case BRW_OPCODE_RNDZ: brw_RNDZ(p, dst, src[0]); break; |