Skip to content

[SYCL][AMDGPU] Set amdgpu-flat-work-group-size for SYCL reqd_work_group_size#22452

Open
wenju-he wants to merge 1 commit into
intel:sycl-webfrom
wenju-he:fix-CodeGenSYCL-reqd-work-group-size.cpp
Open

[SYCL][AMDGPU] Set amdgpu-flat-work-group-size for SYCL reqd_work_group_size#22452
wenju-he wants to merge 1 commit into
intel:sycl-webfrom
wenju-he:fix-CodeGenSYCL-reqd-work-group-size.cpp

Conversation

@wenju-he

@wenju-he wenju-he commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

AMDGPU verifier (added in 6794e31) requires amdgpu-flat-work-group-size function attribute whenever reqd_work_group_size metadata is present. setFunctionDeclAttributes only handled OpenCL's ReqdWorkGroupSizeAttr; SYCL uses SYCLReqdWorkGroupSizeAttr which went through CodeGenFunction.cpp to emit the metadata but never set the function attribute, triggering the verifier error on amdgcn targets.

Fixes CodeGenSYCL/reqd-work-group-size.cpp and check-work-group-attributes-match.cpp.
CMPLRLLVM-76303

…up_size

AMDGPU verifier (added in 6794e31) requires amdgpu-flat-work-group-size
function attribute whenever reqd_work_group_size metadata is present.
setFunctionDeclAttributes only handled OpenCL's ReqdWorkGroupSizeAttr; SYCL
uses SYCLReqdWorkGroupSizeAttr which went through CodeGenFunction.cpp to emit
the metadata but never set the function attribute, triggering the verifier
error on amdgcn targets.

Fixes CodeGenSYCL/reqd-work-group-size.cpp
CMPLRLLVM-76303

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@wenju-he

Copy link
Copy Markdown
Contributor Author

not upstream-able because SYCLReqdWorkGroupSizeAttr doesn't exists in llvm-project

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.

1 participant