Re:PHP 5.3.3 hangs on numeric value 2.2250738585072011e-308
by scottmac on Wednesday January 05, 2011 @02:58PM
(#2072223)
The copying from the 80-bit register to the 64-bit memory cell is causing the result to be corrupted. When we use volatile it tells the compiler not to apply the optimisation which in this case was putting it in a register.
[ Parent
| on HN ]
Re:PHP 5.3.3 hangs on numeric value 2.2250738585072011e-308
by roel_v on Wednesday January 05, 2011 @03:03PM
(#2072240)
But doesn't that make it a compiler bug? If the root cause is that the compiler truncates data it shouldn't, does that mean the fundamental issue is a compiler bug?
Re:PHP 5.3.3 hangs on numeric value 2.2250738585072011e-308
by scottmac on Wednesday January 05, 2011 @04:02PM
(#2072464)
It's a hardware issue with the x87 instruction set,
http://gcc.gnu.org/ml/gcc/2003-08/msg01195.html is a good explanation.