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

--- Comment #3 from Andrey Prokopenko <aprokop at sandia dot gov> ---
Andrew,

Could you please point out the rule? I cannot find it. I also see that Intel
x86/64 reference manual states in section 4.1.1 that 

~~~
Words, doublewords, and quadwords do not need to be aligned in memory on
natural boundaries. The natural boundaries for words, double words, and
quadwords are even-numbered addresses, addresses evenly divisible by four, and
addresses evenly divisible by eight, respectively. However, to improve the
performance of programs, data structures (especially stacks) should be aligned
on natural boundaries whenever possible. The reason for this is that the
processor requires two memory accesses to make an unaligned memory access;
aligned accesses require only one memory access. A word or doubleword operand
that crosses a 4-byte boundary or a quadword operand that crosses an 8-byte
boundary is considered unaligned and requires two separate memory bus cycles
for access.
~~~

Reply via email to