Skip to content

Commit 8d20150

Browse files
author
kbobrovs
committed
disable too eager diagnostics - add TODO.
Signed-off-by: kbobrovs <[email protected]>
1 parent aa7b0e0 commit 8d20150

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

llvm/lib/SYCLLowerIR/ESIMD/LowerESIMDSlmReservation.cpp

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -341,11 +341,15 @@ class ScopedCallGraph {
341341
esimd::assert_and_diag(!SlmInitCall,
342342
"multiple slm_init calls in function ",
343343
F.getName());
344-
esimd::assert_and_diag(
345-
esimd::isESIMDKernel(F) ||
346-
sycl::utils::isSYCLExternalFunction(&F),
347-
"slm_init call met in non-kernel non-external function ",
348-
F.getName());
344+
// TODO: this diagnostics incorrectly fires on functor's
345+
// operator() marked as SYCL_ESIMD_KERNEL, because becomes neither
346+
// spir_kernel nor SYCL_EXERNAL function in IR. It rather becomes
347+
// a function called from spir_kernel.
348+
// esimd::assert_and_diag(
349+
// esimd::isESIMDKernel(F) ||
350+
// sycl::utils::isSYCLExternalFunction(&F),
351+
// "slm_init call met in non-kernel non-external function ",
352+
// F.getName());
349353
esimd::assert_and_diag(
350354
!ScopeMet,
351355
"slm_init must precede any SLMAllocator object in function ",

0 commit comments

Comments
 (0)