[Bug target/66511] [avr] whole-byte shifts not optimized away for uint64_t
gjl at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Jun 27 18:07:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66511
--- Comment #1 from Georg-Johann Lay <gjl at gcc dot gnu.org> ---
(In reply to Matthijs Kooijman from comment #0)
> I haven't found a readily available 5.x package yet to test.
It's the same.
> As you can see, the versions operating on 64 bit values preserve the
> 8-bit shift (which is very inefficient on AVR), while the versions
> running on 32 bit values simply copy the right registers.
Lib functions are used because users complained about bloated 64-bit
arithmetic.
Notice that indide these 64-bit shift functions byte-shifts are used.
> The foo32_16 function still has some useless instructions (r27 and r26
> are not part of the return value, not sure why these are set) but that
> is probably an unrelated problem.
Yes.
> I've marked this with component "target", since I think these
> optimizations are avr-specific (or at least not applicable to bigger
> architectures).
More information about the Gcc-bugs
mailing list