Fourth Draft "Unsafe fp optimizations" project description.
Linus Torvalds
torvalds@transmeta.com
Tue Aug 14 09:54:00 GMT 2001
On Tue, 14 Aug 2001 dewar@gnat.com wrote:
>
> The issue is not accuracy in general, but the requirement that there not
> be a single case in which the result from the hardware is outside ther
> required model interval specified in the ARM. I looked at the Intel
> documentation quite a while ago, and it was statistical in nature,
> and did not have any absolute guarantees. That's what worried me.
I think they _do_ guarantee it, at least for "round to nearest". Just by
virtue of guaranteeing "less than 1 ULP error",
Because, if (for example) "sin()" ever returned a value ourside of [-1,1],
then that would obviously be an error of AT LEAST 1 ULP. Which is a bigger
error than the largest they guarantee. Ergo, the high accuracy guarantees
that they stay in the proper domain.
And they guarantee this for the entire range that they accept as inputs.
There could be bugs, of course. But hey, that's true of _anybody_, so that
argument is absolutely never a valid argument for saying "so we should do
it by hand".
Linus
More information about the Gcc
mailing list