[PR #307] [MERGED] Surface management rework (1/3) #1470

Closed
opened 2026-02-27 21:12:42 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/shadps4-emu/shadPS4/pull/307
Author: @psucien
Created: 7/19/2024
Status: Merged
Merged: 7/20/2024
Merged by: @raphaelthegreat

Base: mainHead: amdgpu/surface_params


📝 Commits (7)

  • 9649d9f amdgpu: proper CB and DB sizes calculation; minor refactoring
  • e8302ed texture_cache: separate file for image_info
  • 1cea273 texture_cache: image guest address moved into image info
  • 3b8efa6 texture_cache: surface size calculation
  • 9c49844 shader_recompiler: fixed sin/cos
  • f3338e7 initial preparations for subresources upload
  • 5a6d887 review comments

📊 Changes

21 files changed (+467 additions, -233 deletions)

View changed files

📝 CMakeLists.txt (+2 -0)
📝 src/core/libraries/videoout/buffer.h (+0 -1)
📝 src/core/libraries/videoout/driver.cpp (+0 -2)
📝 src/shader_recompiler/backend/spirv/emit_spirv_floating_point.cpp (+2 -2)
📝 src/shader_recompiler/backend/spirv/spirv_emit_context.cpp (+7 -2)
📝 src/shader_recompiler/backend/spirv/spirv_emit_context.h (+2 -0)
📝 src/video_core/amdgpu/liverpool.h (+36 -9)
📝 src/video_core/amdgpu/resource.h (+24 -9)
📝 src/video_core/renderer_vulkan/liverpool_to_vk.cpp (+1 -1)
📝 src/video_core/renderer_vulkan/renderer_vulkan.cpp (+2 -1)
📝 src/video_core/renderer_vulkan/renderer_vulkan.h (+2 -2)
📝 src/video_core/renderer_vulkan/vk_compute_pipeline.cpp (+1 -1)
📝 src/video_core/renderer_vulkan/vk_graphics_pipeline.cpp (+1 -1)
📝 src/video_core/renderer_vulkan/vk_rasterizer.cpp (+5 -4)
📝 src/video_core/texture_cache/image.cpp (+2 -107)
📝 src/video_core/texture_cache/image.h (+2 -43)
src/video_core/texture_cache/image_info.cpp (+268 -0)
src/video_core/texture_cache/image_info.h (+61 -0)
📝 src/video_core/texture_cache/texture_cache.cpp (+35 -30)
📝 src/video_core/texture_cache/texture_cache.h (+11 -10)

...and 1 more files

📄 Description

This PR brings correct calculation of tiled subresources memory footprint, which allows use of this information for proper mips upload and simplified detiling pass.
Also addresses an issue with sin/cos found in a meanwhile.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/shadps4-emu/shadPS4/pull/307 **Author:** [@psucien](https://github.com/psucien) **Created:** 7/19/2024 **Status:** ✅ Merged **Merged:** 7/20/2024 **Merged by:** [@raphaelthegreat](https://github.com/raphaelthegreat) **Base:** `main` ← **Head:** `amdgpu/surface_params` --- ### 📝 Commits (7) - [`9649d9f`](https://github.com/shadps4-emu/shadPS4/commit/9649d9f0df7ee7ddcf11fdc5d962d562888c9112) amdgpu: proper CB and DB sizes calculation; minor refactoring - [`e8302ed`](https://github.com/shadps4-emu/shadPS4/commit/e8302ed5e8af86973cb022f3e39d53029cec8b82) texture_cache: separate file for image_info - [`1cea273`](https://github.com/shadps4-emu/shadPS4/commit/1cea273eb70fc730877499052482181b632a312c) texture_cache: image guest address moved into image info - [`3b8efa6`](https://github.com/shadps4-emu/shadPS4/commit/3b8efa608d01424cb27beb08bfc8f547a26e1c1b) texture_cache: surface size calculation - [`9c49844`](https://github.com/shadps4-emu/shadPS4/commit/9c498441078690bb0607316a21bfd7ed4bed526f) shader_recompiler: fixed sin/cos - [`f3338e7`](https://github.com/shadps4-emu/shadPS4/commit/f3338e70807f66df53d7e7adf71245947a743520) initial preparations for subresources upload - [`5a6d887`](https://github.com/shadps4-emu/shadPS4/commit/5a6d8878ae82cdde26dc29413117aa0c5dc6bf97) review comments ### 📊 Changes **21 files changed** (+467 additions, -233 deletions) <details> <summary>View changed files</summary> 📝 `CMakeLists.txt` (+2 -0) 📝 `src/core/libraries/videoout/buffer.h` (+0 -1) 📝 `src/core/libraries/videoout/driver.cpp` (+0 -2) 📝 `src/shader_recompiler/backend/spirv/emit_spirv_floating_point.cpp` (+2 -2) 📝 `src/shader_recompiler/backend/spirv/spirv_emit_context.cpp` (+7 -2) 📝 `src/shader_recompiler/backend/spirv/spirv_emit_context.h` (+2 -0) 📝 `src/video_core/amdgpu/liverpool.h` (+36 -9) 📝 `src/video_core/amdgpu/resource.h` (+24 -9) 📝 `src/video_core/renderer_vulkan/liverpool_to_vk.cpp` (+1 -1) 📝 `src/video_core/renderer_vulkan/renderer_vulkan.cpp` (+2 -1) 📝 `src/video_core/renderer_vulkan/renderer_vulkan.h` (+2 -2) 📝 `src/video_core/renderer_vulkan/vk_compute_pipeline.cpp` (+1 -1) 📝 `src/video_core/renderer_vulkan/vk_graphics_pipeline.cpp` (+1 -1) 📝 `src/video_core/renderer_vulkan/vk_rasterizer.cpp` (+5 -4) 📝 `src/video_core/texture_cache/image.cpp` (+2 -107) 📝 `src/video_core/texture_cache/image.h` (+2 -43) ➕ `src/video_core/texture_cache/image_info.cpp` (+268 -0) ➕ `src/video_core/texture_cache/image_info.h` (+61 -0) 📝 `src/video_core/texture_cache/texture_cache.cpp` (+35 -30) 📝 `src/video_core/texture_cache/texture_cache.h` (+11 -10) _...and 1 more files_ </details> ### 📄 Description This PR brings correct calculation of tiled subresources memory footprint, which allows use of this information for proper mips upload and simplified detiling pass. Also addresses an issue with sin/cos found in a meanwhile. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 21:12:42 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shadPS4#1470
No description provided.