https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70146
--- Comment #4 from H.J. Lu <hjl.tools at gmail dot com> --- (In reply to Andy Lutomirski from comment #3) > I think a similar optimization could be applied to default-visibility > references as well. For example, gcc can generate things like this: > > call __x86.get_pc_thunk.ax > addl $_GLOBAL_OFFSET_TABLE_, %eax > movl foo@GOT(%eax), %eax > > The addl is unnecessary. Yes, GCC does it for MacOS.