http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57260
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|major |normal --- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #3) > Looks like sibcalls are incorrectly done. Or maybe not since it is no longer a call but rather a sibcall which means it can never be using call16 here since it is not a real call. Smallest testcase: int shouldbecall16(void); int g(void) { return shouldbecall16(); } ---- CUT --- lui $3,%hi(%neg(%gp_rel(g))) daddu $3,$3,$25 daddiu $3,$3,%lo(%neg(%gp_rel(g))) ld $25,%got_disp(shouldbecall16)($3) .reloc 1f,R_MIPS_JALR,shouldbecall16 1: jr $25 nop Notice it is a jr rather than a jalr. I think this is correct behavior either way really. I think Xorg's sources are depending on undefined behavior dealing with undefined symbols.