Commit graph

123 commits

Author SHA1 Message Date
Henrik Rydgård
784e8ab782 Fix a race condition during Vulkan shader cache load.
Could lead to unnecessary pipelines being created.
2023-01-13 10:35:04 +01:00
Henrik Rydgård
cf52324e9e Vulkan: Fix pipeline cache clearing.
Extracted from #16759 and bugfixed. Fixes a leak of Vulkan pipelines.

I guess another way would be to queue the variants for destruction at
the same time as we queue the callback, but I like this better.
2023-01-09 09:49:55 +01:00
Henrik Rydgård
44f60ba2f0 Remove overly noisy log 2023-01-05 08:38:53 +01:00
Henrik Rydgård
7e374c9324 Address feedback, more fixes 2023-01-05 08:38:53 +01:00
Henrik Rydgård
1353817afa
Merge pull request #16689 from unknownbrackets/vk-shutdown
Vulkan: Avoid race in compile thread exit
2023-01-01 15:59:55 +01:00
Unknown W. Brackets
6c79d94814 Vulkan: Avoid race in compile thread exit. 2023-01-01 06:40:26 -08:00
Henrik Rydgård
9ceffa284d Vulkan: Add robustness against bad shader module compiles 2022-12-31 12:21:53 +01:00
Henrik Rydgård
d2feb444b7 Bunch of defensive programming around shaders 2022-12-31 12:21:51 +01:00
Henrik Rydgård
31d5881c90 Enable support for Android Vulkan validation. Fix a minor validation error. 2022-12-22 11:13:52 +01:00
Henrik Rydgård
6922ee7e52 Add some asserts in the hope of gathering some more info (and consolidating some crashes). 2022-12-18 21:58:20 +01:00
Henrik Rydgård
11366a2ded Don't refer directly to g_Config.iMultiSampleLevel, it can contain unsupported modes. 2022-12-14 16:43:37 +01:00
Unknown W. Brackets
8c1a247b7b Vulkan: Cleanup some logspam. 2022-12-13 18:29:23 -08:00
Henrik Rydgård
00ebf4957f Make shader cache loading a bit more lenient. 2022-12-13 23:06:57 +01:00
Henrik Rydgård
30e1bc0540 Some logging improvements 2022-12-13 16:29:07 +01:00
Henrik Rydgård
73cd9fac7d Tiny optimization in PipelineDesc 2022-12-13 15:16:11 +01:00
Unknown W. Brackets
3f620dba58 Vulkan: Reduce some logging when things are fast.
On startup especially this spams sometimes.
2022-12-03 14:56:58 -08:00
Unknown W. Brackets
53eedf06e3 Vulkan: Track pipeline desc using a refcount.
Not very safe to not allow deletes, and don't want to force Draw objects
on the deleter (this is referenced by them.)
2022-12-03 14:52:06 -08:00
Henrik Rydgård
8a3e92aa38 Not pretty, but with this, you can switch MSAA level at runtime. 2022-12-01 23:41:31 +01:00
Henrik Rydgård
4990683cf2 Implement "enhanced" multisample quality setting 2022-12-01 22:49:00 +01:00
Henrik Rydgård
e3679df6cf Fix switching between MSAA levels 2022-12-01 22:49:00 +01:00
Henrik Rydgård
4dfce4f6bc Basically working MSAA on desktop GPUs! Some glitches remain. 2022-12-01 22:49:00 +01:00
Henrik Rydgård
06af304c8d Multisampling groundwork 2022-12-01 22:49:00 +01:00
Henrik Rydgård
331d024a8c Add a flags parameter to InvalidateCachedState and rename it Invalidate.
Also rename the old InvalidationFlags enum to InvalidateCallbackFlags.
2022-12-01 19:15:38 +01:00
Henrik Rydgård
31af24a230 Break out VKRFramebuffer/VKRRenderpass from VulkanRenderManager 2022-11-27 10:22:37 +01:00
Henrik Rydgård
70d1d8fa07 Replace the "GetCurrentStepId"-based state invalidation with callbacks 2022-11-24 10:52:42 +01:00
Henrik Rydgård
eea0b2632c Add checks against rendering with depth against non-depth targets. 2022-11-24 10:12:22 +01:00
Henrik Rydgård
4d637342f7 Log source code for failed pipeline creations 2022-11-08 00:21:08 +01:00
Henrik Rydgård
b4507cd5cc Make a lot more code VR build for all platforms 2022-11-06 14:36:51 +01:00
Henrik Rydgård
7742fbdeb6 Switch RenderPassType to be a "proper" bitfield enum. 2022-11-05 22:06:53 +01:00
Henrik Rydgård
6d9008dab5 Fix validation issue with clears, remove redundant code 2022-10-27 11:05:59 +02:00
Henrik Rydgård
31fd928a5c Name more image views. Very useful with a little patch to the Vulkan debug layers. 2022-10-27 11:05:59 +02:00
Henrik Rydgård
0de12f5ca9 Some refactoring of framebuffer views, layer issues, more work. 2022-10-27 11:05:58 +02:00
Henrik Rydgård
3ce8133656 Non-stereo bugfix 2022-10-27 11:05:58 +02:00
Henrik Rydgård
fb250c4b29 More multiview work 2022-10-27 11:05:58 +02:00
Henrik Rydgård
7a620962aa thin3d: Replace hint at future MRT support with basic multi layer support 2022-10-27 11:05:58 +02:00
Henrik Rydgård
cafce7365b Vulkan: Fix frame ordering issue with postprocessing shaders
Requested an init command buffer outside the frame, which is dangerous
and caused validation problems with command pool resets.

Would like to assert on insideFrame in GetInitCmd, but we use it from
some init code where it does work correctly. Might clean that up at some
point.
2022-10-21 12:52:21 +02:00
Henrik Rydgård
90d395a10d Remove "attachment" parameter from BindFramebufferAsTexture everywhere.
Not actually useful since our framebuffer objects don't support multiple
color images, and probably won't ever need to.
2022-10-20 10:15:19 +02:00
Lubos
be2613d495 OpenXR - Move VR passes count calculation 2022-10-17 19:07:27 +02:00
Henrik Rydgård
eb18a87eee
Merge pull request #16186 from lvonasek/feature_openxr_vulkan
OpenXR - Initial work to support multiple render APIs
2022-10-17 14:47:47 +02:00
Henrik Rydgård
f269137c78 Revert "Vulkan: Create depth/stencil buffers on demand"
This reverts commit be37de106c.
2022-10-13 22:39:47 +02:00
Lubos
ade606bc3c OpenXR - Hookup VR API into Vulkan 2022-10-12 16:21:54 +02:00
Henrik Rydgård
d4bfe9299d Track min and max GPU time, init time, render CPU time.
Mainly wanted to see if init time is a factor, there are optimizations
we can do there.
2022-10-10 10:53:27 +02:00
Henrik Rydgård
be37de106c Vulkan: Create depth/stencil buffers on demand 2022-10-09 20:28:32 +02:00
Henrik Rydgård
2207c1271a Fix validation error with the GPU profiler 2022-10-03 12:13:11 +02:00
Unknown W. Brackets
d16caa71af Vulkan: Add geometry shader ID tracking.
We're still not generating them, yet.  But this tracks the objects and
IDs through the pipeline.
2022-10-02 07:42:16 -07:00
Unknown W. Brackets
87171cef98 GPU: Add geometry path for shader writer.
Not yet used.
2022-10-01 12:45:43 -07:00
Henrik Rydgård
8534b8d7ca Typo fix 2022-09-28 16:44:40 +02:00
Henrik Rydgård
bd759790b0 Update the Vulkan debug names when reassigning depth buffers. 2022-09-28 14:09:40 +02:00
Henrik Rydgård
a7642bac15 Replace faulty layout transition deduplication algorithm. 2022-09-25 23:24:54 +02:00
Unknown W. Brackets
e6db0bef2d
Merge pull request #16099 from hrydgard/vulkan-dont-always-alloc-depth
Vulkan: Avoid allocating depth images for stuff like temp copies, depal buffers etc.
2022-09-25 08:05:50 -07:00