On 8/29/2022 9:13 AM, Toon Moene wrote:
On 8/29/22 17:08, Jeff Law via Gcc-patches wrote:

However, I'm hoping to forget as many floating point details, as fast
as possible, as soon as I can ;-).

Actually FP isn't that bad -- I'd largely avoided it for decades, but didn't have a choice earlier this year.  And there's a lot more headroom for improvements in the FP space than the integer space IMHO.

One of the more interesting ones is to try to limit the range of the input to the trigonometric functions - that way you could use ones without any argument reduction phase ...
The difficult part is that most of the trig stuff is in libraries, so we don't have visibility into the full range.

What we do sometimes have is knowledge that the special values are already handled which allows us to do things like automatically transform a division into estimation + NR correction steps (atan2).

I guess we could do specialization based on the input range.  So rather than calling "sin" we could call a special one that didn't have the reduction step when we know the input value is in a sensible range.

Jeff

Reply via email to