diff --git a/src/venus/vkr_common.c b/src/venus/vkr_common.c index e9c0564..1ccf1be 100644 --- a/src/venus/vkr_common.c +++ b/src/venus/vkr_common.c @@ -94,6 +94,7 @@ static const struct vn_info_extension_table vkr_extension_table = { .KHR_external_fence_fd = false, .KHR_external_memory_fd = true, /* EXT extensions */ + .EXT_calibrated_timestamps = true, .EXT_conservative_rasterization = true, .EXT_custom_border_color = true, .EXT_depth_clip_enable = true, diff --git a/src/venus/vkr_device.c b/src/venus/vkr_device.c index 4cd4f93..140b9d9 100644 --- a/src/venus/vkr_device.c +++ b/src/venus/vkr_device.c @@ -319,6 +319,20 @@ vkr_dispatch_vkDeviceWaitIdle(struct vn_dispatch_context *dispatch, vkr_cs_decoder_set_fatal(&ctx->decoder); } +static void +vkr_dispatch_vkGetCalibratedTimestampsEXT( + UNUSED struct vn_dispatch_context *ctx, + struct vn_command_vkGetCalibratedTimestampsEXT *args) +{ + struct vkr_device *dev = vkr_device_from_handle(args->device); + struct vn_device_proc_table *vk = &dev->proc_table; + + vn_replace_vkGetCalibratedTimestampsEXT_args_handle(args); + args->ret = vk->GetCalibratedTimestampsEXT(args->device, args->timestampCount, + args->pTimestampInfos, args->pTimestamps, + args->pMaxDeviation); +} + void vkr_context_init_device_dispatch(struct vkr_context *ctx) { @@ -330,4 +344,6 @@ vkr_context_init_device_dispatch(struct vkr_context *ctx) dispatch->dispatch_vkGetDeviceGroupPeerMemoryFeatures = vkr_dispatch_vkGetDeviceGroupPeerMemoryFeatures; dispatch->dispatch_vkDeviceWaitIdle = vkr_dispatch_vkDeviceWaitIdle; + dispatch->dispatch_vkGetCalibratedTimestampsEXT = + vkr_dispatch_vkGetCalibratedTimestampsEXT; } diff --git a/src/venus/vkr_physical_device.c b/src/venus/vkr_physical_device.c index d98a9b8..e56e296 100644 --- a/src/venus/vkr_physical_device.c +++ b/src/venus/vkr_physical_device.c @@ -630,6 +630,20 @@ vkr_dispatch_vkGetPhysicalDeviceExternalFenceProperties( args->physicalDevice, args->pExternalFenceInfo, args->pExternalFenceProperties); } +static void +vkr_dispatch_vkGetPhysicalDeviceCalibrateableTimeDomainsEXT( + UNUSED struct vn_dispatch_context *ctx, + struct vn_command_vkGetPhysicalDeviceCalibrateableTimeDomainsEXT *args) +{ + struct vkr_physical_device *physical_dev = + vkr_physical_device_from_handle(args->physicalDevice); + struct vn_physical_device_proc_table *vk = &physical_dev->proc_table; + + vn_replace_vkGetPhysicalDeviceCalibrateableTimeDomainsEXT_args_handle(args); + args->ret = vk->GetPhysicalDeviceCalibrateableTimeDomainsEXT( + args->physicalDevice, args->pTimeDomainCount, args->pTimeDomains); +} + void vkr_context_init_physical_device_dispatch(struct vkr_context *ctx) { @@ -679,4 +693,6 @@ vkr_context_init_physical_device_dispatch(struct vkr_context *ctx) vkr_dispatch_vkGetPhysicalDeviceExternalSemaphoreProperties; dispatch->dispatch_vkGetPhysicalDeviceExternalFenceProperties = vkr_dispatch_vkGetPhysicalDeviceExternalFenceProperties; + dispatch->dispatch_vkGetPhysicalDeviceCalibrateableTimeDomainsEXT = + vkr_dispatch_vkGetPhysicalDeviceCalibrateableTimeDomainsEXT; }