File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed
llvm/lib/Transforms/Instrumentation Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change 6464#include " llvm/IR/Use.h"
6565#include " llvm/IR/Value.h"
6666#include " llvm/MC/MCSectionMachO.h"
67- #include " llvm/SYCLLowerIR/DeviceGlobals.h"
6867#include " llvm/Support/Casting.h"
6968#include " llvm/Support/CommandLine.h"
7069#include " llvm/Support/Debug.h"
@@ -1566,7 +1565,11 @@ static bool isUnsupportedDeviceGlobal(GlobalVariable *G) {
15661565 // Non image scope device globals are implemented by device USM, and the
15671566 // out-of-bounds check for them will be done by sanitizer USM part. So we
15681567 // exclude them here.
1569- return (!isDeviceGlobalVariable (*G) || !hasDeviceImageScopeProperty (*G));
1568+ if (!G->hasAttribute (" sycl-device-image-scope" ))
1569+ return true ;
1570+
1571+ Attribute Attr = G->getAttribute (" sycl-device-image-scope" );
1572+ return (!Attr.isStringAttribute () || Attr.getValueAsString () == " false" );
15701573}
15711574
15721575static bool isUnsupportedSPIRAccess (Value *Addr, Instruction *Inst) {
Original file line number Diff line number Diff line change @@ -39,7 +39,6 @@ add_llvm_component_library(LLVMInstrumentation
3939 Core
4040 Demangle
4141 MC
42- SYCLLowerIR
4342 Support
4443 TargetParser
4544 TransformUtils
You can’t perform that action at this time.
0 commit comments