Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

[SYCL] Enable level-zero-link-flags and fix kernel_bundle_api #806

Merged
merged 11 commits into from
Feb 28, 2022
Merged
3 changes: 1 addition & 2 deletions SYCL/Basic/kernel_bundle/kernel_bundle_api.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// Disable fallback assert here until online-support is fixed.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be worth asking @s-kanaev if this comment should be removed. It looks to me like the test still has fallback assert disabled, so maybe the comment should remain until it is enabled.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll ask about your concern.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fallback assert is now disabled by default. See intel/llvm#4694.
Hence, this comment might be removed along with -DSYCL_DISABLE_FALLBACK_ASSERT=1 in build line.
It'll be responsibility of the one who enables the fallback assert to verify it won't impact other tests.

P.S.: Sorry for late response.

// Use of per-kernel device code split and linking the bundle with all images
// involved leads to multiple definition of AssertHappened structure due each
// device image is statically linked against fallback libdevice.
Expand Down Expand Up @@ -185,7 +184,7 @@ int main() {
// CHECK-NEXT: <unknown> : {{.*}}
// CHECK-NEXT: <unknown> : {{.*}}
// CHECK-NEXT: <unknown> : {{.*}}
// CHECK-NEXT: <nullptr>
// CHECK-NEXT: <const char *>:
// CHECK-NEXT: <unknown> : {{.*}}
// CHECK-NEXT: <unknown> : {{.*}}
// CHECK-NEXT: <nullptr>
Expand Down
9 changes: 0 additions & 9 deletions SYCL/KernelAndProgram/level-zero-link-flags.cpp
Original file line number Diff line number Diff line change
@@ -1,15 +1,6 @@
// RUN: %clangxx -fsycl -Xsycl-target-linker=spir64 -foo %s -o %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// REQUIRES: level_zero
//
// This test is disabled because the runtime does not currently pass linker
// flags from "-Xsycl-target-linker=spir64 <opts>" when the program calls
// "sycl::link()". This seems like a bug. Note that the runtime does pass
// those "<opts>" to the online linker in other cases when it links device
// code.
//
// XFAIL: level_zero
//
//==--- level-zero-link-flags.cpp - Error handling for link flags --==//
//
// The Level Zero backend does not accept any online linker options.
Expand Down