Package Info

ghc-double-conversion


Fast conversion between single and double precision floating point and text


Unspecified

A library that performs fast, accurate conversion between floating point and text.

This library is implemented as bindings to the C++ 'double-conversion' library written by Florian Loitsch at Google: <https://github.com/floitsch/double-conversion>.

Now it can convert single precision numbers, and also it can create Builder, instead of bytestring or text.

The 'Text' versions of these functions are about 30 times faster than the default 'show' implementation for the 'Double' type.

The 'ByteString' versions are /slower/ than the 'Text' versions; roughly half the speed. (This seems to be due to the cost of allocating 'ByteString' values via 'malloc'.)

Builder versions are slower on single value, but they are much faster on large number of values (up to 50x faster on list with 20000 doubles).

As a final note, be aware that the 'bytestring-show' package is about 50% slower than simply using 'show'.


License: BSD-2-Clause
URL: https://hackage.haskell.org/package/double-conversion

Categories

Releases

Package Version Update ID Released Package Hub Version Platforms Subpackages
2.0.4.1-bp156.3.3 info GA Release 2023-12-07 15 SP6
  • AArch64
  • ppc64le
  • s390x
  • x86-64
  • ghc-double-conversion
  • ghc-double-conversion-devel
2.0.4.1-bp155.2.17 info GA Release 2023-05-22 15 SP5
  • AArch64
  • ppc64le
  • s390x
  • x86-64
  • ghc-double-conversion
  • ghc-double-conversion-devel
2.0.4.1-bp154.1.11 info GA Release 2022-05-09 15 SP4
  • AArch64
  • ppc64le
  • x86-64
  • ghc-double-conversion
  • ghc-double-conversion-devel
2.0.2.0-bp150.2.4 info GA Release 2018-08-01 15
  • AArch64
  • ghc-double-conversion
  • ghc-double-conversion-devel
2.0.2.0-bp150.2.7 info GA Release 2018-07-30 15
  • ppc64le
  • x86-64
  • ghc-double-conversion
  • ghc-double-conversion-devel