Skip to content

cranelift: use f16 fallbacks#158972

Draft
folkertdev wants to merge 6 commits into
rust-lang:mainfrom
folkertdev:cranelift-use-f16-fallbacks
Draft

cranelift: use f16 fallbacks#158972
folkertdev wants to merge 6 commits into
rust-lang:mainfrom
folkertdev:cranelift-use-f16-fallbacks

Conversation

@folkertdev

@folkertdev folkertdev commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

@rustbot rustbot added A-CI Area: Our Github Actions CI A-testsuite Area: The testsuite used to check the correctness of rustc S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Jul 8, 2026
folkertdev and others added 6 commits July 8, 2026 21:34
in `is_call_from_compiler_builtins_to_upstream_monomorphization`,
suggested by Saethlin
We'll do this using `-Zforce-intrinsic-fallback` in the main repo going forward
A number of float operations from libm have intrinsics for optimization,
but it is also okay to just call the libm functions directly. Add a
fallback for these cases, including converting to/from another float
size where needed, so the backends don't need to override these.

We do not add a fallback body for intrinsics that have a softfloat
implementation (e.g. sqrt, fma), because it would make them harder
to constify later.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-CI Area: Our Github Actions CI A-testsuite Area: The testsuite used to check the correctness of rustc S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants