summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTopi Pohjolainen <topi.pohjolainen@intel.com>2014-09-03 14:40:22 +0300
committerTopi Pohjolainen <topi.pohjolainen@intel.com>2014-11-11 11:15:03 +0200
commitb41c388eb14b3d9230267b05b00c70c391145787 (patch)
tree4e037d07345ac58a0ebf12da97d12b7d5a7997a3
parent696bc949f015c92863e9992f2eb44cdaaa322b46 (diff)
i965/fs: Prepare live interval analysis for double precision
TODO: Prevent double precision being split between push and pull. Perhaps it would be easiest just to force them into pull. Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp
index 3f295354863..9f495fc0386 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
@@ -2129,8 +2129,13 @@ fs_visitor::assign_constant_locations()
continue;
int constant_nr = inst->src[i].reg + inst->src[i].reg_offset;
- if (constant_nr >= 0 && constant_nr < (int) uniforms)
+ if (constant_nr >= 0 && constant_nr < (int) uniforms) {
is_live[constant_nr] = true;
+
+ /* Double precision constants consume two consecutive slots. */
+ if (inst->src[i].type == BRW_REGISTER_TYPE_DF)
+ is_live[constant_nr + 1] = true;
+ }
}
}