mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-30 22:43:12 +03:00
Delete everything under sysdeps/unix/sparc/
* sysdeps/unix/sparc/brk.S: Delete. * sysdeps/unix/sparc/dl-brk.S: Delete. * sysdeps/unix/sparc/pipe.S: Delete. * sysdeps/unix/sparc/sysdep.S: Delete. * sysdeps/unix/sparc/sysdep.h: Delete. * sysdeps/unix/sparc/vfork.S: Delete. * sysdeps/sparc/sysdep.h (SPARC_PIC_THUNK, SPARC_PIC_REG, SPARC_PIC_REG_LEAF, ENTRY, END, LOC): Define. * sysdeps/unix/sysv/linux/sparc/sysdep.h (ret, ret_NOERRNO, ret_ERRVAL, r0, r1, MOVE): Define. (JUMPTARGET): Remove. * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h: Don't include sysdeps/unix/sparc/sysdep.h (ENTRY, END): Remove. * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
This commit is contained in:
18
ChangeLog
18
ChangeLog
@ -1,3 +1,21 @@
|
|||||||
|
2012-04-25 David S. Miller <davem@davemloft.net>
|
||||||
|
|
||||||
|
* sysdeps/unix/sparc/brk.S: Delete.
|
||||||
|
* sysdeps/unix/sparc/dl-brk.S: Delete.
|
||||||
|
* sysdeps/unix/sparc/pipe.S: Delete.
|
||||||
|
* sysdeps/unix/sparc/sysdep.S: Delete.
|
||||||
|
* sysdeps/unix/sparc/sysdep.h: Delete.
|
||||||
|
* sysdeps/unix/sparc/vfork.S: Delete.
|
||||||
|
* sysdeps/sparc/sysdep.h (SPARC_PIC_THUNK, SPARC_PIC_REG,
|
||||||
|
SPARC_PIC_REG_LEAF, ENTRY, END, LOC): Define.
|
||||||
|
* sysdeps/unix/sysv/linux/sparc/sysdep.h (ret, ret_NOERRNO,
|
||||||
|
ret_ERRVAL, r0, r1, MOVE): Define.
|
||||||
|
(JUMPTARGET): Remove.
|
||||||
|
* sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h: Don't include
|
||||||
|
sysdeps/unix/sparc/sysdep.h
|
||||||
|
(ENTRY, END): Remove.
|
||||||
|
* sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
|
||||||
|
|
||||||
2012-04-25 Joseph Myers <joseph@codesourcery.com>
|
2012-04-25 Joseph Myers <joseph@codesourcery.com>
|
||||||
|
|
||||||
* Makerules (native-compile): Use $(BUILD_LDFLAGS).
|
* Makerules (native-compile): Use $(BUILD_LDFLAGS).
|
||||||
|
@ -42,3 +42,53 @@
|
|||||||
#define HWCAP_SPARC_IMA 0x00400000
|
#define HWCAP_SPARC_IMA 0x00400000
|
||||||
#define HWCAP_SPARC_ASI_CACHE_SPARING \
|
#define HWCAP_SPARC_ASI_CACHE_SPARING \
|
||||||
0x00800000
|
0x00800000
|
||||||
|
|
||||||
|
#ifdef __ASSEMBLER__
|
||||||
|
|
||||||
|
#define SPARC_PIC_THUNK(reg) \
|
||||||
|
.ifndef __sparc_get_pc_thunk.reg; \
|
||||||
|
.section .text.__sparc_get_pc_thunk.reg,"axG",@progbits,__sparc_get_pc_thunk.reg,comdat; \
|
||||||
|
.align 32; \
|
||||||
|
.weak __sparc_get_pc_thunk.reg; \
|
||||||
|
.hidden __sparc_get_pc_thunk.reg; \
|
||||||
|
.type __sparc_get_pc_thunk.reg, #function; \
|
||||||
|
__sparc_get_pc_thunk.reg: \
|
||||||
|
jmp %o7 + 8; \
|
||||||
|
add %o7, %reg, %##reg; \
|
||||||
|
.previous; \
|
||||||
|
.endif;
|
||||||
|
|
||||||
|
/* Even when v9 we use a call sequence instead of using "rd %pc" because
|
||||||
|
RDPC is extremely expensive and incurs a full pipeline flush. */
|
||||||
|
|
||||||
|
#define SETUP_PIC_REG(reg) \
|
||||||
|
SPARC_PIC_THUNK(reg) \
|
||||||
|
sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %##reg; \
|
||||||
|
call __sparc_get_pc_thunk.reg; \
|
||||||
|
or %##reg, %lo(_GLOBAL_OFFSET_TABLE_+4), %##reg;
|
||||||
|
|
||||||
|
#define SETUP_PIC_REG_LEAF(reg, tmp) \
|
||||||
|
SPARC_PIC_THUNK(reg) \
|
||||||
|
sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %##reg; \
|
||||||
|
mov %o7, %##tmp; \
|
||||||
|
call __sparc_get_pc_thunk.reg; \
|
||||||
|
or %##reg, %lo(_GLOBAL_OFFSET_TABLE_+4), %##reg; \
|
||||||
|
mov %##tmp, %o7;
|
||||||
|
|
||||||
|
#undef ENTRY
|
||||||
|
#define ENTRY(name) \
|
||||||
|
.align 4; \
|
||||||
|
.global C_SYMBOL_NAME(name); \
|
||||||
|
.type name, @function; \
|
||||||
|
C_LABEL(name) \
|
||||||
|
cfi_startproc;
|
||||||
|
|
||||||
|
#undef END
|
||||||
|
#define END(name) \
|
||||||
|
cfi_endproc; \
|
||||||
|
.size name, . - name
|
||||||
|
|
||||||
|
#undef LOC
|
||||||
|
#define LOC(name) .L##name
|
||||||
|
|
||||||
|
#endif /* __ASSEMBLER__ */
|
||||||
|
@ -1,50 +0,0 @@
|
|||||||
/* Copyright (C) 1993, 1995, 1997, 2005 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/>. */
|
|
||||||
|
|
||||||
#include <sysdep.h>
|
|
||||||
|
|
||||||
#ifndef SYS_brk
|
|
||||||
#define SYS_brk 17
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef C_SYMBOL_NAME
|
|
||||||
#define C_SYMBOL_NAME(name) _##name
|
|
||||||
#endif
|
|
||||||
|
|
||||||
.data
|
|
||||||
.global C_SYMBOL_NAME(__curbrk)
|
|
||||||
C_LABEL(__curbrk)
|
|
||||||
.long C_SYMBOL_NAME(_end)
|
|
||||||
|
|
||||||
.text
|
|
||||||
ENTRY (__brk)
|
|
||||||
add %o0, 7, %o0
|
|
||||||
andn %o0, 7, %o0
|
|
||||||
mov SYS_brk, %g1
|
|
||||||
mov %o0, %o1 /* Save rounded value. */
|
|
||||||
ta %g0
|
|
||||||
bcs error
|
|
||||||
sethi %hi(C_SYMBOL_NAME(__curbrk)), %g1
|
|
||||||
st %o1, [%g1 + %lo(C_SYMBOL_NAME(__curbrk))]
|
|
||||||
ret
|
|
||||||
error: sethi %hi(C_SYMBOL_NAME(errno)), %g1
|
|
||||||
st %o0, [%g1 + %lo(C_SYMBOL_NAME(errno))]
|
|
||||||
sub %g0, 1, %o0
|
|
||||||
retl
|
|
||||||
nop /* Fill the delay slot. */
|
|
||||||
|
|
||||||
weak_alias (__brk, brk)
|
|
@ -1 +0,0 @@
|
|||||||
#include <brk.S>
|
|
@ -1,29 +0,0 @@
|
|||||||
/* Copyright (C) 1991, 1992, 1995, 1997, 2002 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/>. */
|
|
||||||
|
|
||||||
#include <sysdep.h>
|
|
||||||
|
|
||||||
ENTRY (__pipe)
|
|
||||||
mov %o0, %o2 /* Save PIPEDES. */
|
|
||||||
PSEUDO (__Spipe, pipe, 1)
|
|
||||||
st %o0, [%o2] /* PIPEDES[0] = %o0; */
|
|
||||||
st %o1, [%o2 + 4] /* PIPEDES[1] = %o1; */
|
|
||||||
retl /* return 0; */
|
|
||||||
clr %o0
|
|
||||||
|
|
||||||
libc_hidden_def (__pipe)
|
|
||||||
weak_alias (__pipe, pipe)
|
|
@ -1,41 +0,0 @@
|
|||||||
/* Copyright (C) 1994, 1997, 2012 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/>. */
|
|
||||||
|
|
||||||
#include <sysdep.h>
|
|
||||||
#define _ERRNO_H
|
|
||||||
#include <bits/errno.h>
|
|
||||||
|
|
||||||
.global C_SYMBOL_NAME(errno)
|
|
||||||
.global syscall_error
|
|
||||||
|
|
||||||
.text
|
|
||||||
.align 2
|
|
||||||
__syscall_error:
|
|
||||||
#if defined (EWOULDBLOCK_sys) && EWOULDBLOCK_sys != EAGAIN
|
|
||||||
/* We translate the system's EWOULDBLOCK error into EAGAIN.
|
|
||||||
The GNU C library always defines EWOULDBLOCK==EAGAIN.
|
|
||||||
EWOULDBLOCK_sys is the original number. */
|
|
||||||
cmp %o0, EWOULDBLOCK_sys
|
|
||||||
be,a notblock
|
|
||||||
mov EAGAIN, %o0
|
|
||||||
#endif
|
|
||||||
notblock: /* Store the error code in `errno'. */
|
|
||||||
sethi %hi(C_SYMBOL_NAME(errno)), %g1
|
|
||||||
st %o0, [%g1 + %lo(C_SYMBOL_NAME(errno))]
|
|
||||||
/* And return -1. */
|
|
||||||
retl
|
|
||||||
mov -1, %o0
|
|
@ -1,95 +0,0 @@
|
|||||||
/* Copyright (C) 1993, 1994, 1995, 1997, 2003, 2011, 2012
|
|
||||||
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/>. */
|
|
||||||
|
|
||||||
#include <sysdeps/unix/sysdep.h>
|
|
||||||
#include <sysdeps/sparc/sysdep.h>
|
|
||||||
|
|
||||||
#ifdef __ASSEMBLER__
|
|
||||||
|
|
||||||
/* Since C identifiers are not normally prefixed with an underscore
|
|
||||||
on this system, the asm identifier `syscall_error' intrudes on the
|
|
||||||
C name space. Make sure we use an innocuous name. */
|
|
||||||
#define syscall_error C_SYMBOL_NAME(__syscall_error)
|
|
||||||
|
|
||||||
#define SPARC_PIC_THUNK(reg) \
|
|
||||||
.ifndef __sparc_get_pc_thunk.reg; \
|
|
||||||
.section .text.__sparc_get_pc_thunk.reg,"axG",@progbits,__sparc_get_pc_thunk.reg,comdat; \
|
|
||||||
.align 32; \
|
|
||||||
.weak __sparc_get_pc_thunk.reg; \
|
|
||||||
.hidden __sparc_get_pc_thunk.reg; \
|
|
||||||
.type __sparc_get_pc_thunk.reg, #function; \
|
|
||||||
__sparc_get_pc_thunk.reg: \
|
|
||||||
jmp %o7 + 8; \
|
|
||||||
add %o7, %reg, %##reg; \
|
|
||||||
.previous; \
|
|
||||||
.endif;
|
|
||||||
|
|
||||||
/* Even when v9 we use a call sequence instead of using "rd %pc" because
|
|
||||||
RDPC is extremely expensive and incurs a full pipeline flush. */
|
|
||||||
|
|
||||||
#define SETUP_PIC_REG(reg) \
|
|
||||||
SPARC_PIC_THUNK(reg) \
|
|
||||||
sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %##reg; \
|
|
||||||
call __sparc_get_pc_thunk.reg; \
|
|
||||||
or %##reg, %lo(_GLOBAL_OFFSET_TABLE_+4), %##reg;
|
|
||||||
|
|
||||||
#define SETUP_PIC_REG_LEAF(reg, tmp) \
|
|
||||||
SPARC_PIC_THUNK(reg) \
|
|
||||||
sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %##reg; \
|
|
||||||
mov %o7, %##tmp; \
|
|
||||||
call __sparc_get_pc_thunk.reg; \
|
|
||||||
or %##reg, %lo(_GLOBAL_OFFSET_TABLE_+4), %##reg; \
|
|
||||||
mov %##tmp, %o7;
|
|
||||||
|
|
||||||
#define ENTRY(name) \
|
|
||||||
.global C_SYMBOL_NAME(name); \
|
|
||||||
.type name,@function; \
|
|
||||||
.align 4; \
|
|
||||||
C_LABEL(name)
|
|
||||||
|
|
||||||
|
|
||||||
#define PSEUDO(name, syscall_name, args) \
|
|
||||||
.global syscall_error; \
|
|
||||||
ENTRY (name) \
|
|
||||||
mov SYS_ify(syscall_name), %g1; \
|
|
||||||
ta 0; \
|
|
||||||
bcc 1f; \
|
|
||||||
sethi %hi(syscall_error), %g1; \
|
|
||||||
jmp %g1 + %lo(syscall_error); nop; \
|
|
||||||
1:
|
|
||||||
|
|
||||||
#define PSEUDO_NOERRNO(name, syscall_name, args) \
|
|
||||||
.global syscall_error; \
|
|
||||||
ENTRY (name) \
|
|
||||||
mov SYS_ify(syscall_name), %g1; \
|
|
||||||
ta 0
|
|
||||||
|
|
||||||
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
|
||||||
.global syscall_error; \
|
|
||||||
ENTRY (name) \
|
|
||||||
mov SYS_ify(syscall_name), %g1; \
|
|
||||||
ta 0
|
|
||||||
|
|
||||||
#define ret retl; nop
|
|
||||||
#define ret_NOERRNO retl; nop
|
|
||||||
#define ret_ERRVAL retl; nop
|
|
||||||
#define r0 %o0
|
|
||||||
#define r1 %o1
|
|
||||||
#define MOVE(x,y) mov x, y
|
|
||||||
|
|
||||||
#endif /* __ASSEMBLER__ */
|
|
@ -1,34 +0,0 @@
|
|||||||
/* Copyright (C) 1991, 92, 94, 95, 97, 99, 2002 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/>. */
|
|
||||||
|
|
||||||
#include <sysdep.h>
|
|
||||||
|
|
||||||
#ifndef SYS_vfork
|
|
||||||
#define SYS_vfork 66
|
|
||||||
#endif
|
|
||||||
|
|
||||||
SYSCALL__ (vfork, 0)
|
|
||||||
/* %o1 is now 0 for the parent and 1 for the child. Decrement it to
|
|
||||||
make it -1 (all bits set) for the parent, and 0 (no bits set)
|
|
||||||
for the child. Then AND it with %o0, so the parent gets
|
|
||||||
%o0&-1==pid, and the child gets %o0&0==0. */
|
|
||||||
sub %o1, 1, %o1
|
|
||||||
retl
|
|
||||||
and %o0, %o1, %o0
|
|
||||||
libc_hidden_def (__vfork)
|
|
||||||
|
|
||||||
weak_alias (__vfork, vfork)
|
|
@ -20,7 +20,7 @@
|
|||||||
#ifndef _LINUX_SPARC32_SYSDEP_H
|
#ifndef _LINUX_SPARC32_SYSDEP_H
|
||||||
#define _LINUX_SPARC32_SYSDEP_H 1
|
#define _LINUX_SPARC32_SYSDEP_H 1
|
||||||
|
|
||||||
#include <sysdeps/unix/sparc/sysdep.h>
|
#include <sysdeps/unix/sysv/linux/sparc/sysdep.h>
|
||||||
|
|
||||||
#ifdef IS_IN_rtld
|
#ifdef IS_IN_rtld
|
||||||
# include <dl-sysdep.h> /* Defines RTLD_PRIVATE_ERRNO. */
|
# include <dl-sysdep.h> /* Defines RTLD_PRIVATE_ERRNO. */
|
||||||
@ -34,28 +34,7 @@
|
|||||||
|
|
||||||
#define LOADSYSCALL(x) mov __NR_##x, %g1
|
#define LOADSYSCALL(x) mov __NR_##x, %g1
|
||||||
|
|
||||||
/* Linux/SPARC uses a different trap number */
|
|
||||||
#undef PSEUDO
|
#undef PSEUDO
|
||||||
#undef PSEUDO_NOERRNO
|
|
||||||
#undef PSEUDO_ERRVAL
|
|
||||||
#undef PSEUDO_END
|
|
||||||
#undef ENTRY
|
|
||||||
#undef END
|
|
||||||
#undef LOC
|
|
||||||
|
|
||||||
#define ENTRY(name) \
|
|
||||||
.align 4; \
|
|
||||||
.global C_SYMBOL_NAME(name); \
|
|
||||||
.type name, @function; \
|
|
||||||
C_LABEL(name) \
|
|
||||||
cfi_startproc;
|
|
||||||
|
|
||||||
#define END(name) \
|
|
||||||
cfi_endproc; \
|
|
||||||
.size name, . - name
|
|
||||||
|
|
||||||
#define LOC(name) .L##name
|
|
||||||
|
|
||||||
#define PSEUDO(name, syscall_name, args) \
|
#define PSEUDO(name, syscall_name, args) \
|
||||||
.text; \
|
.text; \
|
||||||
ENTRY(name); \
|
ENTRY(name); \
|
||||||
@ -66,18 +45,21 @@ ENTRY(name); \
|
|||||||
SYSCALL_ERROR_HANDLER \
|
SYSCALL_ERROR_HANDLER \
|
||||||
1:
|
1:
|
||||||
|
|
||||||
|
#undef PSEUDO_NOERRNO
|
||||||
#define PSEUDO_NOERRNO(name, syscall_name, args)\
|
#define PSEUDO_NOERRNO(name, syscall_name, args)\
|
||||||
.text; \
|
.text; \
|
||||||
ENTRY(name); \
|
ENTRY(name); \
|
||||||
LOADSYSCALL(syscall_name); \
|
LOADSYSCALL(syscall_name); \
|
||||||
ta 0x10;
|
ta 0x10;
|
||||||
|
|
||||||
|
#undef PSEUDO_ERRVAL
|
||||||
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
||||||
.text; \
|
.text; \
|
||||||
ENTRY(name); \
|
ENTRY(name); \
|
||||||
LOADSYSCALL(syscall_name); \
|
LOADSYSCALL(syscall_name); \
|
||||||
ta 0x10;
|
ta 0x10;
|
||||||
|
|
||||||
|
#undef PSEUDO_END
|
||||||
#define PSEUDO_END(name) \
|
#define PSEUDO_END(name) \
|
||||||
END(name)
|
END(name)
|
||||||
|
|
||||||
@ -141,8 +123,6 @@ ENTRY(name); \
|
|||||||
"f24", "f25", "f26", "f27", "f28", "f29", "f30", "f31", \
|
"f24", "f25", "f26", "f27", "f28", "f29", "f30", "f31", \
|
||||||
"cc", "memory"
|
"cc", "memory"
|
||||||
|
|
||||||
#include <sysdeps/unix/sysv/linux/sparc/sysdep.h>
|
|
||||||
|
|
||||||
#endif /* __ASSEMBLER__ */
|
#endif /* __ASSEMBLER__ */
|
||||||
|
|
||||||
/* Pointer mangling support. */
|
/* Pointer mangling support. */
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
#ifndef _LINUX_SPARC64_SYSDEP_H
|
#ifndef _LINUX_SPARC64_SYSDEP_H
|
||||||
#define _LINUX_SPARC64_SYSDEP_H 1
|
#define _LINUX_SPARC64_SYSDEP_H 1
|
||||||
|
|
||||||
#include <sysdeps/unix/sparc/sysdep.h>
|
#include <sysdeps/unix/sysv/linux/sparc/sysdep.h>
|
||||||
|
|
||||||
#ifdef IS_IN_rtld
|
#ifdef IS_IN_rtld
|
||||||
# include <dl-sysdep.h> /* Defines RTLD_PRIVATE_ERRNO. */
|
# include <dl-sysdep.h> /* Defines RTLD_PRIVATE_ERRNO. */
|
||||||
@ -44,25 +44,7 @@
|
|||||||
|
|
||||||
#define LOADSYSCALL(x) mov __NR_##x, %g1
|
#define LOADSYSCALL(x) mov __NR_##x, %g1
|
||||||
|
|
||||||
/* Linux/SPARC uses a different trap number */
|
|
||||||
#undef PSEUDO
|
#undef PSEUDO
|
||||||
#undef PSEUDO_NOERRNO
|
|
||||||
#undef PSEUDO_ERRVAL
|
|
||||||
#undef PSEUDO_END
|
|
||||||
#undef ENTRY
|
|
||||||
#undef END
|
|
||||||
|
|
||||||
#define ENTRY(name) \
|
|
||||||
.align 4; \
|
|
||||||
.global C_SYMBOL_NAME(name); \
|
|
||||||
.type name, @function; \
|
|
||||||
C_LABEL(name) \
|
|
||||||
cfi_startproc;
|
|
||||||
|
|
||||||
#define END(name) \
|
|
||||||
cfi_endproc; \
|
|
||||||
.size name, . - name
|
|
||||||
|
|
||||||
#define PSEUDO(name, syscall_name, args) \
|
#define PSEUDO(name, syscall_name, args) \
|
||||||
.text; \
|
.text; \
|
||||||
ENTRY(name); \
|
ENTRY(name); \
|
||||||
@ -73,18 +55,21 @@ ENTRY(name); \
|
|||||||
SYSCALL_ERROR_HANDLER \
|
SYSCALL_ERROR_HANDLER \
|
||||||
1:
|
1:
|
||||||
|
|
||||||
|
#undef PSEUDO_NOERRNO
|
||||||
#define PSEUDO_NOERRNO(name, syscall_name, args)\
|
#define PSEUDO_NOERRNO(name, syscall_name, args)\
|
||||||
.text; \
|
.text; \
|
||||||
ENTRY(name); \
|
ENTRY(name); \
|
||||||
LOADSYSCALL(syscall_name); \
|
LOADSYSCALL(syscall_name); \
|
||||||
ta 0x6d;
|
ta 0x6d;
|
||||||
|
|
||||||
|
#undef PSEUDO_ERRVAL
|
||||||
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
||||||
.text; \
|
.text; \
|
||||||
ENTRY(name); \
|
ENTRY(name); \
|
||||||
LOADSYSCALL(syscall_name); \
|
LOADSYSCALL(syscall_name); \
|
||||||
ta 0x6d;
|
ta 0x6d;
|
||||||
|
|
||||||
|
#undef PSEUDO_END
|
||||||
#define PSEUDO_END(name) \
|
#define PSEUDO_END(name) \
|
||||||
END(name)
|
END(name)
|
||||||
|
|
||||||
@ -149,8 +134,6 @@ ENTRY(name); \
|
|||||||
"f48", "f50", "f52", "f54", "f56", "f58", "f60", "f62", \
|
"f48", "f50", "f52", "f54", "f56", "f58", "f60", "f62", \
|
||||||
"cc", "memory"
|
"cc", "memory"
|
||||||
|
|
||||||
#include <sysdeps/unix/sysv/linux/sparc/sysdep.h>
|
|
||||||
|
|
||||||
#endif /* __ASSEMBLER__ */
|
#endif /* __ASSEMBLER__ */
|
||||||
|
|
||||||
/* This is the offset from the %sp to the backing store above the
|
/* This is the offset from the %sp to the backing store above the
|
||||||
|
@ -19,6 +19,20 @@
|
|||||||
#ifndef _LINUX_SPARC_SYSDEP_H
|
#ifndef _LINUX_SPARC_SYSDEP_H
|
||||||
#define _LINUX_SPARC_SYSDEP_H 1
|
#define _LINUX_SPARC_SYSDEP_H 1
|
||||||
|
|
||||||
|
#include <sysdeps/unix/sysdep.h>
|
||||||
|
#include <sysdeps/sparc/sysdep.h>
|
||||||
|
|
||||||
|
#ifdef __ASSEMBLER__
|
||||||
|
|
||||||
|
#define ret retl; nop
|
||||||
|
#define ret_NOERRNO retl; nop
|
||||||
|
#define ret_ERRVAL retl; nop
|
||||||
|
#define r0 %o0
|
||||||
|
#define r1 %o1
|
||||||
|
#define MOVE(x,y) mov x, y
|
||||||
|
|
||||||
|
#else /* __ASSEMBLER__ */
|
||||||
|
|
||||||
#undef INLINE_SYSCALL
|
#undef INLINE_SYSCALL
|
||||||
#define INLINE_SYSCALL(name, nr, args...) \
|
#define INLINE_SYSCALL(name, nr, args...) \
|
||||||
({ INTERNAL_SYSCALL_DECL(err); \
|
({ INTERNAL_SYSCALL_DECL(err); \
|
||||||
@ -165,9 +179,6 @@
|
|||||||
__o0; \
|
__o0; \
|
||||||
})
|
})
|
||||||
|
|
||||||
|
#endif /* __ASSEMBLER__ */
|
||||||
#ifdef __ASSEMBLER__
|
|
||||||
# define JUMPTARGET(sym) sym
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* _LINUX_SPARC_SYSDEP_H */
|
#endif /* _LINUX_SPARC_SYSDEP_H */
|
||||||
|
Reference in New Issue
Block a user