update from main archvie 961022
This commit is contained in:
parent
97250b8f6a
commit
b8bd7edd26
@ -46,4 +46,4 @@ ENTRY (_setjmp)
|
||||
#else
|
||||
jmp C_SYMBOL_NAME (__sigsetjmp)
|
||||
#endif
|
||||
PSEUDO_END (_setjmp)
|
||||
END (_setjmp)
|
||||
|
@ -44,4 +44,4 @@ ENTRY (setjmp)
|
||||
#else
|
||||
jmp C_SYMBOL_NAME (__sigsetjmp)
|
||||
#endif
|
||||
PSEUDO_END (setjmp)
|
||||
END (setjmp)
|
||||
|
@ -27,7 +27,6 @@ Cambridge, MA 02139, USA. */
|
||||
|
||||
.text
|
||||
ENTRY (__clone)
|
||||
CALL_MCOUNT
|
||||
|
||||
/* Sanity check arguments. */
|
||||
movel #-EINVAL, %d0
|
||||
@ -63,17 +62,12 @@ ENTRY (__clone)
|
||||
|
||||
rts
|
||||
|
||||
SYSCALL_ERROR_HANDLER
|
||||
|
||||
thread_start:
|
||||
subl %fp, %fp /* terminate the stack frame */
|
||||
jsr (%a0)
|
||||
movel %d0, -(%sp)
|
||||
#ifdef PIC
|
||||
bsrl _exit@PLTPC
|
||||
#else
|
||||
jbsr _exit
|
||||
#endif
|
||||
jbsr JUMPTARGET (_exit)
|
||||
|
||||
PSEUDO_END (__clone)
|
||||
|
||||
weak_alias (__clone, clone)
|
||||
|
@ -19,10 +19,7 @@ Cambridge, MA 02139, USA. */
|
||||
#include <sysdep.h>
|
||||
|
||||
.text
|
||||
SYSCALL_ERROR_HANDLER
|
||||
|
||||
ENTRY (__mmap)
|
||||
CALL_MCOUNT
|
||||
|
||||
move.l #SYS_ify (mmap), %d0 /* System call number in %d0. */
|
||||
|
||||
|
@ -20,12 +20,10 @@ Cambridge, MA 02139, USA. */
|
||||
|
||||
.text
|
||||
ENTRY (__sigreturn)
|
||||
CALL_MCOUNT
|
||||
|
||||
addq.l #4, %sp /* Pop the return PC. */
|
||||
DO_CALL (#SYS_ify (sigreturn), 0)
|
||||
/* Do the system call; it never returns. */
|
||||
/* NOTREACHED */
|
||||
PSEUDO_END (__sigreturn)
|
||||
END (__sigreturn)
|
||||
|
||||
weak_alias (__sigreturn, sigreturn)
|
||||
|
@ -23,8 +23,6 @@ Cambridge, MA 02139, USA. */
|
||||
#define P2(a, b) a##b
|
||||
|
||||
.text
|
||||
SYSCALL_ERROR_HANDLER
|
||||
|
||||
/* The socket-oriented system calls are handled unusally in Linux.
|
||||
They are all gated through the single `socketcall' system call number.
|
||||
`socketcall' takes two arguments: the first is the subcode, specifying
|
||||
@ -35,7 +33,6 @@ Cambridge, MA 02139, USA. */
|
||||
|
||||
.globl P(__,socket)
|
||||
ENTRY (P(__,socket))
|
||||
CALL_MCOUNT
|
||||
|
||||
/* Save registers. */
|
||||
move.l %d2, %a0
|
||||
|
@ -22,10 +22,7 @@ Cambridge, MA 02139, USA. */
|
||||
more information about the value -128 used below.*/
|
||||
|
||||
.text
|
||||
SYSCALL_ERROR_HANDLER
|
||||
ENTRY (syscall)
|
||||
CALL_MCOUNT
|
||||
|
||||
move.l 4(%sp), %d0 /* Load syscall number. */
|
||||
_DOARGS_5 (24) /* Frob arguments. */
|
||||
trap &0 /* Do the system call. */
|
||||
|
@ -46,7 +46,10 @@ __errno = errno /* This name is expected by the MT code. */
|
||||
|
||||
/* The syscall stubs jump here when they detect an error. */
|
||||
|
||||
ENTRY (__syscall_error)
|
||||
.globl __syscall_error
|
||||
.type __syscall_error, @function
|
||||
.align 4
|
||||
__syscall_error:
|
||||
neg.l %d0
|
||||
move.l %d0, errno
|
||||
#ifdef _LIBC_REENTRANT
|
||||
@ -59,15 +62,14 @@ ENTRY (__syscall_error)
|
||||
return a pointer. */
|
||||
move.l %d0, %a0
|
||||
rts
|
||||
PSEUDO_END (__syscall_error)
|
||||
END (__syscall_error)
|
||||
#endif /* PIC */
|
||||
|
||||
ENTRY (__errno_location)
|
||||
CALL_MCOUNT
|
||||
#ifdef PIC
|
||||
move.l (%pc, errno@GOTPC), %a0
|
||||
#else
|
||||
lea errno, %a0
|
||||
#endif
|
||||
rts
|
||||
PSEUDO_END (__errno_location)
|
||||
END (__errno_location)
|
||||
|
@ -41,6 +41,9 @@ Cambridge, MA 02139, USA. */
|
||||
C_LABEL(name) \
|
||||
CALL_MCOUNT
|
||||
|
||||
#undef END
|
||||
#define END(name) .size name, . - name
|
||||
|
||||
/* If compiled for profiling, call `_mcount' at the start of each function. */
|
||||
#ifdef PROF
|
||||
/* The mcount code relies on a normal frame pointer being on the stack
|
||||
@ -76,7 +79,6 @@ Cambridge, MA 02139, USA. */
|
||||
error values. */
|
||||
#define PSEUDO(name, syscall_name, args) \
|
||||
.text; \
|
||||
SYSCALL_ERROR_HANDLER \
|
||||
ENTRY (name) \
|
||||
DO_CALL (&SYS_ify (syscall_name), args); \
|
||||
moveq.l &-128, %d1; \
|
||||
@ -84,13 +86,14 @@ Cambridge, MA 02139, USA. */
|
||||
jcc syscall_error
|
||||
|
||||
#undef PSEUDO_END
|
||||
#define PSEUDO_END(name) .size name, . - name
|
||||
#define PSEUDO_END(name) \
|
||||
SYSCALL_ERROR_HANDLER; \
|
||||
END (name)
|
||||
|
||||
#ifdef PIC
|
||||
/* Store (- %d0) into errno through the GOT. */
|
||||
#ifdef _LIBC_REENTRANT
|
||||
#define SYSCALL_ERROR_HANDLER \
|
||||
.type syscall_error, @function; \
|
||||
syscall_error: \
|
||||
move.l (errno@GOTPC, %pc), %a0; \
|
||||
neg.l %d0; \
|
||||
@ -105,7 +108,6 @@ syscall_error: \
|
||||
rts;
|
||||
#else
|
||||
#define SYSCALL_ERROR_HANDLER \
|
||||
.type syscall_error, @function; \
|
||||
syscall_error: \
|
||||
move.l (errno@GOTPC, %pc), %a0; \
|
||||
neg.l %d0; \
|
||||
|
Loading…
x
Reference in New Issue
Block a user