1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-12-05 01:24:14 +01:00
Commit Graph

389 Commits

Author SHA1 Message Date
Philip Rebohle
4fc2ea25b8 [dxbc] Implemented typed UAV load/store 2018-01-01 17:14:06 +01:00
Philip Rebohle
5332891748 [dxbc] Implemented switch-case instructions 2017-12-30 17:22:36 +01:00
Philip Rebohle
006e1b25e6 [d3d11] Fixed shader semantic name comparison 2017-12-30 15:30:31 +01:00
Philip Rebohle
e740adfcb7 [dxbc] Implemented f16 pack/unpack instructions 2017-12-30 13:18:31 +01:00
Philip Rebohle
f93745adcf [dxbc] Implemented bfi and bfe instructions 2017-12-30 03:44:19 +01:00
Philip Rebohle
1373fe5fcc [dxbc] Implemented bufinfo instruction 2017-12-30 01:26:37 +01:00
Philip Rebohle
b968aa0472 [dxbc] Implemented continue instructions 2017-12-29 22:54:25 +01:00
Philip Rebohle
298eeedcc4 [dxbc] Implemented round instructions
Also fixed potential numerical stability issues in with min/max
instructions and saturation when an operand is NaN.
2017-12-29 19:26:59 +01:00
Philip Rebohle
5df89fb657 [dxbc] Fixed OpImageRead and OpImageWrite operand types 2017-12-29 12:11:19 +01:00
Philip Rebohle
a51439fb29 [dxbc] Implemented thread group shared memory and barriers 2017-12-29 00:51:31 +01:00
Philip Rebohle
847bfdd8ae [dxbc] Implemented raw and structured UAV stores 2017-12-28 18:37:02 +01:00
Philip Rebohle
a72727a173 [dxbc] Added support for structured and raw buffers 2017-12-28 16:03:17 +01:00
Philip Rebohle
7f5fa18d0b [dxbc] Enabled SPV_KHR_shader_draw_parameters for vertex shaders 2017-12-27 14:31:38 +01:00
Philip Rebohle
5ce975eed9 [dxbc] Fixed SV_VERTEXID and SV_INSTANCEID
Apparently, these two system values ignore the base vertex
and base instance from the draw call. This is not documented,
but in line with what the AMD driver does on Windows.
2017-12-27 12:49:25 +01:00
Philip Rebohle
24b9d9d99a [dxbc] Experimental support for ld,resinfo 2017-12-27 01:37:15 +01:00
Philip Rebohle
3762df6cb6 [d3d11] Added proper support for 1D and 3D shader resources 2017-12-24 13:33:22 +01:00
Philip Rebohle
89290e9eab [dxbc] Minor fixes 2017-12-22 20:15:44 +01:00
Philip Rebohle
f301633516 [dxbc] Compute shader prep work 2017-12-21 17:27:40 +01:00
Philip Rebohle
46717529fa [dxbc] Implemented unsigned comparators and sample_l 2017-12-21 17:14:11 +01:00
Philip Rebohle
3e4e5191a8 [dxbc] Increased number of clip/cull distances
Clip and cull distances can be defined as multi-component
vectors in D3D11. We still need to figure out how to map
them to the actuall cull distance array.
2017-12-21 16:28:42 +01:00
Philip Rebohle
f947fb5d44 [dxbc] Refactored system value mapping
Restores geometry shader support.
2017-12-21 16:00:36 +01:00
Philip Rebohle
2e4275649e [dxbc] Implemented input mapping + sample controls
Input variables are now copied into a temporary array, which allows
dynamic indexing and which also allows us to use system values that
are mapped to input registers in DXBC. This breaks geometry shaders
for now, however.
2017-12-21 12:37:20 +01:00
Philip Rebohle
109ce0a695 [dxbc] Implemented sample_d and vector shift instructions 2017-12-20 23:50:39 +01:00
Philip Rebohle
6ff709513c [dxbc] Added indexable temps 2017-12-20 22:50:05 +01:00
Philip Rebohle
41d660f220 [spirv] Added image operand structure for more flexible sample ops 2017-12-20 20:21:44 +01:00
Philip Rebohle
659ec7b59d [d3d11] Added DXGI format properties 2017-12-20 14:54:24 +01:00
Philip Rebohle
b4e10b7f06 [dxbc] Fixed sampler types for depth-compare operations 2017-12-20 13:41:04 +01:00
Philip Rebohle
2ed2d892d6 [dxvk] Optimized resource binding
Fixes a few bottlenecks that were encountered in the Cascading Shadow
Maps demo from the Microsoft SDK. Performance is now slightly better
than wined3d with CSMT, MESA_NO_ERROR and mesa_glthread enabled.
2017-12-20 12:13:08 +01:00
Philip Rebohle
9865474bb4 [dxbc] Initial shadow sampler support 2017-12-20 00:16:49 +01:00
Philip Rebohle
d1720c0c52 [dxbc] Implemented derivatives 2017-12-19 20:26:05 +01:00
Philip Rebohle
5415b685de [dxbc] Implemented type conversion instructions 2017-12-19 18:12:18 +01:00
Philip Rebohle
95bc4b5826 [dxbc] Added immediate constant buffer support 2017-12-19 17:41:23 +01:00
Philip Rebohle
64a74735f8 [dxbc] oDepth no longer treated as standard output register
Fixes a crash in the shader compiler when starting up Tomb Raider.
2017-12-19 12:58:40 +01:00
Philip Rebohle
6df9fc75d2 [dxbc] Implemented some new bit-wise logical instructions 2017-12-19 00:45:31 +01:00
Philip Rebohle
13d4a3d87d [dxbc] Fixed bug with constant vector operands 2017-12-18 18:02:15 +01:00
Philip Rebohle
6cc3ff4ad8 [dxbc] Basic geometry shader (sm4) support 2017-12-18 16:41:05 +01:00
Philip Rebohle
1e08c0744f [dxbc] Implemented basic control flow instuctions 2017-12-18 11:53:28 +01:00
Philip Rebohle
858913ec0c [dxbc] Shader decoder and compiler overhaul (2/2)
Removed the old decoder and the old shader compiler
and added documentation to the new structures.
2017-12-18 00:46:44 +01:00
Philip Rebohle
47347e38da [dxbc] Shader decoder and compiler overhaul (1/2)
Major rewrite of the entire shader decoder to generate easy
to parse data structures for the compiler, which ultimately
allows new instructions to be implemented more easily.
2017-12-18 00:28:54 +01:00
Philip Rebohle
2f99be9546 [dxbc] Implemented conditional move and comparison instructions 2017-12-17 01:36:41 +01:00
Philip Rebohle
2ad5f49f3e [dxbc] Shader compiler rewrite (2/2) 2017-12-14 12:53:53 +01:00
Philip Rebohle
a4eb807215 [dxbc] Implemented SinCos, Min and Max instructions 2017-12-13 16:35:01 +01:00
Philip Rebohle
464a3e7d4e [dxbc] Shader compiler rewrite (1/2)
Rewrote most parts of the shader compiler and removed the old one. The next
step is to improve documentation and remove the remaining traces of the old
shader compiler.
2017-12-13 15:32:54 +01:00
Philip Rebohle
0f26d1c627 [dxbc] Removed <optional> dependency 2017-12-12 13:00:37 +01:00
Philip Rebohle
22c3cd80a1 [dxbc] Implemented mad instruction 2017-12-11 14:36:35 +01:00
Philip Rebohle
93f79742e9 [dxbc] Scalar values can be expanded to multiple vector components during a store operation 2017-12-10 22:35:55 +01:00
Philip Rebohle
d941446ca0 [dxbc] Fixed bug in decoder that would return wrong component masks 2017-12-10 21:13:22 +01:00
Philip Rebohle
9acc9bf3e0 [dxbc] Implemented Rsq instruction 2017-12-10 20:01:38 +01:00
Philip Rebohle
b4493d90d8 [dxbc] Initial support for sample instruction 2017-12-10 12:08:20 +01:00
Philip Rebohle
7c03495d74 [dxbc] Implemented shader resource declaration for images 2017-12-10 10:34:18 +01:00
Philip Rebohle
939faeaf27 [dxbc] Implemented sampler declaration 2017-12-10 03:39:35 +01:00
Philip Rebohle
bfb05f24b8 [dxbc] Implemented support for MUL instruction 2017-12-09 01:49:30 +01:00
Philip Rebohle
c90bc3e946 [dxbc] Implemented proper resource slot mapping 2017-12-08 22:30:41 +01:00
Philip Rebohle
feab720ddb [spirv] Added methods to force type declaration for arrays and structs 2017-12-08 19:50:36 +01:00
Philip Rebohle
0610296248 [d3d11] Implemented constant buffer binding 2017-12-08 19:39:33 +01:00
Philip Rebohle
e872448ca3 [dxbc] Refactored shader compiler to return a DxvkShader 2017-12-08 18:14:05 +01:00
Philip Rebohle
a2f66025f8 [dxbc] Implemented constant buffers 2017-12-08 17:08:26 +01:00
Philip Rebohle
9f4cc6b77d [dxbc] Minor cleanups 2017-12-08 15:30:12 +01:00
Philip Rebohle
8887e8b2fa [dxbc] Implemented interpolation modes for pixel shader inputs 2017-12-08 14:56:34 +01:00
Philip Rebohle
bd8dc20fa2 [dxbc] User-defined shader interface cannot be an array due to interpolation modes 2017-12-08 14:18:30 +01:00
Philip Rebohle
0843349d72 [dxbc] Added interpolation mode decoder 2017-12-08 13:24:08 +01:00
Philip Rebohle
e3533fb634 [dxbc] Implemented user-defined shader interface 2017-12-08 12:59:08 +01:00
Philip Rebohle
b7e263fc73 [dxbc] Added highly experimental shader input/output interface code 2017-12-07 16:29:34 +01:00
Philip Rebohle
1f89452014 [d3d11] Implemented input layout creation 2017-12-07 12:45:02 +01:00
Philip Rebohle
dece62c70a [d3d11] Implemented basic shader creation methods 2017-12-06 18:54:01 +01:00
Philip Rebohle
a9a03fec69 [dxvk] DxvkShader creates a VkShaderModule again 2017-11-20 14:03:00 +01:00
Philip Rebohle
745466652c [dxvk] Removed shader resource slots for now, needs work 2017-11-18 10:42:27 +01:00
Philip Rebohle
a84e2eabc2 [dxvk] Restructured state tracker again 2017-11-17 19:49:44 +01:00
Philip Rebohle
abc0e98761 [dxbc] Added result modifiers, simple add instruction 2017-11-17 11:41:56 +01:00
Philip Rebohle
4c0404d3c6 [dxbc] Removes shader input/output interfaces for now, needs more work 2017-11-17 11:41:46 +01:00
Philip Rebohle
cded7726a7 [dxbc] Added pixel shader code generator stub 2017-11-16 02:07:10 +01:00
Philip Rebohle
5d26f0fb0c [dxbc] Implemented operand modifiers and load/store stuff 2017-11-16 01:30:17 +01:00
Philip Rebohle
901abe4356 [dxbc] Implemented some very basic load/store operations 2017-11-13 02:07:13 +01:00
Philip Rebohle
43dfba2287 [dxbc] Separate code generator classed for each shader type 2017-11-13 00:22:52 +01:00
Philip Rebohle
403ab75aeb [dxbc] More sophisticated component mask/swizzle classes 2017-11-07 15:11:09 +01:00
Philip Rebohle
4052951542 [dxbc] Removed most of the DXBC compiler again 2017-11-07 15:10:38 +01:00
Philip Rebohle
9cdc341946 [dxbc] Some shader signature stuff 2017-11-01 16:43:04 +01:00
Philip Rebohle
72f353074f [dxbc] Initial xSGN chunk implementation 2017-11-01 00:01:40 +01:00
Philip Rebohle
bc8cc76888 [dxbc] Added operand index decoder, entry point declaration 2017-10-29 02:35:16 +02:00
Philip Rebohle
f5ad024f5d [dxbc] Implemented temporary register declarations 2017-10-26 16:32:10 +02:00
Philip Rebohle
200da4cf60 [spirv] Added SpirvModule class to generate SPIR-V code 2017-10-26 15:40:39 +02:00
Philip Rebohle
294586eeb3 [dxbc] Instruction decoder work 2017-10-25 13:49:13 +02:00
Philip Rebohle
79e2236958 [dxbc] Some more decoding stuff 2017-10-22 23:13:29 +02:00
Philip Rebohle
6954cfd84c [dxbc] Added helper classes for DXBC decoding 2017-10-21 17:58:58 +02:00
Philip Rebohle
1bf05d3687 [spirv] Moved SPIR-V-specific stuff to separate directory 2017-10-18 10:36:47 +02:00
Philip Rebohle
72a87093c5 [dxvk] Moved some SPIR-V bits to separate directory 2017-10-18 09:50:30 +02:00
Philip Rebohle
c1e9d3236f [dxbc] Added type info struct 2017-10-17 13:02:57 +02:00
Philip Rebohle
0a57a4ddf5 [dxbc] Figuring out how to best generate SPIR-V module code 2017-10-16 19:53:17 +02:00
Philip Rebohle
bb5b588d23 [dxbc] Added DXBC to SPIR-V compiler stub 2017-10-16 17:50:09 +02:00