Commit Graph

13516 Commits

Author SHA1 Message Date
baldurk 2e276a7f84 Remove rdcarray sized constructor 2022-11-09 13:22:53 +00:00
baldurk 2cf7b911c7 Fix refcounting issue with python frame objects 2022-11-09 12:20:48 +00:00
baldurk 742e3de252 Cache expanded views from large immutable D3D12 descriptor heaps
* The principle here is that on D3D12 it's common to have huge descriptor heaps
  in which only a handful of descriptors are changed. By caching the expanded
  D3D12Pipe::View results from these unchanging descriptors we don't have to do
  that over and over. Any descriptors written in the captured frame may have
  different contents depending on where we've replayed up to, so we don't cache
  them to keep things simple rather than invalidating the cache.
2022-11-08 17:42:18 +00:00
baldurk ffe09f1cb0 Do a better job of reserving memory for D3D12 pipeline state arrays 2022-11-08 16:26:09 +00:00
baldurk a21b78f55a Treat custom heaps on D3D12 with appropriate properties as CPU-copied 2022-11-08 16:16:31 +00:00
baldurk aacbaa77fb Refactor D3D12 map to do CPU uploads directly into mapped memory 2022-11-08 15:46:04 +00:00
baldurk 909b400683 Increase the data upload list array to 64 to reduce mid-frame syncs 2022-11-08 15:40:29 +00:00
baldurk 94c6b36e44 Don't mark draws as having valid empty feedback results 2022-11-08 15:40:16 +00:00
baldurk c4088be170 In-line buffer -> MSAA copies into command buffer rather than splitting
* We defer destruction of the view objects created until the next flush. In
  future this could be smarter about associating resource destructions with a
  submitted batch and deferring further until a fence is signalled to avoid
  synchronisation.
2022-11-08 13:12:35 +00:00
baldurk e400e9c4f6 Use initial state command buffer for memory 2022-11-08 13:12:35 +00:00
baldurk 4a6c34ac11 Account for D3D12 applications that call CheckFeatureSupport often
* The log is spammy if they check once per frame for example.
2022-11-08 13:12:35 +00:00
Sebastien Alaiwan 3bfea49a2d Fix uninitialized variable 2022-11-07 13:31:27 +01:00
Oliver Enseling 5451acedc1 source home directory from ${HOME} 2022-11-04 20:34:48 +01:00
baldurk 672557f8fa Add some internal logging for D3D12 CheckFeatureSupport calls 2022-11-04 17:42:23 +00:00
baldurk 8e4ae67929 Only apply D3D12Core.dll signature check to untrusted files
* UE5 at least currently (as of this commit) re-signs D3D12Core.dll by Epic.
  Rather than failing to load all such captures, only fail if the capture is
  marked as downloaded since local captures should be implicitly trusted.
2022-11-04 17:42:23 +00:00
Brian Osman 7a3ea53b3d vkEnumeratePhysicalDevices: Handle count being too small
Per the Vulkan Spec: "If pPhysicalDeviceCount is less than the number of physical devices available, at most pPhysicalDeviceCount structures will be written, and VK_INCOMPLETE will be returned instead of VK_SUCCESS, to indicate that not all the available physical devices were returned."
2022-11-03 16:48:55 +01:00
baldurk 95ade35dab Implement vkSetDeviceMemoryPriorityEXT and allow extensions 2022-11-03 12:47:13 +00:00
baldurk 86807180d1 Implement memory oversubscription vulkan extensions 2022-11-02 16:49:48 +00:00
baldurk 30453eb8ce Treat it as valid if no shaders that use dynamic resources are invoked
* E.g. if a draw is off-screen, the PS might not be invoked. If that's the only
  place we expect to see dynamic resources accessed we won't get our valid
  marker but the results should still be considered correct.
2022-11-02 15:29:16 +00:00
baldurk 9df7d40241 Fix compilation on python version update on mac CI 2022-11-02 12:22:33 +00:00
baldurk 32dbbaa707 Correctly handle D3D12 resources with no sparse subresources at all 2022-11-01 16:33:37 +00:00
baldurk 52b5a8954e Update superluminal API header to most recent version 2022-11-01 16:33:37 +00:00
baldurk 3f9bf1ab27 Fix crash handler not launching as expected in official builds 2022-11-01 16:33:37 +00:00
baldurk 2c220e7af0 Fix calculation of offsets on root descriptor buffers
* The stride these buffers are accessed with in the shader is not guaranteed to
  be 4 bytes when used untyped (e.g. structured buffers) so we can't assume it
  and bake the offset into element count. Instead fetch data starting at that
  offset and list a first element of 0.
2022-11-01 16:33:37 +00:00
baldurk 72d4d2702d Remove references to Stadia 2022-10-28 15:36:26 +01:00
baldurk 7393c6db5a Don't refer specifically to windows 10, include all versions
* Windows versions numbers no longer make sense since 11 is just 10 with a worse
  UI refresh, but since it works the same it will be supported as well.
2022-10-28 15:36:15 +01:00
baldurk 1303a50cf5 Sampler tables should not be marked as data volatile (the default) 2022-10-28 14:13:06 +01:00
baldurk 91a77c1698 Re-order builtin inputs to try and avoid suspected AMD driver bug
* In principle the fake SV_ inputs should be able to come in any order, but it
  seems if SV_IsFrontFace is last it can get undefined/wrong results (e.g.
  returning 1 when front-face culling is enabled or vice-versa). Moving it to
  the first seems to fix the issue, and at least shouldn't make anything any
  worse.
2022-10-28 14:12:51 +01:00
baldurk 28b63fe56c Protect against invalid values in view desc for number of mips
* This is mostly relevant for D3D12, where the desc comes from the user and so
  may not be normalised and contain values like 0xffffffff to indicate 'all
  mips' or 'all slices' in the view.
2022-10-28 11:41:43 +01:00
baldurk 6f29b8b939 Work around fxc warnings when building with optimisation disabled 2022-10-27 16:22:54 +01:00
baldurk 3f31671cc3 Use existing depth value to better select candidates for debug on D3D12 2022-10-27 16:05:07 +01:00
baldurk 9e9a333b56 Fix D3D shader debug ddx/ddy being the wrong way around 2022-10-27 16:04:35 +01:00
baldurk d9d06c8390 Fix handling of RANGE_OFFSET_APPEND in multi-type tables in D3D12
* Previously we would only process ranges we were interested in when looking for
  a descriptor, but we need to process all ranges in a table to properly track
  the offset for APPEND.
2022-10-27 11:00:23 +01:00
baldurk 85118ed46c Remove unused variable 2022-10-26 17:47:16 +01:00
baldurk e36c247c6e Upgrade some non-spammy useful log messages from debug logs 2022-10-26 17:09:23 +01:00
baldurk 10d4c69433 Skip unmapped subresources when serialising sparse init states on D3D12 2022-10-26 17:09:05 +01:00
baldurk 4612d71df5 Switch some maps to unordered in resource manager 2022-10-26 13:08:17 +01:00
baldurk 972f56d45a Display type-incompatible bindings overlapping in GL in pipeline view
* This is possible if two sampler uniforms point to the same slot but they are
  not compatible sampler types.
2022-10-21 16:21:34 +01:00
baldurk bdff6cd855 Delete orphaned file 2022-10-20 16:12:34 +01:00
baldurk ea4aa16455 Force custom display shaders VS explicit output location. Closes #2757
* This works around an obtuse GL requirement that explicit locations on one side
  will cause a break in compatibility with the other side, even if dropping the
  location would work otherwise.
2022-10-20 12:50:00 +01:00
baldurk 71684f1003 In VK pipeline view, look up FB from RP attachments. Closes #2756
* Doing this lets us more consistently reference the color attachments in the
  correct indices and makes it easier to match for blends. It also allows the
  user to show unused/empty attachments
2022-10-20 12:36:49 +01:00
baldurk 101dbda8c3 Handle GL hooks called during replay from injected code. Refs #2752 2022-10-18 10:21:04 +01:00
baldurk d024f062c2 Work around gcc 5 false warning 2022-10-14 20:50:51 +01:00
baldurk 33f9f43f7d Handle more than 3 queue family types correctly 2022-10-14 15:18:41 +01:00
baldurk 0dbb38c92e Avoid repeated erase+reorder when resetting pagesets 2022-10-14 14:44:07 +01:00
baldurk e38b4e0fff Add support for VK_EXT_mutable_descriptor_type 2022-10-14 12:06:09 +01:00
baldurk 7798d2e114 Check for shader processing tool failures properly. Closes #2751 2022-10-14 12:00:54 +01:00
baldurk 9a22b2cf46 Remove old android prototyping code 2022-10-14 12:00:54 +01:00
baldurk 835990b052 Ensure texture-generated formats default to scalar packing
* On APIs like OpenGL texture formats (like vertex buffer formats) can be
  tightly packed even in cases that apparently are otherwise not allowed - e.g.
  with fake RGB formats where the stride looks misaligned due to alpha being
  hidden.
2022-10-14 11:51:26 +01:00
baldurk a112e1ad96 Use a default name for un-named children in constant structs 2022-10-13 14:52:37 +01:00