Skip to content

Fix generation of f16 special float ops #7541

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

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

llvm-beanz
Copy link
Collaborator

Due to a bug in the special float builtin function declarations DXC never generated fp16 variants of isnan, isinf, and isfinite. This corrects the issue by making the functions take float_like arguments instead of float arguments.

Fixes #7496

Due to a bug in the special float builtin function declarations DXC
never generated fp16 variants of isnan, isinf, and isfinite. This
corrects the issue by making the functions take float_like arguments
instead of float arguments.

Fixes microsoft#7496

../tools/clang/test/CodeGenDXIL/Ops/SpecialFloat.hlsl
@llvm-beanz llvm-beanz marked this pull request as draft June 18, 2025 20:23
@llvm-beanz
Copy link
Collaborator Author

Dropped this back to a draft. We've found some drivers in the wild that crash on this, so we'll need to provide alternate lowering for existing shader models and work with driver vendors to deploy fixes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: New
Development

Successfully merging this pull request may close these issues.

Special float NaN/Inf checks on fp16 types are implicitly extended to fp32
1 participant