about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--sysdeps/mips/__longjmp.c4
-rw-r--r--sysdeps/mips/bsd-_setjmp.S6
-rw-r--r--sysdeps/mips/bsd-setjmp.S6
-rw-r--r--sysdeps/mips/setjmp.S8
-rw-r--r--sysdeps/unix/mips/pipe.S5
5 files changed, 14 insertions, 15 deletions
diff --git a/sysdeps/mips/__longjmp.c b/sysdeps/mips/__longjmp.c
index e9ef5cff3d..a1920ca257 100644
--- a/sysdeps/mips/__longjmp.c
+++ b/sysdeps/mips/__longjmp.c
@@ -69,7 +69,7 @@ __longjmp (env, val_arg)
   asm volatile ("lw $23, %0" : : "m" (env[0].__regs[7]));
 
   /* Get the PC.  */
-  asm volatile ("lw $31, %0" : : "m" (env[0].__pc));
+  asm volatile ("lw $25, %0" : : "m" (env[0].__pc));
 
   /* Give setjmp 1 if given a 0, or what they gave us if non-zero.  */
   if (val == 0)
@@ -77,7 +77,7 @@ __longjmp (env, val_arg)
   else
     asm volatile ("move $2, %0" : : "r" (val));
 
-  asm volatile ("j $31");
+  asm volatile ("jr $25");
 
   /* Avoid `volatile function does return' warnings.  */
   for (;;);
diff --git a/sysdeps/mips/bsd-_setjmp.S b/sysdeps/mips/bsd-_setjmp.S
index 6d841fc237..bf7cb159fa 100644
--- a/sysdeps/mips/bsd-_setjmp.S
+++ b/sysdeps/mips/bsd-_setjmp.S
@@ -1,5 +1,5 @@
 /* BSD `_setjmp' entry point to `sigsetjmp (..., 0)'.  MIPS version.
-   Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+   Copyright (C) 1996, 1997, 2000 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
@@ -23,12 +23,12 @@
 
 #include <sysdep.h>
 
-#ifdef PIC
+#ifdef __PIC__
 	.option pic2
 #endif
 ENTRY (_setjmp)
 	.set noreorder
-#ifdef PIC
+#ifdef __PIC__
 	.cpload t9
 	la	t9, C_SYMBOL_NAME (__sigsetjmp)
 	jr	t9
diff --git a/sysdeps/mips/bsd-setjmp.S b/sysdeps/mips/bsd-setjmp.S
index 000aee436a..bab312b0df 100644
--- a/sysdeps/mips/bsd-setjmp.S
+++ b/sysdeps/mips/bsd-setjmp.S
@@ -1,5 +1,5 @@
 /* BSD `setjmp' entry point to `sigsetjmp (..., 1)'.  MIPS version.
-   Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+   Copyright (C) 1996, 1997, 2000 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
@@ -23,12 +23,12 @@
 
 #include <sysdep.h>
 
-#ifdef PIC
+#ifdef __PIC__
 	.option pic2
 #endif
 ENTRY (setjmp)
 	.set	noreorder
-#ifdef PIC
+#ifdef __PIC__
 	.cpload t9
 	la	t9, C_SYMBOL_NAME (__sigsetjmp)
 	jr	t9
diff --git a/sysdeps/mips/setjmp.S b/sysdeps/mips/setjmp.S
index 607b5f268d..804b27e897 100644
--- a/sysdeps/mips/setjmp.S
+++ b/sysdeps/mips/setjmp.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+/* Copyright (C) 1996, 1997, 2000 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
@@ -21,11 +21,11 @@
 /* The function __sigsetjmp_aux saves all the registers, but it can't
    reliably access the stack or frame pointers, so we pass them in as
    extra arguments.  */
-#ifdef PIC
+#ifdef __PIC__
 	.option pic2
 #endif
 ENTRY (__sigsetjmp)
-#ifdef PIC
+#ifdef __PIC__
 	.set	noreorder
 	.cpload	t9
 	.set	reorder
@@ -36,7 +36,7 @@ ENTRY (__sigsetjmp)
 #else
 	move	a3, $fp
 #endif
-#ifdef PIC
+#ifdef __PIC__
 	la	t9, __sigsetjmp_aux
 	jr	t9
 #else
diff --git a/sysdeps/unix/mips/pipe.S b/sysdeps/unix/mips/pipe.S
index dac617461d..7066ac71ce 100644
--- a/sysdeps/unix/mips/pipe.S
+++ b/sysdeps/unix/mips/pipe.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1995, 1997 Free Software Foundation, Inc.
+/* Copyright (C) 1992, 1995, 1997, 2000 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Brendan Kehoe (brendan@zen.org).
 
@@ -25,9 +25,8 @@ SYSCALL__ (pipe, 1)
 	sw v1, 4(a0)
 
 	/* Go out with a clean status.  */
-	j ra
 	move v0, zero
-	nop
+	j ra
 	.end __pipe
 
 weak_alias (__pipe, pipe)