From 5f2a109a15d2831bfd293ecd834dc42c4a499ad8 Mon Sep 17 00:00:00 2001 From: Naveen Saini Date: Wed, 1 Mar 2023 13:06:53 +0800 Subject: ispc: upgrade 1.18.0 -> 1.19.0 Dropped patches which are already available. Signed-off-by: Naveen Saini Signed-off-by: Anuj Mittal --- ...txt-link-with-libclang-cpp-library-instea.patch | 16 +++--- .../6a1b2ffae0cc12467838bc671e3b089924de90a6.patch | 33 ------------ .../ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda.patch | 63 ---------------------- .../clang-layer/recipes-core/ispc/ispc_1.18.0.bb | 62 --------------------- .../clang-layer/recipes-core/ispc/ispc_1.19.0.bb | 60 +++++++++++++++++++++ 5 files changed, 68 insertions(+), 166 deletions(-) delete mode 100644 dynamic-layers/clang-layer/recipes-core/ispc/ispc/6a1b2ffae0cc12467838bc671e3b089924de90a6.patch delete mode 100644 dynamic-layers/clang-layer/recipes-core/ispc/ispc/ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda.patch delete mode 100644 dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.18.0.bb create mode 100644 dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.19.0.bb (limited to 'dynamic-layers/clang-layer/recipes-core') 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 index 4e25420c..cacbbbc1 100644 --- 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 @@ -1,6 +1,6 @@ -From b9bc0df996d1e65fd70d5eb2d40866693f23bb67 Mon Sep 17 00:00:00 2001 +From 0445d97c8ad66c9cbb2c6f88c52aadc0b01a1f15 Mon Sep 17 00:00:00 2001 From: Naveen Saini -Date: Thu, 24 Jun 2021 17:53:27 +0800 +Date: Tue, 11 Oct 2022 16:43:22 +0800 Subject: [PATCH] CMakeLists.txt: link with libclang-cpp library instead Upstream-Status: Inappropriate @@ -11,18 +11,18 @@ Signed-off-by: Naveen Saini 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt -index ef88317e..7507d6a5 100644 +index f6199704..f979f1c1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -281,7 +281,7 @@ if (WASM_ENABLED) +@@ -288,7 +288,7 @@ if (WASM_ENABLED) list(APPEND ISPC_TARGETS wasm-i32x4) endif() -set(CLANG_LIBRARY_LIST clangFrontend clangDriver clangSerialization clangParse clangSema clangAnalysis clangAST clangBasic clangEdit clangLex) +set(CLANG_LIBRARY_LIST clang-cpp) - set(LLVM_COMPONENTS engine ipo bitreader bitwriter instrumentation linker option frontendopenmp) - - if (X86_ENABLED) + if (${LLVM_VERSION_NUMBER} VERSION_GREATER_EQUAL "15.0.0") + list(APPEND CLANG_LIBRARY_LIST clangSupport) + endif() -- -2.17.1 +2.37.3 diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/6a1b2ffae0cc12467838bc671e3b089924de90a6.patch b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/6a1b2ffae0cc12467838bc671e3b089924de90a6.patch deleted file mode 100644 index 6aac0c79..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/6a1b2ffae0cc12467838bc671e3b089924de90a6.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 6a1b2ffae0cc12467838bc671e3b089924de90a6 Mon Sep 17 00:00:00 2001 -From: Dmitry Babokin -Date: Thu, 5 May 2022 16:34:34 -0700 -Subject: [PATCH] Bump ISPC version v1.19.0dev - -Upstream-Status: Backport - -Include only the LLVM specific bits and not the ispc version bump. - -Signed-off-by: Anuj Mittal ---- -diff --git a/src/ispc_version.h b/src/ispc_version.h -index 0e28dfcfa..2b9d9b0cc 100644 ---- a/src/ispc_version.h -+++ b/src/ispc_version.h -@@ -51,7 +51,7 @@ - #define ISPC_LLVM_15_0 150000 - - #define OLDEST_SUPPORTED_LLVM ISPC_LLVM_10_0 --#define LATEST_SUPPORTED_LLVM ISPC_LLVM_14_0 -+#define LATEST_SUPPORTED_LLVM ISPC_LLVM_15_0 - - #ifdef __ispc__xstr - #undef __ispc__xstr -@@ -63,7 +63,7 @@ - __ispc__xstr(LLVM_VERSION_MAJOR) "." __ispc__xstr(LLVM_VERSION_MINOR) "." __ispc__xstr(LLVM_VERSION_PATCH) - - #if ISPC_LLVM_VERSION < OLDEST_SUPPORTED_LLVM || ISPC_LLVM_VERSION > LATEST_SUPPORTED_LLVM --#error "Only LLVM 11.0 - 14.0 are supported" -+#error "Only LLVM 11.0 - 14.0 and 15.0 development branch are supported" - #endif - - #define ISPC_VERSION_STRING \ diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda.patch b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda.patch deleted file mode 100644 index a5ab8c19..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda.patch +++ /dev/null @@ -1,63 +0,0 @@ -From ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda Mon Sep 17 00:00:00 2001 -From: Arina Neshlyaeva -Date: Tue, 23 Aug 2022 15:21:50 -0700 -Subject: [PATCH] Adjust opt passes for LLVM 15 - -Upstream-Status: Backport -Signed-off-by: Anuj Mittal ---- - src/opt.cpp | 17 +++++++++++++++++ - 1 file changed, 17 insertions(+) - -diff --git a/src/opt.cpp b/src/opt.cpp -index 910821e26..86219f384 100644 ---- a/src/opt.cpp -+++ b/src/opt.cpp -@@ -84,6 +84,9 @@ - #include - #include - #include -+#if ISPC_LLVM_VERSION >= ISPC_LLVM_15_0 -+#include -+#endif - #include - #include - -@@ -647,7 +650,11 @@ void ispc::Optimize(llvm::Module *module, int optLevel) { - optPM.add(llvm::createCFGSimplificationPass()); - #endif - -+#if ISPC_LLVM_VERSION < ISPC_LLVM_15_0 -+ // Starting LLVM 15.0 this pass is supported with new pass manager only (217e857) -+ // TODO: switch ISPC to new pass manager: https://github.com/ispc/ispc/issues/2359 - optPM.add(llvm::createArgumentPromotionPass()); -+#endif - - optPM.add(llvm::createAggressiveDCEPass()); - optPM.add(llvm::createInstructionCombiningPass(), 241); -@@ -722,7 +729,11 @@ void ispc::Optimize(llvm::Module *module, int optLevel) { - optPM.add(CreateInstructionSimplifyPass()); - - optPM.add(llvm::createFunctionInliningPass()); -+#if ISPC_LLVM_VERSION < ISPC_LLVM_15_0 -+ // Starting LLVM 15.0 this pass is supported with new pass manager only (217e857) -+ // TODO: switch ISPC to new pass manager: https://github.com/ispc/ispc/issues/2359 - optPM.add(llvm::createArgumentPromotionPass()); -+#endif - - optPM.add(llvm::createSROAPass()); - -@@ -736,7 +747,13 @@ void ispc::Optimize(llvm::Module *module, int optLevel) { - optPM.add(llvm::createReassociatePass()); - optPM.add(llvm::createLoopRotatePass()); - optPM.add(llvm::createLICMPass()); -+ // Loop unswitch pass was removed in LLVM 15.0 (fb4113). -+ // Recommended replacement: createSimpleLoopUnswitchLegacyPass -+#if ISPC_LLVM_VERSION < ISPC_LLVM_15_0 - optPM.add(llvm::createLoopUnswitchPass(false)); -+#else -+ optPM.add(llvm::createSimpleLoopUnswitchLegacyPass(false)); -+#endif - optPM.add(llvm::createInstructionCombiningPass()); - optPM.add(CreateInstructionSimplifyPass()); - optPM.add(llvm::createIndVarSimplifyPass()); 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 b7083f82..00000000 --- a/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.18.0.bb +++ /dev/null @@ -1,62 +0,0 @@ -SUMMARY = "Intel(R) Implicit SPMD Program Compiler" -DESCRIPTION = "ispc is a compiler for a variant of the C programming language, \ -with extensions for single program, multiple data programming." -HOMEPAGE = "https://github.com/ispc/ispc" - -LICENSE = "BSD-3-Clause & Apache-2.0-with-LLVM-exception" -LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=da5ecffdd210b3cf776b32b41c182e87 \ - file://third-party-programs.txt;md5=3cd6f8a7c3bd9d2bb898fcb27c75221a" - -inherit cmake python3native ptest - -S = "${WORKDIR}/git" - -SRC_URI = "git://github.com/ispc/ispc.git;protocol=https;branch=main \ - file://0001-CMakeLists.txt-link-with-libclang-cpp-library-instea.patch \ - file://0002-cmake-don-t-build-for-32-bit-targets.patch \ - file://0001-Fix-QA-Issues.patch \ - file://6a1b2ffae0cc12467838bc671e3b089924de90a6.patch \ - file://ec35a6f8e60ba77e59a6f2bfec27011e0ab34dda.patch \ - file://0001-Add-print-function-to-print-test-run-status-in-ptest.patch \ - file://run-ptest \ - " - -SRCREV = "f7ec3aa173c816377c215d83196b5c7c3a88db1c" - -COMPATIBLE_HOST = '(x86_64).*-linux' - -DEPENDS += " clang-native bison-native flex-native" -RDEPENDS:${PN} += " clang-libllvm clang clang-libclang-cpp" -RDEPENDS:${PN}-ptest += " python3-multiprocessing" - -YFLAGS='-d -t -v -y --file-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}' - -do_configure:prepend() { - sed -i -e 's#\${BISON_EXECUTABLE}.*#\${BISON_EXECUTABLE} ${YFLAGS} #g' ${S}/CMakeLists.txt - sed -i -e 's#\${FLEX_EXECUTABLE}.*#\${FLEX_EXECUTABLE} \-L #g' ${S}/CMakeLists.txt -} - -do_install_ptest() { - cp -rf ${S}/run_tests.py ${D}${PTEST_PATH} - cp -rf ${S}/common.py ${D}${PTEST_PATH} - cp -rf ${S}/tests ${D}${PTEST_PATH} - cp -rf ${S}/test_static.isph ${D}${PTEST_PATH} - cp -rf ${S}/fail_db.txt ${D}${PTEST_PATH} - cp -rf ${S}/test_static.cpp ${D}${PTEST_PATH} -} - -EXTRA_OECMAKE += " \ - -DISPC_INCLUDE_TESTS=OFF \ - -DISPC_INCLUDE_EXAMPLES=OFF \ - -DISPC_NO_DUMPS=ON \ - -DARM_ENABLED=OFF \ - -DISPC_CROSS=ON \ - -DISPC_ANDROID_TARGET=OFF \ - -DISPC_FREEBSD_TARGET=OFF \ - -DISPC_WINDOWS_TARGET=OFF \ - -DISPC_IOS_TARGET=OFF \ - -DISPC_PS4_TARGET=OFF \ - -DSYSROOT_DIR=${STAGING_DIR_NATIVE} \ - " - -BBCLASSEXTEND = "native nativesdk" diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.19.0.bb b/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.19.0.bb new file mode 100644 index 00000000..db4f31b4 --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-core/ispc/ispc_1.19.0.bb @@ -0,0 +1,60 @@ +SUMMARY = "Intel(R) Implicit SPMD Program Compiler" +DESCRIPTION = "ispc is a compiler for a variant of the C programming language, \ +with extensions for single program, multiple data programming." +HOMEPAGE = "https://github.com/ispc/ispc" + +LICENSE = "BSD-3-Clause & Apache-2.0-with-LLVM-exception" +LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=da5ecffdd210b3cf776b32b41c182e87 \ + file://third-party-programs.txt;md5=3cd6f8a7c3bd9d2bb898fcb27c75221a" + +inherit cmake python3native ptest + +S = "${WORKDIR}/git" + +SRC_URI = "git://github.com/ispc/ispc.git;protocol=https;branch=main \ + file://0001-CMakeLists.txt-link-with-libclang-cpp-library-instea.patch \ + file://0002-cmake-don-t-build-for-32-bit-targets.patch \ + file://0001-Fix-QA-Issues.patch \ + file://0001-Add-print-function-to-print-test-run-status-in-ptest.patch \ + file://run-ptest \ + " + +SRCREV = "ee43967286215a0511c2bc090e604848b4a32bed" + +COMPATIBLE_HOST = '(x86_64).*-linux' + +DEPENDS += " clang-native bison-native flex-native" +RDEPENDS:${PN} += " clang-libllvm clang clang-libclang-cpp" +RDEPENDS:${PN}-ptest += " python3-multiprocessing" + +YFLAGS='-d -t -v -y --file-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}' + +do_configure:prepend() { + sed -i -e 's#\${BISON_EXECUTABLE}.*#\${BISON_EXECUTABLE} ${YFLAGS} #g' ${S}/CMakeLists.txt + sed -i -e 's#\${FLEX_EXECUTABLE}.*#\${FLEX_EXECUTABLE} \-L #g' ${S}/CMakeLists.txt +} + +do_install_ptest() { + cp -rf ${S}/run_tests.py ${D}${PTEST_PATH} + cp -rf ${S}/common.py ${D}${PTEST_PATH} + cp -rf ${S}/tests ${D}${PTEST_PATH} + cp -rf ${S}/test_static.isph ${D}${PTEST_PATH} + cp -rf ${S}/fail_db.txt ${D}${PTEST_PATH} + cp -rf ${S}/test_static.cpp ${D}${PTEST_PATH} +} + +EXTRA_OECMAKE += " \ + -DISPC_INCLUDE_TESTS=OFF \ + -DISPC_INCLUDE_EXAMPLES=OFF \ + -DISPC_NO_DUMPS=ON \ + -DARM_ENABLED=OFF \ + -DISPC_CROSS=ON \ + -DISPC_ANDROID_TARGET=OFF \ + -DISPC_FREEBSD_TARGET=OFF \ + -DISPC_WINDOWS_TARGET=OFF \ + -DISPC_IOS_TARGET=OFF \ + -DISPC_PS4_TARGET=OFF \ + -DSYSROOT_DIR=${STAGING_DIR_NATIVE} \ + " + +BBCLASSEXTEND = "native nativesdk" -- cgit v1.2.3-54-g00ecf