Browse Source

[vulkan] Revert "[vulkan]fix vuid 02751 (#3573)" (#3721)

Attached backtrace on PR comments

This reverts commit cdf9b556b2.

Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3721
Reviewed-by: Lizzie <lizzie@eden-emu.dev>
Reviewed-by: CamilleLaVey <camillelavey99@gmail.com>
Co-authored-by: DraVee <chimera@dravee.dev>
Co-committed-by: DraVee <chimera@dravee.dev>
xbzk/fastmem-unswizzle-kotlin-side-handling-fix
DraVee 18 hours ago
committed by crueter
parent
commit
98604d369a
No known key found for this signature in database GPG Key ID: 425ACD2D4830EBC6
  1. 8
      src/video_core/renderer_vulkan/vk_buffer_cache.cpp
  2. 5
      src/video_core/vulkan_common/vulkan_device.h

8
src/video_core/renderer_vulkan/vk_buffer_cache.cpp

@ -109,14 +109,6 @@ VkBufferView Buffer::View(u32 offset, u32 size, VideoCore::Surface::PixelFormat
// Null buffer not supported, adjust offset and size // Null buffer not supported, adjust offset and size
offset = 0; offset = 0;
size = 0; size = 0;
} else {
// Align offset down to minTexelBufferOffsetAlignment
const u32 alignment = static_cast<u32>(device->GetMinTexelBufferOffsetAlignment());
if (alignment > 1) {
const u32 aligned_offset = offset & ~(alignment - 1);
size += offset - aligned_offset;
offset = aligned_offset;
}
} }
const auto it{std::ranges::find_if(views, [offset, size, format](const BufferView& view) { const auto it{std::ranges::find_if(views, [offset, size, format](const BufferView& view) {
return offset == view.offset && size == view.size && format == view.format; return offset == view.offset && size == view.size && format == view.format;

5
src/video_core/vulkan_common/vulkan_device.h

@ -318,11 +318,6 @@ public:
return properties.properties.limits.minStorageBufferOffsetAlignment; return properties.properties.limits.minStorageBufferOffsetAlignment;
} }
/// Returns texel buffer offset alignment requirement.
VkDeviceSize GetMinTexelBufferOffsetAlignment() const {
return properties.properties.limits.minTexelBufferOffsetAlignment;
}
/// Returns the maximum range for storage buffers. /// Returns the maximum range for storage buffers.
VkDeviceSize GetMaxStorageBufferRange() const { VkDeviceSize GetMaxStorageBufferRange() const {
return properties.properties.limits.maxStorageBufferRange; return properties.properties.limits.maxStorageBufferRange;

Loading…
Cancel
Save