public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* GNU libc support for extensible rseq ABI
@ 2023-05-18 17:48 Mathieu Desnoyers
  2023-05-18 18:06 ` Florian Weimer
  0 siblings, 1 reply; 3+ messages in thread
From: Mathieu Desnoyers @ 2023-05-18 17:48 UTC (permalink / raw)
  To: carlos, Florian Weimer, libc-alpha

Hi Carlos, Florian,

Now that the 6.3 Linux kernel is out, the ABI for extensible rseq is 
frozen, and we could add support for it in glibc. It would be good to 
upstream this support before we run out of room in the padding space we 
currently re-use.

What glibc release should we target for this ?

You can find the librseq code supporting the extensible rseq ABI here:

https://git.kernel.org/pub/scm/libs/librseq/librseq.git/

specifically under src/rseq.c.

Thanks!

Mathieu

-- 
Mathieu Desnoyers
EfficiOS Inc.
https://www.efficios.com

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

* Re: GNU libc support for extensible rseq ABI
  2023-05-18 17:48 GNU libc support for extensible rseq ABI Mathieu Desnoyers
@ 2023-05-18 18:06 ` Florian Weimer
  2023-11-01 14:45   ` Mathieu Desnoyers
  0 siblings, 1 reply; 3+ messages in thread
From: Florian Weimer @ 2023-05-18 18:06 UTC (permalink / raw)
  To: Mathieu Desnoyers; +Cc: carlos, libc-alpha

* Mathieu Desnoyers:

> Hi Carlos, Florian,
>
> Now that the 6.3 Linux kernel is out, the ABI for extensible rseq is 
> frozen, and we could add support for it in glibc. It would be good to 
> upstream this support before we run out of room in the padding space we 
> currently re-use.
>
> What glibc release should we target for this ?

It may be possible to hack this into the existing TLS allocator.  See
the loop in _dl_determine_tlsoffset.  It should be possible to add the
rseq area as another static TLS block (perhaps as the first one before
the loop), with the size and alignment requested by the kernel.  If we
can make that work, it's going to be a fairly small patch that should
be backportable as well.  That could go into 2.38 or 2.39.

If we need a new TLS allocator, it's definitely 2.39 material at this
point, potentially later.

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

* Re: GNU libc support for extensible rseq ABI
  2023-05-18 18:06 ` Florian Weimer
@ 2023-11-01 14:45   ` Mathieu Desnoyers
  0 siblings, 0 replies; 3+ messages in thread
From: Mathieu Desnoyers @ 2023-11-01 14:45 UTC (permalink / raw)
  To: Florian Weimer, Michael Jeanson; +Cc: carlos, libc-alpha

On 2023-05-18 14:06, Florian Weimer wrote:
> * Mathieu Desnoyers:
> 
>> Hi Carlos, Florian,
>>
>> Now that the 6.3 Linux kernel is out, the ABI for extensible rseq is
>> frozen, and we could add support for it in glibc. It would be good to
>> upstream this support before we run out of room in the padding space we
>> currently re-use.
>>
>> What glibc release should we target for this ?
> 
> It may be possible to hack this into the existing TLS allocator.  See
> the loop in _dl_determine_tlsoffset.  It should be possible to add the
> rseq area as another static TLS block (perhaps as the first one before
> the loop), with the size and alignment requested by the kernel.  If we
> can make that work, it's going to be a fairly small patch that should
> be backportable as well.  That could go into 2.38 or 2.39.
> 
> If we need a new TLS allocator, it's definitely 2.39 material at this
> point, potentially later.

Michael (in CC) showed interest in working on this. I'm adding him to 
this e-mail thread so you are both aware of each other's ongoing progress.

Thanks,

Mathieu

-- 
Mathieu Desnoyers
EfficiOS Inc.
https://www.efficios.com


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

end of thread, other threads:[~2023-11-01 14:45 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-18 17:48 GNU libc support for extensible rseq ABI Mathieu Desnoyers
2023-05-18 18:06 ` Florian Weimer
2023-11-01 14:45   ` Mathieu Desnoyers

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