Skip to content

Commit 91f11cb

Browse files
committed
Merge from 'sycl' to 'sycl-web' (8 commits)
CONFLICT (content): Merge conflict in clang/lib/AST/MicrosoftMangle.cpp CONFLICT (content): Merge conflict in clang/lib/CodeGen/CodeGenFunction.cpp CONFLICT (content): Merge conflict in clang/lib/CodeGen/CodeGenModule.cpp CONFLICT (content): Merge conflict in clang/lib/CodeGen/Targets/AMDGPU.cpp
2 parents 3f59f1e + bab814a commit 91f11cb

Some content is hidden

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

48 files changed

+648
-317
lines changed

clang/lib/CodeGen/TargetInfo.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ unsigned TargetCodeGenInfo::getDeviceKernelCallingConv() const {
117117
// to multiple function arguments etc.
118118
return llvm::CallingConv::SPIR_KERNEL;
119119
}
120-
if (getABIInfo().getContext().getLangOpts().SYCLIsNativeCPU) {
120+
if (getABIInfo().getContext().getTargetInfo().getTriple().isNativeCPU()) {
121121
return llvm::CallingConv::SPIR_KERNEL;
122122
}
123123
llvm_unreachable("Unknown kernel calling convention");

clang/lib/CodeGen/Targets/AMDGPU.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,8 @@ class AMDGPUTargetCodeGenInfo : public TargetCodeGenInfo {
305305
void setTargetAttributes(const Decl *D, llvm::GlobalValue *GV,
306306
CodeGen::CodeGenModule &M) const override;
307307
unsigned getDeviceKernelCallingConv() const override;
308+
void
309+
setOCLKernelStubCallingConvention(const FunctionType *&FT) const override;
308310

309311
llvm::Constant *getNullPointer(const CodeGen::CodeGenModule &CGM,
310312
llvm::PointerType *T, QualType QT) const override;
@@ -435,6 +437,14 @@ unsigned AMDGPUTargetCodeGenInfo::getDeviceKernelCallingConv() const {
435437
return llvm::CallingConv::AMDGPU_KERNEL;
436438
}
437439

440+
void AMDGPUTargetCodeGenInfo::setOCLKernelStubCallingConvention(
441+
const FunctionType *&FT) const {
442+
bool IsSYCL = getABIInfo().getContext().getLangOpts().isSYCL();
443+
FT = getABIInfo().getContext().adjustFunctionType(
444+
FT,
445+
FT->getExtInfo().withCallingConv(!IsSYCL ? CC_C : CC_DeviceKernel));
446+
}
447+
438448
// Currently LLVM assumes null pointers always have value 0,
439449
// which results in incorrectly transformed IR. Therefore, instead of
440450
// emitting null pointers in private and local address spaces, a null

clang/test/CodeGenSYCL/spirv-builtins-addr-space.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clang_cc1 %s -fsycl-is-device -fdeclare-spirv-builtins -emit-llvm -o - -O0 | FileCheck %s
1+
// RUN: %clang_cc1 %s -triple spir64 -fsycl-is-device -fdeclare-spirv-builtins -emit-llvm -o - -O0 | FileCheck %s
22
//
33
// Check that SPIR-V builtins are declared with SYCL address spaces rather
44
// than OpenCL address spaces when using them with SYCL. OpenCL address spaces
@@ -10,19 +10,19 @@
1010

1111
#include "Inputs/sycl.hpp"
1212

13-
// CHECK: __spirv_ocl_modf{{.*}}SYglobal
13+
// CHECK: __spirv_ocl_modf{{.*}}AS1f
1414
void modf_global(float a) {
1515
__attribute__((opencl_global)) float *ptr = nullptr;
1616
sycl::kernel_single_task<class fake_kernel>([=]() { __spirv_ocl_modf(a, ptr); });
1717
}
1818

19-
// CHECK: __spirv_ocl_modf{{.*}}SYlocal
19+
// CHECK: __spirv_ocl_modf{{.*}}AS3f
2020
void modf_local(float a) {
2121
__attribute__((opencl_local)) float *ptr = nullptr;
2222
sycl::kernel_single_task<class fake_kernel>([=]() { __spirv_ocl_modf(a, ptr); });
2323
}
2424

25-
// CHECK: __spirv_ocl_modf{{.*}}SYprivate
25+
// CHECK: __spirv_ocl_modf{{.*}}AS0f
2626
void modf_private(float a) {
2727
__attribute__((opencl_private)) float *ptr = nullptr;
2828
sycl::kernel_single_task<class fake_kernel>([=]() { __spirv_ocl_modf(a, ptr); });

clang/test/Frontend/sycl-propagate-aspect-warning.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
// RUN: %clang_cc1 -internal-isystem %S/Inputs -fsycl-is-device -mconstructor-aliases -emit-codegen-only -verify %s
2-
1+
// RUN: %clang_cc1 -internal-isystem %S/Inputs -triple native_cpu -fsycl-is-device -mconstructor-aliases -emit-llvm %s -o /dev/null
32
// Tests for warnings when propagated aspects do not match the aspects available
43
// in a function, as specified through the 'sycl::device_has' attribute.
54

devops/dependencies-igc-dev.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"linux": {
33
"igc_dev": {
4-
"github_tag": "igc-dev-cee4ac4",
5-
"version": "cee4ac4",
6-
"updated_at": "2025-07-17T03:17:43Z",
7-
"url": "https://api.github.com/repos/intel/intel-graphics-compiler/actions/artifacts/3551081814/zip",
4+
"github_tag": "igc-dev-420b632",
5+
"version": "420b632",
6+
"updated_at": "2025-07-20T08:48:29Z",
7+
"url": "https://api.github.com/repos/intel/intel-graphics-compiler/actions/artifacts/3571853551/zip",
88
"root": "{DEPS_ROOT}/opencl/runtime/linux/oclgpu"
99
}
1010
}

devops/scripts/benchmarks/benches/base.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,8 @@ def benchmarks(self) -> list[Benchmark]:
199199
def name(self) -> str:
200200
pass
201201

202-
def setup(self):
202+
@abstractmethod
203+
def setup(self) -> None:
203204
return
204205

205206
def additional_metadata(self) -> dict[str, BenchmarkMetadata]:

devops/scripts/benchmarks/benches/benchdnn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def benchmarks(self) -> list:
5858
)
5959
return benchmarks
6060

61-
def setup(self):
61+
def setup(self) -> None:
6262
if options.sycl is None:
6363
return
6464

devops/scripts/benchmarks/benches/compute.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ def git_url(self) -> str:
5252
def git_hash(self) -> str:
5353
return "83b9ae3ebb3563552409f3a317cdc1cf3d3ca6bd"
5454

55-
def setup(self):
55+
def setup(self) -> None:
5656
if options.sycl is None:
5757
return
5858

devops/scripts/benchmarks/benches/gromacs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def benchmarks(self) -> list[Benchmark]:
5050
# GromacsBenchmark(self, "0192", "rf", "eager"),
5151
]
5252

53-
def setup(self):
53+
def setup(self) -> None:
5454
self.gromacs_src = git_clone(
5555
self.directory,
5656
"gromacs-repo",

devops/scripts/benchmarks/benches/llamacpp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def git_url(self) -> str:
2828
def git_hash(self) -> str:
2929
return "916c83bfe7f8b08ada609c3b8e583cf5301e594b"
3030

31-
def setup(self):
31+
def setup(self) -> None:
3232
if options.sycl is None:
3333
return
3434

0 commit comments

Comments
 (0)