Commit Graph

14801 Commits

Author SHA1 Message Date
Jake Turner e8ecf2cccb Added D3D11 Pixel History test for pixel shader UAV Write 2024-06-20 11:55:30 +01:00
Cam Mannett 381ece60c6 Non-local child removal fix
The frontend compares the registered child PIDs against the locally running ones, any that aren't in the list are removed - this is how dead procs are removed.  Unfortunately this causes any children from a remote context to be immediately removed.

After discussion with upstream, the agreed solution was to prevent child removal entirely for remote contexts as long as clicking on dead children does nothing.
2024-06-20 11:40:26 +01:00
Jovan Ristic a765ef025d Fix lack of PS UAVs in d3d11 pixel history.
* When a non-zero UAVStartSlot is present, the index in the array and
the slot in the shader do not line up.
* This fixes both the listing for "Usage in Frame" and pixel history
results.
2024-06-20 11:34:53 +01:00
Jovan Ristic 2ee03b3691 Correct usage of shader names.
* GL/Vulkan and D3D11/D3D12 were using reversed terminology.
2024-06-20 11:34:53 +01:00
Jake Turner b6c2824e0f DXIL Disassembly added variable for name of fake input/output structs 2024-06-19 06:46:24 +01:00
baldurk f74a119e05 Remap addresses to live in indirect dispatch on replay 2024-06-18 16:46:12 +01:00
baldurk a8281e91da Demote error to warning for tier 3 descriptor exhaustion
* This is sadly common enough that we will hit it regularly on many D3D12
  programs that just allocate the maximum number of descriptors.
2024-06-18 16:46:12 +01:00
Jasmine Hansen 1ca3f26726 Fix replaying shader object dynamic vertex binds 2024-06-18 13:50:22 +01:00
Jasmine Hansen b8f0196580 Add quad overdraw and tri-size overlay support with shader objects 2024-06-18 13:50:22 +01:00
Jake Turner 8a2d483b40 Update D3D12 ExecuteIndrect argOffset during replay
This fixes D3D12_Execute_Indirect test failure

Only add to m_Cmd->m_RayDispatches when ray tracing is active in the execute indirect
2024-06-17 12:03:51 +01:00
Jake Turner 1ae6882c90 Updated python setup documentation to include instructions for "VS Code" 2024-06-17 10:41:38 +01:00
Jake Turner be0a6ff962 Added DXIL helpers IsDXCNop(), IsSSA(), IsLLVMDebugCall()
IsDXCNop() checks for DXC Nop generated instructions, which take the form of a Load from a global variable called "dx.nothing.*"

IsSSA() checks if a DXIL::Value is an SSA value i.e. from an instruction, not a constant etc.

Store function name from Operation::Call in a const reference instead of making a copy
2024-06-17 10:41:38 +01:00
Jake Turner 49d8c791de DXIL Disassembly rework resource handle display
AnnotateHandle
* Change the SSA result name to be "_typed_descriptor_<N>"
* Show the input handle SSA name instead of the resource alias name

CreateHandleFromHeap
* Change the SSA result name to be "_untyped_descriptor_<N>"

CBufferLoad, CBufferLoadLegacy
* For SM6.6 use the handle alias instead of the cbuffer name

Before:

  _dx.types.Handle _3 = ResourceDescriptorHeap[8];
  _dx.types.Handle __heap_descriptor_0 = (StructuredBuffer<stride=8>)ResourceDescriptorHeap[8];
  _dx.types.Handle _11 = SamplerDescriptorHeap[0];
  _dx.types.Handle __heap_descriptor_1 = (SamplerState)SamplerDescriptorHeap[0];
  _dx.types.Handle _15 = ResourceDescriptorHeap[12];
  _dx.types.Handle __heap_descriptor_2 = (Texture2D<4xF32>)ResourceDescriptorHeap[12];
  _dx.types.ResRet.f32 _19 = __heap_descriptor_2.Sample(__heap_descriptor_1, _.i05, _.i16, Offset = {0, 0});

After:

  _dx.types.Handle __untyped_descriptor_0 = ResourceDescriptorHeap[8];
  _dx.types.Handle __typed_descriptor_0 = (StructuredBuffer<stride=8>)__untyped_descriptor_0;
  _dx.types.Handle __untyped_descriptor_1 = SamplerDescriptorHeap[0];
  _dx.types.Handle __typed_descriptor_1 = (SamplerState)__untyped_descriptor_1;
  _dx.types.Handle __untyped_descriptor_2 = ResourceDescriptorHeap[12];
  _dx.types.Handle __typed_descriptor_2 = (Texture2D<float4>)__untyped_descriptor_2;
  _dx.types.ResRet.f32 _19 = __typed_descriptor_2.Sample(__typed_descriptor_1, _.i05, _.i16, Offset = {0, 0});
2024-06-17 10:41:38 +01:00
Jake Turner fc1e5bb1ad DXIL Disassembly use RD variable type output in AnnotateHandle
i.e.
Texture2D<4xF32> -> Texture2D<float4>
2024-06-17 10:35:57 +01:00
Jake Turner 9825057527 DXIL Disassembly show dx.op.CreateHandle as "InitialiseHandle(...)"
Before

  _dx.types.Handle _bufOut_UAV_structbuf = bufOut;

After

  InitialiseHandle(bufOut);
2024-06-17 10:35:46 +01:00
baldurk d12f5fb5a8 Stop clamping available tier 2024-06-13 14:38:47 +01:00
baldurk c7c9d79ceb Add indirect patching of shader records for indirect ray dispatch
* We use a worst-case estimate of how much scratch buffer space will be needed
  as there's no way to know beforehand on the CPU.
2024-06-13 13:33:06 +01:00
baldurk 652033dbc9 Process ray dispatches in indirect argument lists 2024-06-13 13:33:06 +01:00
baldurk e03c17d079 Refactor ray dispatch patching
* This makes the shader more amenable to running indirectly for indirect
  patching
2024-06-13 13:33:06 +01:00
baldurk 62b2e2226d Commit modified version of intellij-community stubgen & wrapper script 2024-06-13 13:32:58 +01:00
baldurk 4ef1ee5bcc Remove unnecessary and problematic allocator singleton 2024-06-13 13:32:55 +01:00
Louis de Carufel 71ac13e9bf Bookmarks are now listed in menu. 2024-06-13 10:27:41 +01:00
Jasmine Hansen b2644b7f5f Add support for most render overlays with shader objects
Excludes quad overdraw and tri-size
2024-06-12 19:00:15 +01:00
Jake Turner b7b5ec0c14 Remove device scaling factor from margins in the UI
Makes ShaderViewer, Capture Comments and Python Shell margins look correct for non-unit system scaling
2024-06-12 16:37:02 +01:00
Jake Turner a711d219d1 Serialise ShaderDebugInfo::entrySourceName Closes #3353
Required to get the correct entry point when working with remote captures
2024-06-12 15:22:56 +01:00
Jake Turner d031ec4195 Set baseResourceMem for buffer and image resources Closes #3346 2024-06-11 12:05:27 +01:00
Jake Turner 141354a2a4 Extended VK_KHR_Buffer_Address test to cover #3346
One extra draw from GPU memory which doesn't change and is unmapped during the draw loop
2024-06-11 12:05:27 +01:00
Kanglai Qian 27867cc456 extend StoreCompressedTexData for update & subupdate 2024-06-11 11:02:29 +01:00
Joshua Ashton 1a90eed007 Fix segfault with EXT_acquire_drm_display
This needs to be added to HookInitVulkanInstanceExts, like the other KHR_display functions.

Fixes a segfault when Renderdoc'ing SteamVR.

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2024-06-11 10:35:13 +01:00
Jake Turner e99e18e0d6 DXIL Disassembly always show the Buffer index for Store operations
i.e.

bufOut[0] = {_18};
*(&bufOut[0] + 8 bytes) = {_35};
2024-06-07 13:25:58 +01:00
baldurk 9741bacc7b Fix wrong number of shader stages in fixed array 2024-06-07 10:40:41 +01:00
baldurk 9aa57e5aaa Handle root signatures not being specified on pipeline create
* If the root signature is embedded in a shader somewhere we need to pull it out
  for access.
2024-06-06 15:49:06 +01:00
baldurk 80f49ea8e4 On D3D11 destroy swapchain-related resources immediately. Closes #3343
* During capture if ResizeBuffers is called we can't defer destruction to the
  end of the capture as it will cause the function to fail due to refcounting
  rules.
2024-06-06 14:55:25 +01:00
baldurk 1bdffb18a6 Fix access to incorrect GPU address tracker 2024-06-06 14:55:24 +01:00
Jake Turner d6c94b20bc DXIL Debugger preparation changes
Add DXILDebug::[Debugger,ThreadState] as friends to DXIL::Program
Expose DXIL::isUndef(const DXIL::Value* v); for use in the DXIL Debugger
Add more stubs to DXILDebug::[DebugAPIWrapper, ThreadState, GlobalState]
2024-06-06 12:15:03 +01:00
Jake Turner 5d4d3e0c0d Fix incorrect parameter argument to DXIL::Program::ArgToString 2024-06-06 12:09:29 +01:00
Jake Turner 6749ad1770 Remove static DXIL::dxcStyleFormatting and DXIL::dxilIdentifier
Pass in bool dxcStyleFormatting parameter to helper functions
Derive dxilIdentifier from dxcStyleFormatting i.e. '%' or '_'
DXIL Debugger and RD Disassembly specific helper methods choose to use "dxcStyleFormatting = false"
2024-06-05 15:09:01 +01:00
baldurk ad35a251b0 Add PR/Push specific commit message handling in CI
* The previous ignoring of the top commit was to avoid badly-written merge
  commits added by github, we want to continue doing that for PRs but check all
  commits on push as a safety measure.
2024-06-05 13:47:18 +01:00
baldurk 1b81c02919 Add GLES clip control extension equivalence. Refs #3336 2024-06-05 13:11:44 +01:00
Jake Turner e64bf288b0 Tweak Mac CI workflow to fix github CI warnings 2024-06-04 13:32:02 +01:00
baldurk 6134e05525 Update checkout actions on CI 2024-06-04 11:10:21 +01:00
baldurk 9b62337a13 Compile fixes 2024-06-04 10:40:00 +01:00
baldurk a7e9a60280 When patching mesh shaders only consider globals for its entry point
* For shaders with multiple entry points we can't process outputs for other
  entry points that may not be arrayed.
2024-06-04 10:08:08 +01:00
baldurk af67b951de Ensure descriptor sizes are properly initialised in default pipe state 2024-06-04 10:08:08 +01:00
baldurk aecaa7e208 Calculate texture byte sizes as 64-bit on GL and Vulkan. Closes #3338 2024-06-04 10:08:08 +01:00
baldurk 44f9f24ace Add correct support for GL_EXT_clip_control on GLES. Closes #3336 2024-06-04 10:08:08 +01:00
Jake Turner 70d93f14db DXIL Disassembly small tweaks
Change some RDCASSERT(a == b); to RDCASSERTEQUAL(a,b); now that the stringise exists for the data types
2024-06-03 17:31:08 +01:00
Jake Turner f4e361eba8 Fix spelling mistake "preceeded" in DXIL Disassembly output 2024-06-03 13:55:38 +01:00
Jake Turner dcaba505cd DXIL Disassembly Refactoring to use GetArgId instead of ArgToString 2024-06-03 13:48:12 +01:00
Jake Turner 38340e3cb1 DXIL Debugger foundation refactoring
Removed "rdcstr Program::GetResourceReferenceName(ResourceClass resClass, const BindingSlot &slot) const"
Moved "DXIL::BindingSlot" to "DXILDebug::BindingSlot"
2024-06-03 13:06:54 +01:00