* new virtual GRF for the previous offset many registers
*/
if (split_points[reg]) {
+ assert(offset <= MAX_VGRF_SIZE);
int grf = virtual_grf_alloc(offset);
for (int k = reg - offset; k < reg; k++)
new_virtual_grf[k] = grf;
}
/* The last one gets the original register number */
+ assert(offset <= MAX_VGRF_SIZE);
virtual_grf_sizes[i] = offset;
for (int k = reg - offset; k < reg; k++)
new_virtual_grf[k] = i;
int class_sizes[BRW_MAX_MRF];
if (devinfo->gen >= 7) {
- for (class_count = 0; class_count < BRW_MAX_MRF; class_count++)
+ for (class_count = 0; class_count < MAX_VGRF_SIZE; class_count++)
class_sizes[class_count] = class_count + 1;
} else {
for (class_count = 0; class_count < 4; class_count++)
int src_size = 0;
int channels_remaining = 0;
int reg_from = -1, reg_to = -1;
- int reg_to_offset[MAX_SAMPLER_MESSAGE_SIZE];
- fs_inst *mov[MAX_SAMPLER_MESSAGE_SIZE];
- int var_to[MAX_SAMPLER_MESSAGE_SIZE];
- int var_from[MAX_SAMPLER_MESSAGE_SIZE];
+ int reg_to_offset[MAX_VGRF_SIZE];
+ fs_inst *mov[MAX_VGRF_SIZE];
+ int var_to[MAX_VGRF_SIZE];
+ int var_from[MAX_VGRF_SIZE];
foreach_block_and_inst(block, fs_inst, inst, cfg) {
if (!is_coalesce_candidate(this, inst))
reg_from = inst->src[0].reg;
src_size = virtual_grf_sizes[inst->src[0].reg];
- assert(src_size <= MAX_SAMPLER_MESSAGE_SIZE);
+ assert(src_size <= MAX_VGRF_SIZE);
assert(inst->src[0].width % 8 == 0);
channels_remaining = src_size;