Philip Rebohle
69171873fa
[d3d11] Add compile-time debug flag for lazy binding
2025-02-23 12:06:51 +01:00
Philip Rebohle
c0983a32be
[d3d11] Reset dirty bindings on command submission
2025-02-23 12:06:51 +01:00
Philip Rebohle
3e6dfcfb15
[d3d11] Reset dirty tracking when re-applying context state
2025-02-23 12:06:51 +01:00
Philip Rebohle
9d890c75ac
[d3d11] Don't template methods that restore shader bindings
...
This was only needed because Bind* methods were also templated.
2025-02-23 12:06:51 +01:00
Philip Rebohle
771f14c466
[d3d11] Refactor BindUnorderedAccessView
...
We won't do lazy bindings for UAVs, but at least bring this function
in line with the rest of the binding functions.
2025-02-23 12:06:51 +01:00
Philip Rebohle
b0d881046f
[d3d11] Lazy-bind samplers
2025-02-23 12:06:51 +01:00
Philip Rebohle
f2ab76c8db
[d3d11] Lazy-bind shader resources
2025-02-23 12:06:51 +01:00
Philip Rebohle
4fdbfffdcc
[d3d11] Lazy-bind constant buffers
2025-02-23 12:06:51 +01:00
Philip Rebohle
a61c114519
[d3d11] Change AllowFlush behaviour
...
No functional change, just makes it less annoying to use in methods that
can be called from both immediate and deferred contexts-
2025-02-23 12:06:51 +01:00
Philip Rebohle
41ec7b6a02
[d3d11] Track shader stages with dirty bindings as well as used bindings
2025-02-23 12:06:51 +01:00
Philip Rebohle
be61341178
[d3d11] Rework DXBC shader stage to Vulkan shader stage mapping
...
We're going to have to do this at runtime, so this needs to be fast.
2025-02-23 12:06:51 +01:00
Philip Rebohle
6080e6d24d
[d3d11] Store used binding mask inside shader objects
2025-02-23 12:06:51 +01:00
Philip Rebohle
75599780f2
[dxbc] Gather binding info during shader compilation
2025-02-23 12:06:51 +01:00
Philip Rebohle
5f16faaae0
[util] Generalize bit mask iterator
2025-02-23 12:06:51 +01:00
Robin Kertels
94b48c1633
[d3d9] Slightly clean up sampler slot handling
2025-02-21 13:25:23 +01:00
Robin Kertels
f7d56886c5
[d3d9] Fix sampler slot correction not respecting dmap texture
2025-02-21 13:25:23 +01:00
Philip Rebohle
0691a7fc46
[dxvk] De-duplicate drawIndirectCount implementations
...
No functional change, just some code cleanup.
2025-02-20 13:30:31 +01:00
Philip Rebohle
a135e01f89
[dxvk] Unroll merged indirect draws as necessary
2025-02-20 13:30:31 +01:00
Philip Rebohle
1d8fb818fc
[dxvk] Check whether pipeline has potentially hazardous stores
2025-02-20 13:30:31 +01:00
Philip Rebohle
6f7a468174
[dxvk] Fix global render pass barrier
...
Only need to deal with common write-after-read scenarios, we can
ignore writes since those will add extra barriers anyway. Also
move this work out of the somewhat hot pipeline bind function.
2025-02-20 13:30:31 +01:00
Philip Rebohle
dd1ca4ce59
[dxvk] Track order-invariant access ops in barrier tracker
...
This elides barriers between draws or dispatches if we can prove
order-invariance through atomic operations.
2025-02-20 13:30:31 +01:00
Philip Rebohle
c475960754
[dxvk] Pass store op around for barrier tracking
2025-02-20 13:30:31 +01:00
Philip Rebohle
e01a6eec3e
[dxbc] Track bindings with order-invariant atomic stores
2025-02-20 13:30:31 +01:00
Philip Rebohle
d94e3633dc
[dxvk] Introduce concept of order-invariant atomic stores
2025-02-20 13:30:31 +01:00
Philip Rebohle
8c7da07085
[util] Fix enum declaration
2025-02-20 13:30:31 +01:00
WinterSnowfall
22052106d8
[d3d9] Relax logging level on validateGammaRamp
2025-02-20 00:01:10 +01:00
WinterSnowfall
3716d48c89
[d3d8/9] Use numeric_limits globally
2025-02-20 00:01:10 +01:00
WinterSnowfall
317607e192
[d3d8/9] Prevent device child ref underruns on release
2025-02-20 00:01:10 +01:00
Philip Rebohle
19361c962c
[dxvk] Add debug region for barrier control
2025-02-19 19:34:52 +01:00
Philip Rebohle
636669e1a5
[dxvk] Improve handling of nested debug regions
2025-02-19 19:34:52 +01:00
Philip Rebohle
b03d457ffb
[dxvk,d3d11] Improve explicit UAV overlap behaviour
...
If the app explicitly enables UAV overlap, don't synchronize
back-to-back read-modify-write operations to the same UAV either.
2025-02-19 19:34:52 +01:00
Philip Rebohle
a2c9c0f740
[d3d11] Use resource cookies for draw buffer tracking
...
Avoids keeping draw buffers alive when the app stops using indirect
draws. Unlikely to have caused issues in practice, but draw buffers
are not part of the API state to begin with.
2025-02-19 19:34:52 +01:00
Philip Rebohle
07f7ccdc96
[dxvk,d3d11] Fix draw buffer tracking for DrawAuto
...
Not like anybody uses this feature, but we need to both check for
hazards and make sure the SO counter actually gets tracked. Use
the existing draw buffer mechanism for this.
2025-02-19 19:34:52 +01:00
Philip Rebohle
d37a13847a
[dxvk] Rename and repurpose ignoreGraphicsBarriers option
...
Less nuclear approach that hopefully works just as well in practice.
2025-02-19 19:34:52 +01:00
Philip Rebohle
18e5c12b6d
[dxvk] Fix resource hazard checks
...
Turns out we've had broken write-after-read checks for a while.
2025-02-19 19:34:52 +01:00
Philip Rebohle
48d145fff6
[dxvk] Change debug color for pipelines with side effects
2025-02-19 19:34:52 +01:00
Philip Rebohle
04d2609a91
[dxvk] Clean up shader resource hazard checking
2025-02-19 19:34:52 +01:00
Philip Rebohle
3bbae86ec9
[dxvk] Rework compute barrier tracking
2025-02-19 19:34:52 +01:00
Philip Rebohle
53b076be61
[dxvk] Rework graphics barrier tracking
...
Avoids having to insert redundant barriers when the app does UAV rendering.
2025-02-19 19:34:52 +01:00
Philip Rebohle
009f8ee356
[dxvk] Emit barriers when updating shader resources
2025-02-19 19:34:52 +01:00
Philip Rebohle
be9391ded5
[dxvk] Track transform feedback buffer access
2025-02-19 19:34:52 +01:00
Philip Rebohle
96337f11d4
[dxvk] Track vertex buffer access
2025-02-19 19:34:52 +01:00
Philip Rebohle
24b58e5858
[dxvk] Track index buffer access
2025-02-19 19:34:52 +01:00
Philip Rebohle
21eb682b39
[dxvk] Track indirect draw buffer access
2025-02-19 19:34:52 +01:00
Philip Rebohle
a7c1e7a2a0
[dxvk] Add resource flag to track graphics pipeline side effects
2025-02-19 19:34:52 +01:00
Philip Rebohle
978d7cb65b
[dxvk] Add more convenience methods to track buffer barriers
2025-02-19 19:34:52 +01:00
Philip Rebohle
23067c48c7
[dxvk] Clean up CS chunk allocation
...
This also makes it more robust w.r.t. alignment.
2025-02-18 15:37:11 +01:00
Philip Rebohle
4c8ee300b5
[util] Add more optimal popcnt implementation
2025-02-18 15:28:41 +01:00
Robin Kertels
4282829f38
[d3d9] Route operations on unmappable memory through allocator
...
Fixes an extremely race condition that can happen when freeing a chunk.
2025-02-17 19:23:15 +01:00
WinterSnowfall
92523fc0dd
[d3d9] Fix x64 crash on SetVertexShaderConstantF index overflow
2025-02-17 15:11:05 +01:00