Commit Graph

498 Commits

Author SHA1 Message Date
baldurk d8835126a5 Implement image & buffer atomic operations 2020-04-28 18:15:33 +01:00
Steve Karolewics 2c4f2a57a8 Add resource tracking to DXBC shader debugging
When a resource is accessed, it is now tracked by the debug step. The
shader viewer has a new panel to display resources accessed up to the
current step, with context menus to go to previous/next access of a
specific resource.
2020-04-27 18:16:46 +01:00
baldurk 745b65b3d2 Fix sampling from cube textures 2020-04-27 17:03:12 +01:00
baldurk 19bb332207 Fix bug in disassembly and debugging of vectorshuffle
* Not all vectors are four components, the indices are relative to the number of
  components each vector has, not always 0-3 and 5-7
2020-04-27 16:19:38 +01:00
baldurk 67c3f4fe25 Add support for accessing arrays of resources 2020-04-27 15:41:12 +01:00
baldurk 70256217fe Handle diverging/converging control flow in pixel shader 2020-04-24 20:14:48 +01:00
baldurk 76a866a5c2 Fix vulkan postvs output with components 2020-04-24 20:14:47 +01:00
baldurk 38efe4e6e0 SPIR-V matrix I/O parameters are column-major by default 2020-04-24 20:14:47 +01:00
baldurk 83bbcc5b51 Add support for matrix, struct, component and array pixel inputs 2020-04-24 20:14:47 +01:00
baldurk 4da3238bfa Build our own shaderc since the vulkan SDK's is no longer static 2020-04-24 20:14:47 +01:00
baldurk 7560960a9d Use deterministic filenames for shader compilation 2020-04-24 20:14:47 +01:00
Aliya Pazylbekova f8c5c2878b Vk pixel history: unbound fragment shader
Add support for unbound fragment shader.
2020-04-23 22:27:50 +01:00
baldurk 92e04417d5 Add support for storage image load/store 2020-04-23 19:14:09 +01:00
baldurk 18713f644e Implement OpImageQueryLod by faking derivatives on sample quad 2020-04-23 19:14:09 +01:00
baldurk 925b177bad Support Proj sampling variants with manual q divide 2020-04-23 19:14:08 +01:00
baldurk f506dcf395 Add support for storage buffer access 2020-04-23 19:14:08 +01:00
Aliya Pazylbekova f63dd71221 Vulkan Pixel History: secondary command buffers
Also:
- support for choosing mip level and slice
- tests for secondary command buffers
- adds a callback around vkCmdExecuteCommands
- refactors pixel history occlusion callback into its own
callback. Allows processing fewer events later on, and getting colour
information separately.
- keep track of subpassContents for vkCmdBeginRenderPass (inline or
  secondary)
2020-04-23 19:13:42 +01:00
baldurk 222f28d953 Add support for glsl pack/unpack functions 2020-04-22 20:40:14 +01:00
baldurk b35de95602 Fix python3 warning about use of 'is not' for literal comparison 2020-04-22 14:02:19 +01:00
baldurk 6a6c86139b Don't test mod/rem operations with negative operands
* This is undefined in vulkan
2020-04-21 19:14:41 +01:00
baldurk e3d2852080 Add test of large query pools on vulkan 2020-04-21 17:09:33 +01:00
baldurk 3ef67d6647 Test passing NULL in object names/labels 2020-04-21 17:09:33 +01:00
baldurk 9accb4033b Test push constant range that applies to vertex and fragment stages 2020-04-21 17:09:33 +01:00
baldurk 660d696b58 Test that dirty pipelines can still be shader-edited properly 2020-04-21 17:09:33 +01:00
baldurk 66a9e00f3e Don't serialise D3D12_STREAM_OUTPUT_DESC.pBufferStrides if NumEntries==0
* This is true even if NumStrides is a high number, it's entirely ignored.
2020-04-21 17:09:33 +01:00
baldurk 8ee6e43ed6 Check that we can render secondary mesh data with only two components
* We need to be sure that we don't accidentally read RGB anyway.
2020-04-21 17:09:24 +01:00
baldurk 207852bb15 Disable linked shaderc as vulkan SDK copy now links /MTD
* We'll probably want to add support for optionally compiling in a linked
  shaderc that we build ourselves now.
2020-04-20 13:25:02 +01:00
baldurk 83c7350e4a Implement remaining image sampling operations 2020-04-16 18:42:03 +01:00
baldurk 143f2bf054 Fix access to texel buffers 2020-04-16 18:41:59 +01:00
baldurk 7082f4eb44 Implement image dimension query opcodes 2020-04-16 18:41:59 +01:00
baldurk 831ffbf226 Add different OpCopy* opcodes 2020-04-16 18:41:58 +01:00
baldurk f2cb1ddc53 Implement remaining bit twiddling operations 2020-04-16 18:41:58 +01:00
baldurk a725a4e278 Add support for extended int math functions (with borrow/carry/overflow) 2020-04-16 18:41:58 +01:00
baldurk e34183d887 Add support for GLSL ops with struct/pointer outputs
* This is the functions that return multiple values - Modf/ModfStruct and
  Frexp/FrexpStruct
2020-04-16 18:41:58 +01:00
baldurk 217a693487 Add support for misc math GLSL opcodes that don't have struct variants
* step, smoothstep
* ldexp
* fma
* faceforward, reflect
2020-04-16 18:19:08 +01:00
baldurk 137a613179 Support pushing operations with limited precision over to the GPU
* This is primarily transcendentals - sqrt, pow, sin/cos, etc. It also includes
  operations derived from those (like length/normalize/etc)
2020-04-15 20:33:57 +01:00
baldurk d889ba7513 Implement OpKill support 2020-04-15 20:33:57 +01:00
baldurk def5476cf2 Add tests for NMin/NMax/NClamp 2020-04-15 20:33:57 +01:00
baldurk c4437f6be0 Add logical comparisons and any/all operators 2020-04-15 20:33:57 +01:00
baldurk d76e944799 Implement radians/degrees conversion functions 2020-04-15 20:33:57 +01:00
baldurk c3a5d99bc0 Add support for matrix operations (transpose/determinant/inverse) 2020-04-15 20:33:57 +01:00
baldurk 26f5b6a4b4 Implement more rounding-related GLSL extended instructions 2020-04-15 20:33:57 +01:00
baldurk ca7c1bbba9 Support push constants the same as constant buffer data 2020-04-15 20:33:56 +01:00
baldurk f4e141e843 Handle invalid pointers in create info when viewport state is dynamic 2020-04-15 20:33:56 +01:00
Aliya Pazylbekova 772905c4d3 Basic Vulkan pixel history test
+ a small pixel history fix for figuring out if depth test failed
- the test demo is based on overlay demo, with a few modifications so
  far: added a draw that will fail on culling, added shader discard for
  any pixel with x = 150
- tests some basic failed tests: stencil, depth, culling, shader discard
2020-04-14 23:06:28 +01:00
baldurk 07f60abf9e Implement OpIsNan and OpIsInf 2020-04-14 18:02:10 +01:00
baldurk 22dcb1f539 Centralise calculation of derivatives, implement OpFwidth* 2020-04-14 17:55:29 +01:00
baldurk 139d53e5e1 Add some type variants of supported glsl450 functions 2020-04-14 17:41:32 +01:00
baldurk 91e7563d09 Add support for glsl450 min/max/clamp 2020-04-14 17:16:18 +01:00
baldurk 72d7e828b0 Add OpNot to bitwise tests 2020-04-14 17:16:17 +01:00