diff options
author | Jason Ekstrand <[email protected]> | 2014-10-01 10:27:24 -0700 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2014-10-02 13:17:03 -0700 |
commit | 75986830b40d2442be3d22c25dde5d70682babef (patch) | |
tree | 62fdf091472284a00101f67d2095882d3df770cc /src/mesa | |
parent | 7309c6126f2987d703b2f30b3cb56edf97d437d3 (diff) |
i965/fs_fp: Use null_reg from fs_visitor instead of rolling our own
Signed-off-by: Jason Ekstrand <[email protected]>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=84529
Reviewed-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_fs_fp.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_fp.cpp b/src/mesa/drivers/dri/i965/brw_fs_fp.cpp index f9eec10a04b..9f0c0c7ac48 100644 --- a/src/mesa/drivers/dri/i965/brw_fs_fp.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs_fp.cpp @@ -115,8 +115,6 @@ fs_visitor::emit_fragment_program_code() { setup_fp_regs(); - fs_reg null = fs_reg(brw_null_reg()); - /* Keep a reg with 1.0 around, for reuse by emit_fp_sop so that it can just * be: * @@ -163,7 +161,7 @@ fs_visitor::emit_fragment_program_code() if (fpi->DstReg.WriteMask & (1 << i)) { fs_inst *inst; - emit(CMP(null, offset(src[0], i), fs_reg(0.0f), + emit(CMP(reg_null_f, offset(src[0], i), fs_reg(0.0f), BRW_CONDITIONAL_L)); inst = emit(BRW_OPCODE_SEL, offset(dst, i), @@ -250,8 +248,8 @@ fs_visitor::emit_fragment_program_code() * undiscarded pixels, and updates just those pixels to be * turned off. */ - fs_inst *cmp = emit(CMP(null, offset(src[0], i), fs_reg(0.0f), - BRW_CONDITIONAL_GE)); + fs_inst *cmp = emit(CMP(reg_null_f, offset(src[0], i), + fs_reg(0.0f), BRW_CONDITIONAL_GE)); cmp->predicate = BRW_PREDICATE_NORMAL; cmp->flag_subreg = 1; } @@ -283,7 +281,7 @@ fs_visitor::emit_fragment_program_code() if (fpi->DstReg.WriteMask & WRITEMASK_YZ) { fs_inst *inst; - emit(CMP(null, offset(src[0], 0), fs_reg(0.0f), + emit(CMP(reg_null_f, offset(src[0], 0), fs_reg(0.0f), BRW_CONDITIONAL_LE)); if (fpi->DstReg.WriteMask & WRITEMASK_Y) { |