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 invalid lowerings for ROCm in Pallas #26368

Merged
merged 1 commit into from
Feb 7, 2025

Conversation

mrodden
Copy link
Collaborator

@mrodden mrodden commented Feb 6, 2025

popcount and clz were effectively broken on ROCm,
since math_dialect fallbacks were resulting in
incorrect lowerings during compilation in XLA.

Use the device intrinsics for these functions, as
well as for exp and absf, which fixes some accuracy issues in the pallas tests.

Docs for OCML/OCKL

popcount and clz were effectively broken on ROCm,
since math_dialect fallbacks were resulting in
incorrect lowerings during compilation in XLA.

Use the device intrinsics for these functions, as
well as for exp and absf, which fixes some accuracy issues in
the pallas tests.

Docs for OCML/OCKL

- https://github.com/ROCm/llvm-project/blob/amd-staging/amd/device-libs/doc/OCML.md
- https://github.com/ROCm/llvm-project/blob/amd-staging/amd/device-libs/doc/OCKL.md

Co-Authored-By: <[email protected]>
@google-ml-butler google-ml-butler bot added kokoro:force-run pull ready Ready for copybara import and testing labels Feb 7, 2025
@superbobry
Copy link
Collaborator

Thanks you!

@copybara-service copybara-service bot merged commit 6ad38af into jax-ml:main Feb 7, 2025
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pull ready Ready for copybara import and testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants