aco: add pending_lds_access option for insert waitcnt
For tcs epilog to add p_barrier at the beginning to sync main shader part tess factor LDS write. Reviewed-by: Rhys Perry <pendingchaos02@gmail.com> Signed-off-by: Qiang Yu <yuq825@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24442>
This commit is contained in:
@@ -1049,6 +1049,11 @@ insert_wait_states(Program* program)
|
||||
std::stack<unsigned, std::vector<unsigned>> loop_header_indices;
|
||||
unsigned loop_progress = 0;
|
||||
|
||||
if (program->pending_lds_access) {
|
||||
update_barrier_imm(in_ctx[0], get_counters_for_event(event_lds), event_lds,
|
||||
memory_sync_info(storage_shared));
|
||||
}
|
||||
|
||||
for (Definition def : program->args_pending_vmem) {
|
||||
update_counters(in_ctx[0], event_vmem);
|
||||
insert_wait_entry(in_ctx[0], def, event_vmem);
|
||||
|
||||
@@ -2145,6 +2145,9 @@ public:
|
||||
|
||||
std::vector<Definition> args_pending_vmem;
|
||||
|
||||
/* For shader part with previous shader part that has lds access. */
|
||||
bool pending_lds_access = false;
|
||||
|
||||
struct {
|
||||
FILE* output = stderr;
|
||||
bool shorten_messages = false;
|
||||
|
||||
Reference in New Issue
Block a user