NULL), inst->dst.type);
for (unsigned i = 0; i < regs_written(entry->generator); ++i) {
- vec4_instruction *copy = MOV(offset(entry->generator->dst, i),
- offset(entry->tmp, i));
+ vec4_instruction *copy =
+ MOV(byte_offset(entry->generator->dst, i * REG_SIZE),
+ byte_offset(entry->tmp, i * REG_SIZE));
copy->force_writemask_all =
entry->generator->force_writemask_all;
entry->generator->insert_after(block, copy);
assert(inst->dst.type == entry->tmp.type);
for (unsigned i = 0; i < regs_written(inst); ++i) {
- vec4_instruction *copy = MOV(offset(inst->dst, i),
- offset(entry->tmp, i));
+ vec4_instruction *copy =
+ MOV(byte_offset(inst->dst, i * REG_SIZE),
+ byte_offset(entry->tmp, i * REG_SIZE));
copy->force_writemask_all = inst->force_writemask_all;
inst->insert_before(block, copy);
}
if (inst->dst.file == VGRF) {
for (unsigned i = 0; i < regs_written(inst); i++) {
for (int c = 0; c < 4; c++)
- result_live[c] |= BITSET_TEST(
- live, var_from_reg(alloc, offset(inst->dst, i), c));
+ result_live[c] |= BITSET_TEST(live,
+ var_from_reg(alloc,
+ byte_offset(inst->dst, i * REG_SIZE), c));
}
} else {
for (unsigned c = 0; c < 4; c++)
for (unsigned i = 0; i < regs_written(inst); i++) {
for (int c = 0; c < 4; c++) {
if (inst->dst.writemask & (1 << c)) {
- BITSET_CLEAR(live, var_from_reg(alloc,
- offset(inst->dst, i), c));
+ BITSET_CLEAR(live,
+ var_from_reg(alloc,
+ byte_offset(inst->dst,
+ i * REG_SIZE),
+ c));
}
}
}
for (unsigned j = 0; j < regs_read(inst, i); j++) {
for (int c = 0; c < 4; c++) {
BITSET_SET(live, var_from_reg(alloc,
- offset(inst->src[i], j), c));
+ byte_offset(inst->src[i],
+ j * REG_SIZE),
+ c));
}
}
}
for (unsigned j = 0; j < regs_read(inst, i); j++) {
for (int c = 0; c < 4; c++) {
const unsigned v =
- var_from_reg(alloc, offset(inst->src[i], j), c);
+ var_from_reg(alloc,
+ byte_offset(inst->src[i], j * REG_SIZE),
+ c);
if (!BITSET_TEST(bd->def, v))
BITSET_SET(bd->use, v);
}
for (int c = 0; c < 4; c++) {
if (inst->dst.writemask & (1 << c)) {
const unsigned v =
- var_from_reg(alloc, offset(inst->dst, i), c);
+ var_from_reg(alloc,
+ byte_offset(inst->dst, i * REG_SIZE), c);
if (!BITSET_TEST(bd->use, v))
BITSET_SET(bd->def, v);
}
for (unsigned j = 0; j < regs_read(inst, i); j++) {
for (int c = 0; c < 4; c++) {
const unsigned v =
- var_from_reg(alloc, offset(inst->src[i], j), c);
+ var_from_reg(alloc,
+ byte_offset(inst->src[i], j * REG_SIZE), c);
start[v] = MIN2(start[v], ip);
end[v] = ip;
}
for (int c = 0; c < 4; c++) {
if (inst->dst.writemask & (1 << c)) {
const unsigned v =
- var_from_reg(alloc, offset(inst->dst, i), c);
+ var_from_reg(alloc,
+ byte_offset(inst->dst, i * REG_SIZE), c);
start[v] = MIN2(start[v], ip);
end[v] = ip;
}
inst = emit(TCS_OPCODE_SET_OUTPUT_URB_OFFSETS, dst_reg(message),
brw_imm_ud(writemask), indirect_offset);
inst->force_writemask_all = true;
- inst = emit(MOV(offset(dst_reg(retype(message, value.type)), 1), value));
+ inst = emit(MOV(byte_offset(dst_reg(retype(message, value.type)), REG_SIZE),
+ value));
inst->force_writemask_all = true;
inst = emit(TCS_OPCODE_URB_WRITE, dst_null_f(), message);
else
emit(pull);
- dst_reg index_reg = retype(offset(dst_reg(header), 1),
+ dst_reg index_reg = retype(byte_offset(dst_reg(header), REG_SIZE),
offset_reg.type);
pull = MOV(writemask(index_reg, WRITEMASK_X), offset_reg);