From 1e4599311b37a1324c4fe5fff8d70dc5e9d6d089 Mon Sep 17 00:00:00 2001 From: Antonios Christidis Date: Wed, 1 Jul 2026 16:17:31 -0500 Subject: [PATCH] opencl-cts: Suppress -Wfree-nonheap-object compiler warning Suppress warnings from -Wfree-nonheap-object check. The warning occurs during std::vector cleanup when deallocating memory with offset pointers for test "compare_pointers" only on 32 bit platforms. /recipe-sysroot/usr/include/c++/16.1.0/bits/new_allocator.h:183:66: error: 'void operator delete(void*, std::size_t)' called on pointer '__result' with nonzero offset 24 [-Werror=free-nonheap-object] 183 | _GLIBCXX_OPERATOR_DELETE(_GLIBCXX_SIZED_DEALLOC(__p, __n)); | ^ /test_conformance/generic_address_space/basic_tests.cpp: In function 'int test_compare_pointers(cl_device_id, cl_context, cl_command_queue, int)': /test_common/harness/testHarness.h:151:9: note: declared here 151 | int test_##name(cl_device_id device, cl_context context, \ | ^~~~~ /test_common/harness/testHarness.h:154:29: note: in expansion of macro 'REGISTER_TEST_VERSION' 154 | #define REGISTER_TEST(name) REGISTER_TEST_VERSION(name, Version(1, 2)) | ^~~~~~~~~~~~~~~~~~~~~ /test_conformance/generic_address_space/basic_tests.cpp:776:1: note: in expansion of macro 'REGISTER_TEST' 776 | REGISTER_TEST(compare_pointers) | ^~~~~~~~~~~~~ Signed-off-by: Antonios Christidis Signed-off-by: Khem Raj --- meta-oe/recipes-core/opencl/opencl-cts_2026.06.18.bb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meta-oe/recipes-core/opencl/opencl-cts_2026.06.18.bb b/meta-oe/recipes-core/opencl/opencl-cts_2026.06.18.bb index 17480d62ef..e0db6a1314 100644 --- a/meta-oe/recipes-core/opencl/opencl-cts_2026.06.18.bb +++ b/meta-oe/recipes-core/opencl/opencl-cts_2026.06.18.bb @@ -22,6 +22,8 @@ SRCREV = "8d8f3d272dbd3f0a84156be7890835c4b6deff8e" EXTRA_OECMAKE:append = " -DSPIRV_INCLUDE_DIR=${STAGING_EXECPREFIXDIR} -DCL_INCLUDE_DIR=${STAGING_INCDIR} -DCL_LIB_DIR=${STAGING_LIBDIR} -DOPENCL_LIBRARIES=OpenCL" +SECURITY_STRINGFORMAT:append:arm = " -Wno-free-nonheap-object" + PACKAGECONFIG = " \ ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'opengl gles', '', d)} \ ${@bb.utils.filter('DISTRO_FEATURES', 'vulkan', d)} \