diff options
author | Francisco Jerez <currojerez@riseup.net> | 2015-03-18 20:49:43 +0200 |
---|---|---|
committer | Francisco Jerez <currojerez@riseup.net> | 2015-03-23 14:52:49 +0200 |
commit | e6e655ef76bb22193b31af2841cb50fda0c39461 (patch) | |
tree | fc4e0ffd090942398d4689fc6358825d30f6cea4 /src/mesa/drivers/dri/i965/brw_vec4_cse.cpp | |
parent | eddb87402ea7ce68357a3d93b0dbb41857be27f6 (diff) | |
download | external_mesa3d-e6e655ef76bb22193b31af2841cb50fda0c39461.zip external_mesa3d-e6e655ef76bb22193b31af2841cb50fda0c39461.tar.gz external_mesa3d-e6e655ef76bb22193b31af2841cb50fda0c39461.tar.bz2 |
i965/vec4: Define helpers to calculate the common live interval of a range of variables.
These will be especially useful when we start keeping track of
liveness information for each subregister.
Reviewed-by: Matt Turner <mattst88@gmail.com>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_vec4_cse.cpp')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4_cse.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_cse.cpp b/src/mesa/drivers/dri/i965/brw_vec4_cse.cpp index 489248e..100e511 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_cse.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_cse.cpp @@ -232,13 +232,7 @@ vec4_visitor::opt_cse_local(bblock_t *block) * more -- a sure sign they'll fail operands_match(). */ if (src->file == GRF) { - assert((unsigned)(src->reg * 4 + 3) < (alloc.count * 4)); - - int last_reg_use = MAX2(MAX2(virtual_grf_end[src->reg * 4 + 0], - virtual_grf_end[src->reg * 4 + 1]), - MAX2(virtual_grf_end[src->reg * 4 + 2], - virtual_grf_end[src->reg * 4 + 3])); - if (last_reg_use < ip) { + if (var_range_end(var_from_reg(alloc, *src), 4) < ip) { entry->remove(); ralloc_free(entry); break; |