Skip to content

Conversation

@FranciscoTGouveia
Copy link
Contributor

@FranciscoTGouveia FranciscoTGouveia commented Oct 26, 2025

Fixes #4642.

I would appreciate feedback on the following:

  • Initially, I decided to add two test cases -- one for f32 and another for f64 -- but I later concluded that this might be redundant. If not, I am happy to reintroduce the second one;
  • I have thoroughly looked into the documentation of rustc_apfloat, and the only suitable solution I have found was from_bits. I may have overlooked something, but going through the codebase, I did not find any other way to do this;
  • As all operations done (to_bits() -> cast -> from_bits()) are bit-preserving, I do not think we need to worry about signaling NaNs here. Am I correct thinking this should not be problematic?

Thank you in advance for your time and input!

@rustbot
Copy link
Collaborator

rustbot commented Oct 26, 2025

Thank you for contributing to Miri!
Please remember to not force-push to the PR branch except when you need to rebase due to a conflict or when the reviewer asks you for it.

@rustbot rustbot added the S-waiting-on-review Status: Waiting for a review to complete label Oct 26, 2025
@RalfJung
Copy link
Member

This looks great, thanks! Please squash the commits using ./miri squash. Then write @rustbot ready after you force-pushed the squashed PR.

@rustbot author

@rustbot rustbot removed the S-waiting-on-review Status: Waiting for a review to complete label Oct 27, 2025
@rustbot
Copy link
Collaborator

rustbot commented Oct 27, 2025

Reminder, once the PR becomes ready for a review, use @rustbot ready.

@rustbot rustbot added the S-waiting-on-author Status: Waiting for the PR author to address review comments label Oct 27, 2025
@FranciscoTGouveia
Copy link
Contributor Author

I believe this was a spurious failure in the CI.

@rustbot ready

@rustbot rustbot added S-waiting-on-review Status: Waiting for a review to complete and removed S-waiting-on-author Status: Waiting for the PR author to address review comments labels Oct 28, 2025
@RalfJung RalfJung enabled auto-merge October 28, 2025 09:52
@RalfJung RalfJung added this pull request to the merge queue Oct 28, 2025
Merged via the queue into rust-lang:master with commit fa8b965 Oct 28, 2025
17 of 26 checks passed
@rustbot rustbot removed the S-waiting-on-review Status: Waiting for a review to complete label Oct 28, 2025
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.

Support f32/f64 in native function calls.

3 participants