mirror of
https://github.com/Takiiiiiiii/strato.git
synced 2025-07-17 08:46:39 +00:00
Drop size restruction bypass for frequently synced buffers
In cases where large buffers are updated every draw this could seriously increase memory usage beyond 3GB in the megabuffer.
This commit is contained in:
@ -354,8 +354,10 @@ namespace skyline::gpu {
|
||||
return BufferBinding{unifiedMegaBuffer.buffer, unifiedMegaBuffer.offset + offset, size};
|
||||
}
|
||||
|
||||
if (size > MegaBufferingDisableThreshold && sequenceNumber < FrequentlySyncedThresholdHigh)
|
||||
if (size > MegaBufferingDisableThreshold) {
|
||||
megaBufferViewAccumulatedSize += size;
|
||||
return {};
|
||||
}
|
||||
|
||||
size_t entryIdx{offset >> megaBufferTableShift};
|
||||
size_t bufferEntryOffset{entryIdx << megaBufferTableShift};
|
||||
@ -409,6 +411,7 @@ namespace skyline::gpu {
|
||||
void Buffer::unlock() {
|
||||
tag = ContextTag{};
|
||||
AllowAllBackingWrites();
|
||||
lastExecutionNumber = 0;
|
||||
mutex.unlock();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user