about summary refs log tree commit diff
path: root/sysdeps/unix/sysv
diff options
context:
space:
mode:
authorZack Weinberg <zackw@panix.com>2019-05-16 13:34:27 -0400
committerZack Weinberg <zackw@panix.com>2019-05-22 10:05:40 -0400
commita053e878494080f7070cf92890e546057236c9c9 (patch)
treec906e6ed1cb5ffd3f7ea460d521bd8317e8d855b /sysdeps/unix/sysv
parent46ae07324b1cd50fbf8f37a076d6babcfca7c510 (diff)
downloadglibc-a053e878494080f7070cf92890e546057236c9c9.tar.gz
glibc-a053e878494080f7070cf92890e546057236c9c9.tar.xz
glibc-a053e878494080f7070cf92890e546057236c9c9.zip
Remove support for PowerPC SPE extension (powerpc*-*-*gnuspe*).
GCC 9 dropped support for the SPE extensions to PowerPC, which means
powerpc*-*-*gnuspe* configurations are no longer buildable with that
compiler.  This ISA extension was peculiar to the “e500” line of
embedded PowerPC chips, which, as far as I can tell, are no longer
being manufactured, so I think we should follow suit.

This patch was developed by grepping for “e500”, “__SPE__”, and
“__NO_FPRS__”, and may not eliminate every vestige of SPE support.
Most uses of __NO_FPRS__ are left alone, as they are relevant to
normal embedded PowerPC with soft-float.

        * sysdeps/powerpc/preconfigure: Error out on powerpc-*-*gnuspe*
        host type.
        * scripts/build-many-glibcs.py: Remove powerpc-*-linux-gnuspe
        and powerpc-*-linux-gnuspe-e500v1 from list of build configurations.

        * sysdeps/powerpc/powerpc32/e500: Recursively delete.
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500: Recursively delete.
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/context-e500.h:
        Delete.

        * sysdeps/powerpc/fpu_control.h: Remove SPE variant.
        Issue an #error if used with a compiler in SPE-float mode.
        * sysdeps/powerpc/powerpc32/__longjmp_common.S
        * sysdeps/powerpc/powerpc32/setjmp_common.S
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/getcontext.S
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/setcontext.S
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/swapcontext.S
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
        * sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S:
        Remove code to preserve SPE register state.

        * sysdeps/unix/sysv/linux/powerpc/elision-lock.c
        * sysdeps/unix/sysv/linux/powerpc/elision-trylock.c
        * sysdeps/unix/sysv/linux/powerpc/elision-unlock.c
        Remove __SPE__ ifndefs.
Diffstat (limited to 'sysdeps/unix/sysv')
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/elision-lock.c2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/elision-trylock.c2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/elision-unlock.c4
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/nofpu/Implies2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S4
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/context-e500.h144
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/getcontext.S2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/setcontext.S2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/swapcontext.S2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S4
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S8
11 files changed, 0 insertions, 176 deletions
diff --git a/sysdeps/unix/sysv/linux/powerpc/elision-lock.c b/sysdeps/unix/sysv/linux/powerpc/elision-lock.c
index f0e3dcab76..7564507890 100644
--- a/sysdeps/unix/sysv/linux/powerpc/elision-lock.c
+++ b/sysdeps/unix/sysv/linux/powerpc/elision-lock.c
@@ -45,7 +45,6 @@
 int
 __lll_lock_elision (int *lock, short *adapt_count, EXTRAARG int pshared)
 {
-#ifndef __SPE__
   /* adapt_count is accessed concurrently but is just a hint.  Thus,
      use atomic accesses but relaxed MO is sufficient.  */
   if (atomic_load_relaxed (adapt_count) > 0)
@@ -83,6 +82,5 @@ __lll_lock_elision (int *lock, short *adapt_count, EXTRAARG int pshared)
 			  aconf.skip_lock_out_of_tbegin_retries);
 
 use_lock:
-#endif
   return LLL_LOCK ((*lock), pshared);
 }
diff --git a/sysdeps/unix/sysv/linux/powerpc/elision-trylock.c b/sysdeps/unix/sysv/linux/powerpc/elision-trylock.c
index 72d707f7e6..edcf7f423d 100644
--- a/sysdeps/unix/sysv/linux/powerpc/elision-trylock.c
+++ b/sysdeps/unix/sysv/linux/powerpc/elision-trylock.c
@@ -30,7 +30,6 @@
 int
 __lll_trylock_elision (int *futex, short *adapt_count)
 {
-#ifndef __SPE__
   /* Implement POSIX semantics by forbiding nesting elided trylocks.  */
   __libc_tabort (_ABORT_NESTED_TRYLOCK);
 
@@ -66,6 +65,5 @@ __lll_trylock_elision (int *futex, short *adapt_count)
     }
 
 use_lock:
-#endif
   return lll_trylock (*futex);
 }
diff --git a/sysdeps/unix/sysv/linux/powerpc/elision-unlock.c b/sysdeps/unix/sysv/linux/powerpc/elision-unlock.c
index 18ec23fa64..0665cb005e 100644
--- a/sysdeps/unix/sysv/linux/powerpc/elision-unlock.c
+++ b/sysdeps/unix/sysv/linux/powerpc/elision-unlock.c
@@ -23,7 +23,6 @@
 int
 __lll_unlock_elision (int *lock, short *adapt_count, int pshared)
 {
-#ifndef __SPE__
   /* When the lock was free we're in a transaction.  */
   if (*lock == 0)
     __libc_tend (0);
@@ -40,8 +39,5 @@ __lll_unlock_elision (int *lock, short *adapt_count, int pshared)
 
       lll_unlock ((*lock), pshared);
     }
-#else
-  lll_unlock ((*lock), pshared);
-#endif
   return 0;
 }
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/nofpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/nofpu/Implies
deleted file mode 100644
index aab22f212c..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/nofpu/Implies
+++ /dev/null
@@ -1,2 +0,0 @@
-powerpc/powerpc32/e500/nofpu
-powerpc/nofpu
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
index 9fde4ac29f..f7979c8262 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
@@ -262,10 +262,6 @@ ENTRY(__CONTEXT_FUNC_NAME)
 # endif
 #endif
 
-#ifdef __CONTEXT_ENABLE_E500
-	getcontext_e500
-#endif
-
 /* We need to set up parms and call sigprocmask which will clobber
    volatile registers. So before the call we need to retrieve the
    original ucontext ptr (parm1) from stack and store the UC_REGS_PTR
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/context-e500.h b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/context-e500.h
deleted file mode 100644
index ef53f7c069..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/context-e500.h
+++ /dev/null
@@ -1,144 +0,0 @@
-/* getcontext/setcontext/makecontext support for e500 high parts of registers.
-   Copyright (C) 2006-2019 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Lesser General Public
-   License as published by the Free Software Foundation; either
-   version 2.1 of the License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Lesser General Public License for more details.
-
-   You should have received a copy of the GNU Lesser General Public
-   License along with the GNU C Library; if not, see
-   <http://www.gnu.org/licenses/>.  */
-
-#ifndef _CONTEXT_E500_H
-#define _CONTEXT_E500_H 1
-
-#if defined __SPE__ || (defined __NO_FPRS__ && !defined _SOFT_FLOAT)
-
-# define __CONTEXT_ENABLE_E500 1
-
-/* We follow the kernel's layout, which saves the high parts of the
-   SPE registers in the vregs area, immediately followed by the ACC
-   value (call-clobbered, not handled here) and the SPEFSCR value.  */
-
-.macro getcontext_e500
-	la	r10,(_UC_VREGS)(r3)
-	evstwwe	r0,(0*4)(r10)
-	evstwwe	r1,(1*4)(r10)
-	evstwwe	r2,(2*4)(r10)
-	evstwwe	r3,(3*4)(r10)
-	evstwwe	r4,(4*4)(r10)
-	evstwwe	r5,(5*4)(r10)
-	evstwwe	r6,(6*4)(r10)
-	evstwwe	r7,(7*4)(r10)
-	evstwwe	r8,(8*4)(r10)
-	evstwwe	r9,(9*4)(r10)
-	evstwwe	r10,(10*4)(r10)
-	evstwwe	r11,(11*4)(r10)
-	evstwwe	r12,(12*4)(r10)
-	evstwwe	r13,(13*4)(r10)
-	evstwwe	r14,(14*4)(r10)
-	evstwwe	r15,(15*4)(r10)
-	evstwwe	r16,(16*4)(r10)
-	evstwwe	r17,(17*4)(r10)
-	evstwwe	r18,(18*4)(r10)
-	evstwwe	r19,(19*4)(r10)
-	evstwwe	r20,(20*4)(r10)
-	evstwwe	r21,(21*4)(r10)
-	evstwwe	r22,(22*4)(r10)
-	evstwwe	r23,(23*4)(r10)
-	evstwwe	r24,(24*4)(r10)
-	evstwwe	r25,(25*4)(r10)
-	evstwwe	r26,(26*4)(r10)
-	evstwwe	r27,(27*4)(r10)
-	evstwwe	r28,(28*4)(r10)
-	evstwwe	r29,(29*4)(r10)
-	evstwwe	r30,(30*4)(r10)
-	evstwwe	r31,(31*4)(r10)
-	mfspefscr	r9
-	stw	r9,(34*4)(r10)
-.endm
-
-.macro setcontext_e500
-	lwz	r3,_UC_VREGS+(0*4)(r31)
-	evmergelo	r0,r3,r0
-	lwz	r3,_UC_VREGS+(1*4)(r31)
-	evmergelo	r1,r3,r1
-	lwz	r3,_UC_VREGS+(2*4)(r31)
-	evmergelo	r2,r3,r2
-	lwz	r3,_UC_VREGS+(1*4)(r31)
-	evmergelo	r1,r3,r1
-	lwz	r3,_UC_VREGS+(2*4)(r31)
-	evmergelo	r2,r3,r2
-	lwz	r3,_UC_VREGS+(3*4)(r31)
-	evmergelo	r3,r3,r3
-	lwz	r3,_UC_VREGS+(4*4)(r31)
-	evmergelo	r4,r3,r4
-	lwz	r3,_UC_VREGS+(5*4)(r31)
-	evmergelo	r5,r3,r5
-	lwz	r3,_UC_VREGS+(6*4)(r31)
-	evmergelo	r6,r3,r6
-	lwz	r3,_UC_VREGS+(7*4)(r31)
-	evmergelo	r7,r3,r7
-	lwz	r3,_UC_VREGS+(8*4)(r31)
-	evmergelo	r8,r3,r8
-	lwz	r3,_UC_VREGS+(9*4)(r31)
-	evmergelo	r9,r3,r9
-	lwz	r3,_UC_VREGS+(10*4)(r31)
-	evmergelo	r10,r3,r10
-	lwz	r3,_UC_VREGS+(11*4)(r31)
-	evmergelo	r11,r3,r11
-	lwz	r3,_UC_VREGS+(12*4)(r31)
-	evmergelo	r12,r3,r12
-	lwz	r3,_UC_VREGS+(13*4)(r31)
-	evmergelo	r13,r3,r13
-	lwz	r3,_UC_VREGS+(14*4)(r31)
-	evmergelo	r14,r3,r14
-	lwz	r3,_UC_VREGS+(15*4)(r31)
-	evmergelo	r15,r3,r15
-	lwz	r3,_UC_VREGS+(16*4)(r31)
-	evmergelo	r16,r3,r16
-	lwz	r3,_UC_VREGS+(17*4)(r31)
-	evmergelo	r17,r3,r17
-	lwz	r3,_UC_VREGS+(18*4)(r31)
-	evmergelo	r18,r3,r18
-	lwz	r3,_UC_VREGS+(19*4)(r31)
-	evmergelo	r19,r3,r19
-	lwz	r3,_UC_VREGS+(20*4)(r31)
-	evmergelo	r20,r3,r20
-	lwz	r3,_UC_VREGS+(21*4)(r31)
-	evmergelo	r21,r3,r21
-	lwz	r3,_UC_VREGS+(22*4)(r31)
-	evmergelo	r22,r3,r22
-	lwz	r3,_UC_VREGS+(23*4)(r31)
-	evmergelo	r23,r3,r23
-	lwz	r3,_UC_VREGS+(24*4)(r31)
-	evmergelo	r24,r3,r24
-	lwz	r3,_UC_VREGS+(25*4)(r31)
-	evmergelo	r25,r3,r25
-	lwz	r3,_UC_VREGS+(26*4)(r31)
-	evmergelo	r26,r3,r26
-	lwz	r3,_UC_VREGS+(27*4)(r31)
-	evmergelo	r27,r3,r27
-	lwz	r3,_UC_VREGS+(28*4)(r31)
-	evmergelo	r28,r3,r28
-	lwz	r3,_UC_VREGS+(29*4)(r31)
-	evmergelo	r29,r3,r29
-	lwz	r3,_UC_VREGS+(30*4)(r31)
-	evmergelo	r30,r3,r30
-	lwz	r3,_UC_VREGS+(31*4)(r31)
-	evmergelo	r31,r3,r31
-	lwz	r3,_UC_VREGS+(34*4)(r31)
-	mtspefscr	r3
-.endm
-#else
-# undef __CONTEXT_ENABLE_E500
-#endif
-
-#endif /* context-e500.h */
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/getcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/getcontext.S
index 7a0aa934d1..fc7bbf561f 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/getcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/getcontext.S
@@ -24,8 +24,6 @@
 #include <asm/ptrace.h>
 #include "ucontext_i.h"
 
-#include <context-e500.h>
-
 #define __CONTEXT_FUNC_NAME __getcontext
 #undef __CONTEXT_ENABLE_FPRS
 #undef __CONTEXT_ENABLE_VRS
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/setcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/setcontext.S
index 0f798fd1fb..01ee68aa5a 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/setcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/setcontext.S
@@ -24,8 +24,6 @@
 #include <asm/ptrace.h>
 #include "ucontext_i.h"
 
-#include <context-e500.h>
-
 #define __CONTEXT_FUNC_NAME __setcontext
 #undef __CONTEXT_ENABLE_FPRS
 #undef __CONTEXT_ENABLE_VRS
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/swapcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/swapcontext.S
index fb34390127..3e775be6b6 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/swapcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/swapcontext.S
@@ -24,8 +24,6 @@
 #include <asm/ptrace.h>
 #include "ucontext_i.h"
 
-#include <context-e500.h>
-
 #define __CONTEXT_FUNC_NAME __swapcontext
 #undef __CONTEXT_ENABLE_FPRS
 #undef __CONTEXT_ENABLE_VRS
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
index 47235dd0cb..b370391863 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
@@ -228,10 +228,6 @@ ENTRY(__CONTEXT_FUNC_NAME)
 	lfd	fp31,_UC_FREGS+(31*8)(r31)
 #endif /* __CONTEXT_ENABLE_FPRS */
 
-#ifdef __CONTEXT_ENABLE_E500
-	setcontext_e500
-#endif
-
 	/* Restore LR and CCR, and set CTR to the NIP value */
 	lwz	r3,_UC_GREGS+(PT_LNK*4)(r31)
 	lwz	r4,_UC_GREGS+(PT_NIP*4)(r31)
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
index e0fd249615..efebb10bba 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
@@ -265,10 +265,6 @@ ENTRY(__CONTEXT_FUNC_NAME)
 # endif /* __CONTEXT_ENABLE_VRS */
 #endif /* __CONTEXT_ENABLE_FPRS */
 
-#ifdef __CONTEXT_ENABLE_E500
-	getcontext_e500
-#endif
-
 /* Restore ucontext (parm1) from stack.  */
 	lwz	r12,_FRAME_PARM_SAVE1(r1)
 	lwz	r4,_FRAME_PARM_SAVE2(r1)
@@ -451,10 +447,6 @@ ENTRY(__CONTEXT_FUNC_NAME)
 	lfd	fp31,_UC_FREGS+(31*8)(r31)
 #endif /* __CONTEXT_ENABLE_FPRS */
 
-#ifdef __CONTEXT_ENABLE_E500
-	setcontext_e500
-#endif
-
 	/* Restore LR and CCR, and set CTR to the NIP value */
 	lwz	r3,_UC_GREGS+(PT_LNK*4)(r31)
 	lwz	r4,_UC_GREGS+(PT_NIP*4)(r31)