From: Adhemerval Zanella Netto <adhemerval.zanella@linaro.org>
To: Carlos O'Donell <carlos@redhat.com>, libc-alpha@sourceware.org
Subject: Re: [PATCH v4 0/6] Optimize posix_spawn signal setup with clone3
Date: Thu, 19 Jan 2023 11:39:54 -0300 [thread overview]
Message-ID: <2c6cef85-bc1d-2ac3-7a1a-49c732134122@linaro.org> (raw)
In-Reply-To: <c81dc64f-8a50-be01-c17a-851975f1136c@redhat.com>
Just to confirm that it is for 2.38, since you replied as 2.28 on the patches :}.
On 18/01/23 19:24, Carlos O'Donell wrote:
> On 1/18/23 12:53, Adhemerval Zanella Netto wrote:
>> Carlos, do we still want this for 2.37?
>
> I think we should just push this to 2.38.
>
> Start by committing everything we have for x86_64 and aarch64.
>
> Then repost the other arches for review.
>
>> On 12/01/23 10:58, Adhemerval Zanella wrote:
>>> Currently posix_spawn has to issue at least NSIG sigaction syscalls
>>> to obtain current signal disposition and more if they there are not
>>> either SIG_IGN or SIG_DFL. The new clone3 CLONE_CLEAR_SIGHAND flags
>>> introduced with Linux 5.5 resets all signal handlers of the child not
>>> set to SIG_IGN to SIG_DFL, thus allowing posix_spawn to skip this
>>> preparation phase.
>>>
>>> The exception is the signals defined by posix_spawnattr_setsigdefault
>>> when POSIX_SPAWN_SETSIGDEF is set (since they can be SIG_IGN). In
>>> this case posix_spawn helper process needs to issue a sigction to
>>> set the signal disposition to SIG_DFL.
>>>
>>> The patchset also adds clone3 implementation for aarch64. The clone3
>>> for x86_64 is change to not align the stack, since this is not
>>> async-signal safe (although current calls does mask/unmask signals).
>>>
>>> * Changes from v3:
>>> - Changes commit message and comments wording.
>>> - Removed powerpc, s390x, riscv, arm, and mips clone3 optimizations.
>>>
>>> * Changes from v2:
>>> - Improve clone3 internal documentation.
>>>
>>> * Changes from v1:
>>> - Extend clone3 documentation.
>>> - Remove x86_64 stack alignment on clone3 child.
>>> - Fixed powerpc64 missing initial stack frame.
>>> - Fixed missing save/restore r7 for arm.
>>>
>>> Adhemerval Zanella (6):
>>> linux: Do not reset signal handler in posix_spawn if it is already
>>> SIG_DFL
>>> linux: Extend internal clone3 documentation
>>> Linux: Do not align the stack for __clone3
>>> linux: Add clone3 CLONE_CLEAR_SIGHAND optimization to posix_spawn
>>> aarch64: Add the clone3 wrapper
>>> Linux: optimize clone3 internal usage
>>>
>>> include/clone_internal.h | 37 +++-
>>> posix/Makefile | 3 +-
>>> posix/tst-spawn7.c | 179 ++++++++++++++++++
>>> sysdeps/unix/sysv/linux/Makefile | 3 +-
>>> sysdeps/unix/sysv/linux/aarch64/clone3.S | 85 +++++++++
>>> sysdeps/unix/sysv/linux/aarch64/sysdep.h | 2 +
>>> sysdeps/unix/sysv/linux/clone-internal.c | 59 ++++--
>>> sysdeps/unix/sysv/linux/clone3.h | 15 +-
>>> sysdeps/unix/sysv/linux/kernel-features.h | 9 +
>>> sysdeps/unix/sysv/linux/spawni.c | 33 +++-
>>> .../sysv/linux/tst-misalign-clone-internal.c | 74 --------
>>> sysdeps/unix/sysv/linux/x86_64/clone3.S | 3 -
>>> 12 files changed, 384 insertions(+), 118 deletions(-)
>>> create mode 100644 posix/tst-spawn7.c
>>> create mode 100644 sysdeps/unix/sysv/linux/aarch64/clone3.S
>>> delete mode 100644 sysdeps/unix/sysv/linux/tst-misalign-clone-internal.c
>>>
>>
>
next prev parent reply other threads:[~2023-01-19 14:39 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-12 13:58 Adhemerval Zanella
2023-01-12 13:58 ` [PATCH v4 1/6] linux: Do not reset signal handler in posix_spawn if it is already SIG_DFL Adhemerval Zanella
2023-01-18 22:24 ` Carlos O'Donell
2023-01-12 13:58 ` [PATCH v4 2/6] linux: Extend internal clone3 documentation Adhemerval Zanella
2023-01-18 22:25 ` Carlos O'Donell
2023-01-12 13:58 ` [PATCH v4 3/6] Linux: Do not align the stack for __clone3 Adhemerval Zanella
2023-01-18 22:26 ` Carlos O'Donell
2023-01-12 13:58 ` [PATCH v4 4/6] linux: Add clone3 CLONE_CLEAR_SIGHAND optimization to posix_spawn Adhemerval Zanella
2023-01-18 22:28 ` Carlos O'Donell
2023-01-12 13:58 ` [PATCH v4 5/6] aarch64: Add the clone3 wrapper Adhemerval Zanella
2023-01-18 22:29 ` Carlos O'Donell
2023-01-12 13:58 ` [PATCH v4 6/6] Linux: optimize clone3 internal usage Adhemerval Zanella
2023-01-18 22:31 ` Carlos O'Donell
2023-01-18 17:53 ` [PATCH v4 0/6] Optimize posix_spawn signal setup with clone3 Adhemerval Zanella Netto
2023-01-18 22:24 ` Carlos O'Donell
2023-01-19 14:39 ` Adhemerval Zanella Netto [this message]
2023-01-22 23:21 ` Carlos O'Donell
2023-02-28 16:34 ` H.J. Lu
2023-02-28 17:11 ` Adhemerval Zanella Netto
2023-02-28 18:09 ` Florian Weimer
2023-02-28 18:16 ` Adhemerval Zanella Netto
2023-02-28 19:07 ` H.J. Lu
2023-02-28 21:19 ` Andreas Schwab
2023-02-28 21:31 ` H.J. Lu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2c6cef85-bc1d-2ac3-7a1a-49c732134122@linaro.org \
--to=adhemerval.zanella@linaro.org \
--cc=carlos@redhat.com \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).