[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] struct align




No, the alignment is decided based on what the CPU requires and which
is faster.
[...]

I see your point, I know all this stuff. I was wondering why gcc/68k does this -- for CPU >= 68020 (definitely for 060) is faster to align stuff on 4 bytes boundaries (16 bytes if reading bigger chunks). So either gcc is such smart and it sees I'm picking up values one-by-one in that order (but this doesn't explain that gap for 2 bytes align) or gcc simply should align it on 4 byte boundary when it's long variable. Or do you have any other explanation for it? I don't say gcc is wrong I just want to know the reason why it behaves in this way :)

--
MiKRO / Mystic Bytes
http://mikro.atari.org