Skip to content

[libclc] Make CLC library warning-free #128864

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

Conversation

frasercrmck
Copy link
Contributor

There is a long-standing workaround in the libclc build system that silences a warning about the use of parentheses in bitwise conditional operations.

In an effort to remove this workaround, this commit re-enables the warning on the internal CLC library, where most of the bodies of the builtins will eventually be defined. Thus as we move builtin implementations into this library, the warnings will trigger and we can clean up the codebase as we go.

As it happens the only instance in the CLC library which triggered the warning was in __clc_ldexp.

There is a long-standing workaround in the libclc build system that
silences a warning about the use of parentheses in bitwise conditional
operations.

In an effort to remove this workaround, this commit re-enables the
warning on the internal CLC library, where most of the bodies of the
builtins will eventually be defined. Thus as we move builtin
implementations into this library, the warnings will trigger and we can
clean up the codebase as we go.

As it happens the only instance in the CLC library which triggered the
warning was in __clc_ldexp.
@frasercrmck frasercrmck added the libclc libclc OpenCL library label Feb 26, 2025
@frasercrmck frasercrmck requested a review from arsenm February 26, 2025 11:23
@frasercrmck frasercrmck merged commit 5f4d1f7 into llvm:main Feb 26, 2025
13 checks passed
@frasercrmck frasercrmck deleted the libclc-clc-bitwise-cond-paren-clean branch February 26, 2025 12:11
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