News for hackers. Stuff that matters.
Re:Searching for fast complex numbers in C99 and C++ by s__mac on Wednesday July 19, 2017 @01:15PM (#14805925)
I submitted a bug report to GCC:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81478

Even though it's not a real bug, it's a missed optimization. My pitch is to emit the code to do the multiplication, and only call a fixup function when the results are NaN. If you short-circuit the NaN check, you only need 3 pretty cheap instructions to decide to call the standard library for help, and you can avoid it in the vast vast majority of cases. This should make multiplication and division much faster in the default case. Naturally the checks would still be elided with -fcx-limited-range is on.

There are no comments on this comment yet.