Internal error in current CVS tree

Joern Rennecke amylaar@cygnus.co.uk
Wed Sep 16 13:51:00 GMT 1998


> I'm getting:
> 
> stage1/xgcc -Bstage1/ -c  -DIN_GCC    -W -Wall -O2 -g -O2  -W -Wall    -I. -I.. -I../../../gcc/f -I../../../gcc/f/.. -I../../../gcc/f/../config ../../../gcc/f/data.c
> ../../gcc/expr.c:2421: Internal compiler error in function emit_move_insn
> 
> on x86-linux-gnu at the moment.  I suspect the recent regmove changes
> since the call to emit_move_insn is coming from copy_src_to_dest in
> regmove.c.  The reason for the crash is that one REG is DImode while
> the other is SImode.

I propose the following patch:

Wed Sep 16 20:31:29 1998  J"orn Rennecke <amylaar@cygnus.co.uk>

	* regmove.c (copy_src_to_dest): Check that modes match.

Index: regmove.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/regmove.c,v
retrieving revision 1.36
diff -p -r1.36 regmove.c
*** regmove.c	1998/09/16 06:49:57	1.36
--- regmove.c	1998/09/16 19:32:03
*************** copy_src_to_dest (insn, src, dest, loop_
*** 617,623 ****
        && GET_CODE (dest) == REG
        && REG_LIVE_LENGTH (REGNO (dest)) > 0
        && (set = single_set (insn)) != NULL_RTX
!       && !reg_mentioned_p (dest, SET_SRC (set)))
      {
        int old_num_regs = reg_rtx_no;
  
--- 617,624 ----
        && GET_CODE (dest) == REG
        && REG_LIVE_LENGTH (REGNO (dest)) > 0
        && (set = single_set (insn)) != NULL_RTX
!       && !reg_mentioned_p (dest, SET_SRC (set))
!       && GET_MODE (src) == GET_MODE (dest))
      {
        int old_num_regs = reg_rtx_no;
  



More information about the Gcc-bugs mailing list