Skip to content
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

Fix float128 compilation of NVPTX backend for LLVM #3823

Merged

Conversation

dedoardo
Copy link
Contributor

Description

The latest version of libfmt began using the __float128 type but this is not supported in the NVPTX backend for LLVM. A way to detect this particular platform seems to be to check both __CUDA_ARCH__ and __clang__.
I am not disabling it entirely on any CUDA target because NVCC 10+ understands _float128 and generates instructions for it when tested on godbolt.

Following up from #3809.

Checklist:

Copy link
Collaborator

@lgritz lgritz left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for the fix!

@lgritz lgritz merged commit c231dfb into AcademySoftwareFoundation:master Apr 28, 2023
lgritz pushed a commit to lgritz/OpenImageIO that referenced this pull request Apr 30, 2023
…undation#3823)

The latest version of libfmt began using the `__float128` type but this
is [not supported in the NVPTX backend for
LLVM](https://discourse.llvm.org/t/compiling-cuda-code-fails/61240/13).
A way to detect this particular platform seems to be to check both
`__CUDA_ARCH__` and `__clang__`.
I am not disabling it entirely on any CUDA target because NVCC 10+
understands `_float128` and generates instructions for it when tested on
godbolt.

Following up from AcademySoftwareFoundation#3809.

Co-authored-by: Edoardo Dominici <[email protected]>
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.

2 participants