platform/upstream/VK-GL-CTS.git
2 years agoRemove api.tooling_info.validate_instance_layers
Arkadiusz Sarwa [Tue, 7 Dec 2021 17:22:32 +0000 (18:22 +0100)]
Remove api.tooling_info.validate_instance_layers

Remove:
dEQP-VK.api.tooling_info.validate_instance_layers

Components: Vulkan
VK-GL-CTS issue: 3395

This reverts commit 7628909f404f665eb54c6a5019386747fb631134.

Change-Id: I68de938e73c10fed80d4e9bb3698b513a1b44315

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 14 Jan 2022 05:19:30 +0000 (05:19 +0000)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I7ec0667baf95d997230a8befced3ca4f2cda4876

2 years agoFix sType Tooling Info tests
Mohankumar Nekkarakalaya [Wed, 12 Jan 2022 21:23:25 +0000 (13:23 -0800)]
Fix sType Tooling Info tests

Tooling Info tests were not setting the sType correctly. This goes
against spec
where "sType must be
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TOOL_PROPERTIES_EXT". These
tests also check this sType to validate functionality.

Components: Vulkan

Affects:
dEQP-VK.api.tooling_info.*

VK-GL-CTS issue: 3444

Change-Id: Ic72104261a577d7d767742d4b2828296eba3922c

2 years agoDeqpTestRunner: fix deqpLogFilename
Paul Thomson [Fri, 3 Dec 2021 16:48:36 +0000 (16:48 +0000)]
DeqpTestRunner: fix deqpLogFilename

Fix capitalization of shell argument "deqpLogFilename" in
DeqpTestRunner.java. The code still worked fine in most cases because
the default filename matches the filename passed in DeqpTestRunner.java.

Components: Android
Google bug: b/206657494

Change-Id: I857fa3994ada72aa96d199569704a46034255309
(cherry picked from commit 42017ff7072dcc7e7a7d51dd5611be05abf5460f)

2 years agoAdd format check to SharedPresentableImageTest
Mikolaj Chadzynski [Thu, 23 Dec 2021 08:38:54 +0000 (09:38 +0100)]
Add format check to SharedPresentableImageTest

The SharedPresentableImageTest does not follow Vulkan spec.
The SurfaceFormats got by getPhysicalDeviceSurfaceFormats ->
getPhysicalDeviceSurfaceFormatsKHR should be checked by
vkGetPhysicalDeviceImageFormatProperties. This is according to:
www.khronos.org/registry/vulkan/specs/1.2-extensions/html/chap33.html
"33.5. Surface Queries
In addition to the surface capabilities as obtained by surface queries
below, swapchain images are also subject to ordinary image creation
limits as reported by vkGetPhysicalDeviceImageFormatProperties. As an
application is instructed by the appropriate Valid Usage sections, both
the surface capabilities and the image creation limits have to be
satisfied whenever swapchain images are created."

Unsupported format can lead to non-deterministic behavior e.g.
a segmentation fault, a null pointer dereference in a test or a driver.

VK-GL-CTS issue: 3422

Affects:
dEQP-VK.wsi.android.shared_presentable_image.*

Components: Vulkan

Change-Id: Id4bb4d1c81e090ed1d7f34a76f3cfafc464d8cf8

2 years agoAdditional warning fix for Clang 13
Ricardo Garcia [Thu, 9 Dec 2021 14:23:57 +0000 (15:23 +0100)]
Additional warning fix for Clang 13

Fixes warning about unused variable. No test results should be affected
by this change.

Components: Vulkan
VK-GL-CTS issue: 3147

Change-Id: Ib7c0425891e33e65e22ed90668aa3d0d7eae85df

2 years agoFix mismatched ray payload in descriptor set random tests
Ricardo Garcia [Tue, 14 Dec 2021 10:08:16 +0000 (11:08 +0100)]
Fix mismatched ray payload in descriptor set random tests

Miss shaders had a ray payload declaration that didn't match other
shading stages.

Affected tests:
dEQP-VK.binding_model.descriptorset_random.*.miss.*

Components: Vulkan
VK-GL-CTS issue: 3412

Change-Id: I4473a883248bc9d572e6112da82bc4c774689071

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 7 Jan 2022 06:07:01 +0000 (01:07 -0500)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I85eab03afdf24359556917617b56856b51b7eb07

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Thu, 6 Jan 2022 22:45:47 +0000 (17:45 -0500)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: Id711f3ba5558c490c3629051677c7f41ec2da2d6

2 years agoFix warnings reported by clang 13
Ricardo Garcia [Fri, 10 Dec 2021 13:54:01 +0000 (14:54 +0100)]
Fix warnings reported by clang 13

This commit fixes code that was producing warnings when built using
clang 13. They are mostly about unused variables and null pointer
substractions, but the new code should be semantically the same.

No test results should be affected by these changes.

Components: Framework, Vulkan, OpenGL
VK-GL-CTS issue: 3147

Change-Id: I0eb87c17270a610c8b29ec27ae8e10009053f8e1

2 years agoRename various things for more inclusive language
Jari Komppa [Fri, 19 Nov 2021 13:16:54 +0000 (15:16 +0200)]
Rename various things for more inclusive language

This change renames various things to avoid gender-specific or degatory
terms.

Khronos inclusive language policy:
https://www.khronos.org/about/inclusive-language

Majority of the changes are due to the term 'dummy', as in mannequin or
placeholder, which in programming may mean any of empty, placeholder,
unused, minimal, busywork, ignored or irrelevant.

Changes not included are file names (gluDummyRenderContext), test names
(dummy_instruction_set) or branch names (master).

Affects:
*

Components: Framework, Vulkan, OpenGL
VK-GL-CTS issue: 2509

Change-Id: I3837477a1b3de1142e8d97c503890ccbce9138f8

2 years agoRemove vkDestroyBuffer
Ari Suonpaa [Tue, 14 Dec 2021 05:27:53 +0000 (07:27 +0200)]
Remove vkDestroyBuffer

A buffer allocation test that is supposed to fail a large
allocation still tried to destroy the buffer even when an
error was returned from the allocation. This is now removed.

VK-GL-CTS Issue: 3192

Affects:

dEQP-VK.api.buffer.basic.size_max_uint64

Components: Vulkan
Change-Id: Ic36cb548ab2796b41e2a0b44d023e644b02a6d8c

2 years agoAvoid querying non-supported hardware features
Jari Komppa [Tue, 23 Nov 2021 10:53:00 +0000 (12:53 +0200)]
Avoid querying non-supported hardware features

Change the feature query test to avoid querying information on hardware
features that are not supported. This is done by querying non-existing
feature (max_enum) instead, which must be ignored by implementations.

The change also adds comment to all generated files stating what script
generates the files.

Affects:
dEQP-VK.api.info.get_physical_device_properties2.features

Components: Vulkan
VK-GL-CTS issue: 2853

Change-Id: I24a3832abc0721e649edbb112bd7f776c2b5d7f4

2 years agoDisable two warnings for old Amber versions
Mika Väinölä [Mon, 13 Dec 2021 11:00:05 +0000 (13:00 +0200)]
Disable two warnings for old Amber versions

Older versions of Amber fail to build with Clang >= 11 and GCC >=11 due
-Werror and warnings that have been fixed in later versions. Upgrading
Amber in older CTS branches risks accidental downgrades during fix
propagation. This change disables -Wsuggest-destructor-override for
Clang and -Wuninitialized for GCC when building libamber. These
should be re-enabled in newer Vulkan CTS releases.

Components: Framework, Vulkan

VK-GL-CTS issue: 3361

Change-Id: Ifc2ed69584d8ad179042b80212e02ceb9956d110

2 years agoZero initialize array in internal tests
Mika Väinölä [Wed, 1 Dec 2021 10:24:52 +0000 (12:24 +0200)]
Zero initialize array in internal tests

This suppresses a -Wmaybe-uninitialized warning in GCC 11 release
builds.

Affects: dE-IT.delibs.decpp.block_buffer

Components: Framework

VK-GL-CTS issue: 3378

Change-Id: I2315b5cdeecb6e9a54dd419c88134f30a3335029

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Thu, 9 Dec 2021 17:41:52 +0000 (17:41 +0000)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I837a41fd83ac421e799900ff74df8b4daa549ecc

2 years agoReduce complexity of some random cases
Jari Komppa [Wed, 8 Dec 2021 14:10:04 +0000 (16:10 +0200)]
Reduce complexity of some random cases

This change adds a complexity heuristics to some random cases and
reduces the final nested array size to avoid complexity explosion.

In practice only 18 test cases out of 1576 are affected.

Affects:
dEQP-VK.ubo.random.*

Components: Vulkan
VK-GL-CTS issue: 3389

Change-Id: If108ce2f04272b7bae9799daffa3682d1fb3aa52

2 years agoGCC 11 build fixes
Mika Väinölä [Wed, 10 Mar 2021 11:16:38 +0000 (13:16 +0200)]
GCC 11 build fixes

Some files used std::numeric_limits without including <limits> and
failed to compile.

VK-GL-CTS issue: 2842

Change-Id: I5bd290f9c312a30c2fcb223307c7b5c785a0fa92
(cherry picked from commit c686fd7ddf13d9ec51c84aea044d36ef3dd69c68)

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Fri, 3 Dec 2021 16:51:10 +0000 (11:51 -0500)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I0adccdf3f29176238bd4ca92fe8c9aa380986f43

2 years agoRelax protected heap allocation tests - continuation
Tomasz Gregorek [Fri, 29 Oct 2021 08:01:54 +0000 (03:01 -0500)]
Relax protected heap allocation tests - continuation

Some implementations have limitations on protected heap
allocations, and these limitations cannot be queried
using the Vulkan API. This change allows an out-of-memory
to happen after a certain number of allocations to
compensate that.

Fix protected memory allocation to be done on small
allocation chunks and ignore allocation failures
if there is at least 80 of concurrent allocations
at a time.

VK-GL-CTS issue: 3257

Affects:
dEQP-VK.memory.allocation.random.*

Components: Vulkan
Change-Id: I32ed020195ff468de468bbd8527dec1d7f0db183

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Thu, 18 Nov 2021 21:52:19 +0000 (16:52 -0500)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I888aaa5fc93ef69f75c6f3a31ab2a02202028cbd

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Thu, 18 Nov 2021 19:56:13 +0000 (19:56 +0000)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I627fd4331d6dcf4f56a90b8a348dd1294e911e64

2 years agoGCC 11 build fixes
Mika Väinölä [Wed, 10 Mar 2021 11:16:38 +0000 (13:16 +0200)]
GCC 11 build fixes

Some files used std::numeric_limits without including <limits> and
failed to compile.

Some dynamic casts and calls to AndroidHardwareBufferExternalApi::
getInstance() produced nonnull warnings. Suppress these by
wrapping them in if statements.

This commit also removes implicit-fallthrough from the list of ignored
GCC warnings in check_build_sanity.py. All such warnings in the CTS
should be fixed by now and recent versions of Clang also support
this warning.

VK-GL-CTS issue: 2842

Change-Id: I5bd290f9c312a30c2fcb223307c7b5c785a0fa92

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Thu, 4 Nov 2021 20:45:39 +0000 (16:45 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I1c61bd275a7161d071ad79aa493c6634582391a2

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Thu, 4 Nov 2021 20:45:32 +0000 (16:45 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: Ice8e3ca5f949d6c134f91a7d5317ab5892d5147d

2 years agoCheck shaderInt64 in workgroup memory explicit layout alias tests
Ricardo Garcia [Thu, 14 Oct 2021 11:27:46 +0000 (13:27 +0200)]
Check shaderInt64 in workgroup memory explicit layout alias tests

A few workgroup memory explicit layout alias tests were not checking
shaderInt64 while using 64-bit integers in shaders.

Affected tests:
dEQP-VK.compute.workgroup_memory_explicit_layout.alias.*u64*array*
dEQP-VK.compute.workgroup_memory_explicit_layout.alias.*array*u64*

Components: Vulkan
VK-GL-CTS issue: 3131

Change-Id: I1911018c471e9548603d5de987625163bb356eb9

2 years agoAllow NaN result when result exceeds limit
Mohankumar Nekkarakalaya [Thu, 21 Oct 2021 00:14:08 +0000 (17:14 -0700)]
Allow NaN result when result exceeds limit

Based on spec if the result is too large to be represented
in the floating point the result is undefined.

Issue was found with ldexp. Since fix is applicable in general
updated the isFinite() to take maxValue and checks the interval value
with the allowed max value in the context (and similarly for
negative numbers). If the result is beyond the 32-bit
floating-point representation expected result is unbounded

Components: Vulkan, OpenGL, Framework

VK-GL-CTS Issue: 3138

Affected tests:
dEQP-VK.glsl.builtin.function.*
dEQP-VK.glsl.builtin.precision.*
dEQP-GLES31.functional.shaders.builtin_functions.precision.*
dEQP-GLES31.functional.shaders.builtin_functions.common.fma.*

Change-Id: Iba27d6b0d7d0bc433a1d0c055cef6f6a61b239ba

2 years agoAccept NaN as valid in atan2 precision tests
Graeme Leese [Fri, 27 Aug 2021 12:46:19 +0000 (13:46 +0100)]
Accept NaN as valid in atan2 precision tests

The Vulkan CTS has been updated
(https://gerrit.khronos.org/c/vk-gl-cts/+/7857) so that it is not
required to generate correct results for atan(inf, inf), and this makes
the corresponding change in GL. The GLSL spec is not as clear on what is
required here, but does say:
    Built-in functions not listed above and not defined as equations of
    the above have undefined precision. These include, for example, the
    trigonometric functions

In general, I think that it is expected that the default state of Vulkan
is a match for GL.

Components: OpenGL
VK-GL-CTS issue: 3073
Affects: dEQP-GLES3.functional.shaders.builtin_functions.precision.atan2.highp_*

Change-Id: Ifae97a2e86962f5aff68d5eed09ba38069445468

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Thu, 28 Oct 2021 21:57:06 +0000 (17:57 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I54315f34095f396294bab85b0da4a1e3cf38aac8

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Thu, 28 Oct 2021 21:57:00 +0000 (17:57 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I2f2be91bd696c7de227f804202f9a8eb222cab03

2 years agoFix VK_KHR_shader_clock feature checks
Ricardo Garcia [Fri, 8 Oct 2021 07:50:00 +0000 (09:50 +0200)]
Fix VK_KHR_shader_clock feature checks

The shader clock tests were not checking if the implementation supported
64-bit integers for tests that required the feature and they were
checking supported features at test instance creation time instead of
the specific checkSupport method for test cases.

Affected tests:
dEQP-VK.glsl.shader_clock.*

Components: Vulkan
VK-GL-CTS issue: 3187

Change-Id: I0dc86a4fae619c0d27628d97f0ac11c5def5ff4f

2 years agoFix dEQP-VK.tessellation.geometry_interaction.limits.output_required_max_geometry...
Juha Heiskanen [Tue, 19 Oct 2021 11:38:09 +0000 (14:38 +0300)]
Fix dEQP-VK.tessellation.geometry_interaction.limits.output_required_max_geometry validation error

Adjust numSliceNodesComponentLimit in order to keep
m_numGeometryPrimitivesPerInvocation within minimum limits defined in
the spec.

Components: Vulkan

VK-GL-CTS Issue: 3180

Affects:
dEQP-VK.tessellation.geometry_interaction.limits.output_required_max_geometry

Change-Id: I72ca43bec27256cb75a11d75aab91b9b565be9ab

2 years agoMove log prints from test-ctor to test-inst-ctor
Jari Komppa [Tue, 5 Oct 2021 09:52:03 +0000 (12:52 +0300)]
Move log prints from test-ctor to test-inst-ctor

Some of the tesselation tests were printing values into the output log
from the test constructor, which meant that said prints end up in more
or less random place in the log. Moved those prints to the test instance
instead, so the information now resides within the test output.

The prints were also done in the amber-verify run mode.

Affects:
dEQP-VK.tessellation.geometry_interaction.scatter.*
dEQP-VK.tessellation.geometry_interaction.limits.*

Components: Vulkan
VK-GL-CTS issue: 3057

Change-Id: Ic5b2ce59369d1c20f25b8dc1c6cb594baac74f8f

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 22 Oct 2021 17:01:32 +0000 (13:01 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I6873657c378b02b383da36905a31886806519459

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Fri, 22 Oct 2021 17:01:27 +0000 (13:01 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I67159d811b780fc975c41a18043c177bceba6da7

2 years agoFix zx_handle_t typedef
Mika Väinölä [Wed, 13 Oct 2021 07:51:57 +0000 (10:51 +0300)]
Fix zx_handle_t typedef

Change from signed to unsigned 32-bit integer to match zircon/types.h.

Components: Framework, Vulkan

VK-GL-CTS issue: 3214

Change-Id: Ic887e90adc1583cfcd1518e21831d330e0f89b17

2 years agoFix tessellation SPIR-V tests use of Restrict
Jason Ekstrand [Mon, 21 Jun 2021 20:35:36 +0000 (15:35 -0500)]
Fix tessellation SPIR-V tests use of Restrict

Their usage of Restrict violates the SPIR-V spec which requires that it
only got on variables, not types or struct members.

Affected tests:
dEQP-VK.tessellation.*

Components: Vulkan
VK-GL-CTS issue: 2975

Change-Id: Ifbde1b493bf56d1ee6454a4ab54e98bcd05f839b

2 years agoAllowing spirv1.4 shaders compilation
Mohd Faisal [Wed, 26 Aug 2020 10:51:25 +0000 (11:51 +0100)]
Allowing spirv1.4 shaders compilation

Components: Vulkan

VK-GL-CTS Issue: 2560

Affects: dEQP-VK.spirv_assembly.instruction.spirv1p4.*

Change-Id: Icbfe3ad623da98968eee401d08df5ed6b3b2db1e
(cherry picked from commit c96d524d079fdada26b3548effd1539174415be6)

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 15 Oct 2021 17:57:51 +0000 (13:57 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I0abe7100c16a273d62463b916957255150d344d0

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Fri, 15 Oct 2021 17:57:39 +0000 (13:57 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: Ib23f14c29d67945839ab3763968963d7dcc91464

2 years agoFix validation errors with unnormalized coordinates samplers
Samuel Iglesias Gonsálvez [Fri, 8 Oct 2021 13:26:21 +0000 (15:26 +0200)]
Fix validation errors with unnormalized coordinates samplers

Components: Vulkan
VK-GL-CTS issue: 3190

Affects:

   dEQP-VK.pipeline.sampler.*unnormalized*

Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Change-Id: I1dde344fe39289b945a434eab7276dc58deab881

2 years agoFix descriptor indexing test dependency
Graeme Leese [Thu, 7 Oct 2021 17:15:51 +0000 (18:15 +0100)]
Fix descriptor indexing test dependency

The UBO and SSBO non-uniform indexing tests use runtimeDescriptorArray,
so this needs to be included in the checkSupport condition.

Components: Vulkan
Affects: dEQP-VK.ubo.*
         dEQP-VK.ssbo.*

Change-Id: I54edb2d06135a8d1d549a42ac97014dabc80c9dd

2 years agoCheck resource limits properly
Samuel Iglesias Gonsálvez [Wed, 2 Jun 2021 14:41:30 +0000 (16:41 +0200)]
Check resource limits properly

The tests were not checking the resource limits per stage when
creating the shaders, which could create potential issues on
some drivers. Specially the random generated tests.

Affected tests:

   dEQP-VK.ssbo.layout.*

Components: Vulkan
VK-GL-CTS issue: 2953

Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Change-Id: I7509dce38b849a0dd26f9e47d7f74e637930d897

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3
Matthew Netsch [Fri, 15 Oct 2021 16:47:17 +0000 (12:47 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3

Change-Id: Id485bc8ae929179e7786039966a233dd6fa57cdc

2 years agoMove anisotropic filtering support check to a function
Vihanakangas [Mon, 4 Oct 2021 10:52:27 +0000 (13:52 +0300)]
Move anisotropic filtering support check to a function

Support check for anisotropic filtering was done inside of iterate.
This change moves that check inside of a function for consistency
and performance.

Affects:

dEQP-VK.texture.filtering_anisotropy.*

Components: Vulkan

VK-GL-CTS issue: 3068

Change-Id: I3a1c0a1acff96b6f6b291bb53d3d9dc0bd122c17
(cherry picked from commit 522f4ba64beee8828030320591d20faa027a8e0a)

2 years agoFix incorrect computation of pointer size
Marcin Kańtoch [Tue, 31 Aug 2021 11:08:45 +0000 (13:08 +0200)]
Fix incorrect computation of pointer size

CTS always fills the array of pointers with a stride of 64-bits.
So, for 32-bits applications, each two 32-bits has one valid pointer
to instance of bottom-level acceleration structure.

To correct this the pointer size should be calculated as
sizeof(VkDeviceOrHostAddressConstKHR::hostAddress) for host built
top-level acceleration structure and
sizeof(VkDeviceOrHostAddressConstKHR::deviceAddress) for device built
top-level acceleration structure.

VK-GL-CTS issue: 3084
Components: Vulkan

Affects:
dEQP-VK.ray*instances_aop*

Change-Id: I8c412a5a5d2ce3f1f687795768d6d83ad4913892

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Thu, 7 Oct 2021 20:56:05 +0000 (16:56 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I911747cbf1726e161c457fa6ae666148ff0b36c7

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Thu, 7 Oct 2021 20:55:56 +0000 (16:55 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I6994a2ac890d752906a8f6464a9cb7819e22a55f

2 years agoFix crashes on depth stencil resolve tests with separate layouts
Samuel Iglesias Gonsálvez [Tue, 28 Sep 2021 09:05:30 +0000 (11:05 +0200)]
Fix crashes on depth stencil resolve tests with separate layouts

Mesa drivers were crashing in depth stencil resolve tests when
used with separate layouts.

The issue was that if layout only specifies the layout of the
depth aspect of the attachment, the layout of the stencil aspect
is specified by the stencilLayout member of a
VkAttachmentReferenceStencilLayout structure included in the
pNext chain. We were not setting it.

Affected tests:

   dEQP-VK.renderpass2.depth_stencil_resolve.*separate_layouts*

Components: Vulkan
VK-GL-CTS issue: 3157

Change-Id: I72f8fdba88717ab0442501911fb26a7469da65d8
Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 1 Oct 2021 19:32:56 +0000 (15:32 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I133af15a49b220d94c26f9db70e7830fbe167b72

2 years agoAllow the use of the standard types
Alexander Galazin [Fri, 18 Jun 2021 08:17:32 +0000 (10:17 +0200)]
Allow the use of the standard types

Removes the script that enforces the use of
the de-wrappers instead of the standard types.

VK-GL-CTS issue: 2963

Components: Framework

Change-Id: I5e2ff38a2b2cbc63a3c756a1e0260833ecd9381e
(cherry picked from commit ce1ae17c4785a8a57214a16fac46e28832956fa9)

2 years agoFix dEQP-VK.image.mutable.*srgb* validation errors
Samuel Iglesias Gonsálvez [Tue, 28 Sep 2021 12:32:25 +0000 (14:32 +0200)]
Fix dEQP-VK.image.mutable.*srgb* validation errors

The tests were not checking that the image format was
supported before creating the image.

Components: Vulkan
VK-GL-CTS issue: 3143

Affected tests:

   dEQP-VK.image.mutable.*

Change-Id: Ia42ccc815456ac09c4ffd44c63a0c65db8a9f1ec
Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 24 Sep 2021 15:04:24 +0000 (11:04 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: Ifc19ab1fcdcfa681d0fef9b3c5e3448d12813fdf

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Fri, 24 Sep 2021 15:04:20 +0000 (11:04 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: Iab8e5c27a9f07ca0459c97bc8d72cd93b8ce675a

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3
Matthew Netsch [Fri, 24 Sep 2021 15:04:16 +0000 (11:04 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3

Change-Id: Icdbb121ec7a828457ff9df34efe018fbf845e3f9

2 years agoAccept NaN as valid pass value in shader precision atan2 tests
Mohankumar Nekkarakalaya [Wed, 25 Aug 2021 22:45:12 +0000 (15:45 -0700)]
Accept NaN as valid pass value in shader precision atan2 tests

Spec mentions that implementation may assume arguments are not
Inf if the entrypoint is not declared with SignedZeroInfNanPreserve
and can perform optimizations.

Components: Vulkan

VK-GL-CTS Issue: 3073

Affected tests:
dEQP-VK.spirv_assembly.instruction.compute.float16.*.atan2
dEQP-VK.spirv_assembly.instruction.graphics.float16.*.atan2*
dEQP-VK.glsl.builtin.precision.atan2.*

Change-Id: I6e1fbc14a5654422cf88e1453fae0774bfce0bb6

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Matthew Netsch [Fri, 17 Sep 2021 15:56:59 +0000 (11:56 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I521f0b1f6f4c3a86e8612239ce2134be76e5d16a

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Matthew Netsch [Fri, 17 Sep 2021 15:56:48 +0000 (11:56 -0400)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: Ic1ab6043f9d70b8491192137c6d8c2fc12f2112d

2 years agoFix AHB external memory test mip levels
Ari Suonpaa [Tue, 14 Sep 2021 10:08:37 +0000 (13:08 +0300)]
Fix AHB external memory test mip levels

AHB external memory tests were testing mipmaps using a
queried maximum number of supported mipmap levels, but
at the same time using an image size of 64x64.
The number of mip levels need to match the number for a
full mip chain, in this case 7. Now a correct number of
mip levels is used, which also gets rid of a validation
error.

VK-GL-CTS Issue: 3112

Affects:

dEQP-VK.api.external.memory.android_hardware_buffer.image_formats.*

Components: Vulkan
Change-Id: I1c6d09f93c06ac1c52cea283fd86359ccde01e4f

2 years agoRemove invalid SPIR-V decorations
Ilkka Saarelainen [Tue, 7 Sep 2021 13:03:46 +0000 (16:03 +0300)]
Remove invalid SPIR-V decorations

Some SPIR-V asm tests used invalid Binding and DescriptorSet decorations.
This CL removes those decorations.

Affects:

dEQP-VK.spirv_assembly.instruction.compute.physical_pointers.complex_types_compute.*
dEQP-VK.spirv_assembly.instruction.compute.pointer_parameter.buffer_memory
dEQP-VK.spirv_assembly.instruction.graphics.pointer_parameter.buffer_memory*
dEQP-VK.spirv_assembly.instruction.graphics.16bit_storage.input_output_float_16_to_16x2.scalar
dEQP-VK.spirv_assembly.instruction.graphics.16bit_storage.input_output_float_16_to_16x2.vec2
dEQP-VK.spirv_assembly.instruction.graphics.16bit_storage.input_output_int_16_to_16x2.scalar_int
dEQP-VK.spirv_assembly.instruction.graphics.16bit_storage.input_output_int_16_to_16x2.scalar_uint
dEQP-VK.spirv_assembly.instruction.graphics.16bit_storage.input_output_int_16_to_16x2.ivec2
dEQP-VK.spirv_assembly.instruction.graphics.16bit_storage.input_output_int_16_to_16x2.uvec2

Components: Vulkan

VK-GL-CTS issue: 3063

Change-Id: Icfee33f9ce041bf60a19fba55aef9fdab0747148

2 years agoMerge branch 'vulkan-cts-1.2.4' into vulkan-cts-1.2.5
Peter Kohaut [Fri, 3 Sep 2021 07:33:02 +0000 (09:33 +0200)]
Merge branch 'vulkan-cts-1.2.4' into vulkan-cts-1.2.5

Change-Id: I952af5b744206c52b4161d8c1102b6a8c2a53f58

2 years agoMerge branch 'vulkan-cts-1.2.3' into vulkan-cts-1.2.4
Peter Kohaut [Thu, 2 Sep 2021 20:22:53 +0000 (22:22 +0200)]
Merge branch 'vulkan-cts-1.2.3' into vulkan-cts-1.2.4

Change-Id: Ica9ea69514cd36415ad89f4b34e8384b0523181c

2 years agoMerge remote-tracking branch 'origin/vulkan-cts-1.2.2' into vulkan-cts-1.2.3
Peter Kohaut [Thu, 2 Sep 2021 17:05:54 +0000 (19:05 +0200)]
Merge remote-tracking branch 'origin/vulkan-cts-1.2.2' into vulkan-cts-1.2.3

Change-Id: I3c5b289149d9f2601b5d5ab8986d41b3f33f8bab

2 years agoCorrect Vulkan multiview 'tesellation' test names
Alex Walters [Thu, 12 Aug 2021 13:12:55 +0000 (14:12 +0100)]
Correct Vulkan multiview 'tesellation' test names

Tests are renamed from 'tesellation' to 'tessellation' but are otherwise
unchanged.

Affects:

dEQP-VK.multiview*tessellation*

Components: Vulkan
Change-Id: I1686bb6fb8a0e85e201853602f840e03e847169d

2 years agoFix protected memory ssbo pipeline barrier use
Mike Byrne [Mon, 9 Aug 2021 11:40:07 +0000 (12:40 +0100)]
Fix protected memory ssbo pipeline barrier use

Incorrect stage flags are passed to vkCmdPipelineBarrier in the copy
buffer operation in the dEQP-VK.protected_memory.ssbo.ssbo_read.*

These tests were introduced in origin/vulkan-cts-1.1.0

Components: Vulkan

Affects:
dEQP-VK.protected_memory.ssbo.*

VK-GL-CTS Issue: 3041

Change-Id: Iccdb96fee30e32bf26dec1e26d65ea8d5600c384

2 years agoAdd missing vertexPipelineStoresAndAtomics checks in ray query tests
John Anthony [Wed, 18 Aug 2021 20:16:53 +0000 (22:16 +0200)]
Add missing vertexPipelineStoresAndAtomics checks in ray query tests

Affected tests:
dEQP-VK.ray_query.acceleration_structures.*.vertex_shader.*
dEQP-VK.ray_query.acceleration_structures.*.tess_control_shader.*
dEQP-VK.ray_query.acceleration_structures.*.tess_evaluation_shader.*
dEQP-VK.ray_query.acceleration_structures.*.geometry_shader.*
dEQP-VK.ray_query.ray_flags.vertex_shader.*
dEQP-VK.ray_query.ray_flags.tess_control_shader.*
dEQP-VK.ray_query.ray_flags.tess_evaluation_shader.*
dEQP-VK.ray_query.ray_flags.geometry_shader.*
dEQP-VK.ray_query.traversal_control.vertex_shader.*
dEQP-VK.ray_query.traversal_control.tess_control_shader.*
dEQP-VK.ray_query.traversal_control.tess_evaluation_shader.*
dEQP-VK.ray_query.traversal_control.geometry_shader.*

Components: Vulkan

VK-GL-CTS Issue: 3069

Change-Id: I49c37d292380fda47b113bf4fa14a6395f8e81a5

2 years agoFix error in build_apk.py
Ilkka Saarelainen [Thu, 12 Aug 2021 07:22:22 +0000 (10:22 +0300)]
Fix error in build_apk.py

A typo caused build_apk.py to fail if required Android build
tools were missing.

Components: framework

Change-Id: Ia55b95a9057a37152e5a4c91773b1eaa3abc0156

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Alexander Galazin [Thu, 12 Aug 2021 18:56:51 +0000 (20:56 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: Id1af44b78cbe4ba82cc76c656e0a22421ac20073

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Alexander Galazin [Thu, 12 Aug 2021 18:03:29 +0000 (20:03 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I13ff1ac57c064dc46bbc7c555ba1fed07e04080c

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3
Alexander Galazin [Thu, 12 Aug 2021 18:02:19 +0000 (20:02 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3

Change-Id: Iab13500b9aaa9b6da0e99ea9d93fe9cabc66da33

2 years agoRelax protected heap allocation tests
Ari Suonpaa [Fri, 6 Aug 2021 12:08:21 +0000 (15:08 +0300)]
Relax protected heap allocation tests

Some implementations have limitations on protected heap
allocations, and these limitations cannot be queried
using the Vulkan API. This change allows an out-of-memory
to happen after a certain number of allocations to
compensate that.

VK-GL-CTS Issue: 3038

Affects:

dEQP-VK.memory.*allocation.*

Components: Vulkan
Change-Id: I3a34637c8c15eb8670613dce9b6e394a622a4c71

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Alexander Galazin [Tue, 27 Jul 2021 10:25:19 +0000 (12:25 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I22fcd718aadfed74408323615cc4bf58618d979a

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Alexander Galazin [Tue, 27 Jul 2021 09:29:33 +0000 (11:29 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: If23bb885846d42651d7ac77b375b6c44ea02fa93

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3
Alexander Galazin [Tue, 27 Jul 2021 08:01:37 +0000 (10:01 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3

Change-Id: If1bb9f63d56815c3ced2ac72d17d4e55ec090f39

2 years agoFix early destruction of VkPipelineLayout
Samuel Iglesias Gonsálvez [Thu, 15 Jul 2021 10:15:09 +0000 (12:15 +0200)]
Fix early destruction of VkPipelineLayout

Components: Vulkan
VK-GL-CTS issue: 3004

Affected:

    dEQP-VK.sparse_resources.shader_intrinsics.*

Change-Id: Id5508fac89961c5bb934005257d2caa26d32f2dd
Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
2 years agoFix validation errors in AHB tests
Ari Suonpaa [Wed, 9 Sep 2020 11:27:26 +0000 (14:27 +0300)]
Fix validation errors in AHB tests

AHB protected memory tests were also removed as the test
tried to use protected memory without creating a device
and queue that would support protected operations.

VK-GL-CTS Issue: 2508

Affects:

dEQP-VK.api.external.memory.android_hardware_buffer.*

Components: Vulkan
Change-Id: I307e7450d06d20b6497f2a529e5724ae0538e5a9

2 years agoClean ExternalMemoryUtil
Piotr Byszewski [Thu, 9 Apr 2020 11:41:09 +0000 (13:41 +0200)]
Clean ExternalMemoryUtil

This change separates choosing of memory type from
allocateExportableMemory utility function. This makes
use of this functions more clear.
Previous implementation needed to be done ASAP and
involved passing of non-const reference to
allocateExportableMemory which was then filled.
This workaround made code unnecessarily hard to follow.

Components: Vulkan

VK-GL-CTS issue: 587

Affects:
dEQP-VK.api.external.memory.*
dEQP-VK.synchronization.signal_order.*
dEQP-VK.synchronization.cross_instance.*

Change-Id: I781388db390f13c7c03785dd0ae34ae0128ec31c

2 years agoRemove tests with too many overlapping instances in the accelleration structure
Sławomir Cygan [Thu, 15 Jul 2021 13:22:26 +0000 (15:22 +0200)]
Remove tests with too many overlapping instances in the accelleration structure

These tests generate a grid of random triangles and assign them to the large
number of instances in the acceleration structure. Because of the randomness,
all instances overlap with each other and the accelleration structure is extremely
slow to trace - as each ray must traverse through all instances.

This change removes some tests cases with 65536 instances and tests cases with
1048576 instances to avoid device timeouts.

The tests apply only to implementations with host accelleration structure builds
supported.

Components: Vulkan

VK-GL-CTS Issue: 3005

Change-Id: I94bcde596cd097672cf8e00c6fe018328998cb37
Affects: dEQP-VK.ray_tracing_pipeline.build.*

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Alexander Galazin [Thu, 8 Jul 2021 18:08:17 +0000 (20:08 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I41d5f00d649218e1418c13591f50885858624198

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Alexander Galazin [Thu, 8 Jul 2021 17:09:43 +0000 (19:09 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I166b558acc75b2d9259620be5fb8ba89eaa10841

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3
Alexander Galazin [Thu, 8 Jul 2021 16:27:33 +0000 (18:27 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.2 into vk-gl-cts/vulkan-cts-1.2.3

Change-Id: Ic61d3218b466b8fd2c50127867a0cfdb77c07637

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.1 into vk-gl-cts/vulkan-cts-1.2.2
Alexander Galazin [Thu, 8 Jul 2021 15:37:58 +0000 (17:37 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.1 into vk-gl-cts/vulkan-cts-1.2.2

Change-Id: I7c0abe6efdeab69b5928cc0e67a6365f15b1e5c5

2 years agoCall computeFixedPointError only for fixed point case
Mohankumar Nekkarakalaya [Wed, 7 Jul 2021 23:00:03 +0000 (16:00 -0700)]
Call computeFixedPointError only for fixed point case

Calling computeFixedPointError for integer case (numAccurateBits=32)
is incorrect and causes crash.
Added assert to make sure numAccurateBits is in legal range.

Affected tests: dEQP-VK.sparse_resources.image_sparse_residency.*

Components: Vulkan

VK-GL-CTS issue: 2994

Change-Id: Ib357cbbbda0f7980ec2d7115053cabc6825a18d3

2 years agoAvoid overflowing arrays in GLSL atomic tests
Iago Toral Quiroga [Tue, 6 Jul 2021 09:10:04 +0000 (11:10 +0200)]
Avoid overflowing arrays in GLSL atomic tests

Tilers may need to execute vertex pipeline stages more than once,
leading to additional shader invocations. This is a problem for atomic
tests, since their result depends on the number of shader invocations
executed.

This is already handled properly for vertex shaders but not for other
vertex pipeline stages.

Affected tests:
dEQP-VK.glsl.atomic_operations.*

Components: Vulkan
VK-GL-CTS issue: 2987

Co-authored-by: Ricardo Garcia <rgarcia@igalia.com>
Change-Id: Iab08e3fb2ef40fc29dcf073817e5fd5dd49e7875

2 years agoFix semaphore leak in image atomic operations test
Sławomir Cygan [Fri, 25 Jun 2021 14:08:23 +0000 (16:08 +0200)]
Fix semaphore leak in image atomic operations test

The class 'Image', being base class for `SparseImage` class needs to be
marked as virtual, so objects of SparseImage type can be owned and
destroyed through a pointer of `Image` type.  Without that the implicit
destructor of `SparseImage` class is never called.

As SparseImage class has a semaphore member, this fixes the
semaphore VK object leak.

Components: Vulkan

VK-GL-CTS Issue: 2981

Change-Id: Ice24f7018cf9144f4c1adbb8987b730d5f1ca2aa
Affects: dEQP-VK.image.atomic_operations.*

2 years agoFix use of binary semaphore in signaled state
Lars-Ivar Hesselberg Simonsen [Fri, 23 Apr 2021 10:04:44 +0000 (12:04 +0200)]
Fix use of binary semaphore in signaled state

Vulkan spec specifies that binary semaphore waits and signals should
occur in discrete 1:1 pairs.

This change ensures that the binary semaphore signaled by
synchronizationWrapper[SECOND] is waited on before being used again,
which resolves the corresponding validation layer error.

In addition, the change fixes an issue where the second submission pair
did not correctly swap semaphore info.

Components: Vulkan

Affects:
dEQP-VK.synchronization.basic.binary_semaphore.multi_queue
dEQP-VK.synchronization.basic.binary_semaphore.multi_queue_typed
dEQP-VK.synchronization.basic.timeline_semaphore.multi_queue

VK-GL-CTS Issue: 2910

Change-Id: Id2fb2211a43150e3acb5c07dd6c205c7a42296d5
(cherry picked from commit a017db3c0d1fbf89f30253254d57fb869f57a430)

2 years agoProperly enable Sample Shading in Fragment Shading Rate tests
Sebastiano Cucinotta [Mon, 14 Jun 2021 15:15:40 +0000 (17:15 +0200)]
Properly enable Sample Shading in Fragment Shading Rate tests

Vulkan spec states:

> Sample shading is enabled for a graphics pipeline:
>
> * If the interface of the fragment shader entry point of the graphics
>   pipeline includes an input variable decorated with SampleId or
>   SamplePosition. In this case minSampleShadingFactor takes the value
>   1.0.
> * Else if the sampleShadingEnable member of the
>   VkPipelineMultisampleStateCreateInfo structure specified when
>   creating the graphics pipeline is set to VK_TRUE. In this case
>   minSampleShadingFactor takes the value of
>   VkPipelineMultisampleStateCreateInfo::minSampleShading.
>
> Otherwise, sample shading is considered disabled.

This change ensures that sample shading is properly enabled in the
Fragment Shading Rate tests relying on it by using gl_SampleId.

Components: Vulkan

Affects:
dEQP-VK.fragment_shading_rate.sampleshadinginput.*

VK-GL-CTS Issue: 2966

Change-Id: I7fad0ed7694a2d26ef7db9ea268fa5d6f93264a6

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Alexander Galazin [Wed, 16 Jun 2021 07:43:06 +0000 (09:43 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I01d6cedef0b807be928ba68d3aab64fd3d045d8d

2 years agoFix dEQP-VK.info.device_extensions not working
Ricardo Garcia [Wed, 9 Jun 2021 11:28:55 +0000 (13:28 +0200)]
Fix dEQP-VK.info.device_extensions not working

The test is using the list of extension dependencies for instances
instead of devices, so it's actually not checking anything in most
cases.

Affected tests:
dEQP-VK.info.device_extensions

Components: Vulkan
VK-GL-CTS issue: 2959

Change-Id: I8ee2ea10f98e1dd45590edc2b5cc8e0c3e21890b

2 years agoSPIR-V 1.4 test fixes
Ricardo Garcia [Wed, 9 Jun 2021 10:11:56 +0000 (12:11 +0200)]
SPIR-V 1.4 test fixes

This commit fixes a couple of SPIR-V 1.4 tests that had inconsistent
requirements in the Amber script and in the CTS side. In one case we're
dropping the requirement from Amber and in the other one we're adding
the requirement to CTS.

Affected tests:
dEQP-VK.spirv_assembly.instruction.spirv1p4.opptrnotequal.variable_pointers_vars_wg_not_equal
dEQP-VK.spirv_assembly.instruction.spirv1p4.hlsl_functionality1.member_decorate_string

Components: Vulkan
VK-GL-CTS issue: 2958

Change-Id: If1e58bc028ce3756623a241bb259024ef077c815

2 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Alexander Galazin [Wed, 16 Jun 2021 06:52:23 +0000 (08:52 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I89ac6a1c9b0b7d908be65033c47371f60cc880cb

2 years agoDo not exceed heap size when allocating memory
Slawomir Cygan [Wed, 19 May 2021 15:18:48 +0000 (17:18 +0200)]
Do not exceed heap size when allocating memory

It is invalid to make larger allocations than heap size.

Components: Vulkan

VK-GL-CTS Issue: 2927

Change-Id: I738356254d95a152a2bb89d711eb6b3f047b405c
Affects: dEQP-VK.memory.mapping

2 years agoOptimize the AS build tests to not use host uncached memory
Slawomir Cygan [Tue, 11 May 2021 14:53:20 +0000 (16:53 +0200)]
Optimize the AS build tests to not use host uncached memory

Use userspace host memory for scratch buffer (instead mapped device memory)
and try using HOST_CACHED memory (if supported) for the accelleration structure.

Components: Vulkan

VK-GL-CTS Issue: 2922

Affects:
dEQP-VK.ray_tracing_pipeline.build.*
dEQP-VK.ray_tracing_pipeline.*

Change-Id: I7592c3f93f2e10766cd1276f37ca51924e1cc16f

2 years agoAdd missing cull flags when counting intersections of rays with triangle-based cubes
Sławomir Cygan [Fri, 4 Jun 2021 15:49:38 +0000 (17:49 +0200)]
Add missing cull flags when counting intersections of rays with triangle-based cubes

Add a cull flags, so each convex geometry is counted once, instead of twice.

Components: Vulkan

VK-GL-CTS Issue: 2890

Affects:
    dEQP-VK.ray_tracing_pipeline.misc.*stress*
    dEQP-VK.ray_tracing_pipeline.misc.cullmask*
    dEQP-VK.ray_tracing_pipeline.misc.mixedPrimTL

Change-Id: Ie2e74149be8bb710c7ae3afb77f5854dca247aca

2 years agoRevert "Move the hit counting from any hit to closest hit shader stage"
Slawomir Cygan [Fri, 4 Jun 2021 15:45:39 +0000 (15:45 +0000)]
Revert "Move the hit counting from any hit to closest hit shader stage"

The problem with this test was in cull flags, rather than counting
in 'any hit' shader stage.

This reverts commit 2f33c7beac25308ef85a1856032d7a5936197f83.

VK-GL-CTS Issue: 2890

Change-Id: I066fac55a80ff4f4a93748425517785df8777d06
Affects: dEQP-VK.ray_tracing_pipeline.misc.*stress*

3 years agoFix several issues in swapchain tests
Ricardo Garcia [Fri, 28 May 2021 11:53:56 +0000 (13:53 +0200)]
Fix several issues in swapchain tests

This commit fixes the following issues found in the swapchain tests:

- The initial image layout in some render passes did not match the
  actual image layout when starting the render pass.

- image_swapchain_create_info tests were using VK_KHR_bind_memory2
  functions without activating the extension on the device or making
  sure it was core in the used Vulkan API version.

- Many devices were being created with the wrong instance, using the
  context instance instead of the custom instance created for the tests.

- Several tests using VK_SHARING_MODE_CONCURRENT did not check for the
  availability of two queues or were always using one, which is invalid.

- VkDeviceGroupSwapchainCreateInfoKHR had a wrong sType.

- Swapchain resize tests were calling vkBeginCommandBuffer() on active
  command buffers without waiting for them to complete execution.

- Typos and other minor issues.

Affected tests:
dEQP-VK.wsi.*.swapchain.*

Components: Vulkan
VK-GL-CTS issue: 2941

Change-Id: I54d5f46cbcb76617260439a59bf3aef4028309bb

3 years agoFix surfaceless platform for Android
Paul Thomson [Tue, 18 May 2021 10:54:54 +0000 (11:54 +0100)]
Fix surfaceless platform for Android

Fix Vulkan library path on Android and fix config selection when
glu::RenderConfig::DONT_CARE is used.

Affected tests:
dEQP-VK.*

Components: Framework
Change-Id: I8809dd691e144223991a693aa9b90c03cd829a63

3 years agoAllow false positive hits from build-in AABBs intersector
Slawomir Cygan [Wed, 19 May 2021 16:04:58 +0000 (18:04 +0200)]
Allow false positive hits from build-in AABBs intersector

This extends the fix from 7ff1f9cd to 'mixed' tests, which
also use AABBs.

This change allows the test to execute any hit shader,
in case of AABB geometry is used and the ray falsely 'intersects'
it.

This is needed, as the test does not calculate the proper
intersection in 'intersection' stage - it uses a shader that always
reports TRUE. Hence the test relies on build-in AABB
intersector, which may report false positives according to the
specification.

VK-GL-CTS Issue: 2848

Components: Vulkan

Affects: dEQP-VK.ray_tracing_pipeline.build.*mix*

Change-Id: Ia962992df866b68f84714dcb6429a1a90499d9b6

3 years agoMerge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5
Alexander Galazin [Wed, 26 May 2021 09:15:08 +0000 (11:15 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.4 into vk-gl-cts/vulkan-cts-1.2.5

Change-Id: I5a38303ad269d39786584512a105e0e4b636eca1

3 years agoMerge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4
Alexander Galazin [Wed, 26 May 2021 08:45:36 +0000 (10:45 +0200)]
Merge vk-gl-cts/vulkan-cts-1.2.3 into vk-gl-cts/vulkan-cts-1.2.4

Change-Id: I2182f671aa88657e150c9d987713b93920377b23