diff options
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/files/0001-Do-not-error-on-uninitialized-warnings.patch | 28 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/files/0001-Include-limits-header-for-numeric_limits.patch | 88 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/files/0001-Workaround-for-GCC-11-uninit-variable-warnings-946.patch | 73 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/files/fix-clang-private-operator.patch | 6 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/files/fix-musl.patch | 24 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/khronos-cts.inc | 4 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/opengl-es-cts_3.2.7.0.bb (renamed from meta-oe/recipes-graphics/vk-gl-cts/opengl-es-cts_3.2.6.1.bb) | 14 | ||||
-rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts_1.2.6.0.bb (renamed from meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts_1.2.3.2.bb) | 12 |
8 files changed, 189 insertions, 60 deletions
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Do-not-error-on-uninitialized-warnings.patch b/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Do-not-error-on-uninitialized-warnings.patch deleted file mode 100644 index 4f3c7554cf..0000000000 --- a/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Do-not-error-on-uninitialized-warnings.patch +++ /dev/null | |||
@@ -1,28 +0,0 @@ | |||
1 | From f9906a3a1b7f1ade7a6c4e1a8aa67cb3a5e663a9 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Wed, 3 Mar 2021 11:33:15 -0800 | ||
4 | Subject: [PATCH] Do not error on uninitialized warnings | ||
5 | |||
6 | code in verifier.cc violates C/C++ aliasing rules so code should be | ||
7 | perhaps changed to use a union | ||
8 | |||
9 | Upstream-Status: Pending | ||
10 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
11 | --- | ||
12 | external/amber/src/CMakeLists.txt | 1 + | ||
13 | 1 file changed, 1 insertion(+) | ||
14 | |||
15 | diff --git a/external/amber/src/CMakeLists.txt b/external/amber/src/CMakeLists.txt | ||
16 | index 80a0df7..4323c81 100644 | ||
17 | --- a/external/amber/src/CMakeLists.txt | ||
18 | +++ b/external/amber/src/CMakeLists.txt | ||
19 | @@ -133,6 +133,7 @@ elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") | ||
20 | -Werror | ||
21 | -Wextra | ||
22 | -Wno-unknown-pragmas | ||
23 | + -Wno-error=uninitialized | ||
24 | -Wpedantic | ||
25 | -pedantic-errors) | ||
26 | elseif(MSVC) | ||
27 | -- | ||
28 | 2.30.1 | ||
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Include-limits-header-for-numeric_limits.patch b/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Include-limits-header-for-numeric_limits.patch new file mode 100644 index 0000000000..746497d047 --- /dev/null +++ b/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Include-limits-header-for-numeric_limits.patch | |||
@@ -0,0 +1,88 @@ | |||
1 | From aec0be857ed3faef8802c7fd61f3d7798a565108 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Thu, 29 Apr 2021 16:03:42 -0700 | ||
4 | Subject: [PATCH] Include <limits> header for numeric_limits | ||
5 | |||
6 | Fixes | ||
7 | vulkancts/framework/vulkan/vkRayTracingUtil.hpp:116:32: error: 'numeric_limits' is not a member of 'std' | ||
8 | |||
9 | Upstream-Status: Pending | ||
10 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
11 | --- | ||
12 | framework/vulkan/vkRayTracingUtil.hpp | 1 + | ||
13 | modules/vulkan/api/vktApiBufferTests.cpp | 1 + | ||
14 | modules/vulkan/spirv_assembly/vktSpvAsmNonSemanticInfoTests.cpp | 2 ++ | ||
15 | 3 files changed, 4 insertions(+) | ||
16 | |||
17 | --- a/framework/vulkan/vkRayTracingUtil.hpp | ||
18 | +++ b/framework/vulkan/vkRayTracingUtil.hpp | ||
19 | @@ -33,6 +33,7 @@ | ||
20 | #include "tcuVector.hpp" | ||
21 | #include "tcuVectorType.hpp" | ||
22 | |||
23 | +#include <limits> | ||
24 | #include <vector> | ||
25 | |||
26 | namespace vk | ||
27 | --- a/modules/vulkan/api/vktApiBufferTests.cpp | ||
28 | +++ b/modules/vulkan/api/vktApiBufferTests.cpp | ||
29 | @@ -35,6 +35,7 @@ | ||
30 | #include "tcuPlatform.hpp" | ||
31 | |||
32 | #include <algorithm> | ||
33 | +#include <limits> | ||
34 | |||
35 | namespace vkt | ||
36 | { | ||
37 | --- a/modules/vulkan/spirv_assembly/vktSpvAsmNonSemanticInfoTests.cpp | ||
38 | +++ b/modules/vulkan/spirv_assembly/vktSpvAsmNonSemanticInfoTests.cpp | ||
39 | @@ -28,6 +28,8 @@ | ||
40 | #include "vktSpvAsmComputeShaderCase.hpp" | ||
41 | #include "vktSpvAsmGraphicsShaderTestUtil.hpp" | ||
42 | |||
43 | +#include <limits> | ||
44 | + | ||
45 | namespace vkt | ||
46 | { | ||
47 | namespace SpirVAssembly | ||
48 | --- a/modules/vulkan/memory/vktMemoryDeviceMemoryReportTests.cpp | ||
49 | +++ b/modules/vulkan/memory/vktMemoryDeviceMemoryReportTests.cpp | ||
50 | @@ -40,6 +40,7 @@ | ||
51 | |||
52 | #include "deSharedPtr.hpp" | ||
53 | |||
54 | +#include <limits> | ||
55 | #include <set> | ||
56 | #include <vector> | ||
57 | |||
58 | --- a/modules/vulkan/draw/vktDrawDepthClampTests.cpp | ||
59 | +++ b/modules/vulkan/draw/vktDrawDepthClampTests.cpp | ||
60 | @@ -38,6 +38,7 @@ | ||
61 | #include "vkQueryUtil.hpp" | ||
62 | #include "tcuTextureUtil.hpp" | ||
63 | |||
64 | +#include <limits> | ||
65 | #include <cmath> | ||
66 | |||
67 | namespace vkt | ||
68 | --- a/modules/vulkan/wsi/vktWsiFullScreenExclusiveTests.cpp | ||
69 | +++ b/modules/vulkan/wsi/vktWsiFullScreenExclusiveTests.cpp | ||
70 | @@ -39,6 +39,8 @@ | ||
71 | #include "tcuPlatform.hpp" | ||
72 | #include "tcuCommandLine.hpp" | ||
73 | |||
74 | +#include <limits> | ||
75 | + | ||
76 | #if ( DE_OS == DE_OS_WIN32 ) | ||
77 | #define NOMINMAX | ||
78 | #define WIN32_LEAN_AND_MEAN | ||
79 | --- a/modules/vulkan/synchronization/vktSynchronizationUtil.cpp | ||
80 | +++ b/modules/vulkan/synchronization/vktSynchronizationUtil.cpp | ||
81 | @@ -21,6 +21,7 @@ | ||
82 | * \brief Synchronization tests utilities | ||
83 | *//*--------------------------------------------------------------------*/ | ||
84 | |||
85 | +#include <limits> | ||
86 | #include "vktSynchronizationUtil.hpp" | ||
87 | #include "vkTypeUtil.hpp" | ||
88 | #include "vkCmdUtil.hpp" | ||
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Workaround-for-GCC-11-uninit-variable-warnings-946.patch b/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Workaround-for-GCC-11-uninit-variable-warnings-946.patch new file mode 100644 index 0000000000..6c87cad0a6 --- /dev/null +++ b/meta-oe/recipes-graphics/vk-gl-cts/files/0001-Workaround-for-GCC-11-uninit-variable-warnings-946.patch | |||
@@ -0,0 +1,73 @@ | |||
1 | From 9cd614dd5481a4fdf552effac4820f51a10092c7 Mon Sep 17 00:00:00 2001 | ||
2 | From: =?UTF-8?q?Mika=20V=C3=A4in=C3=B6l=C3=A4?= | ||
3 | <33728696+mvainola@users.noreply.github.com> | ||
4 | Date: Wed, 7 Apr 2021 13:12:17 +0300 | ||
5 | Subject: [PATCH] Workaround for GCC 11 uninit variable warnings (#946) | ||
6 | |||
7 | Building Amber with GCC 11.0.1 produces some uninitialized variable | ||
8 | warnings. This commit works around them by replacing | ||
9 | reinterpret_cast with memcpy when type punning unsigned integers to | ||
10 | floats. | ||
11 | |||
12 | Upstream-Status: Backport [https://github.com/google/amber/commit/aa69a0ac23ea7f68dd32bbef210546a5d84c1734] | ||
13 | --- | ||
14 | src/float16_helper.cc | 22 ++++++++++++++++------ | ||
15 | 1 file changed, 16 insertions(+), 6 deletions(-) | ||
16 | |||
17 | diff --git a/src/float16_helper.cc b/src/float16_helper.cc | ||
18 | index 617bd72..5cb35e7 100644 | ||
19 | --- a/src/float16_helper.cc | ||
20 | +++ b/src/float16_helper.cc | ||
21 | @@ -15,6 +15,7 @@ | ||
22 | #include "src/float16_helper.h" | ||
23 | |||
24 | #include <cassert> | ||
25 | +#include <cstring> | ||
26 | |||
27 | // Float10 | ||
28 | // | 9 8 7 6 5 | 4 3 2 1 0 | | ||
29 | @@ -75,8 +76,11 @@ float HexFloat16ToFloat(const uint8_t* value) { | ||
30 | } | ||
31 | |||
32 | uint32_t hex = sign | exponent | mantissa; | ||
33 | - float* hex_float = reinterpret_cast<float*>(&hex); | ||
34 | - return *hex_float; | ||
35 | + float hex_float; | ||
36 | + static_assert((sizeof(uint32_t) == sizeof(float)), | ||
37 | + "sizeof(uint32_t) != sizeof(float)"); | ||
38 | + memcpy(&hex_float, &hex, sizeof(float)); | ||
39 | + return hex_float; | ||
40 | } | ||
41 | |||
42 | // Convert float |value| whose size is 11 bits to 32 bits float | ||
43 | @@ -89,8 +93,11 @@ float HexFloat11ToFloat(const uint8_t* value) { | ||
44 | uint32_t mantissa = (static_cast<uint32_t>(value[0]) & 0x3f) << 17U; | ||
45 | |||
46 | uint32_t hex = exponent | mantissa; | ||
47 | - float* hex_float = reinterpret_cast<float*>(&hex); | ||
48 | - return *hex_float; | ||
49 | + float hex_float; | ||
50 | + static_assert((sizeof(uint32_t) == sizeof(float)), | ||
51 | + "sizeof(uint32_t) != sizeof(float)"); | ||
52 | + memcpy(&hex_float, &hex, sizeof(float)); | ||
53 | + return hex_float; | ||
54 | } | ||
55 | |||
56 | // Convert float |value| whose size is 10 bits to 32 bits float | ||
57 | @@ -103,8 +110,11 @@ float HexFloat10ToFloat(const uint8_t* value) { | ||
58 | uint32_t mantissa = (static_cast<uint32_t>(value[0]) & 0x1f) << 18U; | ||
59 | |||
60 | uint32_t hex = exponent | mantissa; | ||
61 | - float* hex_float = reinterpret_cast<float*>(&hex); | ||
62 | - return *hex_float; | ||
63 | + float hex_float; | ||
64 | + static_assert((sizeof(uint32_t) == sizeof(float)), | ||
65 | + "sizeof(uint32_t) != sizeof(float)"); | ||
66 | + memcpy(&hex_float, &hex, sizeof(float)); | ||
67 | + return hex_float; | ||
68 | } | ||
69 | |||
70 | } // namespace | ||
71 | -- | ||
72 | 2.31.1 | ||
73 | |||
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/files/fix-clang-private-operator.patch b/meta-oe/recipes-graphics/vk-gl-cts/files/fix-clang-private-operator.patch index b4573b38b5..ea7659c698 100644 --- a/meta-oe/recipes-graphics/vk-gl-cts/files/fix-clang-private-operator.patch +++ b/meta-oe/recipes-graphics/vk-gl-cts/files/fix-clang-private-operator.patch | |||
@@ -1,7 +1,5 @@ | |||
1 | Index: git/external/glslang/src/glslang/Include/PoolAlloc.h | 1 | --- a/external/glslang/src/glslang/Include/PoolAlloc.h |
2 | =================================================================== | 2 | +++ b/external/glslang/src/glslang/Include/PoolAlloc.h |
3 | --- git.orig/external/glslang/src/glslang/Include/PoolAlloc.h | ||
4 | +++ git/external/glslang/src/glslang/Include/PoolAlloc.h | ||
5 | @@ -240,8 +240,9 @@ protected: | 3 | @@ -240,8 +240,9 @@ protected: |
6 | 4 | ||
7 | int numCalls; // just an interesting statistic | 5 | int numCalls; // just an interesting statistic |
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/files/fix-musl.patch b/meta-oe/recipes-graphics/vk-gl-cts/files/fix-musl.patch index 4116ae7d14..99cb87b301 100644 --- a/meta-oe/recipes-graphics/vk-gl-cts/files/fix-musl.patch +++ b/meta-oe/recipes-graphics/vk-gl-cts/files/fix-musl.patch | |||
@@ -1,19 +1,15 @@ | |||
1 | Index: git/framework/delibs/dethread/CMakeLists.txt | 1 | --- a/framework/delibs/dethread/CMakeLists.txt |
2 | =================================================================== | 2 | +++ b/framework/delibs/dethread/CMakeLists.txt |
3 | --- git.orig/framework/delibs/dethread/CMakeLists.txt | 3 | @@ -42,6 +42,7 @@ if (DE_OS_IS_UNIX) |
4 | +++ git/framework/delibs/dethread/CMakeLists.txt | 4 | add_definitions(-D__BSD_VISIBLE) |
5 | @@ -39,6 +39,7 @@ include_directories( | 5 | add_definitions(-D_XOPEN_SOURCE=600) |
6 | 6 | endif () | |
7 | if (DE_OS_IS_UNIX) | ||
8 | add_definitions(-D_GNU_SOURCE) | ||
9 | + add_definitions(-D_XOPEN_SOURCE=600) | 7 | + add_definitions(-D_XOPEN_SOURCE=600) |
10 | set(DETHREAD_LIBS ${DETHREAD_LIBS} pthread) | 8 | add_definitions(-D_GNU_SOURCE) |
11 | endif () | ||
12 | 9 | ||
13 | Index: git/framework/qphelper/CMakeLists.txt | 10 | set(DETHREAD_LIBS ${DETHREAD_LIBS} pthread) |
14 | =================================================================== | 11 | --- a/framework/qphelper/CMakeLists.txt |
15 | --- git.orig/framework/qphelper/CMakeLists.txt | 12 | +++ b/framework/qphelper/CMakeLists.txt |
16 | +++ git/framework/qphelper/CMakeLists.txt | ||
17 | @@ -28,6 +28,7 @@ set(QPHELPER_LIBS | 13 | @@ -28,6 +28,7 @@ set(QPHELPER_LIBS |
18 | if (DE_OS_IS_UNIX OR DE_OS_IS_QNX) | 14 | if (DE_OS_IS_UNIX OR DE_OS_IS_QNX) |
19 | # For vsnprintf() | 15 | # For vsnprintf() |
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/khronos-cts.inc b/meta-oe/recipes-graphics/vk-gl-cts/khronos-cts.inc index e64a935dda..d0f0e23429 100644 --- a/meta-oe/recipes-graphics/vk-gl-cts/khronos-cts.inc +++ b/meta-oe/recipes-graphics/vk-gl-cts/khronos-cts.inc | |||
@@ -22,6 +22,10 @@ REQUIRED_DISTRO_FEATURES += "opengl" | |||
22 | 22 | ||
23 | DEPENDS += "libpng zlib virtual/libgles2 virtual/egl" | 23 | DEPENDS += "libpng zlib virtual/libgles2 virtual/egl" |
24 | 24 | ||
25 | SRC_URI += "file://0001-Workaround-for-GCC-11-uninit-variable-warnings-946.patch;patchdir=external/amber/src \ | ||
26 | file://0001-Include-limits-header-for-numeric_limits.patch;patchdir=external/vulkancts \ | ||
27 | " | ||
28 | |||
25 | SRC_URI_append_libc-musl = "\ | 29 | SRC_URI_append_libc-musl = "\ |
26 | file://fix-musl.patch \ | 30 | file://fix-musl.patch \ |
27 | " | 31 | " |
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/opengl-es-cts_3.2.6.1.bb b/meta-oe/recipes-graphics/vk-gl-cts/opengl-es-cts_3.2.7.0.bb index 184547aa76..a67992ee95 100644 --- a/meta-oe/recipes-graphics/vk-gl-cts/opengl-es-cts_3.2.6.1.bb +++ b/meta-oe/recipes-graphics/vk-gl-cts/opengl-es-cts_3.2.7.0.bb | |||
@@ -1,16 +1,14 @@ | |||
1 | DESCRIPTION = "OpenGL CTS" | 1 | DESCRIPTION = "OpenGL CTS" |
2 | 2 | ||
3 | require khronos-cts.inc | 3 | require khronos-cts.inc |
4 | # opengl-es-cts-3.2.6.1 | 4 | # opengl-es-cts-3.2.7.0 |
5 | SRCREV_vk-gl-cts = "7e023f81b4fff54b558882fe739d7c959d0a02a8" | 5 | SRCREV_vk-gl-cts = "7cba7113c40f2ff03573c8c2c90661b2249e04fa" |
6 | SRCREV_amber = "d26ee22dd7faab1845a531d410f7ec1db407402a" | 6 | SRCREV_amber = "4d0115cccfcb3b73d20b6513b1c40748e6403c50" |
7 | SRCREV_glslang = "c538b5d796fb24dd418fdd650c7f76e56bcc3dd8" | 7 | SRCREV_glslang = "ffccefddfd9a02ec0c0b6dd04ef5e1042279c97f" |
8 | SRCREV_spirv-headers = "e4322e3be589e1ddd44afb20ea842a977c1319b8" | 8 | SRCREV_spirv-headers = "104ecc356c1bea4476320faca64440cd1df655a3" |
9 | SRCREV_spirv-tools = "1eb89172a82b436d8037e8a8c29c80f7e1f7df74" | 9 | SRCREV_spirv-tools = "cd590fa3341284cd6d1ee82366155786cfd44c96" |
10 | SRC_URI[renderdoc.sha256sum] = "e7b5f0aa5b1b0eadc63a1c624c0ca7f5af133aa857d6a4271b0ef3d0bdb6868e" | 10 | SRC_URI[renderdoc.sha256sum] = "e7b5f0aa5b1b0eadc63a1c624c0ca7f5af133aa857d6a4271b0ef3d0bdb6868e" |
11 | 11 | ||
12 | SRC_URI += "file://0001-Do-not-error-on-uninitialized-warnings.patch" | ||
13 | |||
14 | S = "${WORKDIR}/git" | 12 | S = "${WORKDIR}/git" |
15 | 13 | ||
16 | do_install() { | 14 | do_install() { |
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts_1.2.3.2.bb b/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts_1.2.6.0.bb index f07b12decd..f816c1bd17 100644 --- a/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts_1.2.3.2.bb +++ b/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts_1.2.6.0.bb | |||
@@ -1,12 +1,12 @@ | |||
1 | DESCRIPTION = "Vulkan CTS" | 1 | DESCRIPTION = "Vulkan CTS" |
2 | 2 | ||
3 | require khronos-cts.inc | 3 | require khronos-cts.inc |
4 | # vulkan-cts-1.2.3.2 | 4 | # vulkan-cts-1.2.6.0 |
5 | SRCREV_vk-gl-cts = "5cd2240b60825fbbf6bd9ddda6af176ee3100c70" | 5 | SRCREV_vk-gl-cts = "2cab49df5ad25a2d0061152367a21c6da83ed097" |
6 | SRCREV_amber = "a40bef4dba98d2d80b48e5a940d8574fbfceb197" | 6 | SRCREV_amber = "dabae26164714abf951c6815a2b4513260f7c6a4" |
7 | SRCREV_glslang = "b5f003d7a3ece37db45578a8a3140b370036fc64" | 7 | SRCREV_glslang = "5c4f421121c4d24aad23a507e630dc5dc6c92c7c" |
8 | SRCREV_spirv-headers = "f8bf11a0253a32375c32cad92c841237b96696c0" | 8 | SRCREV_spirv-headers = "faa570afbc91ac73d594d787486bcf8f2df1ace0" |
9 | SRCREV_spirv-tools = "d2b486219495594f2e5d0e8d457fc234a3460b3b" | 9 | SRCREV_spirv-tools = "f11f7434815838bbad349124767b258ce7df41f0" |
10 | SRC_URI[renderdoc.sha256sum] = "e7b5f0aa5b1b0eadc63a1c624c0ca7f5af133aa857d6a4271b0ef3d0bdb6868e" | 10 | SRC_URI[renderdoc.sha256sum] = "e7b5f0aa5b1b0eadc63a1c624c0ca7f5af133aa857d6a4271b0ef3d0bdb6868e" |
11 | 11 | ||
12 | S = "${WORKDIR}/git" | 12 | S = "${WORKDIR}/git" |