Commit Graph

886 Commits

Author SHA1 Message Date
baldurk 0d9ea809dd Fix some test failures by consistently stripping gl_PerVertex_Var prefix 2023-11-17 18:47:47 +00:00
baldurk d9fd975138 Add a test of unmapping read-only persistent buffers on GL 2023-11-15 14:51:04 +00:00
William Pearson 9cf30b190e Fix crash when descriptor update template uses unreferenced layout
It is possible for the VkDescriptorUpdateTemplateCreateInfo to have its
descriptorSetLayout or pipelineLayout be the only reference to the
corresponding object, as vkCmdPushDescriptorSetWithTemplateKHR and
vkUpdateDescriptorSetWithTemplate only require that the actual layout
matches/is compatible with the one used by the template. Before, there
was no dependency from the update template to the layout, so if it was
the sole use of a layout, the layout would not be saved in the capture,
resulting in a crash during playback.

This change also modifies the vk_parameter_zoo to test this case. With
those modifications, the change to vk_descriptor_funcs is required to
prevent the crash. Note that on my machine, I needed to comment out
other parts of vk_parameter_zoo, or else it would crash (even when
not run under renderdoc) due to driver issues.

For reference:

https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkCmdPushDescriptorSetWithTemplateKHR.html#VUID-vkCmdPushDescriptorSetWithTemplateKHR-layout-07993
https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkUpdateDescriptorSetWithTemplate.html#VUID-vkUpdateDescriptorSetWithTemplate-pData-01685
https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDescriptorUpdateTemplateCreateInfoKHR.html#_members
2023-11-09 10:15:00 +00:00
Dan Hawson 0ff1c66ca7 Removed demos project reference to '.clang-format' file
This was added by mistake in an earlier commit.
2023-11-08 15:25:36 +00:00
Dan Hawson 910f1dcd7e Add new d3d12_multi_wait_before_signal.py test
It's currently forcibly disabled via 'check_support' because it's known
to fail due to the fact that the commands are always serialised and
replayed in submission order instead of the order that respects queues
blocked on fence waits that get signalled later from other queues.
2023-11-08 15:25:36 +00:00
Cam Mannett ec408e21c0 Android extra flags not applied on initial CMake generation
CMAKE_CXX_FLAGS was overwritten if not already in the cache (i.e. when first built).  Presumably down to toolchain loading order.
2023-11-07 19:01:04 +00:00
Jake Turner cf004e8ba5 Basic tests for non-zero UNPACK_ROW_LENGTH and glTexImage?D APIs
Covers:
glTexImage1D
glTexImage2D
glTexImage3D
2023-11-06 12:02:50 +00:00
Jake Turner b19665212c Fix demos compile error on Linux & Android 2023-11-05 13:10:53 +00:00
Dan Hawson 7619414b8a Add multi-queue wait-before-signal test
This tests submitting commands, signals, and waits to graphics and
multiple compute queues where the entire frame's submission for each
queue depends on the other queues and the submission order is not the
order in which the GPU (and replay) need to be processed.  This is to
ensure any capture or replaying deserialises adequately.
2023-11-03 10:46:42 +00:00
Dan Hawson fb02202505 New D3D12BufferCreator and D3D12TextureCreator state setters
Added 'D3D12BufferCreator::InitialState(D3D12_RESOURCE_STATES)' to allow
user code to avoid adding unnecessary transition barriers after resource
creation.

Added 'D3D12TextureCreator::ClearVal(const D3D12_CLEAR_VALUE &)' to avoid
a PIX performance warning/tip about clearing resources that haven't had
their clear value set on creation.
2023-11-03 10:46:42 +00:00
Jake Turner 3fbf060894 Test for very large variable sized descriptor binding
New Binding 3
Initial size is UINT32_MAX
Updated to be sized DESC_ARRAY3_SIZE
Used in the shader to ensure the binding is referenced

Stress tests the FetchShaderFeedback code when it computes the maximum size of feedbackStorageSize.
2023-11-01 14:53:06 +00:00
Cam Mannett aec25cfcaa Add -Wno-deprecated-declarations to demo when NDK >=26 is used
Compiles the demo APK with -Wno-deprecated-declarations when the NDK is v26 or over, otherwise it fails to compile the fmt core header.  In the LLVM version used in the NDK, using std::char_traits with non-std types is marked as deprecated.
2023-10-27 18:12:15 +01:00
Cam Mannett 3746f83039 Minor functional test fixes
* Fixed issue where a previously built demo APK would be added into the APK archive upon next build
* Correct the functional test's --in-process help output
2023-10-26 15:38:48 +01:00
baldurk dd4e0d44ad Do two-pass processing of pNext chains for strict validity. Closes #3093
* We first need to do a pass to find extension structs that affect validity of
  pointers (whether they're ignored or not), then do a pass to process.
2023-10-25 17:56:38 +01:00
baldurk b6470b03de Add a delay after Compute_Only tests to allow capture to be found 2023-10-25 17:56:38 +01:00
Jake Turner 5b8c8e30a4 Changes to Android demos to support RenderDoc capture
Change package name to "renderdoc.org.demos" instead of "org.renderdoc.demos" (RenderDoc filters out packages containing "org.renderdoc.")

Added an <intent-filter> to the Android manifest.
This registers the activity with the android package system which means RenderDoc Launch Application knows the activity name to launch.
Used category CATEGORY_ALTERNATIVE to prevent the activity from appearing on the launcher UI.
2023-10-10 16:12:36 +01:00
Steve Karolewics e1516fa521 Add D3D12 pixel history test
This is a basic test that mirrors the Vulkan pixel history test,
but repeats draws multiple times to verify SM5.1 and SM6.0.
SM6.6 should be tested as well for writes from direct heap access
but is not yet implemented differently than SM6.0.
2023-10-10 11:50:55 +01:00
Steve Karolewics bad922e1f4 Allow providing NULL shaders for D3D12PSOCreator 2023-10-06 11:26:20 +01:00
Jake Turner b835a4cbad Abs x,y for pixel history in Iter_Test python script
Prevents exceptions about uint32_t overflow if negative x or y is used
2023-10-02 09:06:08 +01:00
Eric Long f36d8a3b23 RISC-V support
With some addition to macros the project is able to build on riscv64
machine.

plthook has added RISC-V support upstream [1]. However upstream has
changed their code quite a bit, so I just modified the current vendored
version.

[1]: https://github.com/kubo/plthook/commit/a564738a4707fc5eb4d388b9e97eeab51b8c9d56
2023-09-29 17:26:11 +01:00
baldurk 81cbd7f404 Add delay to empty capture tests to ensure the capture propagates 2023-09-20 12:06:21 +01:00
baldurk d88eff15f3 Update execute indirect test to verify more complex EI behaviour 2023-09-18 12:19:36 +01:00
baldurk 92f4aeacde Fix compile error on some clangs with non-const string literals 2023-09-13 16:25:09 +01:00
baldurk 1bfe6d1492 Add dedicated test for VK_Counters so GPU duration isn't degenerate
* Some cards run it so fast that the triangle takes "0" microseconds
2023-09-12 21:53:23 +01:00
Jake Turner c72a79988d Only do the overlay mip subresource tests once 2023-09-10 09:39:19 +01:00
Jake Turner 93506245c4 Add format name to overlay test python logging 2023-09-10 09:39:19 +01:00
Jake Turner 78a64f8640 Extend Overlay tests to handle more depth stencil formats : D3D12
D32_S8, D24_S8, D32, D24, D16
2023-09-08 22:38:01 +01:00
Jake Turner cfdb349cdb Extend Overlay tests to handle more depth stencil formats : D3D11
D32_S8, D24_S8, D32, D16
2023-09-08 22:38:01 +01:00
Jake Turner 8459229441 Extend Overlay tests to handle more depth stencil formats : Vk
D32_S8, D24_S8, D32, D24, D16
2023-09-08 22:38:01 +01:00
Jake Turner 40090fb779 Extend Overlay tests to handle more depth stencil formats : GL
D32_S8, D24_S8, D32, D24, D16
2023-09-08 22:38:01 +01:00
Jake Turner 163f2ff747 Fix validation error in Vk_Overlay_Test 2023-09-07 09:48:57 +01:00
baldurk 9d39b8e1a8 Reformat code for clang-format 15 2023-09-05 11:02:08 +01:00
Jake Turner bfe89e4c17 Extended test to include a test for GL uniform array of size 1
ie.
uniform float2_struct M[1];
2023-09-05 09:36:11 +01:00
William Pearson 71e886cecc Add demo/test for many primitives hitting the same pixel in one drawcall 2023-08-09 10:58:04 +01:00
baldurk d23cf4bf0b Allow a little latitude on expected line numbers in callstacks test 2023-08-04 17:06:03 +01:00
baldurk 65859d13bf Add test of Set*Root32BitConstants with 0 constants being set
* This crashes on nvidia, on compute only strangely, if we pass in a NULL
  pointer along with a 0 number of constants.
2023-08-04 17:06:03 +01:00
Jake Turner 117db087a4 Vk tests ignore default pipeline in headless mode
Fixes crash trying to launch VK_Compute_Only
2023-07-20 17:26:30 +01:00
Jake Turner 53bf231104 Extend D3D12 Execute Indirect test
Change it to do 8 indirect draws with a clear in between.
Check the pixel and mesh data for each draw is correct (simple triangle)
2023-07-03 13:05:10 +01:00
baldurk 472add2f51 Fix autotests for new global resources 2023-06-21 12:43:33 +01:00
baldurk 5118f08e23 Update Vulkan & SPIR-V headers to latest 2023-06-15 13:56:10 +01:00
baldurk 7f8e14fb65 Add some helpers to make minimal templates for each autotest API 2023-06-15 11:25:27 +01:00
baldurk 91b084a2df Update D3D12 headers to verison 1.610.1 2023-05-19 13:28:04 +01:00
baldurk d57a7c9979 Fix error message in D3D12 compute test 2023-05-18 17:04:39 +01:00
Jake Turner bd545cb9b6 Remove unintentional use of nullptr 2023-04-25 14:09:01 +01:00
baldurk cc3d383287 Manually check depth bounds test in vulkan pixel history 2023-04-14 16:08:10 +01:00
baldurk fb0b643c55 Mark non-final fragments as having unknown stencil in pixel history 2023-04-14 16:08:10 +01:00
Jake Turner b692626839 Synchronize Metal-CPP from renderdoc to demos 2023-04-12 10:50:09 +01:00
Jake Turner 4ae4116f85 Synchronise Metal-CPP between driver and demos
Added

CA::Layer* NS::View::layer() const;
2023-04-12 10:50:09 +01:00
baldurk c353f6fe6d Add memory readback microbenchmark 2023-03-23 16:16:03 +00:00
baldurk 448b78ca68 Bare bones port of demos project to android 2023-03-23 16:16:03 +00:00