Mesa (master): aco/ngg: Fix exports for NGG VS and TES.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Apr 7 11:44:57 UTC 2020


Module: Mesa
Branch: master
Commit: d7b4bb3a88540cc04f3ac62d07cf1ab062b784cd
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=d7b4bb3a88540cc04f3ac62d07cf1ab062b784cd

Author: Timur Kristóf <timur.kristof at gmail.com>
Date:   Wed Apr  1 12:14:59 2020 +0200

aco/ngg: Fix exports for NGG VS and TES.

The exports in NGG VS and TES work just like VS exports,
so the assembler needs to fix these too in the same manner.

Signed-off-by: Timur Kristóf <timur.kristof at gmail.com>
Reviewed-by: Daniel Schürmann <daniel at schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3576>

---

 src/amd/compiler/aco_assembler.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/amd/compiler/aco_assembler.cpp b/src/amd/compiler/aco_assembler.cpp
index 8e89568a58b..aa6402c93b4 100644
--- a/src/amd/compiler/aco_assembler.cpp
+++ b/src/amd/compiler/aco_assembler.cpp
@@ -659,7 +659,7 @@ void fix_exports(asm_context& ctx, std::vector<uint32_t>& out, Program* program)
       {
          if ((*it)->format == Format::EXP) {
             Export_instruction* exp = static_cast<Export_instruction*>((*it).get());
-            if (program->stage & hw_vs) {
+            if (program->stage & (hw_vs | hw_ngg_gs)) {
                if (exp->dest >= V_008DFC_SQ_EXP_POS && exp->dest <= (V_008DFC_SQ_EXP_POS + 3)) {
                   exp->done = true;
                   exported = true;
@@ -749,7 +749,7 @@ unsigned emit_program(Program* program,
 {
    asm_context ctx(program);
 
-   if (program->stage & (hw_vs | hw_fs))
+   if (program->stage & (hw_vs | hw_fs | hw_ngg_gs))
       fix_exports(ctx, code, program);
 
    for (Block& block : program->blocks) {



More information about the mesa-commit mailing list