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] Fix PR8973 for ARC backend


Hi,
	The following patch, made against the ARC back-end in the mainline takes care 
of PR 8973 by updating the flags while returning from an interrupt handler.


Please commit, if OK.


regards
saurabh


ChangeLog
---------

2005-06-10  Saurabh Verma  <saurabh.verma@codito.com>

	PR target/8973
	* config/arc/arc.c (arc_output_function_epilogue): Update flags while
	returning from an interrupt handler.


Index: arc.c
===================================================================
RCS file: /cvsroot/gcc/gcc/gcc/config/arc/arc.c,v
retrieving revision 1.71
diff -p -u -r1.71 arc.c
--- arc.c       26 May 2005 05:27:35 -0000      1.71
+++ arc.c       10 Jun 2005 08:40:58 -0000
@@ -1362,7 +1362,13 @@ arc_output_function_epilogue (FILE *file
        static const int regs[4] = {
          0, RETURN_ADDR_REGNUM, ILINK1_REGNUM, ILINK2_REGNUM
        };
-       fprintf (file, "\tj.d %s\n", reg_names[regs[fn_type]]);
+
+       /* Update the flags, if returning from an interrupt handler. */
+       if (ARC_INTERRUPT_P (fn_type))
+         fprintf (file, "\tj.d.f %s\n", reg_names[regs[fn_type]]);
+       else
+         fprintf (file, "\tj.d %s\n", reg_names[regs[fn_type]]);
+
       }

       /* If the only register saved is the return address, we need a



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