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: [mips] generate PIC jump tables for n32 and n64


On Oct 24, 2002, Alexandre Oliva <aoliva@redhat.com> wrote:

> Index: gcc/ChangeLog
> from  Alexandre Oliva  <aoliva@redhat.com>

> 	* config.gcc (tm_defines): Define HAVE_GNU_AS and HAVE_GNU_LD.
> 	* config/mips/mips.h (ASM_OUTPUT_ADDR_DIFF_ELT): Output
> 	.gpword/.gpdword for ABI_N32 and ABI_64 too.
> 	* config/mips/mips.md (tablejump_internal3): Output .cpadd
> 	before jump on ABI_N32 too.
> 	(tablejump_internal4): Ditto on ABI_64.  Increase maximum
> 	length to match.

Ping?


Meanwhile, I'm installing this obviously-correct patch that silences
some warnings in the assembler.  All other call sequences were already
correct.

Index: gcc/ChangeLog
from  Alexandre Oliva  <aoliva@redhat.com>

	* config/mips/mips.md (call_value_multiple_internal2): Use dla for
	non-SImode addresses.

Index: gcc/config/mips/mips.md
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/mips/mips.md,v
retrieving revision 1.149
diff -u -p -r1.149 mips.md
--- gcc/config/mips/mips.md 29 Oct 2002 13:47:10 -0000 1.149
+++ gcc/config/mips/mips.md 6 Nov 2002 17:54:52 -0000
@@ -1,6 +1,6 @@
 ;;  Mips.md	     Machine Description for MIPS based processors
 ;;  Copyright (C) 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-;;  1999, 2000, 2001 Free Software Foundation, Inc.
+;;  1999, 2000, 2001, 2002 Free Software Foundation, Inc.
 ;;  Contributed by   A. Lichnewsky, lich@inria.inria.fr
 ;;  Changes by       Michael Meissner, meissner@osf.org
 ;;  64 bit r4000 support by Ian Lance Taylor, ian@cygnus.com, and
@@ -10558,7 +10565,7 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\\n
       if (GET_MODE (target) == SImode)
 	return \"la\\t%^,%1\\n\\tjal\\t%4,%^\";
       else
-	return \"la\\t%^,%1\\n\\tjal\\t%4,%^\";
+	return \"dla\\t%^,%1\\n\\tjal\\t%4,%^\";
     }
   else if (REGNO (target) != PIC_FUNCTION_ADDR_REGNUM)
     return \"move\\t%^,%1\\n\\tjal\\t%4,%^\";
-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer

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