summaryrefslogtreecommitdiffstats
path: root/dynamic-layers
diff options
context:
space:
mode:
authorAnuj Mittal <anuj.mittal@intel.com>2021-10-05 00:34:20 +0800
committerAnuj Mittal <anuj.mittal@intel.com>2021-10-07 22:51:41 +0800
commitcd0ba51efdd23b817b903f3841d3dbabb9d23c72 (patch)
treea29fd14ed1c52cdf87037e7bf813639ec33cf3af /dynamic-layers
parent2d445772a75958768cd9e4e5b15831be9ef34022 (diff)
downloadmeta-intel-cd0ba51efdd23b817b903f3841d3dbabb9d23c72.tar.gz
intel-compute-runtime: upgrade 21.33.20678 -> 21.37.20939
Disable built-ins compilation when building for native. Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Diffstat (limited to 'dynamic-layers')
-rw-r--r--dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/0001-Revert-Change-builtin-kernels-compilation-process.patch117
-rw-r--r--dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/allow-to-find-cpp-generation-tool.patch44
-rw-r--r--dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_21.37.20939.bb (renamed from dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_21.33.20678.bb)7
3 files changed, 27 insertions, 141 deletions
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/0001-Revert-Change-builtin-kernels-compilation-process.patch b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/0001-Revert-Change-builtin-kernels-compilation-process.patch
deleted file mode 100644
index ec3d3183..00000000
--- a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime/0001-Revert-Change-builtin-kernels-compilation-process.patch
+++ /dev/null
@@ -1,117 +0,0 @@
1From f031f4d7ab4021c2b60391b3a957e75fac14c2e3 Mon Sep 17 00:00:00 2001
2From: Dongwon Kim <dongwon.kim@intel.com>
3Date: Sat, 21 Aug 2021 11:27:59 -0700
4Subject: [PATCH] Revert "Change builtin kernels compilation process"
5
6This reverts commit ab52c702337358af57140e760d618549372e1cdd.
7Upstream-Status: Pending
8Signed-off-by: Dongwon Kim <dongwon.kim@intel.com>
9---
10 .../offline_compiler_tests.cpp | 23 ----------------
11 .../source/offline_compiler.cpp | 2 +-
12 .../source/built_ins/kernels/CMakeLists.txt | 26 +++++++------------
13 3 files changed, 10 insertions(+), 41 deletions(-)
14
15diff --git a/opencl/test/unit_test/offline_compiler/offline_compiler_tests.cpp b/opencl/test/unit_test/offline_compiler/offline_compiler_tests.cpp
16index 1427cd5cc..8b913d740 100644
17--- a/opencl/test/unit_test/offline_compiler/offline_compiler_tests.cpp
18+++ b/opencl/test/unit_test/offline_compiler/offline_compiler_tests.cpp
19@@ -1651,27 +1651,4 @@ TEST(OclocCompile, givenPackedDeviceBinaryFormatWhenGeneratingElfBinaryThenItIsR
20 ASSERT_EQ(true, ocloc.generateElfBinary());
21 EXPECT_EQ(0, memcmp(zebin.storage.data(), ocloc.elfBinary.data(), zebin.storage.size()));
22 }
23-
24-TEST(OclocCompile, givenSpirvInputThenDontGenerateSpirvFile) {
25- MockOfflineCompiler ocloc;
26-
27- std::vector<std::string> argv = {
28- "ocloc",
29- "-q",
30- "-file",
31- "test_files/binary_with_zeroes",
32- "-out_dir",
33- "offline_compiler_test",
34- "-device",
35- gEnvironment->devicePrefix.c_str(),
36- "-spirv_input"};
37-
38- int retVal = ocloc.initialize(argv.size(), argv);
39- ASSERT_EQ(0, retVal);
40- retVal = ocloc.build();
41- EXPECT_EQ(0, retVal);
42- EXPECT_TRUE(compilerOutputExists("offline_compiler_test/binary_with_zeroes", "gen"));
43- EXPECT_TRUE(compilerOutputExists("offline_compiler_test/binary_with_zeroes", "bin"));
44- EXPECT_FALSE(compilerOutputExists("offline_compiler_test/binary_with_zeroes", "spv"));
45-}
46 } // namespace NEO
47diff --git a/shared/offline_compiler/source/offline_compiler.cpp b/shared/offline_compiler/source/offline_compiler.cpp
48index 0ffc3bbca..aa02e0550 100644
49--- a/shared/offline_compiler/source/offline_compiler.cpp
50+++ b/shared/offline_compiler/source/offline_compiler.cpp
51@@ -1050,7 +1050,7 @@ void OfflineCompiler::writeOutAllFiles() {
52 }
53 }
54
55- if (irBinary && !inputFileSpirV) {
56+ if (irBinary) {
57 std::string irOutputFileName = generateFilePathForIr(fileBase) + generateOptsSuffix();
58
59 argHelper->saveOutput(irOutputFileName, irBinary, irBinarySize);
60diff --git a/shared/source/built_ins/kernels/CMakeLists.txt b/shared/source/built_ins/kernels/CMakeLists.txt
61index 59723fdb2..12dc4aa7a 100644
62--- a/shared/source/built_ins/kernels/CMakeLists.txt
63+++ b/shared/source/built_ins/kernels/CMakeLists.txt
64@@ -58,8 +58,11 @@ function(compile_builtin gen_type platform_type builtin bits builtin_options mod
65 # get name of the file w/o extension
66 get_filename_component(BASENAME ${builtin} NAME_WE)
67
68- set(OUTPUT_FILE_SPV
69- ${OUTPUTDIR}/${mode}_${BASENAME}_${family_name_with_type}.spv
70+ set(OUTPUTPATH_BASE "${OUTPUTDIR}/${mode}_${BASENAME}_${family_name_with_type}")
71+ set(OUTPUT_FILES
72+ ${OUTPUTPATH_BASE}.spv
73+ ${OUTPUTPATH_BASE}.bin
74+ ${OUTPUTPATH_BASE}.gen
75 )
76
77 if(NOT DEFINED cloc_cmd_prefix)
78@@ -76,8 +79,8 @@ function(compile_builtin gen_type platform_type builtin bits builtin_options mod
79 list(APPEND __cloc__options__ "-cl-kernel-arg-info")
80 set(INTERNAL_OPTIONS "${${mode}_OPTIONS}")
81 add_custom_command(
82- OUTPUT ${OUTPUT_FILE_SPV}
83- COMMAND ${cloc_cmd_prefix} -q -file ${FILENAME} -spv_only -device ${DEFAULT_SUPPORTED_${gen_type}_${platform_type}_PLATFORM} ${builtin_options} -${bits} -output ${mode}_${BASENAME} -out_dir ${OUTPUTDIR} ${INTERNAL_OPTIONS} -options "$<JOIN:${__cloc__options__}, >"
84+ OUTPUT ${OUTPUT_FILES}
85+ COMMAND ${cloc_cmd_prefix} -q -file ${FILENAME} -device ${DEFAULT_SUPPORTED_${gen_type}_${platform_type}_PLATFORM} ${builtin_options} -${bits} -output ${mode}_${BASENAME} -out_dir ${OUTPUTDIR} ${INTERNAL_OPTIONS} -options "$<JOIN:${__cloc__options__}, >"
86 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
87 DEPENDS ${builtin} ocloc copy_compiler_files
88 )
89@@ -85,23 +88,12 @@ function(compile_builtin gen_type platform_type builtin bits builtin_options mod
90 set(OUTPUT_FILE_CPP
91 ${OUTPUTDIR}/${mode}_${BASENAME}_${family_name_with_type}_${REVISION_ID}.cpp
92 )
93- set(BINARY_OUTPUT "${OUTPUTDIR}/${mode}_${BASENAME}_${REVISION_ID}_${family_name_with_type}")
94- set(OUTPUT_FILES_BINARIES
95- ${BINARY_OUTPUT}.gen
96- ${BINARY_OUTPUT}.bin
97- )
98 list(APPEND BUILTINS_COMMANDS "${OUTPUT_FILE_CPP}")
99- add_custom_command(
100- OUTPUT ${OUTPUT_FILES_BINARIES}
101- COMMAND ${cloc_cmd_prefix} -q -file ${OUTPUT_FILE_SPV} -spirv_input -device ${DEFAULT_SUPPORTED_${gen_type}_${platform_type}_PLATFORM} ${builtin_options} -${bits} -output ${mode}_${BASENAME}_${REVISION_ID} -out_dir ${OUTPUTDIR} -revision_id ${REVISION_ID} ${INTERNAL_OPTIONS} -options "$<JOIN:${__cloc__options__}, >"
102- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
103- DEPENDS ${OUTPUT_FILE_SPV} ocloc copy_compiler_files
104- )
105 add_custom_command(
106 OUTPUT ${OUTPUT_FILE_CPP}
107- 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}
108+ COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${OUTPUTPATH_BASE}.gen --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID}
109 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
110- DEPENDS ${OUTPUT_FILES_BINARIES} $<TARGET_FILE:cpp_generate_tool>
111+ DEPENDS ${OUTPUTPATH_BASE}.gen $<TARGET_FILE:cpp_generate_tool>
112 )
113 endforeach()
114 set(BUILTINS_COMMANDS ${BUILTINS_COMMANDS} PARENT_SCOPE)
115--
1162.20.1
117
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 f580693d..456dc5cd 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 @@
1From b5d0b22011dd0360ad92dcd34f69a2b6a9e0772f Mon Sep 17 00:00:00 2001 1From 47ae5d13ad021076f5a79f245e33bcb228b0a0da Mon Sep 17 00:00:00 2001
2From: Dongwon Kim <dongwon.kim@intel.com> 2From: Dongwon Kim <dongwon.kim@intel.com>
3Date: Sat, 21 Aug 2021 16:09:39 -0700 3Date: Sat, 21 Aug 2021 16:09:39 -0700
4Subject: [PATCH] Build not able to locate cpp_generation_tool. 4Subject: [PATCH] Build not able to locate cpp_generation_tool.
@@ -12,33 +12,33 @@ Signed-off-by: Dongwon Kim <dongwon.kim@intel.com>
12 1 file changed, 4 insertions(+), 4 deletions(-) 12 1 file changed, 4 insertions(+), 4 deletions(-)
13 13
14diff --git a/shared/source/built_ins/kernels/CMakeLists.txt b/shared/source/built_ins/kernels/CMakeLists.txt 14diff --git a/shared/source/built_ins/kernels/CMakeLists.txt b/shared/source/built_ins/kernels/CMakeLists.txt
15index 12dc4aa7a..9e42d7a34 100644 15index 929b981fe..57cd3d4b3 100644
16--- a/shared/source/built_ins/kernels/CMakeLists.txt 16--- a/shared/source/built_ins/kernels/CMakeLists.txt
17+++ b/shared/source/built_ins/kernels/CMakeLists.txt 17+++ b/shared/source/built_ins/kernels/CMakeLists.txt
18@@ -91,9 +91,9 @@ function(compile_builtin gen_type platform_type builtin bits builtin_options mod 18@@ -100,9 +100,9 @@ if(NOT NEO_DISABLE_BUILTINS_COMPILATION)
19 list(APPEND BUILTINS_COMMANDS "${OUTPUT_FILE_CPP}") 19 )
20 add_custom_command(
21 OUTPUT ${OUTPUT_FILE_CPP}
22- 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}
23+ COMMAND cpp_generate_tool --file ${BINARY_OUTPUT}.gen --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID}
24 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
25- DEPENDS ${OUTPUT_FILES_BINARIES} $<TARGET_FILE:cpp_generate_tool>
26+ DEPENDS ${OUTPUT_FILES_BINARIES} cpp_generate_tool
27 )
28 endforeach()
29 set(BUILTINS_COMMANDS ${BUILTINS_COMMANDS} PARENT_SCOPE)
30@@ -144,9 +144,9 @@ if(NOT NEO_DISABLE_BUILTINS_COMPILATION)
31 )
20 add_custom_command( 32 add_custom_command(
21 OUTPUT ${OUTPUT_FILE_CPP} 33 OUTPUT ${OUTPUT_FILE_CPP}
22- COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${OUTPUTPATH_BASE}.gen --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID} 34- COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${GENERATED_SPV_INPUT} --output ${OUTPUT_FILE_CPP} --array ${BASENAME}
23+ COMMAND cpp_generate_tool --file ${OUTPUTPATH_BASE}.gen --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID} 35+ COMMAND cpp_generate_tool --file ${GENERATED_SPV_INPUT} --output ${OUTPUT_FILE_CPP} --array ${BASENAME}
24 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} 36 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
25- DEPENDS ${OUTPUTPATH_BASE}.gen $<TARGET_FILE:cpp_generate_tool> 37- DEPENDS ${GENERATED_SPV_INPUT} $<TARGET_FILE:cpp_generate_tool>
26+ DEPENDS ${OUTPUTPATH_BASE}.gen cpp_generate_tool 38+ DEPENDS ${GENERATED_SPV_INPUT} cpp_generate_tool
27 ) 39 )
28 endforeach() 40 endfunction()
29 set(BUILTINS_COMMANDS ${BUILTINS_COMMANDS} PARENT_SCOPE)
30@@ -135,9 +135,9 @@ function(generate_cpp_spirv builtin)
31 )
32 add_custom_command(
33 OUTPUT ${OUTPUT_FILE_CPP}
34- COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${GENERATED_SPV_INPUT} --output ${OUTPUT_FILE_CPP} --array ${BASENAME}
35+ COMMAND cpp_generate_tool --file ${GENERATED_SPV_INPUT} --output ${OUTPUT_FILE_CPP} --array ${BASENAME}
36 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
37- DEPENDS ${GENERATED_SPV_INPUT} $<TARGET_FILE:cpp_generate_tool>
38+ DEPENDS ${GENERATED_SPV_INPUT} cpp_generate_tool
39 )
40 endfunction()
41 41
42-- 42--
432.20.1 432.32.0
44 44
diff --git a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_21.33.20678.bb b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_21.37.20939.bb
index 4c94bcbe..2d1ae487 100644
--- a/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_21.33.20678.bb
+++ b/dynamic-layers/clang-layer/recipes-opencl/compute-runtime/intel-compute-runtime_21.37.20939.bb
@@ -9,12 +9,11 @@ LIC_FILES_CHKSUM = "file://LICENSE.md;md5=983b0c493ea3dc3c21a90ff743bf90e4 \
9 file://third_party/opencl_headers/LICENSE;md5=dcefc90f4c3c689ec0c2489064e7273b" 9 file://third_party/opencl_headers/LICENSE;md5=dcefc90f4c3c689ec0c2489064e7273b"
10 10
11SRC_URI = "git://github.com/intel/compute-runtime.git;protocol=https \ 11SRC_URI = "git://github.com/intel/compute-runtime.git;protocol=https \
12 file://0001-Revert-Change-builtin-kernels-compilation-process.patch \
13 " 12 "
14 13
15SRC_URI:append:class-target = "file://allow-to-find-cpp-generation-tool.patch" 14SRC_URI:append:class-target = "file://allow-to-find-cpp-generation-tool.patch"
16 15
17SRCREV = "4461fcdc2a0d28cab8c80b6cfc3a11baef707acc" 16SRCREV = "7c1ea18f74e053907a35cc4bf91f621def9b9f38"
18 17
19S = "${WORKDIR}/git" 18S = "${WORKDIR}/git"
20 19
@@ -33,7 +32,11 @@ EXTRA_OECMAKE = " \
33 -DBUILD_TYPE=Release \ 32 -DBUILD_TYPE=Release \
34 -DSKIP_UNIT_TESTS=1 \ 33 -DSKIP_UNIT_TESTS=1 \
35 -DCCACHE_ALLOWED=FALSE \ 34 -DCCACHE_ALLOWED=FALSE \
35 -DNEO_DISABLE_LD_LLD=ON \
36 -DNEO_DISABLE_LD_GOLD=ON \
36 " 37 "
38EXTRA_OECMAKE:append:class-native = " -DNEO_DISABLE_BUILTINS_COMPILATION=ON"
39
37EXTRA_OECMAKE:append:class-target = " \ 40EXTRA_OECMAKE:append:class-target = " \
38 -Dcloc_cmd_prefix=ocloc \ 41 -Dcloc_cmd_prefix=ocloc \
39 " 42 "