|
|
|
@ -1892,9 +1892,13 @@ bool BufferCache<P>::IntersectsInPlaceWrites(DAddr device_addr, u64 size) { |
|
|
|
template <class P> |
|
|
|
void BufferCache<P>::WaitForInPlaceWrites() { |
|
|
|
if constexpr (!IS_OPENGL) { |
|
|
|
if (in_place_write_tick > runtime.KnownGpuTick()) { |
|
|
|
runtime.Wait(in_place_write_tick); |
|
|
|
if (in_place_write_tick <= in_place_host_available_tick) { |
|
|
|
return; |
|
|
|
} |
|
|
|
runtime.UnifiedMemoryWriteBarrier(); |
|
|
|
const u64 barrier_tick = runtime.CurrentTick(); |
|
|
|
runtime.Wait(barrier_tick); |
|
|
|
in_place_host_available_tick = barrier_tick; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|