Skip to content
This repository was archived by the owner on Oct 31, 2025. It is now read-only.
This repository was archived by the owner on Oct 31, 2025. It is now read-only.

Investigate adding fast-math functions #12

@Jasper-Bekkers

Description

@Jasper-Bekkers

Relevant: rust-lang/rust#21690

My current thinking around this is that we probably shouldn't even do this.

However, if we do this, I'm kind of partial to having something like unsafe fn sqrt_approx() implemented on floats, that one needs to call explicitly within an unsafe block. As discussed in that issue, there are quite a few problems with the existing LLVM backend, it's optimizations etc. Many of which we don't need to care about because we're rolling our own. Having said that, SPIR-V and especially Vulkan have their own set of restrictions around floats: https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#spirvenv-precision-operation

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: spirv-stdIssues specific to the spirv-std cratet: enhancementA new feature or improvement to an existing one.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions