def f16_nan
import bendtorch@1.3.0.0/dtype.bend as Dtypeimport Base
84# a NaN keeps the top 9 bits of its payload and gets the quiet bit
85def f16_nan(+a: U32) -> U32:
86 (32256 .|. U32.shrn((a .&. 8388607 : U32), 13n) : U32)
import bendtorch@1.3.0.0/dtype.bend as Dtypeimport Base
84# a NaN keeps the top 9 bits of its payload and gets the quiet bit
85def f16_nan(+a: U32) -> U32:
86 (32256 .|. U32.shrn((a .&. 8388607 : U32), 13n) : U32)