Should asm("" : : : "memory") order accesses to the GOT?

Franz Sirl Franz.Sirl-kernel@lauterbach.com
Thu Jun 17 14:17:00 GMT 1999


Am Don, 17 Jun 1999 schrieb David S. Miller:
>From: Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
>   Date: Thu, 17 Jun 1999 21:57:36 +0200
>
>   the subject says it all, should address loads from the GOT
>   considered as memory accesses?
>
>Try adding __volatile__, it might do the trick.

sorry, I should have been exact, I already used __volatile__. The only dirty
trick I found so far is to clobber the PIC register.

BTW, don't you have problems with glibc-2.1.1 and gcc-2.95pre on Sparc? On PPC
the addresses of _dl_rtld_map and _dl_debug_statistics are loaded out of the
GOT before the ELF_DYNAMIC_RELOCATE happens in _dl_start(). I think the
cleanest solution is to move the end of _dl_start() to a separate file.

Franz.


More information about the Gcc mailing list