jk-jeon / floff

A test repository for the WIP algorithm for fixed-precision floating-point formatting.
Apache License 2.0
18 stars 0 forks source link

floff

A test repository for the WIP algorithm for fixed-precision floating-point formatting.

An explanation of the algorithm is given here.

For quick experiment: https://godbolt.org/z/5948en1zo

Here is how it performs for printing double:

benchmark

Compiled binary size of the benchmark program:

                                base : 1,022,464 bytes
                floff full-long only : 1,050,112 bytes (base +  27,648 bytes)
 floff compressed-super-compact only : 1,040,384 bytes (base +  17,920 bytes)
                     Ryu-printf only : 1,133,568 bytes (base + 111,104 bytes)
                above three together : 1,180,160 bytes (base + 157,696 bytes)