Skip to content

Use apfloat for full-precision sqrt #3534

Open
@RalfJung

Description

@RalfJung

With rust-lang/rust#121793 and rust-lang/rust#118217, most float functions are now documented to have varying precision, so using host floats for them in Miri is actually fine. The only exceptions are mul_add (tracked at #2995) and sqrt -- those guarantee an infinite-precision result, so we should ideally use softfloats. (That said, using host floats is not wrong here since the host functions are in fact guaranteeing the infinite-precision result we are supposed to be emulating. Still, it seems cleaner to use softfloats for everything where precision is guaranteed.)

This is blocked on rust-lang/rustc_apfloat#14.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-shimsArea: This affects the external function shimsC-enhancementCategory: a PR with an enhancement or an issue tracking an accepted enhancementS-blockedStatus: blocked on something happening somewhere else

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions