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

Change f32::midpoint to upcast to f64 #121062

Merged
merged 1 commit into from
Jun 3, 2024
Merged

Commits on Jun 2, 2024

  1. Change f32::midpoint to upcast to f64

    This has been verified by kani as a correct optimization
    
    see: rust-lang#110840 (comment)
    
    The new implementation is branchless, and only differs in which NaN
    values are produced (if any are produced at all). Which is fine to change.
    Aside from NaN handling, this implementation produces bitwise identical
    results to the original implementation.
    
    The new implementation is gated on targets that have a fast 64-bit
    floating point implementation in hardware, and on WASM.
    RustyYato committed Jun 2, 2024
    Configuration menu
    Copy the full SHA
    849c525 View commit details
    Browse the repository at this point in the history