summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_vulkan/wrapper.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #4204 from ReinUsesLisp/vulkan-1.0bunnei2020-10-191-1/+3
|\ | | | | renderer_vulkan: Create and properly use Vulkan 1.0 instances when 1.1 is not available
| * renderer_vulkan: Create a Vulkan 1.0 instance when 1.1 is not availableReinUsesLisp2020-08-201-1/+3
| | | | | | | | | | This commit doesn't make yuzu compatible with Vulkan 1.0 yet, it only creates an 1.0 instance.
* | renderer_vulkan: Make unconditional use of VK_KHR_timeline_semaphoreReinUsesLisp2020-09-191-3/+45
|/ | | | | | | | | | | | | | | | | | | | | | | This reworks how host<->device synchronization works on the Vulkan backend. Instead of "protecting" resources with a fence and signalling these as free when the fence is known to be signalled by the host GPU, use timeline semaphores. Vulkan timeline semaphores allow use to work on a subset of D3D12 fences. As far as we are concerned, timeline semaphores are a value set by the host or the device that can be waited by either of them. Taking advantange of this, we can have a monolithically increasing atomic value for each submission to the graphics queue. Instead of protecting resources with a fence, we simply store the current logical tick (the atomic value stored in CPU memory). When we want to know if a resource is free, it can be compared to the current GPU tick. This greatly simplifies resource management code and the free status of resources should have less false negatives. To workaround bugs in validation layers, when these are attached there's a thread waiting for timeline semaphores.
* Vk Async pipeline compilationameerj2020-08-161-1/+1
|
* General: Tidy up clang-format warnings part 2Lioncash2020-08-131-14/+14
|
* Merge pull request #4150 from ReinUsesLisp/dynamic-state-implbunnei2020-07-071-0/+54
|\ | | | | vulkan: Use VK_EXT_extended_dynamic_state when available
| * renderer_vulkan/wrapper: Add VK_EXT_extended_dynamic_state functionsReinUsesLisp2020-06-271-0/+54
| |
* | renderer_vulkan: Update validation layer name and test before enablingReinUsesLisp2020-06-221-0/+4
|/ | | | | | | Update validation layer string to VK_LAYER_KHRONOS_validation. While we are at it, properly check for available validation layers before enabling them.
* vulkan/wrapper: Remove noexcept from GetSurfaceCapabilitiesKHR()Lioncash2020-06-201-1/+1
| | | | | | | Check() can throw an exception if the Vulkan result isn't successful. We remove the check so that std::terminate isn't outright called and allows for better debugging (should it ever actually fail).
* {maxwell_3d,buffer_cache}: Implement memory barriers using 3D registersReinUsesLisp2020-04-281-0/+10
| | | | | | | | | | | | | Drop MemoryBarrier from the buffer cache and use Maxwell3D's register WaitForIdle. To implement this on OpenGL we just call glMemoryBarrier with the necessary bits. Vulkan lacks this synchronization primitive, so we set an event and immediately wait for it. This is not a pretty solution, but it's what Vulkan can do without submitting the current command buffer to the queue (which ends up being more expensive on the CPU).
* Merge pull request #3677 from FernandoS27/better-syncbunnei2020-04-231-0/+20
|\ | | | | Introduce Predictive Flushing and Improve ASYNC GPU
| * vk_fence_manager: Initial implementationReinUsesLisp2020-04-221-0/+20
| |
* | renderer_vulkan: Integrate Nvidia Nsight Aftermath on WindowsReinUsesLisp2020-04-141-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds optional support for Nsight Aftermath. It is enabled through ENABLE_NSIGHT_AFTERMATH in cmake. A path to the SDK has to be provided by the environment variable NSIGHT_AFTERMATH_SDK. Nsight Aftermath allows an application to generate "minidumps" of the GPU state when a device loss happens. By analysing these on Nsight we can know what a game was doing and why it triggered a device loss. The dump is generated inside %APPDATA%\yuzu\log\gpucrash and this directory is deleted every time a new instance is initialized with Nsight enabled. To enable it on yuzu there has a to be a driver and device capable of running Nsight Aftermath on Vulkan. That means only Turing based GPUs on the latest stable driver, beta drivers won't work for now. It is manually enabled in Configuration>Debug>Enable Graphics Debugging because when using all debugging capabilities there is a runtime cost.
* | renderer_vulkan: Remove Nvidia checkpointsReinUsesLisp2020-04-131-6/+0
| |
* | renderer_vulkan: Catch device losses in more placesReinUsesLisp2020-04-131-18/+7
|/
* renderer_vulkan/wrapper: Add vkEnumerateInstanceExtensionProperties wrapperReinUsesLisp2020-04-011-0/+3
|
* renderer_vulkan/wrapper: Add command buffer handleReinUsesLisp2020-04-011-0/+192
|
* renderer_vulkan/wrapper: Add physical device handleReinUsesLisp2020-04-011-0/+40
|
* renderer_vulkan/wrapper: Add device handleReinUsesLisp2020-04-011-0/+95
|
* renderer_vulkan/wrapper: Add swapchain handleReinUsesLisp2020-04-011-0/+7
|
* renderer_vulkan/wrapper: Add fence handleReinUsesLisp2020-04-011-0/+17
|
* renderer_vulkan/wrapper: Add device memory handleReinUsesLisp2020-04-011-0/+15
|
* renderer_vulkan/wrapper: Add pool handlesReinUsesLisp2020-04-011-0/+15
|
* renderer_vulkan/wrapper: Add buffer and image handlesReinUsesLisp2020-04-011-0/+16
|
* renderer_vulkan/wrapper: Add queue handleReinUsesLisp2020-04-011-0/+25
|
* renderer_vulkan/wrapper: Add instance handleReinUsesLisp2020-04-011-0/+17
|
* renderer_vulkan/wrapper: Address feedbackReinUsesLisp2020-03-281-3/+24
|
* renderer_vulkan/wrapper: Add owning handlesReinUsesLisp2020-03-271-0/+18
|
* renderer_vulkan/wrapper: Add pool allocations owning templated classReinUsesLisp2020-03-271-0/+81
|
* renderer_vulkan/wrapper: Add owning handle templated classReinUsesLisp2020-03-271-0/+144
|
* renderer_vulkan/wrapper: Add destroy and free overload setReinUsesLisp2020-03-271-0/+28
|
* renderer_vulkan/wrapper: Add dispatch table and loadersReinUsesLisp2020-03-271-0/+137
|
* renderer_vulkan/wrapper: Add exception classReinUsesLisp2020-03-271-0/+30
|
* renderer_vulkan/wrapper: Add ToString function for VkResultReinUsesLisp2020-03-271-0/+3
|
* renderer_vulkan/wrapper: Add Vulakn wrapper and a span helperReinUsesLisp2020-03-271-0/+83
The intention behind a Vulkan wrapper is to drop Vulkan-Hpp. The issues with Vulkan-Hpp are: - Regular breaks of the API. - Copy constructors that do the same as the aggregates (fixed recently) - External dynamic dispatch that is hard to remove - Alias KHR handles with non-KHR handles making it impossible to use smart handles on Vulkan 1.0 instances with extensions that were included on Vulkan 1.1. - Dynamic dispatchers silently change size depending on preprocessor definitions. Different files will have different dispatch definitions, generating all kinds of hard to debug memory issues. In other words, Vulkan-Hpp is not "production ready" for our needs and this wrapper aims to replace it without losing RAII and exception safety.