eden/src/common
CamilleLaVey 3d0eb4b5d7
[vulkan] 1st Vulkan Global Maintenance (#3839)
This pr aims to make a first step into giving Eden's Vulkan backend maintenance with better formatting, understanding and reduce the redundancy between some wrong implementations:

-> ProvokingVertex: Has been reworked completely, now the wiring to ExtendedDynamicState3 (ProvokingVertexMode) it works safe, the gating of the extension no longer requires user enabling on UI, it will be enabled automatically based on what features of the extension are available on driver, depending if first or last mode are available and also will be properly set under TrasformFeedback operations; this way we're gonna ensure all drivers, including Android stock drivers on QCOM, Mali and other mobile vendors drivers access correctly to the extension, fixing some graphical issues (flickering textures or wrong sccisors on vertex that required first mode) generated by the missing first mode handling or the proper clearing on pipeline state. This change will increase/ decrease slightly the performance on some games that changes dynamically between first and last modes, but will also ensure a clear path to GPU to use resources smartly, reducing VRAM consumption in PC and MEM/GPU percentage of use on Android (marginal to 5 - 8% approx).

-> Removal VK_EXT_multi_draw: It has passed some months since the first try to implement this feature, but wasn't completed so functionality was null to negative, taking space in source and using small CPU cicles for initialization during device creation that reduced CPU effectiveness by 2 - 5%, aside that, after reviewing the situation of formally introducing handling for multidraws to reduce the floods of constants draw calls into 1 per batch, seems to not pay the overhead when the multidraw capacity is less or equal to 1, aside that, for the time being batching multidraws will introduce indirections on each batch of command draws, that graphical issues will appear and reducing performance can happen, something it was gonna solve. For the time being it's discarded, but, may be analyzed the chance to introduce it properly in a later date.

-> Removal VK_EXT_indexing_descriptor: Currently the implementation of this feature was partial, with not proper handling on layouts; just the initial checks on device creation and chained up to the pNext feature, currently this extension will require a buffer cache and texture cache rework to set layouts and reduce the amount of use of descriptor into making it a less expensive cost effective, aside that to generate a path for the Bindless Texture and Bindless Buffer, allowing to track state of textures in runtime and ensuring the state of some compiled shaders doesn't change if it's no needed, among other benefits, besides that, enabling this feature was only generating innecessary checks on GPU, so consumption would be higher than it should be.

-> Removal of VK_EXT_swapchain_maintenance1: The use of this feature was really conditional to certain support on newer drivers and cards, which wasn't available for all platforms, I concluded that if the support for this instance wasn't really there, the cost effective between the try to initialize it and running it, won't be good as when it didn't exist on our Vulkan device, with also the constant factor of not being completely implemented, right now I'm aiming to reduce the complexity on Vulkan side to keep it as simple as it could for a future video_core rework, which may start somewhere these weeks.

-> Refined the Maintenance features: Meawhile this features are usually inherent to Vulkan core functionality, sometimes drivers doesn't expose them well, which leads to Eden run Vulkan without really noticing the existence of maintenance features on driver to improve stability, so we're tied to declare them and load them when a device creation starts by asking if driver supports and which, currently 1 - 5 are core maintenance features, meanwhile the 7 - 9 are more experimental and not being available everywhere, so right now to help drivers give attention to this features we not only load them, but also calculate with features bits which features inside Maintenance5 are available to use, that was the initial purpose, but we weren't using the full potential of the extension; I made cleaned part of the unneeded log code for the initialization of this Maintenance5 and it's feature flags, but also making an operation to sanitize depth/ stencil when One is not available in swizzle operations, making it easier to draw it; it's also needed to mention that Maintenance9 was removed from source code until we can have better handling on Arrays2D, aside that, the use of the extension was really conditional to certain drivers being capable of use it, so I remove it.

Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3839
Co-authored-by: CamilleLaVey <camillelavey99@gmail.com>
Co-committed-by: CamilleLaVey <camillelavey99@gmail.com>
2026-04-08 23:46:50 +02:00
..
android [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
arm64 Rework time service to fix time passing offline. 2024-01-24 04:26:55 +00:00
fs [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
windows [port] windows 7 support (#3105) 2025-11-30 06:04:36 +01:00
x64 [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
address_space.cpp general: Format licenses as per SPDX guidelines 2022-10-06 21:00:54 +02:00
address_space.h Move to Clang Format 15 2023-01-29 17:49:42 -07:00
address_space.inc Fix address space allocator slow path to avoid OOB 2023-05-07 15:11:16 +01:00
algorithm.h General: Fix compilation for GCC 2022-10-06 21:00:53 +02:00
alignment.h fssystem: rework for yuzu style 2023-08-15 17:47:40 -04:00
announce_multiplayer_room.h [chore] Fixed a couple memory leaks using up ~15 MB each iteration (#398) 2025-12-26 02:55:52 +01:00
assert.cpp [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
assert.h [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
atomic_ops.h [common] provide fallback for lack of atomic u128 support (#2999) 2025-11-13 13:27:32 +01:00
bit_field.h externals: Update to fmt 10 and add format_as formatter for BitField 2023-05-28 15:05:55 -04:00
bit_util.h Move to Clang Format 15 2023-01-29 17:49:42 -07:00
bounded_threadsafe_queue.h [video_core] reduce SPSC/MPSC queue contention for commands (#289) 2025-11-16 22:39:46 +01:00
cityhash.cpp chore: add missing SPDX tags 2022-04-28 18:24:11 +02:00
cityhash.h chore: add missing SPDX tags 2022-04-28 18:24:11 +02:00
CMakeLists.txt [cmake, deps] conjure common/httplib.h and remove global def for httplib macros (#3800) 2026-04-06 19:13:09 +02:00
common_funcs.h [common] Do not expose platform specific Crash() macro that is only used ever once (#2909) 2025-11-03 21:07:30 +01:00
common_types.h [tools, cmake] refactor: update/hash check scripts, use tags for some more deps, proper CPMUtil separation (#2666) 2025-10-05 03:04:53 +02:00
concepts.h [common] replace Common::(DerivedFrom, IsArithmetic, Size, ConvertibleTo, IsIntegral) with libstdc++ equivalents (#290) 2025-11-07 17:03:01 +01:00
container_hash.h container_hash: use climits 2023-03-26 10:24:33 -04:00
demangle.cpp [compat] Solaris build fixes for openssl, catch2; NetBSD build fixes (#2752) 2025-10-17 22:12:58 +02:00
demangle.h Move demangle impl to cpp 2023-01-14 05:12:41 +00:00
detached_tasks.cpp general: Silence -Wshadow{,-uncaptured-local} warnings 2023-07-18 19:31:35 -04:00
detached_tasks.h chore: make yuzu REUSE compliant 2022-07-27 12:53:49 +02:00
device_power_state.cpp Add Device Power State (Windows, Linux, Mac and Android) (#197) 2025-06-18 08:34:54 +00:00
device_power_state.h Add Device Power State (Windows, Linux, Mac and Android) (#197) 2025-06-18 08:34:54 +00:00
div_ceil.h Move to Clang Format 15 2023-01-29 17:49:42 -07:00
dynamic_library.cpp Update fmt to allow for v11 2025-04-10 01:11:22 +02:00
dynamic_library.h common: dynamic_library: Add ctor for existing handle. 2023-06-03 00:05:31 -07:00
elf.h jit: add support for relr-type relocations 2023-10-11 11:13:19 -04:00
error.cpp common: error: Fix for Android. 2023-06-03 00:05:27 -07:00
error.h chore: make yuzu REUSE compliant 2022-07-27 12:53:49 +02:00
expected.h Move to Clang Format 15 2023-01-29 17:49:42 -07:00
fiber.cpp [fiber] fix windows 11 regression with DefaultSettings due to fiber stack corruption (#3400) 2026-01-27 23:42:34 +01:00
fiber.h [common, core] remove uneeded memory indirection overhead at startup (#3306) 2026-01-16 23:39:16 +01:00
fixed_point.h [common] replace Common::(DerivedFrom, IsArithmetic, Size, ConvertibleTo, IsIntegral) with libstdc++ equivalents (#290) 2025-11-07 17:03:01 +01:00
free_region_manager.h [meta] fix license headers (#2547) 2025-09-21 21:58:59 +02:00
hash.h Refactor VideoCore to use AS sepparate from Channel. 2022-10-06 21:00:52 +02:00
heap_tracker.cpp [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
heap_tracker.h Partial revert "[common] remove HeapTracker (#3001)" (#3107) 2025-11-27 15:31:34 +01:00
hex_util.cpp chore: add missing SPDX tags 2022-04-28 18:24:11 +02:00
hex_util.h Update fmt to allow for v11 2025-04-10 01:11:22 +02:00
host_memory.cpp [ports, freebsd] remove fastmem ban (#3786) 2026-03-27 13:49:10 +01:00
host_memory.h [host_memory] remove unused fastmem fallback path (#3133) 2026-01-13 02:06:35 +01:00
httplib.h [cmake, deps] conjure common/httplib.h and remove global def for httplib macros (#3800) 2026-04-06 19:13:09 +02:00
input.h [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
intrusive_list.h common: add intrusive list type 2023-04-29 17:46:26 -04:00
intrusive_red_black_tree.h general: fixes for gcc 13 2023-04-02 19:02:04 -04:00
literals.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
log_classes.inc [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
logging.cpp [common/logging] fix android stupid ctor() init order not initializing logging first (#3719) 2026-03-12 23:16:56 +01:00
logging.h [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
lru_cache.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
lz4_compression.cpp fssystem: rework for yuzu style 2023-08-15 17:47:40 -04:00
lz4_compression.h fssystem: rework for yuzu style 2023-08-15 17:47:40 -04:00
make_unique_for_overwrite.h Move to Clang Format 15 2023-01-29 17:49:42 -07:00
math_util.h [meta] fix license headers (#2547) 2025-09-21 21:58:59 +02:00
memory_detect.cpp general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
memory_detect.h Rework time service to fix time passing offline. 2024-01-24 04:26:55 +00:00
multi_level_page_table.cpp general: Format licenses as per SPDX guidelines 2022-10-06 21:00:54 +02:00
multi_level_page_table.h General: address feedback 2022-10-06 21:00:54 +02:00
multi_level_page_table.inc general: Format licenses as per SPDX guidelines 2022-10-06 21:00:54 +02:00
overflow.h [common] replace Common::BitCast with libc++ provided one (#2774) 2025-10-22 02:56:28 +02:00
page_table.cpp [dynarmic, common] pagetable clustering (#3215) 2026-01-13 00:27:31 +01:00
page_table.h [dynarmic, common] pagetable clustering (#3215) 2026-01-13 00:27:31 +01:00
param_package.cpp [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
param_package.h [*] change all std::unordered_map and std::unordered_set into ankerl::unordered_dense::map/set variants (#3442) 2026-02-10 03:34:07 +01:00
parent_of_member.h Silence std::aligned_storage warnings as it's deprecated in C++23, 2022-09-01 16:50:41 +01:00
point.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
polyfill_thread.h [common] use libc++ provided jthread instead of in-house one (which deadlocks on FBSD 14) (#351) 2025-10-01 06:59:35 +02:00
quaternion.h chore: make yuzu REUSE compliant 2022-07-27 12:53:49 +02:00
random.cpp [android] fix crash due to ctor/dtor ordering for std::random_device being uninitialized when used in other static ctor/dtors (#3806) 2026-03-31 23:45:06 +02:00
random.h [common] unify std::random_device (#3801) 2026-03-31 20:12:41 +02:00
range_map.h [meta] fix license headers (#2547) 2025-09-21 21:58:59 +02:00
range_mutex.h smmu: use new range mutex construction for protecting counters 2024-01-31 16:38:51 +01:00
range_sets.h Common: Rename SplitRangeSet to OverlapRangeSet 2024-02-05 23:01:17 +01:00
range_sets.inc [cmake] enable clang-cl and WoA builds (#348) 2025-09-09 20:47:49 +02:00
ring_buffer.h [cmake] enable clang-cl and WoA builds (#348) 2025-09-09 20:47:49 +02:00
scm_rev.cpp.in [cmake, frontend] Fix update checker and move to self-hosted Git (#3558) 2026-02-15 20:51:05 +01:00
scm_rev.h [cmake, frontend] Fix update checker and move to self-hosted Git (#3558) 2026-02-15 20:51:05 +01:00
scope_exit.h scope_exit: Make constexpr 2024-02-19 16:00:46 +01:00
scratch_buffer.h Fix ScratchBuffer moves 2023-07-04 16:02:58 +01:00
settings.cpp [ports, freebsd] remove fastmem ban (#3786) 2026-03-27 13:49:10 +01:00
settings.h [vulkan] 1st Vulkan Global Maintenance (#3839) 2026-04-08 23:46:50 +02:00
settings_common.cpp Fix more typos 2024-01-15 23:26:53 +00:00
settings_common.h [cmake, common] allow build with -fno-rtti and /GR-, to disable gen of rtti and save some bytes in vtables (#359) 2026-02-22 03:09:03 +01:00
settings_enums.h [common, hle] add new updates Polish+Thai languages (#3587) 2026-02-23 13:39:16 +01:00
settings_input.cpp core: hid: Split SL and SR buttons 2023-11-11 21:03:15 -06:00
settings_input.h android: Input mapping 2024-02-17 12:32:33 -05:00
settings_setting.h [cmake, common] allow build with -fno-rtti and /GR-, to disable gen of rtti and save some bytes in vtables (#359) 2026-02-22 03:09:03 +01:00
signal_chain.cpp android: Add cpu bakend gui toggle 2023-11-25 00:47:28 -05:00
signal_chain.h Address some review comments 2023-11-25 00:47:35 -05:00
slot_vector.h [compat] Debian stable gcc12/clang14 compilation fixes (#2763) 2025-10-18 01:54:43 +02:00
socket_types.h ssl: Reorder inclusions 2023-07-17 15:46:24 -04:00
spin_lock.h [common] move spinlock to pure header def (#3287) 2026-01-13 04:17:27 +01:00
stb.cpp cmake: prefer system stb headers 2023-10-25 21:47:32 +02:00
stb.h cmake: prefer system stb headers 2023-10-25 21:47:32 +02:00
steady_clock.cpp [port] windows 7 support (#3105) 2025-11-30 06:04:36 +01:00
steady_clock.h steady_clock: Introduce a real time clock 2023-03-07 21:17:46 -05:00
stream.cpp general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
stream.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
string_util.cpp [common, fs] Use std::string_view instead of std::string&; inline functions that are used rarely (#330) 2025-08-27 22:21:04 +02:00
string_util.h [common, fs] include missing header introduced on #330 (#370) 2025-08-31 08:40:46 +02:00
swap.h [common] fix formatting of swapped u32_le/u64_le for BE targets (#2998) 2025-11-13 13:23:46 +01:00
thread.cpp [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
thread.h [android, core] pin core threads to logical CPUs 0-3 (#3121) 2026-02-01 01:54:59 +01:00
thread_queue_list.h chore: add missing SPDX tags 2022-04-28 18:24:11 +02:00
thread_worker.h [common] use libc++ provided jthread instead of in-house one (which deadlocks on FBSD 14) (#351) 2025-10-01 06:59:35 +02:00
threadsafe_queue.h [common] use libc++ provided jthread instead of in-house one (which deadlocks on FBSD 14) (#351) 2025-10-01 06:59:35 +02:00
time_zone.cpp [common/logging] Simplify logging logic and fix issues when logging before system is created (#3688) 2026-03-12 18:29:15 +01:00
time_zone.h common: Move system time zone string detection 2023-06-05 15:15:11 -04:00
tiny_mt.h [common] unify std::random_device (#3801) 2026-03-31 20:12:41 +02:00
tree.h [common] Use U8 for colour of RB-tree instead of integer to save space (#228) 2025-08-15 23:21:15 +02:00
typed_address.h Update fmt to allow for v11 2025-04-10 01:11:22 +02:00
uint128.h [meta] fix license headers (#2547) 2025-09-21 21:58:59 +02:00
unique_function.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
uuid.cpp [common] unify std::random_device (#3801) 2026-03-31 20:12:41 +02:00
uuid.h [desktop, core] yuzu -> Eden, eden -> Eden 2025-07-19 00:12:21 -04:00
vector_math.h [vector_math]: Use NEON intrinsics in Vec4 dot operation (#177) 2025-08-02 01:48:04 +02:00
virtual_buffer.cpp [compat] HaikuOS port (#2805) 2025-10-22 04:53:40 +02:00
virtual_buffer.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00
wall_clock.cpp [common, core] remove uneeded memory indirection overhead at startup (#3306) 2026-01-16 23:39:16 +01:00
wall_clock.h [common, core] remove uneeded memory indirection overhead at startup (#3306) 2026-01-16 23:39:16 +01:00
zstd_compression.cpp zstd: Use ZSTD_getFrameContentSize instead of ZSTD_getDecompressedSize 2023-03-23 22:16:20 -04:00
zstd_compression.h general: Convert source file copyright comments over to SPDX 2022-04-23 05:55:32 -04:00