diff options
Diffstat (limited to 'dynamic-layers/clang-layer')
22 files changed, 329 insertions, 339 deletions
diff --git a/dynamic-layers/clang-layer/recipes-core/dnn/onednn_2.6.1.bb b/dynamic-layers/clang-layer/recipes-core/dnn/onednn_3.4.1.bb index ee39f51b..2fa3f627 100644 --- a/dynamic-layers/clang-layer/recipes-core/dnn/onednn_2.6.1.bb +++ b/dynamic-layers/clang-layer/recipes-core/dnn/onednn_3.4.1.bb | |||
@@ -3,7 +3,7 @@ SUMMARY = "Deep Neural Network Library" | |||
3 | DESCRIPTION = "This software is a user mode library that accelerates\ | 3 | DESCRIPTION = "This software is a user mode library that accelerates\ |
4 | deep-learning applications and frameworks on Intel architecture." | 4 | deep-learning applications and frameworks on Intel architecture." |
5 | LICENSE = "Apache-2.0 & BSD-3-Clause & BSL-1.0" | 5 | LICENSE = "Apache-2.0 & BSD-3-Clause & BSL-1.0" |
6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=b48e3de3bfd47c27882a0d85b20823f5 \ | 6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=3b64000f6e7d52516017622a37a94ce9 \ |
7 | file://tests/gtests/gtest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \ | 7 | file://tests/gtests/gtest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \ |
8 | file://src/cpu/x64/xbyak/COPYRIGHT;md5=3b9bf048d063d54cdb28964db558bcc7 \ | 8 | file://src/cpu/x64/xbyak/COPYRIGHT;md5=3b9bf048d063d54cdb28964db558bcc7 \ |
9 | file://src/common/ittnotify/LICENSE.BSD;md5=e671ff178b24a95a382ba670503c66fb \ | 9 | file://src/common/ittnotify/LICENSE.BSD;md5=e671ff178b24a95a382ba670503c66fb \ |
@@ -12,9 +12,11 @@ SECTION = "lib" | |||
12 | 12 | ||
13 | inherit pkgconfig cmake ptest | 13 | inherit pkgconfig cmake ptest |
14 | 14 | ||
15 | DNN_BRANCH = "rls-v${@'.'.join(d.getVar('PV').split('.')[0:2])}" | ||
16 | |||
15 | S = "${WORKDIR}/git" | 17 | S = "${WORKDIR}/git" |
16 | SRCREV = "58be3660fb57c4c4a3d306730e849237d1271572" | 18 | SRCREV = "f5ff0a6de16c130053bec1a1aec3a9b826c66f78" |
17 | SRC_URI = "git://github.com/oneapi-src/oneDNN.git;branch=rls-v2.6;protocol=https \ | 19 | SRC_URI = "git://github.com/oneapi-src/oneDNN.git;branch=${DNN_BRANCH};protocol=https \ |
18 | file://run-ptest \ | 20 | file://run-ptest \ |
19 | " | 21 | " |
20 | 22 | ||
@@ -32,10 +34,11 @@ EXTRA_OECMAKE += " \ | |||
32 | -DDNNL_CPU_RUNTIME=OMP \ | 34 | -DDNNL_CPU_RUNTIME=OMP \ |
33 | -DDNNL_ARCH_OPT_FLAGS="" \ | 35 | -DDNNL_ARCH_OPT_FLAGS="" \ |
34 | -DCMAKE_SKIP_RPATH=ON \ | 36 | -DCMAKE_SKIP_RPATH=ON \ |
37 | -DONEDNN_BUILD_GRAPH=OFF \ | ||
35 | " | 38 | " |
36 | 39 | ||
37 | PACKAGECONFIG ??= "gpu" | 40 | PACKAGECONFIG ??= "gpu" |
38 | PACKAGECONFIG[gpu] = "-DDNNL_GPU_RUNTIME=OCL, , opencl-headers ocl-icd, intel-compute-runtime" | 41 | PACKAGECONFIG[gpu] = "-DDNNL_GPU_RUNTIME=OCL, , opencl-headers virtual/opencl-icd, intel-compute-runtime" |
39 | 42 | ||
40 | do_install:append () { | 43 | do_install:append () { |
41 | install -d ${D}${bindir}/mkl-dnn/tests/benchdnn/inputs | 44 | install -d ${D}${bindir}/mkl-dnn/tests/benchdnn/inputs |
diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-link-with-libclang-cpp-library-instea.patch b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-link-with-libclang-cpp-library-instea.patch deleted file mode 100644 index 4e25420c..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-link-with-libclang-cpp-library-instea.patch +++ /dev/null | |||
@@ -1,28 +0,0 @@ | |||
1 | From b9bc0df996d1e65fd70d5eb2d40866693f23bb67 Mon Sep 17 00:00:00 2001 | ||
2 | From: Naveen Saini <naveen.kumar.saini@intel.com> | ||
3 | Date: Thu, 24 Jun 2021 17:53:27 +0800 | ||
4 | Subject: [PATCH] CMakeLists.txt: link with libclang-cpp library instead | ||
5 | |||
6 | Upstream-Status: Inappropriate | ||
7 | |||
8 | Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com> | ||
9 | --- | ||
10 | CMakeLists.txt | 2 +- | ||
11 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
12 | |||
13 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
14 | index ef88317e..7507d6a5 100644 | ||
15 | --- a/CMakeLists.txt | ||
16 | +++ b/CMakeLists.txt | ||
17 | @@ -281,7 +281,7 @@ if (WASM_ENABLED) | ||
18 | list(APPEND ISPC_TARGETS wasm-i32x4) | ||
19 | endif() | ||
20 | |||
21 | -set(CLANG_LIBRARY_LIST clangFrontend clangDriver clangSerialization clangParse clangSema clangAnalysis clangAST clangBasic clangEdit clangLex) | ||
22 | +set(CLANG_LIBRARY_LIST clang-cpp) | ||
23 | set(LLVM_COMPONENTS engine ipo bitreader bitwriter instrumentation linker option frontendopenmp) | ||
24 | |||
25 | if (X86_ENABLED) | ||
26 | -- | ||
27 | 2.17.1 | ||
28 | |||
diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-Fix-QA-Issues.patch b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-Fix-QA-Issues.patch deleted file mode 100644 index e7bb599e..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-Fix-QA-Issues.patch +++ /dev/null | |||
@@ -1,37 +0,0 @@ | |||
1 | From 139b94a7fb72114c31a2a6ab3f7e6024b4a738ec Mon Sep 17 00:00:00 2001 | ||
2 | From: Yogesh Tyagi <yogesh.tyagi@intel.com> | ||
3 | Date: Tue, 26 Jul 2022 15:25:10 +0800 | ||
4 | Subject: [PATCH] Fix QA Issues | ||
5 | |||
6 | Stop ispc from inserting host file path in generated headers which leads to reproducibility problems. | ||
7 | |||
8 | Upstream-Status: Inappropriate [OE build specific] | ||
9 | |||
10 | Signed-off-by: Yogesh Tyagi <yogesh.tyagi@intel.com> | ||
11 | |||
12 | --- | ||
13 | src/module.cpp | 4 ++-- | ||
14 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
15 | |||
16 | diff --git a/src/module.cpp b/src/module.cpp | ||
17 | index 58a2ae83..82673052 100644 | ||
18 | --- a/src/module.cpp | ||
19 | +++ b/src/module.cpp | ||
20 | @@ -2105,7 +2105,7 @@ bool Module::writeHeader(const char *fn) { | ||
21 | perror("fopen"); | ||
22 | return false; | ||
23 | } | ||
24 | - fprintf(f, "//\n// %s\n// (Header automatically generated by the ispc compiler.)\n", fn); | ||
25 | + fprintf(f, "//\n// \n// (Header automatically generated by the ispc compiler.)\n"); | ||
26 | fprintf(f, "// DO NOT EDIT THIS FILE.\n//\n\n"); | ||
27 | |||
28 | // Create a nice guard string from the filename, turning any | ||
29 | @@ -2219,7 +2219,7 @@ bool Module::writeDispatchHeader(DispatchHeaderInfo *DHI) { | ||
30 | FILE *f = DHI->file; | ||
31 | |||
32 | if (DHI->EmitFrontMatter) { | ||
33 | - fprintf(f, "//\n// %s\n// (Header automatically generated by the ispc compiler.)\n", DHI->fn); | ||
34 | + fprintf(f, "//\n// \n// (Header automatically generated by the ispc compiler.)\n"); | ||
35 | fprintf(f, "// DO NOT EDIT THIS FILE.\n//\n\n"); | ||
36 | } | ||
37 | // Create a nice guard string from the filename, turning any | ||
diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0002-cmake-don-t-build-for-32-bit-targets.patch b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0002-cmake-don-t-build-for-32-bit-targets.patch deleted file mode 100644 index a13ade9f..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0002-cmake-don-t-build-for-32-bit-targets.patch +++ /dev/null | |||
@@ -1,64 +0,0 @@ | |||
1 | From 493e886d6dae2ed7bdc12ed03f717ee0e98dfe09 Mon Sep 17 00:00:00 2001 | ||
2 | From: Naveen Saini <naveen.kumar.saini@intel.com> | ||
3 | Date: Thu, 24 Feb 2022 20:01:11 +0530 | ||
4 | Subject: [PATCH] cmake: don't build for 32-bit targets | ||
5 | |||
6 | Error log: | ||
7 | | tmp/work/corei7-64-poky-linux/ispc/1.16.0-r0/recipe-sysroot/usr/include/bits/long-double.h:23:10: fatal error: 'bits/long-double-32.h' file not found | ||
8 | | #include <bits/long-double-32.h> | ||
9 | | ^~~~~~~~~~~~~~~~~~~~~~~ | ||
10 | | 1 error generated. | ||
11 | |||
12 | Remove SYSTEM include search path and set -isysroot dir path | ||
13 | for root dir for cross compilation. | ||
14 | |||
15 | Upstream-Status: Inappropriate | ||
16 | |||
17 | Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com> | ||
18 | --- | ||
19 | cmake/GenerateBuiltins.cmake | 8 ++++---- | ||
20 | 1 file changed, 4 insertions(+), 4 deletions(-) | ||
21 | |||
22 | diff --git a/cmake/GenerateBuiltins.cmake b/cmake/GenerateBuiltins.cmake | ||
23 | index fa228247..7adc7e52 100644 | ||
24 | --- a/cmake/GenerateBuiltins.cmake | ||
25 | +++ b/cmake/GenerateBuiltins.cmake | ||
26 | @@ -272,7 +272,7 @@ function(builtin_to_cpp bit os_name arch supported_archs supported_oses resultFi | ||
27 | # In this case headers will be installed in /usr/arm-linux-gnueabihf/include and will not be picked up | ||
28 | # by clang by default. So the following line adds such path explicitly. If this path doesn't exist and | ||
29 | # the headers can be found in other locations, this should not be a problem. | ||
30 | - set(includePath -isystem/usr/${debian_triple}/include) | ||
31 | + set(includePath -isysroot${SYSROOT_DIR}) | ||
32 | endif() | ||
33 | endif() | ||
34 | |||
35 | @@ -354,7 +354,7 @@ function (generate_target_builtins resultList) | ||
36 | set(regular_targets ${ARGN}) | ||
37 | list(FILTER regular_targets EXCLUDE REGEX wasm) | ||
38 | foreach (ispc_target ${regular_targets}) | ||
39 | - foreach (bit 32 64) | ||
40 | + foreach (bit 64) | ||
41 | foreach (os_name ${TARGET_OS_LIST_FOR_LL}) | ||
42 | target_ll_to_cpp(target-${ispc_target} ${bit} ${os_name} output${os_name}${bit}) | ||
43 | list(APPEND tmpList ${output${os_name}${bit}}) | ||
44 | @@ -415,7 +415,7 @@ function (generate_common_builtins resultList) | ||
45 | endif() | ||
46 | |||
47 | message (STATUS "ISPC will be built with support of ${supported_oses} for ${supported_archs}") | ||
48 | - foreach (bit 32 64) | ||
49 | + foreach (bit 64) | ||
50 | foreach (os_name "windows" "linux" "freebsd" "macos" "android" "ios" "ps4" "web") | ||
51 | foreach (arch "x86" "arm" "wasm32") | ||
52 | builtin_to_cpp(${bit} ${os_name} ${arch} "${supported_archs}" "${supported_oses}" res${bit}${os_name}${arch}) | ||
53 | @@ -428,7 +428,7 @@ function (generate_common_builtins resultList) | ||
54 | endforeach() | ||
55 | endforeach() | ||
56 | if (XE_ENABLED) | ||
57 | - foreach (bit 32 64) | ||
58 | + foreach (bit 64) | ||
59 | builtin_xe_to_cpp(${bit} res_xe_${bit}) | ||
60 | list(APPEND tmpList ${res_xe_${bit}} ) | ||
61 | if(MSVC) | ||
62 | -- | ||
63 | 2.17.1 | ||
64 | |||
diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.18.0.bb b/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.18.0.bb deleted file mode 100644 index db674178..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.18.0.bb +++ /dev/null | |||
@@ -1,47 +0,0 @@ | |||
1 | SUMMARY = "Intel(R) Implicit SPMD Program Compiler" | ||
2 | DESCRIPTION = "ispc is a compiler for a variant of the C programming language, \ | ||
3 | with extensions for single program, multiple data programming." | ||
4 | HOMEPAGE = "https://github.com/ispc/ispc" | ||
5 | |||
6 | LICENSE = "BSD-3-Clause & Apache-2.0-with-LLVM-exception" | ||
7 | LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=da5ecffdd210b3cf776b32b41c182e87 \ | ||
8 | file://third-party-programs.txt;md5=3cd6f8a7c3bd9d2bb898fcb27c75221a" | ||
9 | |||
10 | inherit cmake python3native | ||
11 | |||
12 | S = "${WORKDIR}/git" | ||
13 | |||
14 | SRC_URI = "git://github.com/ispc/ispc.git;protocol=https;branch=main \ | ||
15 | file://0001-CMakeLists.txt-link-with-libclang-cpp-library-instea.patch \ | ||
16 | file://0002-cmake-don-t-build-for-32-bit-targets.patch \ | ||
17 | file://0001-Fix-QA-Issues.patch \ | ||
18 | " | ||
19 | SRCREV = "f7ec3aa173c816377c215d83196b5c7c3a88db1c" | ||
20 | |||
21 | COMPATIBLE_HOST = '(x86_64).*-linux' | ||
22 | |||
23 | DEPENDS += " clang-native bison-native flex-native" | ||
24 | RDEPENDS:${PN} += " clang-libllvm clang" | ||
25 | |||
26 | YFLAGS='-d -t -v -y --file-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}' | ||
27 | |||
28 | do_configure:prepend() { | ||
29 | sed -i -e 's#\${BISON_EXECUTABLE}.*#\${BISON_EXECUTABLE} ${YFLAGS} #g' ${S}/CMakeLists.txt | ||
30 | sed -i -e 's#\${FLEX_EXECUTABLE}.*#\${FLEX_EXECUTABLE} \-L #g' ${S}/CMakeLists.txt | ||
31 | } | ||
32 | |||
33 | EXTRA_OECMAKE += " \ | ||
34 | -DISPC_INCLUDE_TESTS=OFF \ | ||
35 | -DISPC_INCLUDE_EXAMPLES=OFF \ | ||
36 | -DISPC_NO_DUMPS=ON \ | ||
37 | -DARM_ENABLED=OFF \ | ||
38 | -DISPC_CROSS=ON \ | ||
39 | -DISPC_ANDROID_TARGET=OFF \ | ||
40 | -DISPC_FREEBSD_TARGET=OFF \ | ||
41 | -DISPC_WINDOWS_TARGET=OFF \ | ||
42 | -DISPC_IOS_TARGET=OFF \ | ||
43 | -DISPC_PS4_TARGET=OFF \ | ||
44 | -DSYSROOT_DIR=${STAGING_DIR_NATIVE} \ | ||
45 | " | ||
46 | |||
47 | BBCLASSEXTEND = "native nativesdk" | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/allow-to-find-cpp-generation-tool.patch b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/allow-to-find-cpp-generation-tool.patch index 4646856d..265fcfa2 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/allow-to-find-cpp-generation-tool.patch +++ b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/allow-to-find-cpp-generation-tool.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From 40e9344d37d62158e6c9f72919f0595ef5fde61a Mon Sep 17 00:00:00 2001 | 1 | From a6361d635e5f3046853883f3ac06fb175116933c Mon Sep 17 00:00:00 2001 |
2 | From: Dongwon Kim <dongwon.kim@intel.com> | 2 | From: Dongwon Kim <dongwon.kim@intel.com> |
3 | Date: Sat, 21 Aug 2021 16:09:39 -0700 | 3 | Date: Sat, 21 Aug 2021 16:09:39 -0700 |
4 | Subject: [PATCH] Build not able to locate cpp_generation_tool. | 4 | Subject: [PATCH] Build not able to locate cpp_generation_tool. |
@@ -7,28 +7,27 @@ Upstream-Status: Inappropriate [oe specific] | |||
7 | 7 | ||
8 | Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com> | 8 | Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com> |
9 | Signed-off-by: Dongwon Kim <dongwon.kim@intel.com> | 9 | Signed-off-by: Dongwon Kim <dongwon.kim@intel.com> |
10 | |||
11 | --- | 10 | --- |
12 | shared/source/built_ins/kernels/CMakeLists.txt | 8 ++++---- | 11 | shared/source/built_ins/kernels/CMakeLists.txt | 10 +++++----- |
13 | 1 file changed, 4 insertions(+), 4 deletions(-) | 12 | 1 file changed, 5 insertions(+), 5 deletions(-) |
14 | 13 | ||
15 | diff --git a/shared/source/built_ins/kernels/CMakeLists.txt b/shared/source/built_ins/kernels/CMakeLists.txt | 14 | diff --git a/shared/source/built_ins/kernels/CMakeLists.txt b/shared/source/built_ins/kernels/CMakeLists.txt |
16 | index 769e2a100..eef25747e 100644 | 15 | index ed85a37c52..f7c9e79137 100644 |
17 | --- a/shared/source/built_ins/kernels/CMakeLists.txt | 16 | --- a/shared/source/built_ins/kernels/CMakeLists.txt |
18 | +++ b/shared/source/built_ins/kernels/CMakeLists.txt | 17 | +++ b/shared/source/built_ins/kernels/CMakeLists.txt |
19 | @@ -94,9 +94,9 @@ function(compile_builtin core_type platform_type builtin bits builtin_options mo | 18 | @@ -107,9 +107,9 @@ function(compile_builtin core_type platform_it builtin bits builtin_options mode |
20 | ) | 19 | ) |
21 | add_custom_command( | 20 | add_custom_command( |
22 | OUTPUT ${OUTPUT_FILE_CPP} | 21 | OUTPUT ${OUTPUT_FILE_CPP} |
23 | - COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${BINARY_OUTPUT}.gen --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID} | 22 | - COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${BINARY_OUTPUT}.bin --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --device ${RELEASE_FILENAME} |
24 | + COMMAND cpp_generate_tool --file ${BINARY_OUTPUT}.gen --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID} | 23 | + COMMAND cpp_generate_tool --file ${BINARY_OUTPUT}.bin --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --device ${RELEASE_FILENAME} |
25 | WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} | 24 | WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} |
26 | - DEPENDS ${OUTPUT_FILES_BINARIES} $<TARGET_FILE:cpp_generate_tool> | 25 | - DEPENDS ${OUTPUT_FILES_BINARIES} $<TARGET_FILE:cpp_generate_tool> |
27 | + DEPENDS ${OUTPUT_FILES_BINARIES} cpp_generate_tool | 26 | + DEPENDS ${OUTPUT_FILES_BINARIES} cpp_generate_tool |
28 | ) | 27 | ) |
29 | list(APPEND BUILTINS_COMMANDS "${OUTPUT_FILE_CPP}") | 28 | list(APPEND BUILTINS_COMMANDS "${OUTPUT_FILE_CPP}") |
30 | else() | 29 | else() |
31 | @@ -147,9 +147,9 @@ function(generate_cpp_spirv builtin) | 30 | @@ -159,9 +159,9 @@ function(generate_cpp_spirv builtin) |
32 | ) | 31 | ) |
33 | add_custom_command( | 32 | add_custom_command( |
34 | OUTPUT ${OUTPUT_FILE_CPP} | 33 | OUTPUT ${OUTPUT_FILE_CPP} |
@@ -40,3 +39,13 @@ index 769e2a100..eef25747e 100644 | |||
40 | ) | 39 | ) |
41 | set(OUTPUT_LIST_CPP_FILES ${OUTPUT_LIST_CPP_FILES} ${OUTPUT_FILE_CPP} PARENT_SCOPE) | 40 | set(OUTPUT_LIST_CPP_FILES ${OUTPUT_LIST_CPP_FILES} ${OUTPUT_FILE_CPP} PARENT_SCOPE) |
42 | else() | 41 | else() |
42 | @@ -277,4 +277,4 @@ if(NOT "${OUTPUT_LIST_CPP_FILES}" STREQUAL "") | ||
43 | ) | ||
44 | endif() | ||
45 | |||
46 | -apply_macro_for_each_core_type("SUPPORTED") | ||
47 | \ No newline at end of file | ||
48 | +apply_macro_for_each_core_type("SUPPORTED") | ||
49 | -- | ||
50 | 2.43.2 | ||
51 | |||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/disable-werror.patch b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/disable-werror.patch new file mode 100644 index 00000000..20d9b847 --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/disable-werror.patch | |||
@@ -0,0 +1,16 @@ | |||
1 | Upstream-Status: Inappropriate | ||
2 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
3 | |||
4 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
5 | index d52e089778..bc0cf35014 100644 | ||
6 | --- a/CMakeLists.txt | ||
7 | +++ b/CMakeLists.txt | ||
8 | @@ -727,7 +727,7 @@ if(NOT MSVC) | ||
9 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-noexcept-type") # Added for gtest | ||
10 | endif() | ||
11 | endif() | ||
12 | - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror -Werror=vla") | ||
13 | + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=vla") | ||
14 | |||
15 | if(USE_SANITIZE_UB) | ||
16 | check_cxx_compiler_flag(-fsanitize=undefined COMPILER_SUPPORTS_UNDEFINED_BEHAVIOR_SANITIZER) | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/external-ocloc.patch b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/external-ocloc.patch index 9ee8c96a..5f93b7b6 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/external-ocloc.patch +++ b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/external-ocloc.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From 1189028d9f77265edf6258a66f8ecadf3aad556a Mon Sep 17 00:00:00 2001 | 1 | From 1f58c22992ddea4167b01b44448528de427f50d5 Mon Sep 17 00:00:00 2001 |
2 | From: Dongwon Kim <dongwon.kim@intel.com> | 2 | From: Dongwon Kim <dongwon.kim@intel.com> |
3 | Date: Wed, 2 Mar 2022 15:52:45 -0800 | 3 | Date: Wed, 2 Mar 2022 15:52:45 -0800 |
4 | Subject: [PATCH] external ocloc | 4 | Subject: [PATCH] external ocloc |
@@ -11,7 +11,7 @@ Signed-off-by: Dongwon Kim <dongwon.kim@intel.com> | |||
11 | 1 file changed, 8 insertions(+), 6 deletions(-) | 11 | 1 file changed, 8 insertions(+), 6 deletions(-) |
12 | 12 | ||
13 | diff --git a/cmake/ocloc_cmd_prefix.cmake b/cmake/ocloc_cmd_prefix.cmake | 13 | diff --git a/cmake/ocloc_cmd_prefix.cmake b/cmake/ocloc_cmd_prefix.cmake |
14 | index 9b6bd3cd3..0aba48709 100644 | 14 | index 2b44330831..03067c9df0 100644 |
15 | --- a/cmake/ocloc_cmd_prefix.cmake | 15 | --- a/cmake/ocloc_cmd_prefix.cmake |
16 | +++ b/cmake/ocloc_cmd_prefix.cmake | 16 | +++ b/cmake/ocloc_cmd_prefix.cmake |
17 | @@ -4,12 +4,14 @@ | 17 | @@ -4,12 +4,14 @@ |
@@ -22,19 +22,19 @@ index 9b6bd3cd3..0aba48709 100644 | |||
22 | - set(ocloc_cmd_prefix ocloc) | 22 | - set(ocloc_cmd_prefix ocloc) |
23 | -else() | 23 | -else() |
24 | - if(DEFINED NEO__IGC_LIBRARY_PATH) | 24 | - if(DEFINED NEO__IGC_LIBRARY_PATH) |
25 | - set(ocloc_cmd_prefix LD_LIBRARY_PATH=${NEO__IGC_LIBRARY_PATH}:$<TARGET_FILE_DIR:ocloc_lib> $<TARGET_FILE:ocloc>) | 25 | - set(ocloc_cmd_prefix ${CMAKE_COMMAND} -E env "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${NEO__IGC_LIBRARY_PATH}:$<TARGET_FILE_DIR:ocloc_lib>" $<TARGET_FILE:ocloc>) |
26 | +if(NOT DEFINED ocloc_cmd_prefix) | 26 | +if(NOT DEFINED ocloc_cmd_prefix) |
27 | + if(WIN32) | 27 | + if(WIN32) |
28 | + set(ocloc_cmd_prefix ocloc) | 28 | + set(ocloc_cmd_prefix ocloc) |
29 | else() | 29 | else() |
30 | - set(ocloc_cmd_prefix LD_LIBRARY_PATH=$<TARGET_FILE_DIR:ocloc_lib> $<TARGET_FILE:ocloc>) | 30 | - set(ocloc_cmd_prefix ${CMAKE_COMMAND} -E env "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$<TARGET_FILE_DIR:ocloc_lib>" $<TARGET_FILE:ocloc>) |
31 | + if(DEFINED NEO__IGC_LIBRARY_PATH) | 31 | + if(DEFINED NEO__IGC_LIBRARY_PATH) |
32 | + set(ocloc_cmd_prefix LD_LIBRARY_PATH=${NEO__IGC_LIBRARY_PATH}:$<TARGET_FILE_DIR:ocloc_lib> $<TARGET_FILE:ocloc>) | 32 | + set(ocloc_cmd_prefix LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${NEO__IGC_LIBRARY_PATH}:$<TARGET_FILE_DIR:ocloc_lib> $<TARGET_FILE:ocloc>) |
33 | + else() | 33 | + else() |
34 | + set(ocloc_cmd_prefix LD_LIBRARY_PATH=$<TARGET_FILE_DIR:ocloc_lib> $<TARGET_FILE:ocloc>) | 34 | + set(ocloc_cmd_prefix LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$<TARGET_FILE_DIR:ocloc_lib> $<TARGET_FILE:ocloc>) |
35 | + endif() | 35 | + endif() |
36 | endif() | 36 | endif() |
37 | endif() | 37 | endif() |
38 | -- | 38 | -- |
39 | 2.20.1 | 39 | 2.37.3 |
40 | 40 | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/f10439aea214984a060566831f63d3aa198ef1b8.patch b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/f10439aea214984a060566831f63d3aa198ef1b8.patch new file mode 100644 index 00000000..b7fcb3d1 --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/f10439aea214984a060566831f63d3aa198ef1b8.patch | |||
@@ -0,0 +1,54 @@ | |||
1 | From f10439aea214984a060566831f63d3aa198ef1b8 Mon Sep 17 00:00:00 2001 | ||
2 | From: Pawel Cieslak <pawel.cieslak@intel.com> | ||
3 | Date: Tue, 14 May 2024 14:20:24 +0000 | ||
4 | Subject: [PATCH] fix: include <algorithm> where std::find is used | ||
5 | |||
6 | Related-To: NEO-11375 | ||
7 | Signed-off-by: Pawel Cieslak <pawel.cieslak@intel.com> | ||
8 | |||
9 | Upstream-Status: Backport [https://github.com/intel/compute-runtime/commit/f10439aea214984a060566831f63d3aa198ef1b8] | ||
10 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
11 | --- | ||
12 | .../sources/linux/nl_api/test_sysman_iaf_nl_api_prelim.cpp | 3 ++- | ||
13 | shared/test/unit_test/gmm_helper/gmm_resource_info_tests.cpp | 4 +++- | ||
14 | 2 files changed, 5 insertions(+), 2 deletions(-) | ||
15 | |||
16 | diff --git a/level_zero/sysman/test/unit_tests/sources/linux/nl_api/test_sysman_iaf_nl_api_prelim.cpp b/level_zero/sysman/test/unit_tests/sources/linux/nl_api/test_sysman_iaf_nl_api_prelim.cpp | ||
17 | index 6ab1b751d866..8a224752c8fc 100644 | ||
18 | --- a/level_zero/sysman/test/unit_tests/sources/linux/nl_api/test_sysman_iaf_nl_api_prelim.cpp | ||
19 | +++ b/level_zero/sysman/test/unit_tests/sources/linux/nl_api/test_sysman_iaf_nl_api_prelim.cpp | ||
20 | @@ -1,5 +1,5 @@ | ||
21 | /* | ||
22 | - * Copyright (C) 2021-2023 Intel Corporation | ||
23 | + * Copyright (C) 2021-2024 Intel Corporation | ||
24 | * | ||
25 | * SPDX-License-Identifier: MIT | ||
26 | * | ||
27 | @@ -13,6 +13,7 @@ | ||
28 | |||
29 | #include "gtest/gtest.h" | ||
30 | |||
31 | +#include <algorithm> | ||
32 | #include <limits> | ||
33 | #include <netlink/handlers.h> | ||
34 | |||
35 | diff --git a/shared/test/unit_test/gmm_helper/gmm_resource_info_tests.cpp b/shared/test/unit_test/gmm_helper/gmm_resource_info_tests.cpp | ||
36 | index 206c272c5bb2..e961248e73a3 100644 | ||
37 | --- a/shared/test/unit_test/gmm_helper/gmm_resource_info_tests.cpp | ||
38 | +++ b/shared/test/unit_test/gmm_helper/gmm_resource_info_tests.cpp | ||
39 | @@ -1,5 +1,5 @@ | ||
40 | /* | ||
41 | - * Copyright (C) 2021-2023 Intel Corporation | ||
42 | + * Copyright (C) 2021-2024 Intel Corporation | ||
43 | * | ||
44 | * SPDX-License-Identifier: MIT | ||
45 | * | ||
46 | @@ -17,6 +17,8 @@ | ||
47 | |||
48 | #include "gtest/gtest.h" | ||
49 | |||
50 | +#include <algorithm> | ||
51 | + | ||
52 | using namespace NEO; | ||
53 | |||
54 | struct MockGmmHandleAllocator : NEO::GmmHandleAllocator { | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_22.32.23937.bb b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_24.13.29138.7.bb index 99391d00..7280ed03 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_22.32.23937.bb +++ b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_24.13.29138.7.bb | |||
@@ -4,27 +4,26 @@ is an open source project to converge Intel's development efforts \ | |||
4 | on OpenCL(TM) compute stacks supporting the GEN graphics hardware \ | 4 | on OpenCL(TM) compute stacks supporting the GEN graphics hardware \ |
5 | architecture." | 5 | architecture." |
6 | 6 | ||
7 | LICENSE = "MIT" | 7 | LICENSE = "MIT & Apache-2.0" |
8 | LIC_FILES_CHKSUM = "file://LICENSE.md;md5=9280143b568466d8fbe385f838078b93 \ | 8 | LIC_FILES_CHKSUM = "file://LICENSE.md;md5=eca6ec6997e18db166db7109cdbe611c \ |
9 | file://third_party/opencl_headers/LICENSE;md5=dcefc90f4c3c689ec0c2489064e7273b" | 9 | file://third_party/opencl_headers/LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" |
10 | 10 | ||
11 | SRC_URI = "git://github.com/intel/compute-runtime.git;protocol=https;branch=master \ | 11 | SRC_URI = "git://github.com/intel/compute-runtime.git;protocol=https;branch=releases/24.13 \ |
12 | " | 12 | file://disable-werror.patch \ |
13 | file://allow-to-find-cpp-generation-tool.patch \ | ||
14 | file://external-ocloc.patch \ | ||
15 | file://f10439aea214984a060566831f63d3aa198ef1b8.patch \ | ||
16 | " | ||
13 | 17 | ||
14 | SRC_URI:append:class-target = "file://allow-to-find-cpp-generation-tool.patch \ | 18 | SRCREV = "7131387cdbb02d480a225c70daef913a6c024a6e" |
15 | file://external-ocloc.patch \ | ||
16 | " | ||
17 | |||
18 | SRCREV = "b38c750cc40d7f5e8bbb2b9b74c6d67120abe0bf" | ||
19 | 19 | ||
20 | S = "${WORKDIR}/git" | 20 | S = "${WORKDIR}/git" |
21 | 21 | ||
22 | DEPENDS += " intel-graphics-compiler gmmlib" | 22 | DEPENDS += " intel-graphics-compiler gmmlib libva qemu-native" |
23 | DEPENDS:append:class-target = " intel-compute-runtime-native libva" | ||
24 | 23 | ||
25 | RDEPENDS:${PN} += " intel-graphics-compiler gmmlib" | 24 | RDEPENDS:${PN} += " intel-graphics-compiler gmmlib" |
26 | 25 | ||
27 | inherit cmake pkgconfig | 26 | inherit cmake pkgconfig qemu |
28 | 27 | ||
29 | COMPATIBLE_HOST = '(x86_64).*-linux' | 28 | COMPATIBLE_HOST = '(x86_64).*-linux' |
30 | COMPATIBLE_HOST:libc-musl = "null" | 29 | COMPATIBLE_HOST:libc-musl = "null" |
@@ -40,14 +39,20 @@ EXTRA_OECMAKE = " \ | |||
40 | 39 | ||
41 | EXTRA_OECMAKE:append:class-target = " \ | 40 | EXTRA_OECMAKE:append:class-target = " \ |
42 | -Docloc_cmd_prefix=ocloc \ | 41 | -Docloc_cmd_prefix=ocloc \ |
43 | " | 42 | -DCMAKE_CROSSCOMPILING_EMULATOR=${WORKDIR}/qemuwrapper \ |
43 | " | ||
44 | 44 | ||
45 | PACKAGECONFIG ??= "" | 45 | PACKAGECONFIG ??= "" |
46 | PACKAGECONFIG[levelzero] = "-DBUILD_WITH_L0=ON, -DBUILD_WITH_L0=OFF, level-zero" | 46 | PACKAGECONFIG[levelzero] = "-DBUILD_WITH_L0=ON, -DBUILD_WITH_L0=OFF, level-zero" |
47 | 47 | ||
48 | do_install:append:class-native() { | 48 | do_configure:prepend:class-target () { |
49 | install -d ${D}${bindir} | 49 | # Write out a qemu wrapper that will be used by cmake. |
50 | install ${B}/bin/cpp_generate_tool ${D}${bindir}/ | 50 | qemu_binary="${@qemu_wrapper_cmdline(d, d.getVar('STAGING_DIR_HOST'), [d.expand('${B}/bin'),d.expand('${STAGING_DIR_HOST}${libdir}'),d.expand('${STAGING_DIR_HOST}${base_libdir}')])}" |
51 | cat > ${WORKDIR}/qemuwrapper << EOF | ||
52 | #!/bin/sh | ||
53 | $qemu_binary "\$@" | ||
54 | EOF | ||
55 | chmod +x ${WORKDIR}/qemuwrapper | ||
51 | } | 56 | } |
52 | 57 | ||
53 | FILES:${PN} += " \ | 58 | FILES:${PN} += " \ |
@@ -57,6 +62,4 @@ FILES:${PN} += " \ | |||
57 | 62 | ||
58 | FILES:${PN}-dev = "${includedir}" | 63 | FILES:${PN}-dev = "${includedir}" |
59 | 64 | ||
60 | BBCLASSEXTEND = "native nativesdk" | ||
61 | |||
62 | UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)" | 65 | UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)" |
diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch index 0dd75537..377081fd 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From 16fb6c022380bbb3c48f21372fcb1da7f30d3903 Mon Sep 17 00:00:00 2001 | 1 | From 3d71670f8ad5b54d434c2f5f71713bb1d5433ae4 Mon Sep 17 00:00:00 2001 |
2 | From: Anuj Mittal <anuj.mittal@intel.com> | 2 | From: Anuj Mittal <anuj.mittal@intel.com> |
3 | Date: Tue, 12 Oct 2021 23:46:42 +0800 | 3 | Date: Tue, 12 Oct 2021 23:46:42 +0800 |
4 | Subject: [PATCH] BiF/CMakeLists.txt: remove opt from DEPENDS | 4 | Subject: [PATCH] BiF/CMakeLists.txt: remove opt from DEPENDS |
@@ -14,22 +14,22 @@ Upstream-Status: Inappropriate | |||
14 | 14 | ||
15 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | 15 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> |
16 | --- | 16 | --- |
17 | IGC/VectorCompiler/lib/BiF/CMakeLists.txt | 2 +- | 17 | IGC/VectorCompiler/lib/BiF/cmake/Functions.cmake | 2 +- |
18 | 1 file changed, 1 insertion(+), 1 deletion(-) | 18 | 1 file changed, 1 insertion(+), 1 deletion(-) |
19 | 19 | ||
20 | diff --git a/IGC/VectorCompiler/lib/BiF/CMakeLists.txt b/IGC/VectorCompiler/lib/BiF/CMakeLists.txt | 20 | diff --git a/IGC/VectorCompiler/lib/BiF/cmake/Functions.cmake b/IGC/VectorCompiler/lib/BiF/cmake/Functions.cmake |
21 | index be8e5557e..07ab40382 100644 | 21 | index d20d7f887..882e09fea 100644 |
22 | --- a/IGC/VectorCompiler/lib/BiF/CMakeLists.txt | 22 | --- a/IGC/VectorCompiler/lib/BiF/cmake/Functions.cmake |
23 | +++ b/IGC/VectorCompiler/lib/BiF/CMakeLists.txt | 23 | +++ b/IGC/VectorCompiler/lib/BiF/cmake/Functions.cmake |
24 | @@ -112,7 +112,7 @@ function(vc_build_bif RES_FILE CMCL_SRC_PATH BIF_NAME PTR_BIT_SIZE) | 24 | @@ -109,7 +109,7 @@ function(vc_build_bif TARGET RES_FILE CMCL_SRC_PATH BIF_NAME PTR_BIT_SIZE) |
25 | add_custom_command(OUTPUT ${BIF_OPT_BC_PATH} | 25 | COMMENT "vc_build_bif: Translating CMCL builtins: ${BIF_CLANG_BC_NAME_FINAL} -> ${BIF_OPT_BC_NAME}" |
26 | COMMAND ${LLVM_OPT_EXE} --O2 -o ${BIF_OPT_BC_NAME} ${BIF_CMCL_BC_NAME} | 26 | COMMAND CMCLTranslatorTool -o ${BIF_CMCL_BC_NAME} ${BIF_CLANG_BC_NAME_FINAL} |
27 | COMMENT "vc_build_bif: running opt with O2: ${BIF_CMCL_BC_NAME} -> ${BIF_OPT_BC_NAME}" | 27 | COMMAND ${LLVM_OPT_EXE} ${IGC_LLVM_DEPENDENT_OPT_FLAGS} --O2 -o ${BIF_OPT_BC_NAME} ${BIF_CMCL_BC_NAME} |
28 | - DEPENDS opt ${BIF_CMCL_BC_PATH}) | 28 | - DEPENDS CMCLTranslatorTool ${LLVM_OPT_EXE} ${BIF_CLANG_BC_PATH_FINAL} |
29 | + DEPENDS ${BIF_CMCL_BC_PATH}) | 29 | + DEPENDS CMCLTranslatorTool ${BIF_CLANG_BC_PATH_FINAL} |
30 | BYPRODUCTS ${BIF_OPT_BC_PATH} | ||
31 | SOURCES ${CMCL_SRC_PATH}) | ||
30 | set(${RES_FILE} ${BIF_OPT_BC_NAME} PARENT_SCOPE) | 32 | set(${RES_FILE} ${BIF_OPT_BC_NAME} PARENT_SCOPE) |
31 | endfunction() | ||
32 | |||
33 | -- | 33 | -- |
34 | 2.35.3 | 34 | 2.43.2 |
35 | 35 | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-external-SPIRV-Tools-change-path-to-tools-and-header.patch b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-external-SPIRV-Tools-change-path-to-tools-and-header.patch new file mode 100644 index 00000000..dca75e22 --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-external-SPIRV-Tools-change-path-to-tools-and-header.patch | |||
@@ -0,0 +1,31 @@ | |||
1 | From e69a3181482e5f442756a61c7b683914072884f1 Mon Sep 17 00:00:00 2001 | ||
2 | From: Anuj Mittal <anuj.mittal@intel.com> | ||
3 | Date: Mon, 9 Jan 2023 11:43:05 +0800 | ||
4 | Subject: [PATCH] external/SPIRV-Tools: change path to tools and headers | ||
5 | |||
6 | We clone the SPIRV headers and tools in a different directory to ensure | ||
7 | file path substitutions take place. | ||
8 | |||
9 | Upstream-Status: Inappropriate | ||
10 | |||
11 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
12 | |||
13 | --- | ||
14 | external/SPIRV-Tools/CMakeLists.txt | 4 ++-- | ||
15 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
16 | |||
17 | diff --git a/external/SPIRV-Tools/CMakeLists.txt b/external/SPIRV-Tools/CMakeLists.txt | ||
18 | index 9afa5746c..7ca24d5dc 100644 | ||
19 | --- a/external/SPIRV-Tools/CMakeLists.txt | ||
20 | +++ b/external/SPIRV-Tools/CMakeLists.txt | ||
21 | @@ -43,8 +43,8 @@ else() #By default use build from sources | ||
22 | message(STATUS "[SPIRV-Tools] : Building from source") | ||
23 | message(STATUS "[SPIRV-Tools] : Current source dir: ${CMAKE_CURRENT_SOURCE_DIR}") | ||
24 | |||
25 | - set(SPIRV-Headers_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../SPIRV-Headers") # used in subdirectory | ||
26 | - set(SPIRV-Tools_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../SPIRV-Tools") | ||
27 | + set(SPIRV-Headers_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../SPIRV-Headers") # used in subdirectory | ||
28 | + set(SPIRV-Tools_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../SPIRV-Tools") | ||
29 | |||
30 | set(SPIRV-Tools_OUTPUT_DIR "${IGC_OPTION__OUTPUT_DIR}/external/SPIRV-Tools/build") | ||
31 | set(IGC_BUILD__SPIRV-Headers_DIR "${SPIRV-Headers_SOURCE_DIR}") | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-fix-tblgen.patch b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-fix-tblgen.patch index 24367f19..39443931 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-fix-tblgen.patch +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0001-fix-tblgen.patch | |||
@@ -1,17 +1,19 @@ | |||
1 | From 5329f00de484b470152e2bd3a5ab6dac45668b13 Mon Sep 17 00:00:00 2001 | 1 | From 5648568e597acd0fed82aac3e6aef0f95a1b78d1 Mon Sep 17 00:00:00 2001 |
2 | From: Anuj Mittal <anuj.mittal@intel.com> | 2 | From: Anuj Mittal <anuj.mittal@intel.com> |
3 | Date: Thu, 19 May 2022 22:50:09 +0800 | 3 | Date: Thu, 19 May 2022 22:50:09 +0800 |
4 | Subject: [PATCH] fix tblgen | 4 | Subject: [PATCH] fix tblgen |
5 | 5 | ||
6 | Upstream-Status: Inappropriate [OE specific] | ||
7 | |||
6 | --- | 8 | --- |
7 | IGC/cmake/igc_llvm.cmake | 2 +- | 9 | IGC/cmake/igc_llvm.cmake | 2 +- |
8 | 1 file changed, 1 insertion(+), 1 deletion(-) | 10 | 1 file changed, 1 insertion(+), 1 deletion(-) |
9 | 11 | ||
10 | diff --git a/IGC/cmake/igc_llvm.cmake b/IGC/cmake/igc_llvm.cmake | 12 | diff --git a/IGC/cmake/igc_llvm.cmake b/IGC/cmake/igc_llvm.cmake |
11 | index 89c03fc49..85be9ae08 100644 | 13 | index 10322533c..9020cb3c8 100644 |
12 | --- a/IGC/cmake/igc_llvm.cmake | 14 | --- a/IGC/cmake/igc_llvm.cmake |
13 | +++ b/IGC/cmake/igc_llvm.cmake | 15 | +++ b/IGC/cmake/igc_llvm.cmake |
14 | @@ -48,7 +48,7 @@ else() | 16 | @@ -52,7 +52,7 @@ else() |
15 | set(LLVM_OPT_EXE "opt" CACHE STRING "") | 17 | set(LLVM_OPT_EXE "opt" CACHE STRING "") |
16 | 18 | ||
17 | set(LLVM_TABLEGEN_EXE "llvm-tblgen") | 19 | set(LLVM_TABLEGEN_EXE "llvm-tblgen") |
@@ -20,6 +22,3 @@ index 89c03fc49..85be9ae08 100644 | |||
20 | if(DEFINED LLVM_TABLEGEN) | 22 | if(DEFINED LLVM_TABLEGEN) |
21 | set(LLVM_TABLEGEN_EXE ${LLVM_TABLEGEN}) | 23 | set(LLVM_TABLEGEN_EXE ${LLVM_TABLEGEN}) |
22 | else() | 24 | else() |
23 | -- | ||
24 | 2.35.3 | ||
25 | |||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0003-Improve-Reproducibility-for-src-package.patch b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0003-Improve-Reproducibility-for-src-package.patch index 7dd36aec..650130a8 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/igc/files/0003-Improve-Reproducibility-for-src-package.patch +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/files/0003-Improve-Reproducibility-for-src-package.patch | |||
@@ -1,7 +1,7 @@ | |||
1 | From c2b7f30dd56568482b1b7c2f22bafdf68736fc88 Mon Sep 17 00:00:00 2001 | 1 | From 0559332abd04b6c8bc70171d201f43d2e4735336 Mon Sep 17 00:00:00 2001 |
2 | From: Lee Chee Yang <chee.yang.lee@intel.com> | 2 | From: Lee Chee Yang <chee.yang.lee@intel.com> |
3 | Date: Wed, 2 Sep 2020 08:28:35 +0800 | 3 | Date: Wed, 2 Sep 2020 08:28:35 +0800 |
4 | Subject: [PATCH 3/5] Improve Reproducibility for src package | 4 | Subject: [PATCH] Improve Reproducibility for src package |
5 | 5 | ||
6 | Improve reproducibility for intel-graphics-compiler-src package. | 6 | Improve reproducibility for intel-graphics-compiler-src package. |
7 | needs to pass build path as environment variable to the build. | 7 | needs to pass build path as environment variable to the build. |
@@ -9,12 +9,13 @@ this only works on bison 3.7 onward, hence check for bison version | |||
9 | before adding the flags. | 9 | before adding the flags. |
10 | Upstream-Status: Inappropriate [applying --file-prefix-map in such way does not work for upstream] | 10 | Upstream-Status: Inappropriate [applying --file-prefix-map in such way does not work for upstream] |
11 | Signed-off-by: Lee Chee Yang <chee.yang.lee@intel.com> | 11 | Signed-off-by: Lee Chee Yang <chee.yang.lee@intel.com> |
12 | |||
12 | --- | 13 | --- |
13 | visa/CMakeLists.txt | 7 +++++-- | 14 | visa/CMakeLists.txt | 7 +++++-- |
14 | 1 file changed, 5 insertions(+), 2 deletions(-) | 15 | 1 file changed, 5 insertions(+), 2 deletions(-) |
15 | 16 | ||
16 | diff --git a/visa/CMakeLists.txt b/visa/CMakeLists.txt | 17 | diff --git a/visa/CMakeLists.txt b/visa/CMakeLists.txt |
17 | index 65dbb4934..8cd607a69 100644 | 18 | index 6be467587..930c386a6 100644 |
18 | --- a/visa/CMakeLists.txt | 19 | --- a/visa/CMakeLists.txt |
19 | +++ b/visa/CMakeLists.txt | 20 | +++ b/visa/CMakeLists.txt |
20 | @@ -123,8 +123,11 @@ endif() | 21 | @@ -123,8 +123,11 @@ endif() |
@@ -31,6 +32,3 @@ index 65dbb4934..8cd607a69 100644 | |||
31 | ADD_FLEX_BISON_DEPENDENCY(CISAScanner CISAParser) | 32 | ADD_FLEX_BISON_DEPENDENCY(CISAScanner CISAParser) |
32 | set(CISAScanner_dependencies) | 33 | set(CISAScanner_dependencies) |
33 | 34 | ||
34 | -- | ||
35 | 2.20.1 | ||
36 | |||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.11702.1.bb b/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.16510.2.bb index 7a994ebe..24eb97bd 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.11702.1.bb +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.16510.2.bb | |||
@@ -6,22 +6,23 @@ hardware architecture." | |||
6 | LICENSE = "MIT & Apache-2.0" | 6 | LICENSE = "MIT & Apache-2.0" |
7 | LIC_FILES_CHKSUM = "file://IGC/BiFModule/Implementation/ExternalLibraries/libclc/LICENSE.TXT;md5=311cfc1a5b54bab8ed34a0b5fba4373e \ | 7 | LIC_FILES_CHKSUM = "file://IGC/BiFModule/Implementation/ExternalLibraries/libclc/LICENSE.TXT;md5=311cfc1a5b54bab8ed34a0b5fba4373e \ |
8 | file://LICENSE.md;md5=488d74376edf2765f6e78d271543dde3 \ | 8 | file://LICENSE.md;md5=488d74376edf2765f6e78d271543dde3 \ |
9 | file://NOTICES.txt;md5=7f4fbc3eb2c34807465e63b1ec3c9d1a" | 9 | file://NOTICES.txt;md5=b81a52411c84df3419f20bad4d755880" |
10 | 10 | ||
11 | SRC_URI = "git://github.com/intel/intel-graphics-compiler.git;protocol=https;name=igc;branch=releases/igc-1.0.11702 \ | 11 | SRC_URI = "git://github.com/intel/intel-graphics-compiler.git;protocol=https;name=igc;branch=releases/igc-1.0.16510 \ |
12 | git://github.com/intel/vc-intrinsics.git;protocol=https;destsuffix=git/vc-intrinsics;name=vc;nobranch=1 \ | 12 | git://github.com/intel/vc-intrinsics.git;protocol=https;destsuffix=git/vc-intrinsics;name=vc;nobranch=1 \ |
13 | git://github.com/KhronosGroup/SPIRV-Tools.git;protocol=https;destsuffix=SPIRV-Tools;name=spirv-tools;branch=sdk-1.3.204 \ | 13 | git://github.com/KhronosGroup/SPIRV-Tools.git;protocol=https;destsuffix=git/SPIRV-Tools;name=spirv-tools;branch=main \ |
14 | git://github.com/KhronosGroup/SPIRV-Headers.git;protocol=https;destsuffix=SPIRV-Headers;name=spirv-headers;branch=master \ | 14 | git://github.com/KhronosGroup/SPIRV-Headers.git;protocol=https;destsuffix=git/SPIRV-Headers;name=spirv-headers;branch=main \ |
15 | file://0003-Improve-Reproducibility-for-src-package.patch \ | 15 | file://0003-Improve-Reproducibility-for-src-package.patch \ |
16 | file://0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch \ | 16 | file://0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch \ |
17 | file://0001-external-SPIRV-Tools-change-path-to-tools-and-header.patch \ | ||
17 | " | 18 | " |
18 | 19 | ||
19 | SRC_URI:append:class-native = " file://0001-fix-tblgen.patch" | 20 | SRC_URI:append:class-native = " file://0001-fix-tblgen.patch" |
20 | 21 | ||
21 | SRCREV_igc = "bf3552db35cabf0ca416f7d216d4697b9bfb03cb" | 22 | SRCREV_igc = "c2495d45f37fadd963ad22eb0cc1a8235a306775" |
22 | SRCREV_vc = "984bb27baacce6ee5c716c2e64845f2a1928025b" | 23 | SRCREV_vc = "f9c34404d0ea9abad83875a10bd48d88cea90ebd" |
23 | SRCREV_spirv-tools = "45dd184c790d6bfc78a5a74a10c37e888b1823fa" | 24 | SRCREV_spirv-tools = "f0cc85efdbbe3a46eae90e0f915dc1509836d0fc" |
24 | SRCREV_spirv-headers = "b42ba6d92faf6b4938e6f22ddd186dbdacc98d78" | 25 | SRCREV_spirv-headers = "1c6bb2743599e6eb6f37b2969acc0aef812e32e3" |
25 | 26 | ||
26 | SRCREV_FORMAT = "igc_vc_spirv-tools_spirv-headers" | 27 | SRCREV_FORMAT = "igc_vc_spirv-tools_spirv-headers" |
27 | 28 | ||
@@ -30,43 +31,45 @@ export B | |||
30 | 31 | ||
31 | S = "${WORKDIR}/git" | 32 | S = "${WORKDIR}/git" |
32 | 33 | ||
33 | inherit cmake pkgconfig | 34 | inherit cmake pkgconfig qemu python3native |
34 | 35 | ||
35 | CXXFLAGS:append = " -Wno-error=nonnull" | 36 | CXXFLAGS:append = " -Wno-error=nonnull" |
36 | 37 | ||
37 | COMPATIBLE_HOST = '(x86_64).*-linux' | 38 | COMPATIBLE_HOST = '(x86_64).*-linux' |
38 | COMPATIBLE_HOST:libc-musl = "null" | 39 | COMPATIBLE_HOST:libc-musl = "null" |
39 | 40 | ||
40 | DEPENDS += " flex-native bison-native clang opencl-clang" | 41 | DEPENDS += " flex-native bison-native clang clang-cross-x86_64 opencl-clang qemu-native python3-mako-native" |
41 | DEPENDS:append:class-target = " clang-cross-x86_64 intel-graphics-compiler-native" | ||
42 | 42 | ||
43 | RDEPENDS:${PN} += "opencl-clang" | 43 | RDEPENDS:${PN} += "opencl-clang" |
44 | 44 | ||
45 | PACKAGECONFIG ??= "vc" | 45 | PACKAGECONFIG ??= "vc" |
46 | PACKAGECONFIG[vc] = "-DIGC_BUILD__VC_ENABLED=ON -DIGC_OPTION__LINK_KHRONOS_SPIRV_TRANSLATOR=ON -DIGC_OPTION__USE_KHRONOS_SPIRV_TRANSLATOR_IN_VC=ON -DIGC_OPTION__SPIRV_TRANSLATOR_MODE=Prebuilds,-DIGC_BUILD__VC_ENABLED=OFF," | 46 | PACKAGECONFIG[vc] = "-DIGC_BUILD__VC_ENABLED=ON -DIGC_OPTION__LINK_KHRONOS_SPIRV_TRANSLATOR=ON -DIGC_OPTION__SPIRV_TRANSLATOR_MODE=Prebuilds,-DIGC_BUILD__VC_ENABLED=OFF," |
47 | 47 | ||
48 | EXTRA_OECMAKE = " \ | 48 | EXTRA_OECMAKE = " \ |
49 | -DIGC_OPTION__LLVM_PREFERRED_VERSION=${LLVMVERSION} \ | 49 | -DIGC_OPTION__LLVM_PREFERRED_VERSION=${LLVMVERSION} \ |
50 | -DPYTHON_EXECUTABLE=${HOSTTOOLS_DIR}/python3 \ | ||
51 | -DVC_INTRINSICS_SRC="${S}/vc-intrinsics" \ | 50 | -DVC_INTRINSICS_SRC="${S}/vc-intrinsics" \ |
52 | -DIGC_OPTION__LLVM_MODE=Prebuilds \ | 51 | -DIGC_OPTION__LLVM_MODE=Prebuilds \ |
53 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | 52 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ |
54 | -DLLVM_LINK_EXE=${STAGING_BINDIR_NATIVE}/llvm-link \ | 53 | -DLLVM_LINK_EXE=${STAGING_BINDIR_NATIVE}/llvm-link \ |
54 | -DCLANG_EXE=${STAGING_BINDIR_NATIVE}/clang \ | ||
55 | -DCMAKE_CROSSCOMPILING_EMULATOR=${WORKDIR}/qemuwrapper \ | ||
55 | " | 56 | " |
56 | 57 | ||
57 | do_install:append:class-native () { | 58 | do_configure:prepend:class-target () { |
58 | install -d ${D}${bindir} | 59 | # Write out a qemu wrapper that will be used by cmake. |
59 | install ${B}/IGC/Release/elf_packager ${D}${bindir}/ | 60 | qemu_binary="${@qemu_wrapper_cmdline(d, d.getVar('STAGING_DIR_HOST'), [d.expand('${STAGING_DIR_HOST}${libdir}'),d.expand('${STAGING_DIR_HOST}${base_libdir}')])}" |
60 | if ${@bb.utils.contains('PACKAGECONFIG', 'vc', 'true', 'false', d)}; then | 61 | cat > ${WORKDIR}/qemuwrapper << EOF |
61 | install ${B}/IGC/Release/CMCLTranslatorTool ${D}${bindir}/ | 62 | #!/bin/sh |
62 | install ${B}/IGC/Release/vcb ${D}${bindir}/ | 63 | $qemu_binary "\$@" |
63 | fi | 64 | EOF |
65 | chmod +x ${WORKDIR}/qemuwrapper | ||
64 | } | 66 | } |
65 | 67 | ||
66 | BBCLASSEXTEND = "native nativesdk" | ||
67 | |||
68 | UPSTREAM_CHECK_GITTAGREGEX = "^igc-(?P<pver>(?!19\..*)\d+(\.\d+)+)$" | 68 | UPSTREAM_CHECK_GITTAGREGEX = "^igc-(?P<pver>(?!19\..*)\d+(\.\d+)+)$" |
69 | 69 | ||
70 | FILES:${PN} += " \ | 70 | FILES:${PN} += " \ |
71 | ${libdir}/igc/NOTICES.txt \ | 71 | ${libdir}/igc/NOTICES.txt \ |
72 | " | 72 | " |
73 | |||
74 | # libigc.so contains buildpaths | ||
75 | INSANE_SKIP:${PN} += "buildpaths" | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0001-cl_headers-CMakeLists.txt-use-clang-from-native-sysr.patch b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0001-cl_headers-CMakeLists.txt-use-clang-from-native-sysr.patch new file mode 100644 index 00000000..031a77c7 --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0001-cl_headers-CMakeLists.txt-use-clang-from-native-sysr.patch | |||
@@ -0,0 +1,49 @@ | |||
1 | From 5aea653e611b59c70e529a1bd71885a509831557 Mon Sep 17 00:00:00 2001 | ||
2 | From: Anuj Mittal <anuj.mittal@intel.com> | ||
3 | Date: Tue, 1 Aug 2023 11:15:31 +0800 | ||
4 | Subject: [PATCH] cl_headers/CMakeLists.txt: use clang from native sysroot | ||
5 | |||
6 | Allow clang to be found in target sysroot for target builds and dont try | ||
7 | to compile cross binaries, we do that ourselves. | ||
8 | |||
9 | Upstream-Status: Inappropriate [oe-specific] | ||
10 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
11 | --- | ||
12 | CMakeLists.txt | 8 ++++---- | ||
13 | cl_headers/CMakeLists.txt | 2 +- | ||
14 | 2 files changed, 5 insertions(+), 5 deletions(-) | ||
15 | |||
16 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
17 | index 5864009..60ba39e 100644 | ||
18 | --- a/CMakeLists.txt | ||
19 | +++ b/CMakeLists.txt | ||
20 | @@ -35,10 +35,10 @@ set(CMAKE_MODULE_PATH | ||
21 | |||
22 | include(CMakeFunctions) | ||
23 | |||
24 | -if(CMAKE_CROSSCOMPILING AND OPENCL_CLANG_BUILD_EXTERNAL) | ||
25 | - include(CrossCompile) | ||
26 | - llvm_create_cross_target(${PROJECT_NAME} NATIVE "" Release) | ||
27 | -endif() | ||
28 | +#if(CMAKE_CROSSCOMPILING AND OPENCL_CLANG_BUILD_EXTERNAL) | ||
29 | +# include(CrossCompile) | ||
30 | +# llvm_create_cross_target(${PROJECT_NAME} NATIVE "" Release) | ||
31 | +#endif() | ||
32 | |||
33 | if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR) | ||
34 | set(USE_PREBUILT_LLVM ON) | ||
35 | diff --git a/cl_headers/CMakeLists.txt b/cl_headers/CMakeLists.txt | ||
36 | index 16cabb7..4423536 100644 | ||
37 | --- a/cl_headers/CMakeLists.txt | ||
38 | +++ b/cl_headers/CMakeLists.txt | ||
39 | @@ -1,6 +1,6 @@ | ||
40 | set(CL_HEADERS_LIB cl_headers) | ||
41 | if(USE_PREBUILT_LLVM) | ||
42 | - find_program(CLANG_COMMAND clang PATHS ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH) | ||
43 | + find_program(CLANG_COMMAND clang PATHS ${LLVM_TOOLS_BINARY_DIR}) | ||
44 | else() | ||
45 | set(CLANG_COMMAND $<TARGET_FILE:clang>) | ||
46 | endif() | ||
47 | -- | ||
48 | 2.37.3 | ||
49 | |||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0001-don-t-redefine-LLVM_TABLEGEN_EXE.patch b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0001-don-t-redefine-LLVM_TABLEGEN_EXE.patch deleted file mode 100644 index 8df7e3ab..00000000 --- a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0001-don-t-redefine-LLVM_TABLEGEN_EXE.patch +++ /dev/null | |||
@@ -1,32 +0,0 @@ | |||
1 | From f3ef79a6301bab0b3a447f07ceb94c39a95009df Mon Sep 17 00:00:00 2001 | ||
2 | From: Anuj Mittal <anuj.mittal@intel.com> | ||
3 | Date: Thu, 2 Apr 2020 08:59:20 +0800 | ||
4 | Subject: [PATCH] don't redefine LLVM_TABLEGEN_EXE | ||
5 | |||
6 | Use the value that has been passed by the user. | ||
7 | |||
8 | Upstream-Status: Submitted | ||
9 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
10 | --- | ||
11 | CMakeLists.txt | 5 ++++- | ||
12 | 1 file changed, 4 insertions(+), 1 deletion(-) | ||
13 | |||
14 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
15 | index 6893e97..941b0ae 100644 | ||
16 | --- a/CMakeLists.txt | ||
17 | +++ b/CMakeLists.txt | ||
18 | @@ -137,7 +137,10 @@ endif(NOT USE_PREBUILT_LLVM) | ||
19 | set (COMPILE_OPTIONS_TD opencl_clang_options.td) | ||
20 | set (COMPILE_OPTIONS_INC opencl_clang_options.inc) | ||
21 | |||
22 | -set(LLVM_TABLEGEN_EXE "llvm-tblgen") | ||
23 | +if(NOT DEFINED LLVM_TABLEGEN_EXE) | ||
24 | + set(LLVM_TABLEGEN_EXE "llvm-tblgen") | ||
25 | +endif() | ||
26 | + | ||
27 | set(LLVM_TARGET_DEFINITIONS ${COMPILE_OPTIONS_TD}) | ||
28 | if(USE_PREBUILT_LLVM) | ||
29 | set(TABLEGEN_ADDITIONAL -I ${LLVM_INCLUDE_DIRS}) | ||
30 | -- | ||
31 | 2.25.1 | ||
32 | |||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0002-Request-native-clang-only-when-cross-compiling-464.patch b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0002-Request-native-clang-only-when-cross-compiling-464.patch new file mode 100644 index 00000000..2f1814f8 --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/files/0002-Request-native-clang-only-when-cross-compiling-464.patch | |||
@@ -0,0 +1,60 @@ | |||
1 | From 43c806ef321b1f677a49d28c89fb7ffecf539c2d Mon Sep 17 00:00:00 2001 | ||
2 | From: Tim Creech <timothy.m.creech@intel.com> | ||
3 | Date: Wed, 28 Jun 2023 03:45:51 -0400 | ||
4 | Subject: [PATCH 2/2] Request native clang only when cross-compiling (#464) | ||
5 | |||
6 | * Request native clang only when cross-compiling | ||
7 | |||
8 | LLVM_USE_HOST_TOOLS may be set if LLVM is configured with | ||
9 | LLVM_OPTIMIZED_TABLEGEN, which does not necessarily indicate | ||
10 | cross-compilation or that clang will only execute on the target. | ||
11 | |||
12 | By checking that CMAKE_CROSSCOMPILING is set, we ensure that we only | ||
13 | build/use clang again if necessary for host execution. | ||
14 | |||
15 | * fixup: CMAKE_CROSSCOMPILING implies LLVM_USE_HOST_TOOLS | ||
16 | |||
17 | Co-authored-by: Wenju He <wenju.he@intel.com> | ||
18 | |||
19 | * fixup: also use CMAKE_CROSSCOMPILING in top-level CMakeLists.txt | ||
20 | |||
21 | --------- | ||
22 | |||
23 | Co-authored-by: Wenju He <wenju.he@intel.com> | ||
24 | |||
25 | Upstream-Status: Backport [https://github.com/intel/opencl-clang/commit/53843eee13cfb2357919ee02714a43bef1af0f86] | ||
26 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
27 | --- | ||
28 | CMakeLists.txt | 2 +- | ||
29 | cl_headers/CMakeLists.txt | 2 +- | ||
30 | 2 files changed, 2 insertions(+), 2 deletions(-) | ||
31 | |||
32 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
33 | index e772de9..5864009 100644 | ||
34 | --- a/CMakeLists.txt | ||
35 | +++ b/CMakeLists.txt | ||
36 | @@ -35,7 +35,7 @@ set(CMAKE_MODULE_PATH | ||
37 | |||
38 | include(CMakeFunctions) | ||
39 | |||
40 | -if(LLVM_USE_HOST_TOOLS AND OPENCL_CLANG_BUILD_EXTERNAL) | ||
41 | +if(CMAKE_CROSSCOMPILING AND OPENCL_CLANG_BUILD_EXTERNAL) | ||
42 | include(CrossCompile) | ||
43 | llvm_create_cross_target(${PROJECT_NAME} NATIVE "" Release) | ||
44 | endif() | ||
45 | diff --git a/cl_headers/CMakeLists.txt b/cl_headers/CMakeLists.txt | ||
46 | index 18296c2..16cabb7 100644 | ||
47 | --- a/cl_headers/CMakeLists.txt | ||
48 | +++ b/cl_headers/CMakeLists.txt | ||
49 | @@ -4,7 +4,7 @@ if(USE_PREBUILT_LLVM) | ||
50 | else() | ||
51 | set(CLANG_COMMAND $<TARGET_FILE:clang>) | ||
52 | endif() | ||
53 | -if(LLVM_USE_HOST_TOOLS AND NOT OPENCL_CLANG_BUILD_EXTERNAL) | ||
54 | +if(CMAKE_CROSSCOMPILING AND NOT OPENCL_CLANG_BUILD_EXTERNAL) | ||
55 | build_native_tool(clang CLANG_COMMAND) | ||
56 | endif() | ||
57 | |||
58 | -- | ||
59 | 2.37.3 | ||
60 | |||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang.inc b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang.inc index 1d9b4d51..31a3fb21 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang.inc +++ b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang.inc | |||
@@ -6,6 +6,8 @@ LICENSE = "NCSA" | |||
6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=e8a15bf1416762a09ece07e44c79118c" | 6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=e8a15bf1416762a09ece07e44c79118c" |
7 | 7 | ||
8 | SRC_URI = "git://github.com/intel/opencl-clang.git;branch=${BRANCH};protocol=https \ | 8 | SRC_URI = "git://github.com/intel/opencl-clang.git;branch=${BRANCH};protocol=https \ |
9 | file://0002-Request-native-clang-only-when-cross-compiling-464.patch \ | ||
10 | file://0001-cl_headers-CMakeLists.txt-use-clang-from-native-sysr.patch \ | ||
9 | " | 11 | " |
10 | S = "${WORKDIR}/git" | 12 | S = "${WORKDIR}/git" |
11 | 13 | ||
@@ -16,9 +18,17 @@ DEPENDS:append:class-target = " opencl-clang-native" | |||
16 | COMPATIBLE_HOST = '(x86_64).*-linux' | 18 | COMPATIBLE_HOST = '(x86_64).*-linux' |
17 | COMPATIBLE_HOST:libc-musl = "null" | 19 | COMPATIBLE_HOST:libc-musl = "null" |
18 | 20 | ||
21 | DEPENDS += " spirv-llvm-translator" | ||
22 | |||
23 | EXTRA_OECMAKE += "\ | ||
24 | -DLLVM_TABLEGEN_EXE=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | ||
25 | -DCMAKE_SKIP_RPATH=TRUE \ | ||
26 | -DPREFERRED_LLVM_VERSION=${LLVMVERSION} \ | ||
27 | " | ||
28 | |||
19 | do_install:append:class-native() { | 29 | do_install:append:class-native() { |
20 | install -d ${D}${bindir} | 30 | install -d ${D}${bindir} |
21 | install -m 0755 ${B}/linux_linker/linux_resource_linker ${D}${bindir}/ | 31 | install -m 0755 ${B}/bin/linux_resource_linker ${D}${bindir}/ |
22 | } | 32 | } |
23 | 33 | ||
24 | BBCLASSEXTEND = "native nativesdk" | 34 | BBCLASSEXTEND = "native nativesdk" |
diff --git a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang_14.0.0.bb b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang_14.0.0.bb deleted file mode 100644 index 367ca7e9..00000000 --- a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang_14.0.0.bb +++ /dev/null | |||
@@ -1,15 +0,0 @@ | |||
1 | require opencl-clang.inc | ||
2 | |||
3 | SRC_URI:append = " file://0001-don-t-redefine-LLVM_TABLEGEN_EXE.patch \ | ||
4 | " | ||
5 | SRCREV = "06c7c0d7f5cbd13810d79489a533fa6c5b6c7d9f" | ||
6 | |||
7 | BRANCH = "ocl-open-140" | ||
8 | |||
9 | DEPENDS += " spirv-llvm-translator" | ||
10 | |||
11 | EXTRA_OECMAKE += "\ | ||
12 | -DLLVM_TABLEGEN_EXE=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | ||
13 | -DCMAKE_SKIP_RPATH=TRUE \ | ||
14 | -DPREFERRED_LLVM_VERSION=${LLVMVERSION} \ | ||
15 | " | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang_15.0.0.bb b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang_15.0.0.bb new file mode 100644 index 00000000..e946c31c --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/opencl-clang/opencl-clang_15.0.0.bb | |||
@@ -0,0 +1,5 @@ | |||
1 | require opencl-clang.inc | ||
2 | |||
3 | SRCREV = "60fd799cc58755c16d951f9ebfde6d0f9b8554dd" | ||
4 | |||
5 | BRANCH = "ocl-open-150" | ||
diff --git a/dynamic-layers/clang-layer/recipes-opencl/vc-intrinsics/vc-intrinsics_0.1.0.bb b/dynamic-layers/clang-layer/recipes-opencl/vc-intrinsics/vc-intrinsics_0.1.0.bb deleted file mode 100644 index dfdb4450..00000000 --- a/dynamic-layers/clang-layer/recipes-opencl/vc-intrinsics/vc-intrinsics_0.1.0.bb +++ /dev/null | |||
@@ -1,27 +0,0 @@ | |||
1 | SUMMARY = "VC Intrinsics" | ||
2 | DESCRIPTION = "VC Intrinsics project contains a set of new intrinsics on \ | ||
3 | top of core LLVM IR instructions that represent SIMD semantics of a program \ | ||
4 | targeting GPU" | ||
5 | |||
6 | LICENSE = "MIT" | ||
7 | LIC_FILES_CHKSUM = "file://Readme.md;beginline=1;endline=7;md5=3b2db19c3b0877bb312b7adbcb815adc" | ||
8 | |||
9 | SRC_URI = "git://github.com/intel/vc-intrinsics.git;protocol=https;branch=master \ | ||
10 | " | ||
11 | SRCREV = "99ac111c2604a47d865bd4d7996be8cfaf2af146" | ||
12 | |||
13 | S = "${WORKDIR}/git" | ||
14 | |||
15 | PE = "1" | ||
16 | PV .= "+git${SRCPV}" | ||
17 | |||
18 | inherit cmake | ||
19 | |||
20 | COMPATIBLE_HOST = '(x86_64).*-linux' | ||
21 | COMPATIBLE_HOST:libc-musl = "null" | ||
22 | |||
23 | DEPENDS += " clang" | ||
24 | |||
25 | EXTRA_OECMAKE = "-DLLVM_DIR=${STAGING_LIBDIR}" | ||
26 | |||
27 | BBCLASSEXTEND = "native nativesdk" | ||