gpu: preserve finite buffer descriptors across sparse PRT holes

This commit is contained in:
nmzik
2026-10-19 05:26:41 +02:00
parent 5f29374d5b
commit e5f0ee7fc2
2 changed files with 47 additions and 1 deletions
@@ -764,7 +764,10 @@ void RenderExecutor::FindBuffers(std::span<PreparedBindings* const> stages) {
size = std::min({size, uint64_t {256} * 1024 * 1024, limit});
}
}
size = Libs::LibKernel::Memory::ClampRangeSize(address, size);
// Finite GPU descriptors can span sparse PRT holes; clamp only oversized/sentinel ranges.
if (size >= (uint64_t {1} << 30u) || descriptor.NumRecords() == UINT32_MAX) {
size = Libs::LibKernel::Memory::ClampRangeSize(address, size);
}
source = {address, size, cache.FindBuffer(address, size)};
}
}