gpr(), lt(), slots(),
max_slots(sh.get_ctx().is_cayman() ? 4 : 5),
has_mova(), uses_ar(), has_predset(), has_kill(),
- updates_exec_mask(), chan_count(), interp_param(), next_id() {
+ updates_exec_mask(), consumes_lds_oqa(), produces_lds_oqa(), chan_count(), interp_param(), next_id() {
available_slots = sh.get_ctx().has_trans ? 0x1F : 0x0F;
}
memset(slots, 0, sizeof(slots));
vmap.clear();
next_id = 0;
+ produces_lds_oqa = 0;
+ consumes_lds_oqa = 0;
has_mova = false;
uses_ar = false;
has_predset = false;
has_mova |= (flags & AF_MOVA);
has_predset |= (flags & AF_ANY_PRED);
uses_ar |= n->uses_ar();
-
+ consumes_lds_oqa |= n->consumes_lds_oq();
+ produces_lds_oqa |= n->produces_lds_oq();
if (flags & AF_ANY_PRED) {
if (n->dst[2] != NULL)
updates_exec_mask = true;
void alu_clause_tracker::reset() {
group = 0;
slot_count = 0;
+ outstanding_lds_oqa_reads = 0;
grp0.reset();
grp1.reset();
}
: sh(sh), kt(sh.get_ctx().hw_class), slot_count(),
grp0(sh), grp1(sh),
group(), clause(),
- push_exec_mask(),
+ push_exec_mask(), outstanding_lds_oqa_reads(),
current_ar(), current_pr(), current_idx() {}
void alu_clause_tracker::emit_group() {
clause->push_front(g);
+ outstanding_lds_oqa_reads += grp().get_consumes_lds_oqa();
+ outstanding_lds_oqa_reads -= grp().get_produces_lds_oqa();
slot_count += grp().slot_count();
new_group();
kt.init_clause(clause->bc);
+ assert(!outstanding_lds_oqa_reads);
assert(!current_ar);
assert(!current_pr);
bool has_kill;
bool updates_exec_mask;
+ bool consumes_lds_oqa;
+ bool produces_lds_oqa;
unsigned chan_count[4];
// param index + 1 (0 means that group doesn't refer to Params)
unsigned literal_slot_count() { return (literal_count() + 1) >> 1; };
unsigned slot_count() { return inst_count() + literal_slot_count(); }
+ bool get_consumes_lds_oqa() { return consumes_lds_oqa; }
+ bool get_produces_lds_oqa() { return produces_lds_oqa; }
alu_group_node* emit();
rp_kcache_tracker& kcache() { return kc; }
bool push_exec_mask;
+ unsigned outstanding_lds_oqa_reads;
public:
container_node conflict_nodes;