diff options
author | Rob Clark <[email protected]> | 2016-02-14 10:02:13 -0500 |
---|---|---|
committer | Rob Clark <[email protected]> | 2016-02-17 10:41:55 -0500 |
commit | 0e91dccf9cd2894e46028bac39caa54d80e39e8e (patch) | |
tree | 0893ff28facef1d038fef157cb7750f51029035b /src/gallium/drivers/freedreno/freedreno_query.h | |
parent | 9d23d7b7cb804fa554c483830685088f97c8877c (diff) |
freedreno/query: some queries don't have ->begin_query()
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_query.h')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_query.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_query.h b/src/gallium/drivers/freedreno/freedreno_query.h index c2c71da2790..1e4f45ffcd3 100644 --- a/src/gallium/drivers/freedreno/freedreno_query.h +++ b/src/gallium/drivers/freedreno/freedreno_query.h @@ -65,4 +65,16 @@ fd_query(struct pipe_query *pq) void fd_query_screen_init(struct pipe_screen *pscreen); void fd_query_context_init(struct pipe_context *pctx); +static inline bool +skip_begin_query(int type) +{ + switch (type) { + case PIPE_QUERY_TIMESTAMP: + case PIPE_QUERY_GPU_FINISHED: + return true; + default: + return false; + } +} + #endif /* FREEDRENO_QUERY_H_ */ |