Commit Graph
15112 Commits
Author SHA1 Message Date
Jake Turner f538e91b05 DXIL Debugger extended support for GPU Sampling instructions
DXOp::Sample
DXOp::SampleBias
DXOp::SampleLevel
DXOp::SampleGrad
DXOp::SampleCmp
DXOp::SampleCmpBias
DXOp::SampleCmpLevel
DXOp::SampleCmpGrad
DXOp::SampleCmpLevelZero
DXOp::TextureGather
DXOp::TextureGatherCmp
2024-10-24 12:54:10 +01:00
Jake Turner a5b63f2f26 Shader Debug HLSL split debugSampleLodCompare into two variables 2024-10-24 12:44:07 +01:00
Jake Turner 86a81507b5 DXIL Debugger : flesh out DXOp::LoadInput, StoreOutput
Handle all possible types and rowIdx parameter
2024-10-24 08:53:55 +01:00
Jake Turner b42ffd0f7f DXIL Debugger use the SRV component type for the Resource Return Type 2024-10-24 08:51:44 +01:00
Jake Turner 0965bdb004 Fix comment UNORM should have been SNORM 2024-10-24 08:51:06 +01:00
Jake Turner d9d06f120d DXIL Debugger support for Atomic instructions
AtomicExchange
AtomicAdd
AtomicSub
AtomicAnd
AtomicNand
AtomicOr
AtomicXor
AtomicMax
AtomicMin
AtomicUMax
AtomicUMin

Missing support for memory that isn't stack allocated
2024-10-23 08:36:17 +01:00
Jake Turner fa616f0186 DXIL Debugger support for Fence 2024-10-23 08:36:00 +01:00
Jake Turner e25b85ae07 DXIL Debugger support for LoadAtomic, StoreAtomic
Missing support for memory that isn't stack allocated
2024-10-23 08:35:35 +01:00
Jake Turner 51d77d42ae DXIL Debugger helper methods for backing memory 2024-10-23 08:33:31 +01:00
Jake Turner a8220a8214 DXIL Debug Set row and column information for source variable mappings 2024-10-23 08:20:19 +01:00
Mario-CuiandJake Turner 33fa37a475 add as/ms disassembly thread group size display 2024-10-23 08:18:00 +01:00
baldurk e6d0d57f80 Wait for initial remote probe before connecting to server. Closes #3445 2024-10-21 14:30:37 +01:00
Cam MannettandBaldur Karlsson 8e5ab5dd41 New memory scope that clears on after first Apply()
Also:
* Use GPUBuffer instead of own radback memory mechanism, but mark as internal
* Use GPU local buffer for AS builds instead of upload memory to improve performance
2024-10-21 14:30:27 +01:00
Cam MannettandBaldur Karlsson c1e7655309 Build AS on first Apply()
Then clone to captured AS.  This is much faster than building on each Apply().
2024-10-21 14:30:27 +01:00
Cam MannettandBaldur Karlsson 99664cec54 Reset initial contents after serialisation when softmem limit flushing
If an initial content AS was destroyed during active capture then resetting before serialisation meant that VkInitialContents::Free() was called, deref-ing the AS info and causing it to be deleted.

So VkInitialContents is now reset after serialisation to ensure its lifetime.

Change-Id: I6a296bd96dd5b639f68347073298e5545e8f980d
2024-10-21 14:30:27 +01:00
Cam MannettandBaldur Karlsson 26a823135d Use single mem block for AS input data
Rather than have a buffer per geometry, allocate a single block to carry all the input geometry.

Change-Id: Ibc6f221ba0a317e8006ccf4a252da71c0aefe7dc

drbrdt

Change-Id: Ia41dd97fec4f7a2b78fc505dacc0304bbc818789
2024-10-21 14:30:27 +01:00
Cam MannettandBaldur Karlsson d3e721c9b3 Vulkan AS rebuild-on-replay: Serialise and Replay
The VkAccelerationStructureInfo structure is serialised followed by the unified geometry readback buffer.

When the initial state Apply() is called the ASes are built from the input data one at a time so that a single scratch buffer can be built (enlarging when needed) and re-used.  Although this is slower it is necessary on Mali as it has poor space efficiency for the scratch buffer and so can easily OOM a device if all the ASes are built in a single command buffer submission.
2024-10-21 14:30:27 +01:00
baldurk c2912fb259 32-bit compile fixes 2024-10-19 10:30:28 +01:00
baldurk 4cf8f76a3f When trying to patch separability, redeclare gl_CullDistance if used 2024-10-19 01:21:48 +01:00
baldurk 5807426581 Set row and column information for source variable mappings 2024-10-19 01:21:48 +01:00
baldurk 89065d0ef4 Set type for direct scalar source variable mappings 2024-10-19 01:21:48 +01:00
baldurk 6408799b5d Allow specifying scalar pointers in buffer formatter 2024-10-19 01:21:48 +01:00
baldurk 600fd2cb73 Force map flushes for command buffers that may reference arbitrary VAs 2024-10-19 01:21:48 +01:00
baldurk 97ff2d67f8 Fix backwards check for valid referenced ASs during init states 2024-10-19 01:21:47 +01:00
baldurk b4c659eb9a Handle unrolling array-of-pointers for replay-time AS builds 2024-10-19 01:21:47 +01:00
baldurk ac1a680b47 Redeclare bitfields in structs when declaring types 2024-10-19 01:21:47 +01:00
baldurk c6c5702d74 Fix calculation of offsets with bitfields when aligning for pointers 2024-10-19 01:21:47 +01:00
baldurk f0aecfbfa3 Add a log message when vkconfig is detected and warned about 2024-10-19 01:21:47 +01:00
baldurk 3bd65816cf Add a demos test that uses RT with ASs 2024-10-19 01:21:47 +01:00
baldurk 60d2e30f43 Do indirect copy via EI to fetch array of instances layout 2024-10-19 01:21:47 +01:00
baldurk cd2a432cb6 Identify new-barrier ASB flag as equivalent to old-barrier ASB state 2024-10-19 01:21:47 +01:00
Jake Turner d7887ff1d9 DXIL Debugger support for switch instruction 2024-10-17 14:19:08 +01:00
Jake Turner 89526027d2 DXIL Debugger support for vector instructions
ExtractElement
InsertElement
ShuffleVector
2024-10-17 14:19:02 +01:00
Jake Turner cd72381432 DXIL Debugger support for ptr cast instructions
PtrToI
IToPtr
2024-10-17 14:18:55 +01:00
Jake Turner 6a931a4082 DXIL Debugger handle different bit widths for logical operations
And, Or, Xor, ShiftLeft, LogicalShiftRight, ArithShiftRight
2024-10-16 16:48:47 +01:00
Jake Turner bb87fef2cd DXIL Debugger support for float cast instructions
FPTrunc
FPExt
2024-10-16 16:48:39 +01:00
Jake Turner d987baff71 DXIL Debugger support for integer cast instructions
Trunc
ZExt
SExt
2024-10-16 16:48:25 +01:00
Jake Turner 605ff9d2d9 DXIL Debugger support for float/integer cast instructions
SToF
UToF
FToS
FToU
2024-10-16 16:47:42 +01:00
Jake Turner 62a737c713 DXIL Debugger support for Integer division and remainder instructions
Operation::UDiv
Operation::SDiv
Operation::URem
Operation::SRem

Remainder implemented using % which keeps the remainder having the same sign as the dividend
2024-10-16 10:16:37 +01:00
Jake Turner 8074aa4a89 DXIL Debugger support for FRem
Implemented using fmod() which keeps the remainder having the same sign as the dividend
2024-10-16 10:16:27 +01:00
Jake Turner 2bfbe81bde DXIL Debugger support for Integer comparison instructions
Handle different bit widths to IEqual, INotEqual

Added support for:
UGreater
UGreaterEqual
ULess
ULessEqual
SGreater
SGreaterEqual
SLess
SLessEqual
2024-10-16 10:16:17 +01:00
Jake Turner ca2138d283 DXIL Debugger extended support for Add, Sub, Mul instructions
Handle different bit widths
2024-10-16 10:15:51 +01:00
Jake Turner 98c1e6b12b DXIL Debugger extended support for FAdd, FSub, FMul, FDiv instructions
Handle different bit widths
2024-10-16 10:15:27 +01:00
Jake Turner 514f45105a DXIL Debugger extended support for FOrd*, FUnord* instructions
Added support (including half, float, double variants) for:
FOrdGreaterEqual
FOrdLess
FOrdLessEqual
FOrdNotEqual
FOrd
FOrdTrue
FUnord
FUnordEqual
FUnordGreater
FUnordGreaterEqual
FUnordLess
FUnordLessEqual
FUnordNotEqual

Extended existing support of FOrdEqual, FOrdNotEqual to handle half and double variants
2024-10-16 10:12:54 +01:00
Jake Turner fa33bcfbfb Add debug config variable D3D12_Experimental_EnableDXILShaderDebugging
When DXIL debugging is enabled, GetDebugStatus() matches currently supported LLVM instructions and DX.OP calls.
2024-10-16 10:10:40 +01:00
Jake Turner d09235f30a Change Mac github runner to MacOS13 instead of MacOS12 2024-10-15 17:25:39 +01:00
Jake Turner 019bf37a9b Handle more scopes in DXIL Program::GetDebugScopeFilePath
If the scope tree does not end at a DIFile node then use the most recent non-NULL file metadata found when walking the scope tree
2024-10-15 15:55:32 +01:00
Jake Turner 9e747cd06b D3D12_Sharing log any errors when creating shared handle 2024-10-15 12:09:09 +01:00
Jake Turner e378267533 DXIL SettleIDs() assert that all instruction arguments have valid SSA Id
Move the check to its own pass after all instructions have been processed to properly handle loops and phi nodes
2024-10-15 09:37:46 +01:00
baldurk 781dfa47aa Fix magic brew python commands to shut CI up 2024-10-09 14:30:33 +01:00