From 273d50fb84640b21230faf148a593461bd283ff8 Mon Sep 17 00:00:00 2001 From: Gert Wollny Date: Mon, 11 Aug 2025 22:19:00 +0200 Subject: [PATCH] r600/sfn: stop early when looking for ALU vec ready ops No need to continue the loop if we already know that we will skip Signed-off-by: Gert Wollny Part-of: --- src/gallium/drivers/r600/sfn/sfn_scheduler.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/r600/sfn/sfn_scheduler.cpp b/src/gallium/drivers/r600/sfn/sfn_scheduler.cpp index 5266a0147ff..f2022b9f7c6 100644 --- a/src/gallium/drivers/r600/sfn/sfn_scheduler.cpp +++ b/src/gallium/drivers/r600/sfn/sfn_scheduler.cpp @@ -1125,9 +1125,9 @@ BlockScheduler::collect_ready_alu_vec(std::list& ready, } int max_check = 0; - while (i != e && max_check++ < 64) { - if (ready.size() < 64 && (*i)->ready()) { + while (i != e && max_check++ < 64 && ready.size() < 64) { + if ((*i)->ready()) { int priority = 0; /* LDS fetches that use static offsets are usually ready ery fast, * so that they would get schedules early, and this leaves the