[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1488546469.1564.1547169116539.JavaMail.zimbra@efficios.com>
Date: Thu, 10 Jan 2019 20:11:56 -0500 (EST)
From: Mathieu Desnoyers <mathieu.desnoyers@...icios.com>
To: Florian Weimer <fweimer@...hat.com>
Cc: carlos <carlos@...hat.com>, Joseph Myers <joseph@...esourcery.com>,
Szabolcs Nagy <szabolcs.nagy@....com>,
libc-alpha <libc-alpha@...rceware.org>,
Thomas Gleixner <tglx@...utronix.de>,
Ben Maurer <bmaurer@...com>,
Peter Zijlstra <peterz@...radead.org>,
"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
Boqun Feng <boqun.feng@...il.com>,
Will Deacon <will.deacon@....com>,
Dave Watson <davejwatson@...com>, Paul Turner <pjt@...gle.com>,
Rich Felker <dalias@...c.org>,
linux-kernel <linux-kernel@...r.kernel.org>,
linux-api <linux-api@...r.kernel.org>
Subject: Re: [RFC PATCH glibc 1/4] glibc: Perform rseq(2) registration at
nptl init and thread creation (v4)
----- On Jan 10, 2019, at 12:31 PM, Mathieu Desnoyers mathieu.desnoyers@...icios.com wrote:
> ----- On Dec 11, 2018, at 2:40 AM, Florian Weimer fweimer@...hat.com wrote:
[...]
>>
>>> diff --git a/nptl/Versions b/nptl/Versions
>>> index e7f691da7a..f7890f73fc 100644
>>> --- a/nptl/Versions
>>> +++ b/nptl/Versions
>>> @@ -277,6 +277,10 @@ libpthread {
>>> cnd_timedwait; cnd_wait; tss_create; tss_delete; tss_get; tss_set;
>>> }
>>>
>>> + GLIBC_2.29 {
>>> + __rseq_refcount;
>>> + }
>>
>> Why put this into libpthread, and __rseq_abi into libc?
>
> The __rseq_abi symbol should be available to the glibc memory allocator.
> I plan to move the __rseq_abi to sysdeps/unix/sysv/linux/Versions instead
> so it becomes Linux-specific.
>
> The __rseq_refcount symbol only needs to be made available to applications
> and libraries linking against libpthread, because only libpthread actually
> handles the rseq registration/unregistration at thread start/exit and
> library initialization.
>
> However, considering that we want this to be Linux-specific as well,
> I could move it to sysdeps/unix/sysv/linux/Versions too.
>
> Then it would make sense to move the __rseq_refcount symbol defined in
> nptl/rseq.c to sysdeps/unix/sysv/linux/rseq.c as well and group
> everything together.
>
> Therefore, both symbols will end up in sysdeps/unix/sysv/linux/Versions.
Now that I think about it, it's important to move the rseq registration
done at nptl init (in my current code) to some lower-level csu initialiation,
so applications that happen _not_ to link against libpthread also get
registered rseq for the main thread.
Does it make sense ?
Thanks,
Mathieu
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
Powered by blists - more mailing lists