• Home
  • Raw
  • Download

Lines Matching refs:PhysReg

46 void add_subdword_definition(Program* program, aco_ptr<Instruction>& instr, PhysReg reg);
49 PhysReg reg;
60 assignment(PhysReg reg_, RegClass rc_) : reg(reg_), rc(rc_), assigned(-1) {} in assignment()
111 PhysReg reg;
113 PhysReg operator*() const { return reg; } in operator *()
136 PhysReg lo_;
140 PhysReg lo() const { return lo_; } in lo()
143 PhysReg hi() const { return PhysReg{lo() + size}; } in hi()
147 lo_ = PhysReg{lo_.reg() + stride}; in operator +=()
154 static PhysRegInterval from_until(PhysReg first, PhysReg end) { return {first, end - first}; } in from_until()
156 bool contains(PhysReg reg) const { return lo() <= reg && reg < hi(); } in contains()
165 PhysRegIterator end() const { return {PhysReg{lo_ + size}}; } in end()
196 return {PhysReg{256}, (unsigned)program->max_reg_demand.vgpr}; in get_reg_bounds()
198 return {PhysReg{0}, (unsigned)program->max_reg_demand.sgpr}; in get_reg_bounds()
257 const uint32_t& operator[](PhysReg index) const { return regs[index]; } in operator []()
259 uint32_t& operator[](PhysReg index) { return regs[index]; } in operator []()
264 for (PhysReg reg : reg_interval) in count_zero()
270 bool test(PhysReg start, unsigned num_bytes) in test()
272 for (PhysReg i = start; i.reg_b < start.reg_b + num_bytes; i = PhysReg(i + 1)) { in test()
287 void block(PhysReg start, RegClass rc) in block()
295 bool is_blocked(PhysReg start) in is_blocked()
307 bool is_empty_or_blocked(PhysReg start) in is_empty_or_blocked()
317 void clear(PhysReg start, RegClass rc) in clear()
345 unsigned get_id(PhysReg reg) in get_id()
351 void fill(PhysReg start, unsigned size, uint32_t val) in fill()
357 void fill_subdword(PhysReg start, unsigned num_bytes, uint32_t val) in fill_subdword()
360 for (PhysReg i = start; i.reg_b < start.reg_b + num_bytes; i = PhysReg(i + 1)) { in fill_subdword()
380 print_reg(const RegisterFile& reg_file, PhysReg reg, bool has_adjacent_variable) in print_reg()
460 std::map<PhysReg, std::pair<unsigned, unsigned>> in print_regs()
464 PhysReg reg = var.reg; in print_regs()
479 PhysReg last_reg = first_reg.advance(size_id.first - 1); in print_regs()
675 add_subdword_definition(Program* program, aco_ptr<Instruction>& instr, PhysReg reg) in add_subdword_definition()
843 PhysReg def_reg = pc.second.physReg(); in update_renames()
870 std::pair<PhysReg, bool>
884 std::pair<PhysReg, bool> res = get_reg_simple(ctx, reg_file, new_info); in get_reg_simple()
889 auto is_free = [&](PhysReg reg_index) in get_reg_simple()
894 PhysRegInterval best_gap{PhysReg{0}, UINT_MAX}; in get_reg_simple()
900 std::min(bounds.end(), std::max(PhysRegIterator{PhysReg{max_gpr + 1}}, reg_it)); in get_reg_simple()
940 best_gap = {PhysReg{best_gap.lo() + buffer}, best_gap.size - buffer}; in get_reg_simple()
965 assert(reg_file[PhysReg{entry.first}] == 0xF0000000); in get_reg_simple()
966 if (!bounds.contains({PhysReg{entry.first}, rc.size()})) in get_reg_simple()
977 reg_found = (reg_file[PhysReg{entry.first + 1}] == 0); in get_reg_simple()
980 PhysReg res{entry.first}; in get_reg_simple()
997 for (PhysReg j : reg_interval) { in find_vars()
1039 std::pair<PhysReg, bool>
1045 PhysReg reg = def_reg.lo(); in get_reg_for_create_vector_copy()
1057 return {PhysReg(), false}; in get_reg_for_create_vector_copy()
1082 return {PhysReg(), false}; in get_reg_for_create_vector_copy()
1085 return {PhysReg(), false}; in get_reg_for_create_vector_copy()
1103 std::pair<PhysReg, bool> res{PhysReg(), false}; in get_regs_for_copies()
1126 info.bounds = PhysRegInterval::from_until(PhysReg{lo}, bounds.hi()); in get_regs_for_copies()
1144 PhysReg best_pos = bounds.lo(); in get_regs_for_copies()
1161 for (PhysReg j : reg_win) { in get_regs_for_copies()
1235 std::pair<PhysReg, bool>
1254 !reg_file.test(PhysReg{op.physReg().reg()}, align(op.bytes() + op.physReg().byte(), 4))) { in get_reg_impl()
1298 for (const PhysReg j : reg_win) { in get_reg_impl()
1385 PhysReg reg) in get_reg_specified()
1388 if (reg >= PhysReg{512}) in get_reg_specified()
1413 PhysReg test_reg; in get_reg_specified()
1459 PhysReg
1461 std::vector<std::pair<Operand, Definition>>& parallelcopies, PhysReg start) in compact_relocate_vars()
1488 PhysReg next_reg = start; in compact_relocate_vars()
1489 PhysReg space_reg; in compact_relocate_vars()
1522 PhysReg first{512}; in is_mimg_vaddr_intact()
1527 PhysReg reg = ctx.assignments[op.tempId()].reg; in is_mimg_vaddr_intact()
1551 std::pair<PhysReg, bool>
1575 PhysReg reg = ctx.assignments[op.tempId()].reg; in get_reg_vector()
1592 std::pair<PhysReg, bool> res = get_reg_simple(ctx, reg_file, info); in get_reg_vector()
1593 PhysReg reg = res.first; in get_reg_vector()
1604 PhysReg
1616 PhysReg reg = affinity.reg; in get_reg()
1638 std::pair<PhysReg, bool> res; in get_reg()
1690 PhysReg space = compact_relocate_vars(ctx, vars, parallelcopies, regs.lo()); in get_reg()
1713 PhysReg
1727 PhysReg best_pos{0xFFF}; in get_reg_create_vector()
1746 PhysRegInterval reg_win = {PhysReg{reg_lower / 4}, size}; in get_reg_create_vector()
1767 for (PhysReg j : reg_win) { in get_reg_create_vector()
1770 PhysReg reg; in get_reg_create_vector()
1819 std::pair<PhysReg, bool> res = get_reg_simple(ctx, reg_file, info); in get_reg_create_vector()
1896 for (; reg >= 0 && reg_file[PhysReg{(unsigned)reg}]; reg--) in handle_pseudo()
1900 for (; reg < ctx.program->max_reg_demand.sgpr && reg_file[PhysReg{(unsigned)reg}]; reg++) in handle_pseudo()
1909 instr->pseudo().scratch_sgpr = PhysReg{(unsigned)reg}; in handle_pseudo()
1913 operand_can_use_reg(amd_gfx_level gfx_level, aco_ptr<Instruction>& instr, unsigned idx, PhysReg reg, in operand_can_use_reg()
1956 PhysReg src = ctx.assignments[operand.tempId()].reg; in get_reg_for_operand()
1957 PhysReg dst; in get_reg_for_operand()
1991 PhysReg
1997 PhysReg reg = get_reg(ctx, register_file, tmp, parallelcopy, phi); in get_reg_phi()
2073 PhysReg reg = phi->operands[0].physReg(); in get_regs_for_phis()
2113 PhysReg reg = op.physReg(); in get_regs_for_phis()
2689 PhysReg br_reg = get_reg_phi(ctx, live_out_per_block[block.index], register_file, in register_allocation()
2765 PhysReg reg = ctx.assignments[operand.tempId()].reg; in register_allocation()
2868 PhysReg reg = instr->operands[0].physReg(); in register_allocation()
2877 std::pair<PhysReg, bool> res = get_reg_simple(ctx, register_file, info); in register_allocation()
2889 PhysReg reg = instr->operands[i].physReg(); in register_allocation()
2895 PhysReg reg = instr->operands[0].physReg(); in register_allocation()
2900 PhysReg reg = get_reg_create_vector(ctx, register_file, definition->getTemp(), in register_allocation()
2909 PhysReg reg = get_reg(ctx, register_file, tmp, parallelcopy, instr); in register_allocation()
3048 PhysReg reg = get_reg(ctx, tmp_file, tmp, parallelcopy, instr); in register_allocation()