http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48598
Summary: x86 backend fails to properly mark memory alignment Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target AssignedTo: unassig...@gcc.gnu.org ReportedBy: hjl.to...@gmail.com [hjl@gnu-6 pr1000]$ cat p.i extern const unsigned char __popcount_tab[256]; int __popcountdi2 (unsigned long long x) { int i, ret = 0; for (i = 0; i < (8 * 8); i += 8) ret += __popcount_tab[(x >> i) & 0xff]; return ret; } [hjl@gnu-6 pr1000]$ gcc -O2 -fPIC p.i -S -da (insn 19 18 20 (set (reg/f:DI 108) (mem/u/c:DI (const:DI (unspec:DI [ (symbol_ref:DI ("__popcount_tab") [flags 0x40] <var_dec l 0x7ffff210e000 __popcount_tab>) ] UNSPEC_GOTPCREL)) [2 S8 A8])) p.i:8 -1 (nil)) __popcount_tab should be marked with 64bit alignment.