Skip to content

[TEST][E2E][CUDA] Fix WorkGroupScratchMemory/missing_launch_property.cpp failure#21965

Open
kweronsx wants to merge 1 commit into
intel:syclfrom
kweronsx:fix-workgroup-scratch-memory
Open

[TEST][E2E][CUDA] Fix WorkGroupScratchMemory/missing_launch_property.cpp failure#21965
kweronsx wants to merge 1 commit into
intel:syclfrom
kweronsx:fix-workgroup-scratch-memory

Conversation

@kweronsx
Copy link
Copy Markdown
Contributor

@kweronsx kweronsx commented May 8, 2026

Fixes the WorkGroupScratchMemory/missing_launch_property.cpp E2E test failure on CUDA (tracked in #21924).

Extends two conditional checks to also handle PTX_Kernel calling convention alongside SPIR_KERNEL. This ensures that work-group scratch memory attributes (WORK_GROUP_SCRATCH_ATTR) are correctly detected and applied for CUDA kernels, not just SPIR kernels.

Adds a LIT test verifying that ptx_kernel (CUDA) functions calling __sycl_dynamicLocalMemoryPlaceholder are correctly lowered by sycllowerwglocalmemory: the placeholder call is replaced by a reference to a real shared-memory global, and the "sycl-work-group-scratch" attribute is stamped on the kernel so the host-side launcher knows to wire up dynamic shared memory at launch.

@kweronsx kweronsx marked this pull request as ready for review May 11, 2026 08:42
@kweronsx kweronsx requested review from a team as code owners May 11, 2026 08:42
@kweronsx kweronsx requested a review from slawekptak May 11, 2026 08:42
Copy link
Copy Markdown
Contributor

@slawekptak slawekptak left a comment

Choose a reason for hiding this comment

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

SYCL test changes LGTM.

@maksimsab
Copy link
Copy Markdown
Contributor

Please, add more descriptive commit message. The current is not sufficient.
Despite of that it worth to add a LIT test.

Comment thread llvm/lib/SYCLLowerIR/LowerWGLocalMemory.cpp
@kweronsx kweronsx force-pushed the fix-workgroup-scratch-memory branch from 509ee4e to 7f80e6f Compare May 12, 2026 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants