summaryrefslogtreecommitdiff
path: root/src/video_core/buffer_cache
diff options
context:
space:
mode:
authorGravatar Ameer J2023-10-31 20:02:11 -0400
committerGravatar Ameer J2023-10-31 20:14:18 -0400
commit75c5be55af3e0db249cb1bb0c0dd1de6e326849d (patch)
tree4b4f8f45569e08287508a681e1d1458a52975493 /src/video_core/buffer_cache
parentbuffer_cache: Apply storage buffer alignment only to the offset (diff)
downloadyuzu-75c5be55af3e0db249cb1bb0c0dd1de6e326849d.tar.gz
yuzu-75c5be55af3e0db249cb1bb0c0dd1de6e326849d.tar.xz
yuzu-75c5be55af3e0db249cb1bb0c0dd1de6e326849d.zip
shader_recompiler: Align SSBO offsets in GlobalMemory functions
Diffstat (limited to 'src/video_core/buffer_cache')
-rw-r--r--src/video_core/buffer_cache/buffer_cache.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/video_core/buffer_cache/buffer_cache.h b/src/video_core/buffer_cache/buffer_cache.h
index 5574c6130..2648970b6 100644
--- a/src/video_core/buffer_cache/buffer_cache.h
+++ b/src/video_core/buffer_cache/buffer_cache.h
@@ -1796,7 +1796,8 @@ Binding BufferCache<P>::StorageBufferBinding(GPUVAddr ssbo_addr, u32 cbuf_index,
1796 return NULL_BINDING; 1796 return NULL_BINDING;
1797 } 1797 }
1798 const std::optional<VAddr> cpu_addr = gpu_memory->GpuToCpuAddress(gpu_addr); 1798 const std::optional<VAddr> cpu_addr = gpu_memory->GpuToCpuAddress(gpu_addr);
1799 ASSERT_MSG(cpu_addr, "Unaligned storage buffer address not found for cbuf index {}", cbuf_index); 1799 ASSERT_MSG(cpu_addr, "Unaligned storage buffer address not found for cbuf index {}",
1800 cbuf_index);
1800 // The end address used for size calculation does not need to be aligned 1801 // The end address used for size calculation does not need to be aligned
1801 const VAddr cpu_end = Common::AlignUp(*cpu_addr + size, Core::Memory::YUZU_PAGESIZE); 1802 const VAddr cpu_end = Common::AlignUp(*cpu_addr + size, Core::Memory::YUZU_PAGESIZE);
1802 1803