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

--- Comment #11 from Katsunori Kumatani <katsunori.kumatani at gmail dot com> 
---
Sorry, one small thing I need to mention in case it's not obvious at first
glance.

The GCC 6 vs GCC 5 portion of code I showed has *exactly* the same behavior.
It's not that it "uses the value later that's why it loads it twice".

After the portion of that code, the state of everything is in exactly the same
condition, but GCC 6 has two extra instructions compared to 5 and uses an extra
register. My fear is, of course, that those two extra instructions use an
additional register. So the real problem would come from having all 8 registers
used and having to spill %st(7) needlessly. Basically, it's not just 2 extra
(useless) instructions, but an extra register being used for no reason (which
is my main issue).

And yes x87 tends to be slower than SSE on most processors (except some AMD
ones), which is why it would be nice to have it solved and have it back like
GCC 5... if it's already bad enough I hope it doesn't become worse :)

Reply via email to