You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I changed the string convertion routines for floating points to use integer calculations now, because the integer arithmetic is a lot faster than the repeated floating point multiplications and conversions of the integral part of the mantissa to integers. The generic math of a repeated multiplication of the mantissa with the base for every digit remains the same of course. I tried that out of curiosity first but that speed gain out of that nerdy bit shifting is indeed quite nice and for this I'll keep that code. That code requires an assumption of the length of the mantissa which is platform depending of course but it should be fine for the common platforms that are using the IEEE-754 floating point numbers and should at maximum limit the precision of the output on other platforms if those even exist.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I changed the string convertion routines for floating points to use integer calculations now, because the integer arithmetic is a lot faster than the repeated floating point multiplications and conversions of the integral part of the mantissa to integers. The generic math of a repeated multiplication of the mantissa with the base for every digit remains the same of course. I tried that out of curiosity first but that speed gain out of that nerdy bit shifting is indeed quite nice and for this I'll keep that code. That code requires an assumption of the length of the mantissa which is platform depending of course but it should be fine for the common platforms that are using the IEEE-754 floating point numbers and should at maximum limit the precision of the output on other platforms if those even exist.
Beta Was this translation helpful? Give feedback.
All reactions