Skip to content
This repository was archived by the owner on Dec 22, 2021. It is now read-only.
This repository was archived by the owner on Dec 22, 2021. It is now read-only.

Allow flushing of subnormals in floating point SIMD operations #2

@stoklund

Description

@stoklund

The proposal in #1 includes this text:

An implementation is allowed to flush subnormals in arithmetic floating-point
operations. This means that any subnormal operand is treated as 0, and any
subnormal result is rounded to 0.

Note that this differs from WebAssembly scalar floating-point semantics which
require correct subnormal handling.

The issue is also mentioned in the future features design document.

The practical issue for SIMD is 32-bit ARM devices: The ARMv7 ISA has two instruction sets for floating point, VFP and NEON. VFP provides scalar floating point instructions with full support for IEEE 754 subnormal values. NEON provides 64-bit and 128-bit SIMD floating point instructions that only have flush-to-zero semantics for subnormal numbers. The same is true of the AArch32 mode of ARMv8. Only AArch64 supports subnormal values in SIMD instructions.

In summary, if we want to run floating-point SIMD code on 32-bit ARM devices (and 64-bit ARM devices running in 32-bit mode) we need to allow for subnormal values to be flushed to zero.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions