Mesa (master): llvmpipe/setup: move line stats collection earlier.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Apr 15 04:49:32 UTC 2020


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

Author: Dave Airlie <airlied at redhat.com>
Date:   Fri Apr 10 10:15:50 2020 +1000

llvmpipe/setup: move line stats collection earlier.

You have to count the stats pre-culling here.

Fixes:
KHR-GL45.pipeline_statistics_query_tests_ARB.functional_primitives_vertices_submitted_and_clipping_input_output_primitives

Reviewed-by: Roland Scheidegger <sroland at vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4560>

---

 src/gallium/drivers/llvmpipe/lp_setup_line.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/gallium/drivers/llvmpipe/lp_setup_line.c b/src/gallium/drivers/llvmpipe/lp_setup_line.c
index 5e26b1e9ffc..3a7212326e3 100644
--- a/src/gallium/drivers/llvmpipe/lp_setup_line.c
+++ b/src/gallium/drivers/llvmpipe/lp_setup_line.c
@@ -320,6 +320,10 @@ try_setup_line( struct lp_setup_context *setup,
    boolean will_draw_start;
    boolean will_draw_end;
 
+   if (lp_context->active_statistics_queries) {
+      lp_context->pipeline_statistics.c_primitives++;
+   }
+
    if (0)
       print_line(setup, v1, v2);
 
@@ -616,10 +620,6 @@ try_setup_line( struct lp_setup_context *setup,
 
    LP_COUNT(nr_tris);
 
-   if (lp_context->active_statistics_queries) {
-      lp_context->pipeline_statistics.c_primitives++;
-   }
-
    /* calculate the deltas */
    plane = GET_PLANES(line);
    plane[0].dcdy = x[0] - x[1];



More information about the mesa-commit mailing list