Commit Graph

10 Commits

Author SHA1 Message Date
Steve Ellcey 389d1f1b23 Partial ILP32 support for aarch64.
* sysdeps/aarch64/crti.S: Add include of sysdep.h.
	(call_weak_fn): Use PTR_REG to get correct reg name in ILP32.
	* sysdeps/aarch64/dl-irel.h: Add include of sysdep.h.
	(elf_irela): Use AARCH64_R macro to get correct relocation in ILP32.
	* sysdeps/aarch64/dl-machine.h: Add include of sysdep.h.
	(elf_machine_load_address, RTLD_START, RTLD_START_1, RTLD_START,
	elf_machine_type_class, ELF_MACHINE_JMP_SLOT, elf_machine_rela,
	elf_machine_lazy_rel): Add ifdef's for ILP32 support.
	* sysdeps/aarch64/dl-tlsdesc.S (_dl_tlsdesc_return,
	_dl_tlsdesc_return_lazy, _dl_tlsdesc_dynamic,
	_dl_tlsdesc_resolve_hold): Extend pointers in ILP32, use PTR_REG
	to get correct reg name for ILP32.
	* sysdeps/aarch64/dl-trampoline.S (ip01): New Macro.
	(RELA_SIZE): New Macro.
	(_dl_runtime_resolve, _dl_runtime_profile): Use new macros and PTR_REG
	to support ILP32.
	* sysdeps/aarch64/jmpbuf-unwind.h (_JMPBUF_CFA_UNWINDS_ADJ): Add
	cast for ILP32 mode.
	* sysdeps/aarch64/memcmp.S (memcmp): Extend arg pointers for ILP32 mode.
	* sysdeps/aarch64/memcpy.S (memmove, memcpy): Ditto.
	* sysdeps/aarch64/memset.S (__memset): Ditto.
	* sysdeps/aarch64/strchr.S (strchr): Ditto.
	* sysdeps/aarch64/strchrnul.S (__strchrnul): Ditto.
	* sysdeps/aarch64/strcmp.S (strcmp): Ditto.
	* sysdeps/aarch64/strcpy.S (strcpy): Ditto.
	* sysdeps/aarch64/strlen.S (__strlen): Ditto.
	* sysdeps/aarch64/strncmp.S (strncmp): Ditto.
	* sysdeps/aarch64/strnlen.S (strnlen): Ditto.
	* sysdeps/aarch64/strrchr.S (strrchr): Ditto.
	* sysdeps/unix/sysv/linux/aarch64/clone.S: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/setcontext.S (__setcontext): Ditto.
	* sysdeps/unix/sysv/linux/aarch64/swapcontext.S (__swapcontext): Ditto.
	* sysdeps/aarch64/__longjmp.S (__longjmp): Extend pointers in ILP32,
	change PTR_MANGLE call to use register numbers instead of names.
	* sysdeps/unix/sysv/linux/aarch64/getcontext.S (__getcontext): Ditto.
	* sysdeps/aarch64/setjmp.S (__sigsetjmp): Extend arg pointers for
	ILP32 mode, change PTR_MANGLE calls to use register numbers.
	* sysdeps/aarch64/start.S (_start): Ditto.
	* sysdeps/aarch64/nptl/bits/pthreadtypes.h
	(__PTHREAD_RWLOCK_INT_FLAGS_SHARED): New define.
	(__SIZEOF_PTHREAD_ATTR_T, __SIZEOF_PTHREAD_MUTEX_T,
	__SIZEOF_PTHREAD_MUTEXATTR_T, __SIZEOF_PTHREAD_COND_T,
	__SIZEOF_PTHREAD_COND_COMPAT_T, __SIZEOF_PTHREAD_CONDATTR_T,
	__SIZEOF_PTHREAD_RWLOCK_T, __SIZEOF_PTHREAD_RWLOCKATTR_T,
	__SIZEOF_PTHREAD_BARRIER_T, __SIZEOF_PTHREAD_BARRIERATTR_T):
	Make defined values dependent on __ILP32__.
	* sysdeps/aarch64/nptl/bits/semaphore.h (__SIZEOF_SEM_T): Change define.
	(sem_t): Change __align type.
	* sysdeps/aarch64/sysdep.h (AARCH64_R, PTR_REG, PTR_LOG_SIZE, DELOUSE,
	PTR_SIZE): New Macros.
	(LDST_PCREL, LDST_GLOBAL) Update to use PTR_REG.
	* sysdeps/unix/sysv/linux/aarch64/bits/fcntl.h (O_LARGEFILE):
	Set when in ILP32 mode.
	(F_GETLK64, F_SETLK64, F_SETLKW64): Only set in LP64 mode.
	* sysdeps/unix/sysv/linux/aarch64/dl-cache.h (DL_CACHE_DEFAULT_ID):
	Set elf flags for ILP32.
	(add_system_dir): Set ILP32 library directories.
	* sysdeps/unix/sysv/linux/aarch64/init-first.c
	(_libc_vdso_platform_setup): Set minimum kernel version for ILP32.
	* sysdeps/unix/sysv/linux/aarch64/ldconfig.h
	(SYSDEP_KNOWN_INTERPRETER_NAMES): Add ILP32 names.
	* sysdeps/unix/sysv/linux/aarch64/sigcontextinfo.h (GET_PC, SET_PC):
	New Macros.
	* sysdeps/unix/sysv/linux/aarch64/sysdep.h: Handle ILP32 pointers.
2016-11-28 09:01:23 -08:00
Zack Weinberg c66b29f9cc Installed-header hygiene (BZ#20366): stack_t.
sys/ucontext.h unconditionally uses stack_t, and it does not make
sense to change that.  But signal.h only declares stack_t under
__USE_XOPEN_EXTENDED || __USE_XOPEN2K8.  The actual definition is
already in a bits header, bits/sigstack.h, but that header insists on
only being included by signal.h, so we have to change that as well as
all of the sys/ucontext.h variants.  (Some but not all variants of
bits/sigcontext.h, which sys/ucontext.h may also need, had already
received this adjustment; for consistency, I made them all the same,
even if that's not strictly necessary in some configurations.)
bits/sigcontext.h and bits/sigstack.h also all need to receive
multiple inclusion guards.

	* sysdeps/generic/sys/ucontext.h
	* sysdeps/arm/sys/ucontext.h
	* sysdeps/i386/sys/ucontext.h
	* sysdeps/m68k/sys/ucontext.h
	* sysdeps/mips/sys/ucontext.h
	* sysdeps/unix/sysv/linux/aarch64/sys/ucontext.h
	* sysdeps/unix/sysv/linux/alpha/sys/ucontext.h
	* sysdeps/unix/sysv/linux/arm/sys/ucontext.h
	* sysdeps/unix/sysv/linux/hppa/sys/ucontext.h
	* sysdeps/unix/sysv/linux/ia64/sys/ucontext.h
	* sysdeps/unix/sysv/linux/m68k/sys/ucontext.h
	* sysdeps/unix/sysv/linux/mips/sys/ucontext.h
	* sysdeps/unix/sysv/linux/nios2/sys/ucontext.h
	* sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h
	* sysdeps/unix/sysv/linux/s390/sys/ucontext.h
	* sysdeps/unix/sysv/linux/sh/sys/ucontext.h
	* sysdeps/unix/sysv/linux/sparc/sys/ucontext.h
	* sysdeps/unix/sysv/linux/tile/sys/ucontext.h
	* sysdeps/unix/sysv/linux/x86/sys/ucontext.h:
	Include both bits/sigcontext.h and bits/sigstack.h.
	Fix grammar error in comment, if present.

	* bits/sigstack.h
	* sysdeps/unix/sysv/linux/aarch64/bits/sigstack.h
	* sysdeps/unix/sysv/linux/alpha/bits/sigstack.h
	* sysdeps/unix/sysv/linux/bits/sigstack.h
	* sysdeps/unix/sysv/linux/ia64/bits/sigstack.h
	* sysdeps/unix/sysv/linux/mips/bits/sigstack.h
	* sysdeps/unix/sysv/linux/powerpc/bits/sigstack.h
	* sysdeps/unix/sysv/linux/sparc/bits/sigstack.h
	* bits/sigcontext.h
	* sysdeps/mach/hurd/i386/bits/sigcontext.h
	* sysdeps/unix/sysv/linux/bits/sigcontext.h
	* sysdeps/unix/sysv/linux/ia64/bits/sigcontext.h
	* sysdeps/unix/sysv/linux/sparc/bits/sigcontext.h:
	Add multiple inclusion guard.  Permit inclusion by sys/ucontext.h
	as well as signal.h, if this was not already allowed.  Request
	definition of size_t if necessary.  Minimize semantically-null
	differences across files.
2016-09-23 08:43:56 -04:00
Szabolcs Nagy 26c2910ac6 [AArch64] Add bits/hwcap.h for aarch64 linux
AArch64 uses HWCAP bits but they are not defined in sys/auxv.h.
This patch adds a copy of the linux v4.6 arm64 uapi asm/hwcap.h
definitions.

	* sysdeps/unix/sysv/linux/aarch64/bits/hwcap.h: New.
2016-07-11 09:57:02 +01:00
Joseph Myers f7a9f785e5 Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
Adhemerval Zanella 7bf8fb1042 libc-vdso.h place consolidation
This patch moves the libc-vdso.h internal header from bits folder to
default architecture one and also corrects the remaning includes in
the files.
2015-04-20 08:51:17 -03:00
Andreas Schwab b763f6ae85 aarch64: Increase MINSIGSTKSZ and SIGSTKSZ (bug 16850) 2015-04-02 12:18:11 +02:00
Joseph Myers b168057aaa Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
Alan Hayward 5c40c3bab2 [AArch64] Add ipc.h.
Adding ipc.h for AArch64 adjusted to behave correctly on big endian
targets.
2014-11-11 16:32:34 +00:00
Roland McGrath 6ad2df0bda AArch64: Consolidate nptl/ subdirectories under linux/... 2014-06-26 09:29:24 -07:00
Marcus Shawcroft 75eff3fe90 Relocate AArch64 from ports to libc.
This patch moves the AArch64 port to the main sysdeps hierarchy.  The
move is essentially:

  git mv ports/sysdeps/aarch64 sysdeps/aarch64
  git mv ports/sysdeps/unix/sysv/linux/aarch64 sysdeps/unix/sysv/linux/aarch64

The README is updated and I've updated ChangeLog.aarch64 along the
lines of the ARM move.  The AArch64 build has been tested to confirm
that there were no changes in objdump -dr output or the shared
objects.
2014-02-11 11:36:00 +00:00