Lines Matching refs:sq

59    struct softpipe_query* sq;  in softpipe_create_query()  local
74 sq = CALLOC_STRUCT( softpipe_query ); in softpipe_create_query()
75 sq->type = type; in softpipe_create_query()
77 return (struct pipe_query *)sq; in softpipe_create_query()
92 struct softpipe_query *sq = softpipe_query(q); in softpipe_begin_query() local
94 switch (sq->type) { in softpipe_begin_query()
98 sq->start = softpipe->occlusion_count; in softpipe_begin_query()
101 sq->start = os_time_get_nano(); in softpipe_begin_query()
104 sq->so.num_primitives_written = softpipe->so_stats.num_primitives_written; in softpipe_begin_query()
105 sq->so.primitives_storage_needed = softpipe->so_stats.primitives_storage_needed; in softpipe_begin_query()
109 sq->so.num_primitives_written = softpipe->so_stats.num_primitives_written; in softpipe_begin_query()
110 sq->so.primitives_storage_needed = softpipe->so_stats.primitives_storage_needed; in softpipe_begin_query()
113 sq->so.num_primitives_written = softpipe->so_stats.num_primitives_written; in softpipe_begin_query()
116 sq->so.primitives_storage_needed = softpipe->so_stats.primitives_storage_needed; in softpipe_begin_query()
128 memcpy(&sq->stats, &softpipe->pipeline_statistics, in softpipe_begin_query()
129 sizeof(sq->stats)); in softpipe_begin_query()
146 struct softpipe_query *sq = softpipe_query(q); in softpipe_end_query() local
149 switch (sq->type) { in softpipe_end_query()
153 sq->end = softpipe->occlusion_count; in softpipe_end_query()
156 sq->start = 0; in softpipe_end_query()
159 sq->end = os_time_get_nano(); in softpipe_end_query()
163 sq->so.num_primitives_written = in softpipe_end_query()
164 softpipe->so_stats.num_primitives_written - sq->so.num_primitives_written; in softpipe_end_query()
165 sq->so.primitives_storage_needed = in softpipe_end_query()
166 softpipe->so_stats.primitives_storage_needed - sq->so.primitives_storage_needed; in softpipe_end_query()
167 sq->end = sq->so.primitives_storage_needed > sq->so.num_primitives_written; in softpipe_end_query()
170 sq->so.num_primitives_written = in softpipe_end_query()
171 softpipe->so_stats.num_primitives_written - sq->so.num_primitives_written; in softpipe_end_query()
172 sq->so.primitives_storage_needed = in softpipe_end_query()
173 softpipe->so_stats.primitives_storage_needed - sq->so.primitives_storage_needed; in softpipe_end_query()
176 sq->so.num_primitives_written = in softpipe_end_query()
177 softpipe->so_stats.num_primitives_written - sq->so.num_primitives_written; in softpipe_end_query()
180 sq->so.primitives_storage_needed = in softpipe_end_query()
181 softpipe->so_stats.primitives_storage_needed - sq->so.primitives_storage_needed; in softpipe_end_query()
187 sq->stats.ia_vertices = in softpipe_end_query()
188 softpipe->pipeline_statistics.ia_vertices - sq->stats.ia_vertices; in softpipe_end_query()
189 sq->stats.ia_primitives = in softpipe_end_query()
190 softpipe->pipeline_statistics.ia_primitives - sq->stats.ia_primitives; in softpipe_end_query()
191 sq->stats.vs_invocations = in softpipe_end_query()
192 softpipe->pipeline_statistics.vs_invocations - sq->stats.vs_invocations; in softpipe_end_query()
193 sq->stats.gs_invocations = in softpipe_end_query()
194 softpipe->pipeline_statistics.gs_invocations - sq->stats.gs_invocations; in softpipe_end_query()
195 sq->stats.gs_primitives = in softpipe_end_query()
196 softpipe->pipeline_statistics.gs_primitives - sq->stats.gs_primitives; in softpipe_end_query()
197 sq->stats.c_invocations = in softpipe_end_query()
198 softpipe->pipeline_statistics.c_invocations - sq->stats.c_invocations; in softpipe_end_query()
199 sq->stats.c_primitives = in softpipe_end_query()
200 softpipe->pipeline_statistics.c_primitives - sq->stats.c_primitives; in softpipe_end_query()
201 sq->stats.ps_invocations = in softpipe_end_query()
202 softpipe->pipeline_statistics.ps_invocations - sq->stats.ps_invocations; in softpipe_end_query()
221 struct softpipe_query *sq = softpipe_query(q); in softpipe_get_query_result() local
224 switch (sq->type) { in softpipe_get_query_result()
228 stats->num_primitives_written = sq->so.num_primitives_written; in softpipe_get_query_result()
229 stats->primitives_storage_needed = sq->so.primitives_storage_needed; in softpipe_get_query_result()
233 memcpy(vresult, &sq->stats, in softpipe_get_query_result()
241 vresult->b = sq->end != 0; in softpipe_get_query_result()
252 *result = sq->so.num_primitives_written; in softpipe_get_query_result()
255 *result = sq->so.primitives_storage_needed; in softpipe_get_query_result()
259 vresult->b = sq->end - sq->start != 0; in softpipe_get_query_result()
262 *result = sq->end - sq->start; in softpipe_get_query_result()