Floating point numbers, and why they suck
riskledger.com
Floating point numbers, and why they suck
1–10 of 46 posts
Re: Floating point numbers, and why they suck
#2Re: Floating point numbers, and why they suck
#3Do we ever need to store floats? using them in flight is one thing, but stored data so often needs to be some fixed precision.
Re: Floating point numbers, and why they suck
#4Actually I wonder if anybody did a performance/power comparison of using floating point vs fixed point math in some common tasks using modern CPUs with extensive FP support.
Re: Floating point numbers, and why they suck
#5Floating point behaviors are well understood. This type of problem shouldn’t happen if your developers are qualified.
Re: Floating point numbers, and why they suck
#6Once we finally move away from binary floats, these nasty binary-exponent-decimal-exponent lossy conversions will end (as will the horribly complicated nasty scanf and printf algorithms).
This is a solved problem. Our actual problem now is momentum of adoption.
I've anticipated that this will eventually happen (hopefully sooner rather than later), and proactively marked binary floats as "legacy formats" [2].
[1] https://en.wikipedia.org/wiki/Decimal64_floating-point_forma...
[2] https://github.com/kstenerud/concise-encoding/blob/master/ce...
Re: Floating point numbers, and why they suck
#7I wish that fixed point numbers (as in Qx.y) was a first class citizen in programming languages. As well as saturation arithmetic. Actually I wonder if anybody did a performance/power comparison of using floating point vs fixed point math in some common tasks using modern CPUs with extensive FP support.