Audit mid-flight waitIdleForShutdown sites for bounded semantics #14
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
[claude 2026-04-18] Opened as follow-up to
ab6c92f0(Vulkan bounded waits).The bounded-waits work migrated all 14 deviceWaitIdle / queueWaitIdle
sites to vk_sync.waitIdleForShutdown (which wraps vkd.deviceWaitIdle
with an unbounded wait and swallows errors to a log line). This
preserved existing behavior while satisfying the grep gate.
However, five of those sites are mid-flight or hot-ish paths — not
shutdown drains — where the driver could wedge exactly the way
ab6c92f0documented:All wait unbounded while the driver may be wedged. If the hang mode
from
ab6c92f0fires during a resize, scale change, or initial atlasupload, we'll freeze again with the same symptoms.
Scope of this ticket:
The fence-based emulation: submit a no-op to the graphics queue,
wait on its fence with a timeout. Return error.VkWaitTimeout on
timeout.
to waitIdleBounded; handle the new timeout error in each caller.
vk_sync.waitIdleForShutdown(self.vkd, self.device);— needs a queue-bounded helper or equivalent fence-based pattern to surface DeviceLost during init).waitIdleForShutdown — those are correct as-is.
Priority: low. The NVIDIA 595 driver flake observed on 2026-04-18
was a fence-wait wedge in drawCells, not a resize/scale wedge.
Resize/scale/init paths have not been observed to hang. File so the
work isn't lost.
Migrated from git-collab issue
0e342b6e65577b240fa92a8b633511a4fa41bf59.Original author: a73x dev@a73x.sh.