summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancisco Jerez <[email protected]>2016-09-01 22:37:57 -0700
committerFrancisco Jerez <[email protected]>2016-09-14 14:50:59 -0700
commit6d861968ca2f3e196ce4bcad4f2b91b5a63ce0f1 (patch)
tree81861bcb7cea2b5819097c2a4417cb03393690ce
parent5ca35c63673dad28854c00ce34ec6f085ba4ec5e (diff)
i965/vec4: Assert that pull constant load offsets are 16B-aligned.
Non-16B-aligned pull constant loads are unlikely to be particularly useful given that you can get roughly the same effect by using swizzles on the result. Reviewed-by: Iago Toral Quiroga <[email protected]>
-rw-r--r--src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
index c88d7b6f229..3e785bc52d9 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
@@ -1651,6 +1651,7 @@ vec4_visitor::emit_pull_constant_load(bblock_t *block, vec4_instruction *inst,
dst_reg temp, src_reg orig_src,
int base_offset, src_reg indirect)
{
+ assert(orig_src.offset % 16 == 0);
int reg_offset = base_offset + orig_src.offset / 16;
const unsigned index = prog_data->base.binding_table.pull_constants_start;