Open locke-lunarg opened 1 month ago
I assigned synchronization label because of queue thread but can also be video specific.
cc @aqnuep for heads up
I don't think that GFXReconstruct supports video capture/replay, so maybe the issue lies there.
Looking at the place the issue is triggered, it does seem that the replay uses an out-of-bounds DPB slot index.
Sure, arguably we could add an additional bounds check somewhere in VVL that should solve this issue (I'll make sure to do so, although I'm surprised this could even happen, considering that there is supposed to be bounds checking for that), but the capture certainly does something illegal or the capture itself is not correct (maybe negative slot index is somehow stored in an unsigned value at some point).
I've created a repro case and it seems it confirms my suspicion that this out-of-bounds access should never occur in a normal situation, but I'll post a PR with the new test case and additional bounds-check nonetheless.
This seems like a capture/replay issue though.
I've created a PR to add more bounds-checks, but I still think this is a capture/replay issue.
Don't forget that video session objects are stateful objects, with device state, so simple capture and replay may not just work as you'd expect it, even if it does not crash the drivers.
@locke-lunarg with the bound checks, the latest VVL will probably not crash there anymore... I assume we can close this issue then?
gfxr_vk-video-enc-test-n3070 is good. But gfxrvk-video-dec-test-n3070 still crashed on `completed.set_value()of
vvl::Fence::Retire()`.
just to confirm, does gfxr_vk-video-dec-test-n3070
run back successfully without validation turned on?
Yes. For now, I just removed completed_.set_value()
to replay with vvl. It helped.
Going to add synchronization label back, it looks like there is still issue there.
Environment:
Describe the Issue Sample code: https://github.com/nvpro-samples/vk_video_samples I used gfxr to capture
vk_video_encoder
andvk_video_decoder
, and then replay. It caused on ValidationLayers. It could replay successfully if VVL is disabled.Here is the capture files. It might help to re-generate the issues easily. gfxr_vk-video-enc-test-n3070.zip gfxr_vk-video-dec-test-n3070.zip
For
vk_video_encoder
(gfxr_vk-video-enc-test-n3070): It crashed onVideoSessionDeviceState::IsSlotActive
.is_active_.size()
is 1, butslot_index
is 16. The stacksFor
vk_video_decoder
(gfxrvk-video-dec-test-n3070): It crashed on `completed.set_value()of
vvl::Fence::Retire(). The value of std::future_error is
promise_already_satisfied`.The stacks