--- egcs-1.0/gcc/README~ Thu Jan 8 23:30:00 1998 +++ egcs-1.0/gcc/README Fri Jan 30 18:42:45 1998 @@ -1,3 +1,9 @@ +* +* Note: This copy of GCC contains patches and changes which are +* not part of the official GCC distribution. Any comments or bug +* reports should be sent to: +* bugs@linuxppc.org + This directory contains the version 2.8.0 release of the GNU C compiler. It includes all of the support for compiling C++ and Objective C, including a run-time library for Objective C. --- egcs-1.0/gcc/gcc.texi~ Fri Jan 30 19:45:40 1998 +++ egcs-1.0/gcc/gcc.texi Fri Jan 30 19:49:35 1998 @@ -2180,6 +2180,10 @@ @node Bug Lists @section Where to Report Bugs @cindex bug report mailing lists +@kindex bugs@@linuxppc.org +Since this version of GNU C/C++ contains unofficial patches, bugs should +be reported first to @samp{bugs@@linuxppc.org}. + @kindex egcs-bugs@@cygnus.com Send bug reports for GNU C to @samp{egcs-bugs@@cygnus.com}. --- egcs-1.0/gcc/config/rs6000/rs6000.c~ Fri Jan 30 19:45:40 1998 +++ egcs-1.0/gcc/config/rs6000/rs6000.c Fri Jan 30 19:51:09 1998 @@ -2290,16 +2290,54 @@ have been eliminated, but may have crept back in. */ void -rs6000_reorg (insn) - rtx insn; +rs6000_reorg (first_insn) + rtx first_insn; { + rtx insn, next; + if (flag_pic && (DEFAULT_ABI == ABI_V4 || DEFAULT_ABI == ABI_SOLARIS)) { rtx got_reg = gen_rtx (REG, Pmode, GOT_TOC_REGNUM); - for ( ; insn != NULL_RTX; insn = NEXT_INSN (insn)) - if (GET_RTX_CLASS (GET_CODE (insn)) == 'i' - && reg_mentioned_p (got_reg, PATTERN (insn))) - fatal_insn ("GOT/TOC register marker not removed:", PATTERN (insn)); + for (insn = first_insn; insn != NULL_RTX; insn = NEXT_INSN (insn)) + if (GET_RTX_CLASS (GET_CODE (insn)) == 'i' + && reg_mentioned_p (got_reg, PATTERN (insn))) + fatal_insn ("GOT/TOC register marker not removed:", PATTERN (insn)); + } + + + for (insn = first_insn; insn != NULL_RTX; insn = next) + { + next = next_nonnote_insn (insn); + if (GET_CODE (insn) == INSN + && next + && (GET_CODE (next) == JUMP_INSN || GET_CODE (next) == CALL_INSN)) + { + rtx pattern = PATTERN (insn); + + /* On System V ABIs, a call instruction could be 4 or 8 bytes long. + The 8 byte call instruction sets CR1 to indicate whether FP + registers are pushed, which means we don't need the NOP. */ + if ((DEFAULT_ABI == ABI_V4 || DEFAULT_ABI == ABI_SOLARIS) + && GET_CODE (next) == CALL_INSN) + { + if (insn_default_length (next) == 8) + continue; + } + + if ((GET_CODE (pattern) == PARALLEL + && XVECLEN (pattern, 0) == 2 + && GET_CODE (XVECEXP (pattern, 0, 0)) == SET + && GET_CODE (SET_DEST (XVECEXP (pattern, 0, 0))) == MEM + && GET_CODE (XVECEXP (pattern, 0, 1)) == SET + && GET_CODE (SET_DEST (XVECEXP (pattern, 0, 1))) == REG) + || (GET_CODE (pattern) == SET + && GET_CODE (SET_DEST (pattern)) == MEM + && (GET_CODE (XEXP (SET_DEST (pattern), 0)) == PRE_INC + || GET_CODE (XEXP (SET_DEST (pattern), 0)) == PRE_DEC))) + { + emit_insn_after (gen_nop (), insn); + } + } } }