Commit Graph

1835 Commits

Author SHA1 Message Date
Philip Rebohle f7b3b9ca5c
[dxvk] Add new methods to find adapters by LUID or device ID
Co-authored-by: Zhiyi Zhang <zzhang@codeweavers.com>
2018-12-04 19:38:52 +01:00
Philip Rebohle bb1f431e44
[dxvk] Query device ID information if available
Co-authored-by: Zhiyi Zhang <zzhang@codeweavers.com>
2018-12-04 19:38:52 +01:00
Philip Rebohle 1cc0455c8a
[dxgi] Remove old DXGIDevice implementation and IDXGIVkDevice
Both have been moved to the D3D11 module and are no longer needed.
2018-12-04 19:38:52 +01:00
Philip Rebohle c5deedef2d
[d3d11] Move IDXGIDevice implementation to D3D11 module
Helps decouple the D3D11 module from the DXGI implementation. This
also allows us to clean up D3D11 device creation, which is much needed.

Based on zzhiyi/dxvk@fa441937f1

Co-authored-by: Zhiyi Zhang <zzhang@codeweavers.com>
2018-12-04 19:38:38 +01:00
Philip Rebohle de29174d42
Revert "[vr] Cosmetic code cleanup"
This reverts commit a3bf90f5a3.

Crashes SuperHot VR for some reason.
2018-12-04 18:50:11 +01:00
Philip Rebohle 556e0d1dba Revert "[util] Report Nvidia GPU for Battlefield 1"
This reverts commit 500d67e002.

This game has some built-in driver detection on Nvidia which makes it
fail to start on non-Nvidia hardware or when nvapi is not present.
Fixes #795.
2018-12-02 20:27:39 +01:00
Philip Rebohle 835d92b802 [d3d10] D3D10CreateDeviceAndSwapChain: Ignore swap chain if null
Like e4b91057ac, this might fix some
issues with ReShade in D3D10 games.
2018-12-02 15:52:17 +01:00
Philip Rebohle e4b91057ac [d3d11] D3D11CreateDeviceAndSwapChain: Ignore swap chain if null
Fixes some issue with ReShade.
2018-12-02 13:43:55 +01:00
Philip Rebohle cf21111401
[d3d11] Implement ID3D11Multithread for D3D11 contexts 2018-11-30 11:38:00 +01:00
Philip Rebohle 28216909bd
[d3d10] Implement D3D10Multithread 2018-11-30 11:37:57 +01:00
Philip Rebohle d1f179c5af
[util] Add likely/unlikely macros 2018-11-29 22:53:04 +01:00
Philip Rebohle af2f5cc77f
[dxgi] Remove format lookup methods from IDXGIVkAdapter interface 2018-11-28 19:06:34 +01:00
Philip Rebohle cc7f5c4bb1
[d3d11] Duplicate format table into D3D11 device
Removes the direct D3D11Device->DXGIAdapter dependency.
2018-11-28 18:34:05 +01:00
Philip Rebohle 193d24a3e2
[dxgi] Remove IDXGIVkBackBuffer 2018-11-28 18:15:27 +01:00
Philip Rebohle 092cad0e76
[dxvk] Remove DxvkSemaphore 2018-11-28 12:44:18 +01:00
Philip Rebohle 80b9f1d03b
[dxvk] Remove DxvkSurface 2018-11-28 12:44:18 +01:00
Philip Rebohle 9b923bb386
[dxvk] Remove DxvkSwapChain 2018-11-28 12:44:17 +01:00
Philip Rebohle 9139fbf95d
[d3d11] Use new Vulkan presenter 2018-11-28 12:44:17 +01:00
Philip Rebohle 81306cdc11
[dxvk] Support new Vulkan presenter in DxvkDevice 2018-11-28 12:44:17 +01:00
Philip Rebohle 746529b71b
[dxvk] Pass raw semaphore handles to submitCommandList 2018-11-28 12:44:17 +01:00
Philip Rebohle a5c17f2753
[d3d11] Use flushCommandList method to flush initializer context 2018-11-28 12:44:17 +01:00
Philip Rebohle 979ccf23e3
[vulkan] Implement new Vulkan presenter / swap chain 2018-11-28 12:44:11 +01:00
Philip Rebohle 7096937c11
[dxbc] Use ballot to determine early-discard condition in fragment shaders 2018-11-27 11:50:01 +01:00
Philip Rebohle 0113e8f360
[spirv] Add subgroup ballot instructions 2018-11-27 11:50:01 +01:00
Philip Rebohle 4057937d2d
[dxvk] Refactor descriptor set allocation
With this new approach, descriptor pools are decoupled from the
command list they are used with. Instead, the DXVK context takes
ownership of a single descriptor pool until it runs out of memory.

This reduces the amount of memory wasted for under-utilized pools
and should this reduce an application's memory footprint.
2018-11-27 11:42:13 +01:00
Philip Rebohle eb7a5da975
[dxvk] Rebalance descriptor set allocation
This should more closely reflect what applications actually use.
The basic idea here is that it is better for apps to run out of
descriptors before running out of sets and thus reduce the
overall memory footprint of the application.
2018-11-27 10:04:16 +01:00
Philip Rebohle 08b403f655
[d3d11] Fix potential UAV binding issue
When rebinding an already active UAV, we still need to
update the counter unless the app passed a value of -1.

Ref #712.
2018-11-26 17:18:35 +01:00
Philip Rebohle 500d67e002
[util] Report Nvidia GPU for Battlefield 1
Reportedly improves performance for some weird reason.
2018-11-26 08:04:30 +01:00
Philip Rebohle 2d55852777
[dxvk] Disable state cache for Anno 2205
Fixes #686.
2018-11-24 20:04:21 +01:00
Philip Rebohle 10b272b4c9
[meta] Release 0.93 2018-11-24 10:41:41 +01:00
Philip Rebohle 2424cf0289
[dxbc] Disable early discard on AMD cards
Causes GPU hangs.
2018-11-24 10:09:33 +01:00
Philip Rebohle ce3642edd0
[dxvk] Don't put rendering stage/access masks into image info
Not needed since these stages and access flags are handled by render
pass transitions.
2018-11-24 00:40:59 +01:00
Philip Rebohle 8081dc1591
[util] Enable TGSM initialization for Quantum Break
Fixes artifacting on Mesa 18.3.
2018-11-23 16:12:09 +01:00
Philip Rebohle a75c596132
[d3d11] Add config option to enable TGSM initialization 2018-11-23 16:12:02 +01:00
Philip Rebohle ea5f11d091
[dxbc] Implement function to clear thread-group shared memory
Can be enabled in case a game reads undefined data from TGSM.
2018-11-23 15:57:54 +01:00
Philip Rebohle 79a6dd111e
[dxbc] Store workgroup size for compute shaders 2018-11-23 14:39:33 +01:00
Philip Rebohle 3e686098cc
[dxbc] Disable subgroup early discard on Nvidia GPUs
People report performance regressions up to 5% with it enabled.
2018-11-23 12:28:48 +01:00
Philip Rebohle 6dd82dfe03
[dxbc] Clamp written depth value to (0.0, 1.0)
Fixes shadow issue in Overwatch (#738).
2018-11-23 12:00:23 +01:00
Philip Rebohle 0418c02ac3
[dxbc] Use clustered subgroup operations on supported hardware 2018-11-21 11:17:09 +01:00
Philip Rebohle ab17c49c4e
[dxbc] Fix compiler warning about uninitialized values 2018-11-21 11:17:09 +01:00
Philip Rebohle 94b0058e0d
[tests] Enable subgroup ops for DXBC compiler app 2018-11-21 11:17:09 +01:00
Philip Rebohle 4f76b89941
[dxbc] Use subgroup operations for early discard
Can improve performance in some complex fragment shaders.
2018-11-21 11:17:09 +01:00
Philip Rebohle a574829bb6
[dxbc] Remove DeferKill flag
This behaviour is correct, and needs to be enabled by default.
2018-11-21 11:17:09 +01:00
Philip Rebohle 968a085f1e
[dxvk] Query device subgroup properties
Also query the device properites for this extension as well
as support for subgroup operations on this device.
2018-11-21 11:17:09 +01:00
Philip Rebohle 67e10246cb
[dxvk] Request Vulkan 1.1 instance
Falls back to a regular 1.0 instance on old drivers.
We need to do this in order to legally use SPIR-V 1.3.
2018-11-21 11:17:09 +01:00
Philip Rebohle 59d0ad4413
[spirv] Add non-uniform group instructions 2018-11-21 11:17:09 +01:00
Philip Rebohle c8e44085c5
[meta] Update SPIR-V headers 2018-11-21 11:17:06 +01:00
Philip Rebohle dbd7db3328
[dxvk] Fix typo around dual-src blending
Fixes e744117042
2018-11-20 19:55:08 +01:00
Philip Rebohle bcd5a9235c
[dxvk] Make use of VK_AMD_memory_overallocation_behavior
Currently only supported on AMDVLK. Enforces memory limits on a driver
level unless the corresponding dxvk.allowMemoryOvercommit option is enabled.
2018-11-20 15:50:41 +01:00
Philip Rebohle 99f6953e89
[dxvk] Store DXVK options directly with the instance object 2018-11-20 15:50:01 +01:00