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: use tablejump_p more places


On Fri, Apr 04, 2003 at 03:37:45PM -0500, John David Anglin wrote:
> The code in cse.c previously checked insn to see if it was 0.

So it did.  Fixed thus.


r~


        * cse.c (fold_rtx): Fix 03-30 change; do check insn non-null.

Index: cse.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cse.c,v
retrieving revision 1.257
diff -c -p -d -u -r1.257 cse.c
--- cse.c	30 Mar 2003 20:46:56 -0000	1.257
+++ cse.c	4 Apr 2003 21:47:27 -0000
@@ -3354,7 +3354,7 @@ fold_rtx (x, insn)
 	 lets us fold switch statements on the VAX.  */
       {
 	rtx next;
-	if (tablejump_p (insn, &next, NULL))
+	if (insn && tablejump_p (insn, &next, NULL))
 	  return gen_rtx_LABEL_REF (Pmode, next);
       }
       break;


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