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

--- Comment #3 from Matthijs Kooijman <matthijs at stdin dot nl> ---
Thanks for digging into this :-D

I suppose you meant
https://gcc.gnu.org/viewcvs/gcc?view=revision&revision=242907 instead of the
commit you linked (which is also nice btw, I noticed that extra sbiw in some
places as well).

Looking at the generated assembly, the optimizations look like fairly simple
(composable) translations, but I assume that the optimization needs to happen
before/while the assembly is generated, not afterwards. And then I can see that
the patterns would indeed become complex.

My goal was indeed to compose values. Using a union is endian-dependent, which
is a downside.

If I understand your vector-example correctly, vectors are always stored as big
endian, so using this approach would be portable? I couldn't find anything
about this in the documentation, though.

Reply via email to