This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: sparc.c bogus comparison



> On Fri, Jan 25, 2002 at 05:09:34PM -0500, DJ Delorie wrote:
> > Shouldn't the above be thusly?
> > 
> >       if (rtx_equal_p (temp1, op0))
> > 	abort ();
> 
> Almost certainly.

Ok, then I'll check this in as almost obvious ;-)

2002-01-25  DJ Delorie  <dj@redhat.com>

	* config/sparc/sparc.c (sparc_emit_set_symbolic_const64): Compare
	using rtx_equal_p, not by comparing pointers.

Index: config/sparc/sparc.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/sparc/sparc.c,v
retrieving revision 1.178
diff -p -3 -r1.178 sparc.c
*** sparc.c	2002/01/16 17:44:22	1.178
--- sparc.c	2002/01/26 02:06:31
*************** sparc_emit_set_symbolic_const64 (op0, op
*** 1423,1429 ****
  	 We _MUST_ have a separate temporary at this point,
  	 if we don't barf immediately instead of generating
  	 incorrect code.  */
!       if (temp1 == op0)
  	abort ();
  
        emit_insn (gen_sethh (op0, op1));
--- 1423,1429 ----
  	 We _MUST_ have a separate temporary at this point,
  	 if we don't barf immediately instead of generating
  	 incorrect code.  */
!       if (rtx_equal_p (temp1, op0))
  	abort ();
  
        emit_insn (gen_sethh (op0, op1));


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]