------- Comment #5 from danglin at gcc dot gnu dot org 2008-09-21 18:31 ------- This is also failing on hppa-unknown-linux-gnu. It uses the define in elfos.h. assemble_external is not called. It looks like output_operand is wrong:
output_operand (rtx x, int code ATTRIBUTE_UNUSED) { if (x && GET_CODE (x) == SUBREG) x = alter_subreg (&x); /* X must not be a pseudo reg. */ gcc_assert (!x || !REG_P (x) || REGNO (x) < FIRST_PSEUDO_REGISTER); PRINT_OPERAND (asm_out_file, x, code); if (x && MEM_P (x) && GET_CODE (XEXP (x, 0)) == SYMBOL_REF) { tree t; x = XEXP (x, 0); t = SYMBOL_REF_DECL (x); if (t) assemble_external (t); } } Breakpoint 4, output_operand (x=0x40146480, code=72) at ../../gcc/gcc/final.c:3365 3365 if (x && GET_CODE (x) == SUBREG) (gdb) p debug_rtx (x) (symbol_ref:SI ("foo") [flags 0x42] <var_decl 0x400e70b0 foo>) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37202