From e4da482d9e94c2ca5935c8cbb864287aa192778a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Timur=20Krist=C3=B3f?= Date: Wed, 1 Apr 2020 16:02:13 +0200 Subject: [PATCH] aco/ngg: Schedule position exports of NGG VS/TES. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Similarly to the HW VS stage, the HW NGG GS stage also benefits from executing these exports as early as possible. Signed-off-by: Timur Kristóf Reviewed-by: Daniel Schürmann Part-of: --- src/amd/compiler/aco_scheduler.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/amd/compiler/aco_scheduler.cpp b/src/amd/compiler/aco_scheduler.cpp index d7cf90be189..d07b4e381ab 100644 --- a/src/amd/compiler/aco_scheduler.cpp +++ b/src/amd/compiler/aco_scheduler.cpp @@ -843,7 +843,7 @@ void schedule_block(sched_ctx& ctx, Program *program, Block* block, live& live_v } } - if ((program->stage & hw_vs) && block->index == program->blocks.size() - 1) { + if ((program->stage & (hw_vs | hw_ngg_gs)) && (block->kind & block_kind_export_end)) { /* Try to move position exports as far up as possible, to reduce register * usage and because ISA reference guides say so. */ for (unsigned idx = 0; idx < block->instructions.size(); idx++) { -- 2.30.2