Module: Mesa Branch: master Commit: 32182bb004923c8746803aa88d4b4505e4124b8c URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=32182bb004923c8746803aa88d4b4505e4124b8c
Author: Eric Anholt <[email protected]> Date: Wed Oct 16 12:39:07 2013 -0700 i965/fs: Fix register unspills from a reg_offset. We were clearing the reg_offset before trying to use it. Oops. Fixes glsl-fs-texture2drect with the reg spilling debug enabled. Reviewed-by: Paul Berry <[email protected]> --- src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp b/src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp index 64fb78b..0102b2e 100644 --- a/src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp @@ -677,13 +677,13 @@ fs_visitor::spill_reg(int spill_reg) if (inst->src[i].file == GRF && inst->src[i].reg == spill_reg) { int regs_read = inst->regs_read(this, i); + int subset_spill_offset = (spill_offset + + reg_size * inst->src[i].reg_offset); inst->src[i].reg = virtual_grf_alloc(regs_read); inst->src[i].reg_offset = 0; - emit_unspill(inst, inst->src[i], - spill_offset + reg_size * inst->src[i].reg_offset, - regs_read); + emit_unspill(inst, inst->src[i], subset_spill_offset, regs_read); } } _______________________________________________ mesa-commit mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/mesa-commit
