paradigm
paradigm copied to clipboard
[non-fatal][recovers] Trashing of GPU memory due to syncing
Severity: High (causes non-fatal issue, and recovers next frame)
Issue: GPU memory can get trashed when realloc happens in a buffer when, in a single frame, range A moves, followed by range B reallocs onto the old range A location. This results in a frame where the affected commands interacting with that region of memory can get incorrect results (f.e. in the case of rendering geometry, usually a "jitter" is observed). This recovers the next frame as the correct offsets are recorded.
Possible resolution:
Implement a mechanism to mark regions of memory as locked
while they are in flight, deferring their dealloc. Let these locks be attached to preferably a user controllable solution, so that we can solve this using fences for this instance, and potentially barriers/others in case of other user defined use cases.