|
|
|
|
|
by MauranKilom
1478 days ago
|
|
> The second code can probably become SIMD as well, but it's beyond GCC's ability to autovectorizer it in that form. Usually, for floating point operations the compiler simply has no chance to do anything clever. NaNs, infinities and signed zero mean that even the most "obvious" identities don't actually hold. For example, x + 0 == x (where the == is bitwise) does not hold for x = -0. |
|
But when operating on floating point numbers, == is not bitwise, and -0 == +0.