32 VkQueryPoolCreateInfo query_pool_info = {
33 .sType = VK_STRUCTURE_TYPE_QUERY_POOL_CREATE_INFO,
34 .queryType = VK_QUERY_TYPE_TIMESTAMP,
55 vkCmdWriteTimestamp(cmd_buf, VK_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT,
68 qboolean any_queries_used = qfalse;
74 any_queries_used = qtrue;
87 VK_QUERY_RESULT_64_BIT | VK_QUERY_RESULT_WITH_AVAILABILITY_BIT);
89 if (result != VK_SUCCESS && result != VK_NOT_READY)
91 Com_EPrintf(
"Failed call to vkGetQueryPoolResults, error code = %d\n", result);
92 any_queries_used = qfalse;
119 draw_query(
int x,
int y, qhandle_t font,
const char *enum_name,
int idx)
123 for(i = 0; i <
LENGTH(buf) - 1 && enum_name[i]; i++)
124 buf[i] = enum_name[i] ==
'_' ?
' ' : tolower(enum_name[i]);
129 snprintf(buf,
sizeof buf,
"%8.2f ms", ms);
140 font = R_RegisterFont(
"conchars");
144 #define PROFILER_DO(name, indent) \
145 draw_query(x, y, font, #name + 9, name); y += 10;
153 PROFILER_DO(PROFILER_ASVGF_DO_GRADIENT_SAMPLES, 2);
165 PROFILER_DO(PROFILER_ASVGF_RECONSTRUCT_GRADIENT, 2);