1 # See LICENSE for license details.
3 #*****************************************************************************
5 #-----------------------------------------------------------------------------
7 # Test corner cases of John Hauser's microarchitectural recoding scheme.
8 # There are twice as many recoded values as IEEE-754 values; some of these
9 # extras are redundant (e.g. Inf) and others are illegal (subnormals with
13 #include "riscv_test.h"
14 #include "test_macros.h"
19 # Make sure infinities with different mantissas compare as equal.
23 TEST_CASE( 2, a0, 1, feq.s a0, f0, f1)
24 TEST_CASE( 3, a0, 1, fle.s a0, f0, f1)
25 TEST_CASE( 4, a0, 0, flt.s a0, f0, f1)
27 # When converting small doubles to single-precision subnormals,
28 # ensure that the extra precision is discarded.
35 TEST_CASE(10, a0, 0, sub a0, a0, a1)
37 # Make sure FSD+FLD correctly saves and restores a single-precision value.
43 TEST_CASE(20, a0, 1, feq.s a0, f0, f1)
55 small: .float 2.9133121e-37
56 tiny: .double 2.3860049081905093e-40