http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46820
Richard Guenther <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2010.12.07 11:50:31 Ever Confirmed|0 |1 --- Comment #6 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-12-07 11:50:31 UTC --- The problem is we partition the toplevel asm away from the function it is refering to. int __attribute__((used)) bar(void) { return 0; } __asm__(".weak\tfoo\n\t.set\tfoo,bar"); bar ends up in a different partition than the asm which then of course doesn't work. I'm not sure we can do much about this. Aliases via toplevel asms (or toplevel asms in general) are hard to deal with with WHOPR. Honza, any ideas? The testcase seems to work fine using the linker-plugin and gold, btw. Not sure if by design or only by chance though. We definitely get different partitioning - which shouldn't happen with 1to1 partitioning, no?