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]

ppc-e500: fix conflicting abi's.


The SPE and AltiVec ABI's cannot co-exist.  This is causing problems
when building the multilibs for powerpc-eabispe.

I have fixed this problem and committed the patch to 3.3-e500,
mainline, and 3.4.

Cheers.

2004-03-07  Aldy Hernandez  <aldyh@redhat.com>

	* config/rs6000/rs6000.c (rs6000_parse_abi_options): SPE and
	AltiVec abi cannot co-exist.

	* config/rs6000/eabispe.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Same.

Index: config/rs6000/rs6000.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/rs6000/rs6000.c,v
retrieving revision 1.601
diff -u -p -r1.601 rs6000.c
--- config/rs6000/rs6000.c	4 Mar 2004 23:19:27 -0000	1.601
+++ config/rs6000/rs6000.c	7 Mar 2004 23:32:19 -0000
@@ -1044,12 +1044,16 @@ rs6000_parse_abi_options (void)
   if (rs6000_abi_string == 0)
     return;
   else if (! strcmp (rs6000_abi_string, "altivec"))
-    rs6000_altivec_abi = 1;
+    {
+      rs6000_altivec_abi = 1;
+      rs6000_spe_abi = 0;
+    }
   else if (! strcmp (rs6000_abi_string, "no-altivec"))
     rs6000_altivec_abi = 0;
   else if (! strcmp (rs6000_abi_string, "spe"))
     {
       rs6000_spe_abi = 1;
+      rs6000_altivec_abi = 0;
       if (!TARGET_SPE_ABI)
 	error ("not configured for ABI: '%s'", rs6000_abi_string);
     }
Index: config/rs6000/eabispe.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/rs6000/eabispe.h,v
retrieving revision 1.5
diff -u -p -r1.5 eabispe.h
--- config/rs6000/eabispe.h	13 Apr 2003 17:51:06 -0000	1.5
+++ config/rs6000/eabispe.h	7 Mar 2004 23:32:19 -0000
@@ -1,6 +1,6 @@
 /* Core target definitions for GNU compiler
    for PowerPC embedded targeted systems with SPE support.
-   Copyright (C) 2002, 2003 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.
    Contributed by Aldy Hernandez (aldyh@redhat.com).
 
    This file is part of GCC.
@@ -30,7 +30,7 @@
 #define SUBSUBTARGET_OVERRIDE_OPTIONS \
   if (rs6000_select[1].string == NULL) \
     rs6000_cpu = PROCESSOR_PPC8540; \
-  if (rs6000_abi_string == NULL || strstr (rs6000_abi_string, "spe") == NULL) \
+  if (rs6000_abi_string == NULL) \
     rs6000_spe_abi = 1; \
   if (rs6000_float_gprs_string == NULL) \
     rs6000_float_gprs = 1; \


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