Skip to content

Commit 1472761

Browse files
committed
Merge remote-tracking branch 'origin/sycl' into zeKernelCreateForLinkedModule
2 parents 4c16f02 + 3351916 commit 1472761

File tree

4,579 files changed

+265887
-56947
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

4,579 files changed

+265887
-56947
lines changed

buildbot/compile.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ def do_compile(args):
3535
"deploy-opencl-aot",
3636
"-j", str(cpu_count)]
3737

38+
if args.verbose:
39+
cmake_cmd.append("--verbose")
40+
3841
print("[Cmake Command]: {}".format(" ".join(cmake_cmd)))
3942

4043
subprocess.check_call(cmake_cmd, cwd=abs_obj_dir)
@@ -55,6 +58,7 @@ def main():
5558
parser.add_argument("-s", "--src-dir", metavar="SRC_DIR", help="source directory")
5659
parser.add_argument("-o", "--obj-dir", metavar="OBJ_DIR", help="build directory")
5760
parser.add_argument("-j", "--build-parallelism", metavar="BUILD_PARALLELISM", help="build parallelism")
61+
parser.add_argument("-v", "--verbose", action='store_true', help="verbose build output")
5862

5963
args = parser.parse_args()
6064

buildbot/configure.py

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,14 @@ def do_configure(args):
1313
if not os.path.isdir(abs_obj_dir):
1414
os.makedirs(abs_obj_dir)
1515

16-
llvm_external_projects = 'sycl;llvm-spirv;opencl-aot;libdevice;xpti;xptifw'
16+
llvm_external_projects = 'sycl;llvm-spirv;opencl;opencl-aot;libdevice;xpti;xptifw'
1717

1818
llvm_dir = os.path.join(abs_src_dir, "llvm")
1919
sycl_dir = os.path.join(abs_src_dir, "sycl")
2020
spirv_dir = os.path.join(abs_src_dir, "llvm-spirv")
2121
xpti_dir = os.path.join(abs_src_dir, "xpti")
2222
xptifw_dir = os.path.join(abs_src_dir, "xptifw")
2323
libdevice_dir = os.path.join(abs_src_dir, "libdevice")
24-
ocl_header_dir = os.path.join(abs_obj_dir, "OpenCL-Headers")
25-
icd_loader_lib = os.path.join(abs_obj_dir, "OpenCL-ICD-Loader", "build")
2624
llvm_targets_to_build = 'X86'
2725
llvm_enable_projects = 'clang;' + llvm_external_projects
2826
libclc_targets_to_build = ''
@@ -34,7 +32,6 @@ def do_configure(args):
3432
llvm_build_shared_libs = 'OFF'
3533

3634
sycl_enable_xpti_tracing = 'ON'
37-
icd_loader_lib = os.path.join(icd_loader_lib, "libOpenCL.so" if platform.system() == 'Linux' else "OpenCL.lib")
3835

3936
# replace not append, so ARM ^ X86
4037
if args.arm:
@@ -87,11 +84,6 @@ def do_configure(args):
8784
"-DSYCL_ENABLE_XPTI_TRACING={}".format(sycl_enable_xpti_tracing)
8885
]
8986

90-
if args.system_ocl:
91-
cmake_cmd.extend([
92-
"-DOpenCL_INCLUDE_DIR={}".format(ocl_header_dir),
93-
"-DOpenCL_LIBRARY={}".format(icd_loader_lib)])
94-
9587
if args.l0_headers and args.l0_loader:
9688
cmake_cmd.extend([
9789
"-DL0_INCLUDE_DIR={}".format(args.l0_headers),
@@ -123,8 +115,10 @@ def do_configure(args):
123115
except subprocess.CalledProcessError:
124116
cmake_cache = os.path.join(abs_obj_dir, "CMakeCache.txt")
125117
if os.path.isfile(cmake_cache):
126-
os.remove(cmake_cache)
127-
subprocess.check_call(cmake_cmd, cwd=abs_obj_dir)
118+
print("There is CMakeCache.txt at " + cmake_cache +
119+
" ... you can try to remove it and rerun.")
120+
print("Configure failed!")
121+
return False
128122

129123
return True
130124

@@ -150,7 +144,6 @@ def main():
150144
parser.add_argument("--arm", action='store_true', help="build ARM support rather than x86")
151145
parser.add_argument("--no-assertions", action='store_true', help="build without assertions")
152146
parser.add_argument("--docs", action='store_true', help="build Doxygen documentation")
153-
parser.add_argument("--system-ocl", action='store_true', help="use OpenCL deps from system (no download)")
154147
parser.add_argument("--no-werror", action='store_true', help="Don't treat warnings as errors")
155148
parser.add_argument("--shared-libs", action='store_true', help="Build shared libraries")
156149
parser.add_argument("--cmake-opt", action='append', help="Additional CMake option not configured via script parameters")

clang-tools-extra/clang-tidy/bugprone/BugproneTidyModule.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
#include "FoldInitTypeCheck.h"
2323
#include "ForwardDeclarationNamespaceCheck.h"
2424
#include "ForwardingReferenceOverloadCheck.h"
25+
#include "ImplicitWideningOfMultiplicationResultCheck.h"
2526
#include "InaccurateEraseCheck.h"
2627
#include "IncorrectRoundingsCheck.h"
2728
#include "InfiniteLoopCheck.h"
@@ -60,6 +61,7 @@
6061
#include "TooSmallLoopVariableCheck.h"
6162
#include "UndefinedMemoryManipulationCheck.h"
6263
#include "UndelegatedConstructorCheck.h"
64+
#include "UnhandledExceptionAtNewCheck.h"
6365
#include "UnhandledSelfAssignmentCheck.h"
6466
#include "UnusedRaiiCheck.h"
6567
#include "UnusedReturnValueCheck.h"
@@ -97,6 +99,8 @@ class BugproneModule : public ClangTidyModule {
9799
"bugprone-forward-declaration-namespace");
98100
CheckFactories.registerCheck<ForwardingReferenceOverloadCheck>(
99101
"bugprone-forwarding-reference-overload");
102+
CheckFactories.registerCheck<ImplicitWideningOfMultiplicationResultCheck>(
103+
"bugprone-implicit-widening-of-multiplication-result");
100104
CheckFactories.registerCheck<InaccurateEraseCheck>(
101105
"bugprone-inaccurate-erase");
102106
CheckFactories.registerCheck<IncorrectRoundingsCheck>(
@@ -175,6 +179,8 @@ class BugproneModule : public ClangTidyModule {
175179
"bugprone-undelegated-constructor");
176180
CheckFactories.registerCheck<UnhandledSelfAssignmentCheck>(
177181
"bugprone-unhandled-self-assignment");
182+
CheckFactories.registerCheck<UnhandledExceptionAtNewCheck>(
183+
"bugprone-unhandled-exception-at-new");
178184
CheckFactories.registerCheck<UnusedRaiiCheck>(
179185
"bugprone-unused-raii");
180186
CheckFactories.registerCheck<UnusedReturnValueCheck>(

clang-tools-extra/clang-tidy/bugprone/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ add_clang_library(clangTidyBugproneModule
1717
FoldInitTypeCheck.cpp
1818
ForwardDeclarationNamespaceCheck.cpp
1919
ForwardingReferenceOverloadCheck.cpp
20+
ImplicitWideningOfMultiplicationResultCheck.cpp
2021
InaccurateEraseCheck.cpp
2122
IncorrectRoundingsCheck.cpp
2223
InfiniteLoopCheck.cpp
@@ -55,6 +56,7 @@ add_clang_library(clangTidyBugproneModule
5556
TooSmallLoopVariableCheck.cpp
5657
UndefinedMemoryManipulationCheck.cpp
5758
UndelegatedConstructorCheck.cpp
59+
UnhandledExceptionAtNewCheck.cpp
5860
UnhandledSelfAssignmentCheck.cpp
5961
UnusedRaiiCheck.cpp
6062
UnusedReturnValueCheck.cpp

0 commit comments

Comments
 (0)