Open Goshido opened 3 months ago
@Goshido there is a limitation to the amount of information that can be provided for the prior_usage
access, but it should be possible to provide resource information for the submitted_usage
.
Quick investigation: It turns out that 3 VkBuffer
do not have proper sync. Here is compute shader snippet for them:
[[vk::binding ( BIND_SYNC_MIP_5, SET_RESOURCE )]]
globallycoherent RWTexture2D<float32_t> g_syncMip5: register ( u0 );
[[vk::binding ( BIND_EXPOSURE, SET_RESOURCE )]]
RWStructuredBuffer<float32_t> g_exposure: register ( u1 );
[[vk::binding ( BIND_GLOBAL_ATOMIC, SET_RESOURCE )]]
globallycoherent RWStructuredBuffer<uint32_t> g_globalAtomic: register ( u2 );
[[vk::binding ( BIND_TEMPORAL_LUMA, SET_RESOURCE )]]
RWStructuredBuffer<float32_t> g_temporalLuma: register ( u3 );
@artem-lunarg could I expect an improvement or it's super strong limitation for VVL architecture?
I'll try to add resource information to submitted_usage
, does not look hard except I missed something. Adding more information to prior_usage
is much harder, this requires to store a lot of information. We plan improvements, but there might be a tendency that current access information is more detailed compared to the previous access.
Great! I gonna wait. Thx 👍
@Goshido Going to postpone the fix. Doable, but need to update memory allocation scheme first.
Implementation note: instead of allocating handle array per usage record, allocate single buffer per command buffer context and store only index/count in the usage record. This will avoid performance impact from large number of allocations. Memory wise single buffer solution is easy to manage (e.g. disable storing handles when memory is a concern) and easy to collect stats.
@Goshido Support is added here https://github.com/KhronosGroup/Vulkan-ValidationLayers/pull/8222. Currently it's buffers only, images will be later after we test current solution for a bit.
Awesome 👍
Environment:
15ba84ba94ff2ed473474deba2b4f2af4705b1fb
VK_VALIDATION_FEATURE_ENABLE_BEST_PRACTICES_EXT
andVK_VALIDATION_FEATURE_ENABLE_SYNCHRONIZATION_VALIDATION_EXT
Describe the Issue
Is it normal that sync validation does not provide description which kind of resource is not synchronized? I mean
VkImage
orVkBuffer
. I gave meaningful names to each Vulkan resource in the app. The typical message looks like this:Expected behavior
Validation warning contains resource type and name.
Valid Usage ID N/A