in reply to Re^2: Decimal Floating Point (DFP) and does Perl needs DFP?
in thread Decimal Floating Point (DFP) and does Perl needs DFP?

Comparing a 2014.08 Rakudo with Perl 5.20 running the rat_mul_div_cancel micro benchmark showed "Rat (rational number) support is 6x faster than Perl 5".

To quote the user doc for Rat:

"To prevent the numerator and denominator from becoming pathologically large, the denominator is limited to 64 bit storage. On overflow of the denominator a Num (floating-point number) is returned instead."

and

"If you want arbitrary precision arithmetic with rational numbers, use the FatRat type instead."

  • Comment on Re^3: Decimal Floating Point (DFP) and does Perl needs DFP?