public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* [PATCH 0/5] Cancellation entrypoint refactor
@ 2016-02-24 20:48 Adhemerval Zanella
  2016-02-24 20:48 ` [PATCH 1/5] Define __ASSUME_ALIGNED_REGISTER_PAIRS for missing ports Adhemerval Zanella
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Adhemerval Zanella @ 2016-02-24 20:48 UTC (permalink / raw)
  To: libc-alpha

Hi all,

This is a respin on previous patch.  Changes from previous version:

 * Split the second patch in two: one for inclusion of generic Linux
   sysdep header in all ports and another to add the SYSCALL_LL{64}
   definition.

 * Rework the mips64-n32 definition by adding a definition
   (__ASSUME_OFF_DIFF_OFF64) which says the sizeof of __off_t is the
   same __off64_t.  So we will have basically 3 scenarios:

   1. __WORDSIZE == 32
     pread   with off_t
     pread64 with off64_t

   2. __WORDSIZE == 64 and __ASSUME_OFF_DIFF_OFF64
     pread   with off_t
     pread64 with off64_t

   3. __WORDSIZE == 64
     pread being and alias to pread64
     pread64

  So for mip64-n32 it will define __ASSUME_OFF_DIFF_OFF64 and thus we can
  remove the mips specific implementations.

--

These patches are a subset of a larger patchset I am working with the
aim to both simplify both syscall cancellation entrypoints and its
definition.

The main aim is to remove the requirement of assembly macros definition
on syscall-cancel.h and instead use C code through SYSCALL_CANCEL
macro.  This both simplify a new port creation by removing arch-specific
code requirements and also make easier to adjust current ports to the
new cancellation mechanism.

To accomplish it the idea is remove all the syscall cancellation auto
generation through syscalls.list and remove all the multiple syscall
definition across multiple ports.  So for all the cancellation
entrypoints for linux will ending have a single C implementation on
sysdep/unix/sysv/linux.

The first patch add the __ASSUME_ALIGNED_REGISTER_PAIRS on the missing
architectures that have the ABI constraint but does not define it.  
Second patch adds a new macro to use along long long syscalls arguments
for 32-bits to currect split it 2 arguments.  The third and last patch
use these new macros to consolidate the pread and pwrite syscall
definition in only one implementation.

Adhemerval Zanella (5):
  Define __ASSUME_ALIGNED_REGISTER_PAIRS for missing ports
  Include generic Linux sysdep.h for all architectures
  Consolidate off_t/off64_t syscall argument passing
  Consolidate pread/pread64 implementations
  Consolidate pwrite/pwrite64 implementations

 ChangeLog                                          | 86 ++++++++++++++++++++++
 sysdeps/unix/sysv/linux/alpha/sysdep.h             |  1 +
 sysdeps/unix/sysv/linux/arm/kernel-features.h      |  4 +
 sysdeps/unix/sysv/linux/arm/pread.c                | 36 ---------
 sysdeps/unix/sysv/linux/arm/pread64.c              | 37 ----------
 sysdeps/unix/sysv/linux/arm/pwrite.c               | 36 ---------
 sysdeps/unix/sysv/linux/arm/pwrite64.c             | 38 ----------
 sysdeps/unix/sysv/linux/arm/sysdep.h               |  2 +
 sysdeps/unix/sysv/linux/generic/sysdep.h           | 13 ++++
 .../unix/sysv/linux/generic/wordsize-32/pread.c    | 37 ----------
 .../unix/sysv/linux/generic/wordsize-32/pread64.c  | 34 ---------
 .../unix/sysv/linux/generic/wordsize-32/pwrite.c   | 36 ---------
 .../unix/sysv/linux/generic/wordsize-32/pwrite64.c | 35 ---------
 sysdeps/unix/sysv/linux/hppa/sysdep.h              |  1 +
 sysdeps/unix/sysv/linux/i386/sysdep.h              |  1 +
 sysdeps/unix/sysv/linux/ia64/sysdep.h              |  1 +
 sysdeps/unix/sysv/linux/m68k/sysdep.h              |  1 +
 sysdeps/unix/sysv/linux/microblaze/sysdep.h        |  1 +
 sysdeps/unix/sysv/linux/mips/kernel-features.h     | 13 ++++
 sysdeps/unix/sysv/linux/mips/mips32/sysdep.h       |  1 +
 sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h   |  1 +
 sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h   |  1 +
 sysdeps/unix/sysv/linux/mips/pread.c               | 54 --------------
 sysdeps/unix/sysv/linux/mips/pread64.c             | 50 -------------
 sysdeps/unix/sysv/linux/mips/pwrite.c              | 54 --------------
 sysdeps/unix/sysv/linux/mips/pwrite64.c            | 51 -------------
 sysdeps/unix/sysv/linux/powerpc/kernel-features.h  |  6 ++
 sysdeps/unix/sysv/linux/powerpc/powerpc32/pread.c  | 34 ---------
 .../unix/sysv/linux/powerpc/powerpc32/pread64.c    | 35 ---------
 sysdeps/unix/sysv/linux/powerpc/powerpc32/pwrite.c | 35 ---------
 .../unix/sysv/linux/powerpc/powerpc32/pwrite64.c   | 36 ---------
 sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep.h | 19 +----
 sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep.h | 19 +----
 sysdeps/unix/sysv/linux/pread.c                    | 25 ++-----
 sysdeps/unix/sysv/linux/pread64.c                  | 23 +++---
 sysdeps/unix/sysv/linux/pwrite.c                   | 25 ++-----
 sysdeps/unix/sysv/linux/pwrite64.c                 | 23 +++---
 sysdeps/unix/sysv/linux/s390/s390-32/sysdep.h      |  1 +
 sysdeps/unix/sysv/linux/s390/s390-64/sysdep.h      |  1 +
 sysdeps/unix/sysv/linux/sh/pread.c                 | 30 ++------
 sysdeps/unix/sysv/linux/sh/pread64.c               | 30 ++------
 sysdeps/unix/sysv/linux/sh/pwrite.c                | 30 ++------
 sysdeps/unix/sysv/linux/sh/pwrite64.c              | 31 ++------
 sysdeps/unix/sysv/linux/sh/sysdep.h                |  1 +
 sysdeps/unix/sysv/linux/sparc/sysdep.h             |  1 +
 sysdeps/unix/sysv/linux/wordsize-64/pread64.c      |  1 -
 sysdeps/unix/sysv/linux/wordsize-64/pwrite64.c     |  1 -
 sysdeps/unix/sysv/linux/wordsize-64/syscalls.list  |  2 -
 sysdeps/unix/sysv/linux/x86_64/kernel-features.h   |  6 ++
 sysdeps/unix/sysv/linux/x86_64/sysdep.h            |  1 +
 50 files changed, 200 insertions(+), 841 deletions(-)
 delete mode 100644 sysdeps/unix/sysv/linux/arm/pread.c
 delete mode 100644 sysdeps/unix/sysv/linux/arm/pread64.c
 delete mode 100644 sysdeps/unix/sysv/linux/arm/pwrite.c
 delete mode 100644 sysdeps/unix/sysv/linux/arm/pwrite64.c
 delete mode 100644 sysdeps/unix/sysv/linux/generic/wordsize-32/pread.c
 delete mode 100644 sysdeps/unix/sysv/linux/generic/wordsize-32/pread64.c
 delete mode 100644 sysdeps/unix/sysv/linux/generic/wordsize-32/pwrite.c
 delete mode 100644 sysdeps/unix/sysv/linux/generic/wordsize-32/pwrite64.c
 delete mode 100644 sysdeps/unix/sysv/linux/mips/pread.c
 delete mode 100644 sysdeps/unix/sysv/linux/mips/pread64.c
 delete mode 100644 sysdeps/unix/sysv/linux/mips/pwrite.c
 delete mode 100644 sysdeps/unix/sysv/linux/mips/pwrite64.c
 delete mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/pread.c
 delete mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/pread64.c
 delete mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/pwrite.c
 delete mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/pwrite64.c
 delete mode 100644 sysdeps/unix/sysv/linux/wordsize-64/pread64.c
 delete mode 100644 sysdeps/unix/sysv/linux/wordsize-64/pwrite64.c

-- 
1.9.1

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-02-24 21:39 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-24 20:48 [PATCH 0/5] Cancellation entrypoint refactor Adhemerval Zanella
2016-02-24 20:48 ` [PATCH 1/5] Define __ASSUME_ALIGNED_REGISTER_PAIRS for missing ports Adhemerval Zanella
2016-02-24 20:48 ` [PATCH 2/5] Include generic Linux sysdep.h for all architectures Adhemerval Zanella
2016-02-24 20:48 ` [PATCH 3/5] Consolidate off_t/off64_t syscall argument passing Adhemerval Zanella
2016-02-24 21:41   ` Mike Frysinger
2016-02-24 20:48 ` [PATCH 4/5] Consolidate pread/pread64 implementations Adhemerval Zanella
2016-02-24 21:39 ` [PATCH 5/5] Consolidate pwrite/pwrite64 implementations Adhemerval Zanella

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).