public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] powerpc: Add support for system call vectored
@ 2020-12-03 17:15 Matheus Castanho
  2020-12-03 17:15 ` [PATCH v2 1/2] powerpc: Runtime selection between sc and scv for syscalls Matheus Castanho
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Matheus Castanho @ 2020-12-03 17:15 UTC (permalink / raw)
  To: libc-alpha

This patchset enables the usage of system call vectored (scv) instruction by
system calls for improved performance on POWER9 and later processors.

This new version dropped the patch to move brk to a C-based implementation, in
favor of Adhemerval's patch [0]. So it should be applied on top of that.

Also, it modified the scv check mechanism to remove the thread pointer check as
suggested by Florian. Now the dynamic loader always uses sc, static code still
checks the thread pointer before accessing the TCB, and shared code (outside the
dl) accesses the TCB directly.

Please check each patch for more details, specially 1/2 which explains the
rationale and details of the runtime mechanism to choose between the old
behavior (sc) and the new one (scv 0).

Tested on powerpc, powerpc64, and powerpc64le (with and without scv)

[0] https://sourceware.org/pipermail/libc-alpha/2020-November/119770.html

---

v2:
  - Fix typos and comments to match GNU style
  - Remove the check for the thread pointer on shared code, and always use sc
    when inside the dynamic loader
  - Drop the patch implementing brk in C

Matheus Castanho (2):
  powerpc: Runtime selection between sc and scv for syscalls
  powerpc: Use scv instruction on clone when available

 sysdeps/powerpc/powerpc32/sysdep.h            |  15 ++-
 sysdeps/powerpc/powerpc64/sysdep.h            | 120 +++++++++++++++++-
 .../unix/sysv/linux/powerpc/powerpc64/clone.S |  36 +++++-
 .../unix/sysv/linux/powerpc/powerpc64/vfork.S |   6 +-
 sysdeps/unix/sysv/linux/powerpc/syscall.S     |  11 +-
 sysdeps/unix/sysv/linux/powerpc/sysdep.h      |  93 ++++++++++----
 6 files changed, 241 insertions(+), 40 deletions(-)

--
2.26.2

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

end of thread, other threads:[~2020-12-30 21:30 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-03 17:15 [PATCH v2 0/2] powerpc: Add support for system call vectored Matheus Castanho
2020-12-03 17:15 ` [PATCH v2 1/2] powerpc: Runtime selection between sc and scv for syscalls Matheus Castanho
2020-12-10 17:28   ` Matheus Castanho
2020-12-10 18:07     ` Adhemerval Zanella
2020-12-30 21:29   ` Tulio Magno Quites Machado Filho
2020-12-03 17:15 ` [PATCH v2 2/2] powerpc: Use scv instruction on clone when available Matheus Castanho
2020-12-30 21:30   ` Tulio Magno Quites Machado Filho
2020-12-08 18:24 ` [PATCH v2 0/2] powerpc: Add support for system call vectored Lucas A. M. Magalhaes

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).