r600/sb: update last_cf if alu is the last clause
authorDave Airlie <airlied@redhat.com>
Wed, 10 Jan 2018 03:46:50 +0000 (03:46 +0000)
committerDave Airlie <airlied@redhat.com>
Thu, 18 Jan 2018 03:36:41 +0000 (03:36 +0000)
It's rare to have a final alu clause on normal shaders (exports)
but tess shaders write to LDS as their output, so we see some
alu clauses, and the CF_END get put in the wrong place.

This makes sure to update last_cf correctly.

Acked-By: Roland Scheidegger <sroland@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
src/gallium/drivers/r600/sb/sb_bc_finalize.cpp

index c20640e47676b490df2b75154b10783f5faf3793..2ec4db624a585518fae5b0af54463537031f9f5c 100644 (file)
@@ -266,6 +266,7 @@ void bc_finalizer::run_on(container_node* c) {
                                                }
                                        }
                                }
+                               last_cf = c;
                        } else if (n->is_fetch_inst()) {
                                finalize_fetch(static_cast<fetch_node*>(n));
                        } else if (n->is_cf_inst()) {