521 Commits

Author SHA1 Message Date
baldurk dc44d6c271 Make doubles vertex attribute test optional for radv missing support 2021-03-22 18:37:10 +00:00
baldurk 83f99b6e56 Fix compile errors in demos project in linux 2021-03-22 18:37:09 +00:00
baldurk 827a48fe57 Check sampler validity against immutable samplers on serialise 2021-03-15 14:39:21 +00:00
baldurk 7a8b4a4664 Fix compile and code style errors in GL_Simple_Triangle 2021-03-15 09:58:57 +00:00
Jake Turner 1985d126c7 Converted gl_simple_triangle test to OpenGL 4.1 2021-03-14 11:17:31 +00:00
Jake Turner 1e90d20185 Changed GL test default shaders to be version 410 2021-03-14 11:17:31 +00:00
baldurk 438d823c32 Add support for optional physical device features to vulkan tests 2021-03-02 17:08:47 +00:00
baldurk 4a379408f9 Patch VkImageFormatListCreateInfo for MSAA textures
* Since we're using mutable format to cast them to UINT for copies, we need to
  ensure that the correct format is in the create info list.
2021-02-22 12:38:43 +00:00
Jake Turner baf0e3ea70 #error for unknown platform in demos project 2021-02-22 10:34:11 +00:00
Jake Turner f14130fc2d Wrap TEST_ASSERT with do...while(0)
Fix compile errors when doing
if (blah) TEST_ASSERT(cond, message)
2021-02-22 10:34:11 +00:00
Jake Turner 7ab0cac68b Fix C++11 error assign string literal to char*
error: ISO C++11 does not allow
      conversion from string literal to 'GLchar *' (aka 'char *') [-Werror,-Wwritable-strings]
2021-02-18 15:41:40 +00:00
Jake Turner eae38aad8a Added -Werror to demos project 2021-02-18 15:41:40 +00:00
Jake Turner b2b76486a5 Move format.cc from VULKAN_SRC to SRC
Support for building demos on a platform without Vulkan support
2021-02-18 15:41:40 +00:00
Jake Turner 0a7020b557 Fix minor typo checkou -> checkout 2021-02-18 15:41:40 +00:00
Jake Turner 2e47b58b18 Minor updates to demos cmake configuration
Ground work for cmake compilation of demos project on non Linux platform
2021-02-18 15:41:40 +00:00
Jake Turner 46f84675f8 Test compiler to decide to add -std=c++11 option
Copied from renderdoc cmake configuration
2021-02-18 15:41:40 +00:00
Jake Turner b7eebf9f68 Compile error fix for Apple clang version 12.0.0
candidate function not viable: 'this'
      argument has type 'const TestMetadata', but method is not marked const
  bool operator<(const TestMetadata &o)
2021-02-18 15:41:40 +00:00
baldurk 5cb9b90f5f Implement support for VK_KHR_synchronization2
* For the most part we implement this as a thin pass-through layer. Where we
  care about things (image barriers for layout transitions and queue
  submissions) we do two different things:
  - For image barriers, we "downcast" to plain VkImageMemoryBarrier. Currently
    the only thing that's unique to VkImageMemoryBarrier2KHR is extra access
    flags and pipeline stages, which we don't care about. This keeps a lot of
    code from having to either handle two paths or handle the new path and then
    do lots of conversions back to VkImageMemoryBarrier when running on older
    drivers.
  - For queue submissions we do the opposite. We promote old VkSubmitInfo to
    VkSubmitInfo2KHR and process that in a common function, then if necessary
    we decay back to VkSubmitInfo before sending to the driver.
2021-02-17 15:03:52 +00:00
baldurk cf23c35d60 Update vulkan headers to 1.1.170
* Note the sync2 structs aren't properly sorted in vk_next_chains.cpp because
  I'm about to implement it and I'm too lazy to insert them in the right places
  only to go find them all again to remove them.
2021-02-17 14:04:57 +00:00
baldurk 7e6a785055 Add test of vulkan dedicated allocations 2021-02-01 14:43:43 +00:00
baldurk 0513914c42 Test that correct root-constant entry is used for cbuffer values 2021-02-01 13:39:09 +00:00
baldurk 2333cfa2a1 Test that UAV reads in shader debugging read data prior to event 2021-02-01 13:31:23 +00:00
baldurk 6b12864a7b Ensure pixel pack/unpack buffers don't break overlays on GL 2021-02-01 13:22:40 +00:00
baldurk 28bf213382 Test APIs where scissor can be disabled doesn't affect overlays 2021-02-01 13:14:28 +00:00
baldurk 13ead841a4 Add tests of cubemaps on GL
* GL treats cubemaps in a more special/different way than other APIs
2021-02-01 12:49:02 +00:00
baldurk 56c5c18aac Tweak leak threshold on vulkan test
* It seems like some drivers don't free some memory from the resident set until
  a certain point, meaning the peak memory is higher after a couple of captures
  then goes down. This isn't a true leak and us  checking the entire process's
  working set size is a very poor litmus test, so bumping this value is fine.
2021-01-27 00:29:46 +00:00
baldurk 106999a43a Fix leak of descriptor memory during each capture on D3D12 2021-01-25 11:13:28 +00:00
baldurk 5ce6093661 Pick resident set memory for current memory usage on linux
* The virtual size can be much bigger than the actual amount of memory in use
  that we care about.
2021-01-22 14:20:11 +00:00
baldurk 019d75cd0d Fix demos project compilation on linux 2021-01-22 14:19:33 +00:00
baldurk 20d8ae2dcf Fix display of 3D texture slices when linear sampling
* When displaying mip 0 of a texture at less than 100% zoom we linear sampling,
  but we don't want to linear sample across slices. Adding a half pixel offset
  in z ensures we sample precisely on the slice itself.
2021-01-20 17:15:34 +00:00
baldurk 0a5353a398 Test inverse viewport height in VK_Mesh_Zoo, with rendering and picking 2021-01-19 17:20:59 +00:00
baldurk 64131e0510 Test vulkan overalys with rasterizer discard and otherwise invalid state
* E.g. no viewport/scissors bound.
2021-01-19 16:43:57 +00:00
baldurk 086b038d0b Add simple checks for large memory leaks
* Smaller memory leaks are harder to differentiate from noise, so we go for a
  large enough leak to be noticable over time (50,000 frames).
2021-01-19 15:22:12 +00:00
baldurk 84dabc7b54 Update buffer size when it resizes mid-capture. Closes #2149
* We need to be careful with this, as we want to update the buffer's creation
  chunks without invalidating any data that may be present there.
2021-01-18 12:20:16 +00:00
baldurk 86ca794494 Add test to check ID3DDeviceContextState refcounting/rewrapping 2021-01-15 11:33:13 +00:00
baldurk a083680b08 Test that primitive restart is enabled for either GL state 2021-01-13 16:29:01 +00:00
baldurk bb5834fd1c Add test of root signature ranges larger than the descriptor heap 2021-01-13 16:07:43 +00:00
baldurk ec50e9005a Test inline uniform block descriptors in VK_CBuffer_Zoo 2021-01-13 15:32:09 +00:00
baldurk 92192ef348 Add test to ensure vkBindBufferMemory2 can be split up 2021-01-13 14:48:40 +00:00
baldurk f5a99d47a2 Update D3D headers in test project 2021-01-13 14:25:54 +00:00
baldurk 026da176bb Update copyright years to 2021 2021-01-13 13:56:10 +00:00
baldurk a3007ffa05 Make sure BDA capture/replay bit is enabled 2021-01-13 10:42:46 +00:00
baldurk 8ed47fd75a Update vulkan headers to 1.2.166 2021-01-11 15:55:21 +00:00
baldurk b01c84f051 Implement proper handling for unbound views in shader debugging
* We force FetchUAV/FetchSRV to always return something, and it can be empty if
  the resource is unbound meaning we get proper OOB behaviour for it. The D3D12
  implementation still prints an error message for registers that don't
  correspond to the root signature at all, but for D3D11 we silently allow it.
2021-01-05 18:26:27 +00:00
baldurk 9a6ec5282d Don't build GL_Callstacks demo in release
* The nice callstacks we're looking for won't happen in release builds.
2020-12-10 16:56:34 +00:00
baldurk bd342e1596 Fix buffer overrun in D3D12_Draw_Zoo 2020-12-10 16:46:01 +00:00
baldurk 1ab2047ecb Reset state in D3D shader debugging to before draw when fetching UAVs
* Debugging shaders with UAV access could(likely will) have side-effects on
  those UAV contents, so when ContinueDebug needs to fetch UAV contents we
  should replay back to before the draw to fetch them.
* This replay only happens once per ContinueDebug, and UAV contents are cached
  globally so we only do it once per UAV that's accessed, so the impact is low.
2020-12-07 15:41:03 +00:00
baldurk b69ca4526e Log the specific error if vkCreateInstance fails in demo program 2020-12-03 10:59:05 +00:00
baldurk 883e023259 Avoid use of EXT_direct_state_access in tests
* Mesa doesn't implement the EXT version, only the KHR version
2020-11-24 16:47:35 +00:00
baldurk abf7e3bd90 Only declare half type if shaderFloat16 is supported
* Without this, the 16-bit storage only refers to ints (if that feature is
  available).
2020-11-24 16:44:08 +00:00