1
0
Fork 0
forked from suyu/suyu
suyu/src/video_core
ReinUsesLisp 82c2601555 video_core: Reimplement the buffer cache
Reimplement the buffer cache using cached bindings and page level
granularity for modification tracking. This also drops the usage of
shared pointers and virtual functions from the cache.

- Bindings are cached, allowing to skip work when the game changes few
  bits between draws.
- OpenGL Assembly shaders no longer copy when a region has been modified
  from the GPU to emulate constant buffers, instead GL_EXT_memory_object
  is used to alias sub-buffers within the same allocation.
- OpenGL Assembly shaders stream constant buffer data using
  glProgramBufferParametersIuivNV, from NV_parameter_buffer_object. In
  theory this should save one hash table resolve inside the driver
  compared to glBufferSubData.
- A new OpenGL stream buffer is implemented based on fences for drivers
  that are not Nvidia's proprietary, due to their low performance on
  partial glBufferSubData calls synchronized with 3D rendering (that
  some games use a lot).
- Most optimizations are shared between APIs now, allowing Vulkan to
  cache more bindings than before, skipping unnecesarry work.

This commit adds the necessary infrastructure to use Vulkan object from
OpenGL. Overall, it improves performance and fixes some bugs present on
the old cache. There are still some edge cases hit by some games that
harm performance on some vendors, this are planned to be fixed in later
commits.
2021-02-13 02:17:22 -03:00
..
buffer_cache video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
command_classes video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
engines video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
host_shaders video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
macro video_core: Remove unnecessary enum class casting in logging messages 2020-12-07 00:41:50 -05:00
renderer_opengl video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
renderer_vulkan video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
shader video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
texture_cache video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
textures common/alignment: Rename AlignBits to AlignUpLog2 2021-01-15 04:13:33 -03:00
vulkan_common video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
cdma_pusher.cpp common/bit_util: Replace CLZ/CTZ operations with standardized ones 2021-01-15 02:15:32 -05:00
cdma_pusher.h common/bit_util: Replace CLZ/CTZ operations with standardized ones 2021-01-15 02:15:32 -05:00
CMakeLists.txt video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
compatible_formats.cpp gl_texture_cache: Avoid format views on Intel and AMD 2021-01-04 02:06:40 -03:00
compatible_formats.h gl_texture_cache: Avoid format views on Intel and AMD 2021-01-04 02:06:40 -03:00
delayed_destruction_ring.h video_core: Add a delayed destruction ring abstraction 2020-12-30 02:10:19 -03:00
dirty_flags.cpp video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
dirty_flags.h video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
dma_pusher.cpp video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
dma_pusher.h video_core: Resolve more variable shadowing scenarios 2020-12-04 16:19:09 -05:00
fence_manager.h video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
framebuffer_config.h video_core: gpu: Refactor out synchronous/asynchronous GPU implementations. 2020-12-28 16:33:48 -08:00
gpu.cpp gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
gpu.h gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
gpu_thread.cpp gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
gpu_thread.h gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
guest_driver.cpp gl_shader_cache: Rework shader cache and remove post-specializations 2020-03-09 18:40:06 -03:00
guest_driver.h video_core: Resolve more variable shadowing scenarios 2020-12-04 16:19:09 -05:00
memory_manager.cpp gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
memory_manager.h gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
query_cache.h video_core: Resolve more variable shadowing scenarios pt.3 2020-12-05 16:02:23 -05:00
rasterizer_accelerated.cpp core: memory: Move to Core::Memory namespace. 2020-04-17 00:59:28 -04:00
rasterizer_accelerated.h core: memory: Move to Core::Memory namespace. 2020-04-17 00:59:28 -04:00
rasterizer_interface.h video_core: Reimplement the buffer cache 2021-02-13 02:17:22 -03:00
renderer_base.cpp video_core: Initialize renderer with a GPU 2020-08-22 01:51:45 -03:00
renderer_base.h gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
shader_cache.h shader_cache: Make use of std::erase_if 2020-07-14 15:49:15 -04:00
shader_notify.cpp Fix style issues 2020-07-18 14:24:32 +10:00
shader_notify.h async shaders 2020-07-17 14:24:57 +10:00
surface.cpp video_core: Rewrite the texture cache 2020-12-30 03:38:50 -03:00
surface.h video_core: Rewrite the texture cache 2020-12-30 03:38:50 -03:00
video_core.cpp gpu: Report renderer errors with exceptions 2021-02-13 02:16:19 -03:00
video_core.h Frontend/GPU: Refactor context management 2020-03-24 21:03:42 -06:00