From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
To: Florian Weimer <fweimer@redhat.com>
Cc: Pavel Machek <pavel@ucw.cz>, carlos <carlos@redhat.com>,
Peter Zijlstra <peterz@infradead.org>,
"Paul E. McKenney" <paulmck@linux.vnet.ibm.com>,
Boqun Feng <boqun.feng@gmail.com>,
Thomas Gleixner <tglx@linutronix.de>,
linux-kernel <linux-kernel@vger.kernel.org>,
libc-alpha <libc-alpha@sourceware.org>
Subject: Re: Restartable Sequences system call merged into Linux
Date: Thu, 14 Jun 2018 13:46:00 -0000 [thread overview]
Message-ID: <1399480624.13011.1528984006717.JavaMail.zimbra@efficios.com> (raw)
In-Reply-To: <1110f198-88c2-544d-6836-f901b8e90f98@redhat.com>
----- On Jun 14, 2018, at 9:32 AM, Florian Weimer fweimer@redhat.com wrote:
> On 06/14/2018 03:25 PM, Pavel Machek wrote:
>
>> But the proposal wanted to add a syscall to thread creation, right?
>> And I believe that may be noticeable.
>
> We already call set_robust_list, so we could just pass a larger area to
> that and the kernel could use it. Then no additional system call would
> be needed in the common case (new kernel which recognizes the new area
> size).
>
> But then we cannot use an initial-exec thread local variable for it
> (although the offset from the thread pointer will still be constant, of
> course).
I'm wondering whether we could turn the problem around: expose a new
system call allowing to register an array of pointers to per-thread data,
which would be used rather than set_robust_list when available. This way,
we could register both the robust list and rseq with a single system call,
e.g.:
enum linux_tls_area_type {
LINUX_TLS_ROBUST_LIST,
LINUX_TLS_RSEQ,
};
struct linux_tls_area_item {
enum linux_tls_area_type type;
void *p;
};
long sys_register_tls_areas(struct linux_tls_area_item *array, size_t nb)
This would allow registering various TLS data structures with a single
system call without hindering flexibility on the user-space side. For
instance, we could still use initial-exec and the __rseq_abi symbol for
rseq with this approach.
Thoughts ?
Thanks,
Mathieu
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
next prev parent reply other threads:[~2018-06-14 13:46 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-11 19:49 Mathieu Desnoyers
2018-06-11 19:55 ` Florian Weimer
2018-06-11 20:04 ` Mathieu Desnoyers
2018-06-12 13:11 ` Florian Weimer
2018-06-12 16:31 ` Mathieu Desnoyers
2018-06-13 8:23 ` Florian Weimer
2018-06-14 12:28 ` Pavel Machek
2018-06-14 13:02 ` Mathieu Desnoyers
2018-06-14 13:26 ` Pavel Machek
2018-06-14 13:32 ` Florian Weimer
2018-06-14 13:46 ` Mathieu Desnoyers [this message]
2018-06-15 5:10 ` Florian Weimer
2018-06-15 17:44 ` Mathieu Desnoyers
2018-06-14 13:38 ` Mathieu Desnoyers
2018-06-14 13:50 ` Pavel Machek
2018-06-14 14:01 ` Florian Weimer
2018-06-14 14:36 ` Mathieu Desnoyers
2018-06-14 14:41 ` Florian Weimer
2018-06-14 15:09 ` Mathieu Desnoyers
2018-06-15 5:09 ` Florian Weimer
2018-06-15 17:50 ` Mathieu Desnoyers
2018-06-15 5:07 ` Florian Weimer
2018-06-13 11:48 ` Heiko Carstens
2018-06-13 16:14 ` Mathieu Desnoyers
2018-06-13 19:53 ` Mathieu Desnoyers
2018-07-11 16:03 ` Stefan Liebler
2018-07-11 16:23 ` Adhemerval Zanella
2018-07-11 17:19 ` Florian Weimer
2018-07-11 17:42 ` Adhemerval Zanella
2018-07-11 17:45 ` Florian Weimer
2018-07-11 17:59 ` Adhemerval Zanella
2018-07-12 8:08 ` Stefan Liebler
2018-07-11 19:05 ` Carlos O'Donell
2018-07-12 8:10 ` Szabolcs Nagy
2018-07-13 13:22 ` Stefan Liebler
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=1399480624.13011.1528984006717.JavaMail.zimbra@efficios.com \
--to=mathieu.desnoyers@efficios.com \
--cc=boqun.feng@gmail.com \
--cc=carlos@redhat.com \
--cc=fweimer@redhat.com \
--cc=libc-alpha@sourceware.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulmck@linux.vnet.ibm.com \
--cc=pavel@ucw.cz \
--cc=peterz@infradead.org \
--cc=tglx@linutronix.de \
/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).