radeonsi/gfx10: simplify a streamout loop in gfx10_emit_ngg_epilogue
[mesa.git] / src / gallium / drivers / swr / swr_query.cpp
index e097790892d3e03abf88a0008b2852e9b8c36a67..ea31de630b3075199d9f1a9f4cce8ceddf42c3be 100644 (file)
@@ -23,7 +23,7 @@
 
 #include "pipe/p_defines.h"
 #include "util/u_memory.h"
-#include "os/os_time.h"
+#include "util/os_time.h"
 #include "swr_context.h"
 #include "swr_fence.h"
 #include "swr_query.h"
@@ -94,6 +94,7 @@ swr_get_query_result(struct pipe_context *pipe,
    switch (pq->type) {
    /* Booleans */
    case PIPE_QUERY_OCCLUSION_PREDICATE:
+   case PIPE_QUERY_OCCLUSION_PREDICATE_CONSERVATIVE:
       result->b = pq->result.core.DepthPassCount != 0;
       break;
    case PIPE_QUERY_GPU_FINISHED:
@@ -180,8 +181,8 @@ swr_begin_query(struct pipe_context *pipe, struct pipe_query *q)
 
       /* Only change stat collection if there are no active queries */
       if (ctx->active_queries == 0) {
-         SwrEnableStatsFE(ctx->swrContext, TRUE);
-         SwrEnableStatsBE(ctx->swrContext, TRUE);
+         ctx->api.pfnSwrEnableStatsFE(ctx->swrContext, TRUE);
+         ctx->api.pfnSwrEnableStatsBE(ctx->swrContext, TRUE);
       }
       ctx->active_queries++;
       break;
@@ -217,8 +218,8 @@ swr_end_query(struct pipe_context *pipe, struct pipe_query *q)
       /* Only change stat collection if there are no active queries */
       ctx->active_queries--;
       if (ctx->active_queries == 0) {
-         SwrEnableStatsFE(ctx->swrContext, FALSE);
-         SwrEnableStatsBE(ctx->swrContext, FALSE);
+         ctx->api.pfnSwrEnableStatsFE(ctx->swrContext, FALSE);
+         ctx->api.pfnSwrEnableStatsBE(ctx->swrContext, FALSE);
       }
 
       break;