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]

[PATCH][M68K] Fix ICE during scheduling


Hello,

The following rather trivial patch makes scheduler handle CONSTs in general and -mxgot references in particular. Tested on ColdFile GNU/Linux with no regressions. OK for trunk?


Thanks,


MaximK
CodeSourcery
2008-11-19  Maxim Kuvyrkov  <maxim@codesourcery.com>

	* config/m68k/m68k.c (sched_attr_op_type): Handle all CONSTs.

2008-11-19  Maxim Kuvyrkov  <maxim@codesourcery.com>

	* gcc.target/m68k/xgot-1.c (dg-options): Add -O2.
Index: testsuite/gcc.target/m68k/xgot-1.c
===================================================================
--- testsuite/gcc.target/m68k/xgot-1.c	(revision 141996)
+++ testsuite/gcc.target/m68k/xgot-1.c	(working copy)
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options "-fpic -mxgot -mcpu=5206" } */
+/* { dg-options "-O2 -fpic -mxgot -mcpu=5206" } */
 /* { dg-final { scan-assembler "foo@GOT,\%\[ad\]\[0-7\]" } } */
 
 extern int foo;
Index: config/m68k/m68k.c
===================================================================
--- config/m68k/m68k.c	(revision 141996)
+++ config/m68k/m68k.c	(working copy)
@@ -4832,7 +4832,8 @@ sched_attr_op_type (rtx insn, bool opx_p
 	}
     }
 
-  if (symbolic_operand (op, VOIDmode)
+  if (GET_CODE (op) == CONST
+      || symbolic_operand (op, VOIDmode)
       || LABEL_P (op))
     {
       switch (GET_MODE (op))

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