Skip to content

[libclc] Have all targets build all CLC functions #124779

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 10, 2025

Conversation

frasercrmck
Copy link
Contributor

This removes all remaining SPIR-V workarounds for CLC functions, in an effort to streamline the CLC implementation and prevent further issues that #124614 had to fix. This commit fixes the same issue for the SPIR-V targets.

Target-specific CLC implementations can and will exist, but for now they're all identical and so the target-specific SOURCES files have been removed. Target implementations now always include the 'generic' CLC directory, meaning we can avoid unnecessary duplication of SOURCES listings.

@frasercrmck frasercrmck added the libclc libclc OpenCL library label Jan 28, 2025
@frasercrmck frasercrmck requested a review from arsenm January 28, 2025 16:21
@frasercrmck
Copy link
Contributor Author

CC @rjodinchr

@arsenm
Copy link
Contributor

arsenm commented Jan 29, 2025

Target-specific CLC implementations can and will exist, but for now they're all identical and so the target-specific SOURCES files have been removed.

Do we not have at least one sample of these? We should probably go out of the way to add one so the build infrastructure doesn't decay

@frasercrmck
Copy link
Contributor Author

Target-specific CLC implementations can and will exist, but for now they're all identical and so the target-specific SOURCES files have been removed.

Do we not have at least one sample of these? We should probably go out of the way to add one so the build infrastructure doesn't decay

I was working on porting over FMA yesterday and clspv/spirv have custom implementations for that. So that'll hopefully be coming up soon. That depends on a bunch of the integer functions in #116786 so there's a bit of a pipeline to flush first. But yeah we can wait for that to all go in. I'm not so worried about the infrastructure decaying since the OpenCL layer isn't changing, but it would save on unnecessary churn.

The only other thing they custom define is vstore_half but I've not looked into what's going on there, and that'll be a wee way off yet.

This removes all remaining SPIR-V workarounds for CLC functions, in an
effort to streamline the CLC implementation and prevent further issues
that llvm#124614 had to fix. This commit fixes the same issue for the SPIR-V
targets.

Target-specific CLC implementations can and will exist, but for now
they're all identical and so the target-specific SOURCES files have been
removed. Target implementations now always include the 'generic' CLC
directory, meaning we can avoid unnecessary duplication of SOURCES
listings.
@frasercrmck frasercrmck merged commit 4dec390 into llvm:main Feb 10, 2025
8 checks passed
@frasercrmck frasercrmck deleted the libclc-clc-buildall branch February 10, 2025 10:19
Icohedron pushed a commit to Icohedron/llvm-project that referenced this pull request Feb 11, 2025
This removes all remaining SPIR-V workarounds for CLC functions, in an
effort to streamline the CLC implementation and prevent further issues
that llvm#124614 had to fix. This commit fixes the same issue for the SPIR-V
targets.

Target-specific CLC implementations can and will exist, but for now
they're all identical and so the target-specific SOURCES files have been
removed. Target implementations now always include the 'generic' CLC
directory, meaning we can avoid unnecessary duplication of SOURCES
listings.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
libclc libclc OpenCL library
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants