From: Michael Jeanson <mjeanson@efficios.com>
To: "H.J. Lu" <hjl.tools@gmail.com>
Cc: libc-alpha@sourceware.org,
Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Subject: Re: [PATCH] nptl: fix potential merge of __rseq_* relro symbols
Date: Mon, 15 Jan 2024 16:34:00 -0500 [thread overview]
Message-ID: <308d8dd5-551c-403f-a634-23990be2db64@efficios.com> (raw)
In-Reply-To: <CAMe9rOq2gyh6Ccp+Ub14jT-wRZULGkhvVodMVyRaapNtPXQkRA@mail.gmail.com>
On 2024-01-15 16:20, H.J. Lu wrote:
>> +/* Due to the use of '-fmerge-all-constants' the compiler is allowed to merge
>> + all 'const' variables of the same size that are initialized to the same
>> + value. To work around this, declare them as regular static variable and use
>> + an alias that is 'const'. */
>> +static unsigned int rseq_size attribute_relro;
>> +extern const unsigned int __attribute__ ((alias ("rseq_size"))) __rseq_size;
>> +static ptrdiff_t rseq_offset attribute_relro;
>> +extern const ptrdiff_t __attribute__ ((alias ("rseq_offset"))) __rseq_offset;
>
> Don't you want to mark them as hidden if they are internal to glibc?
Indeed, the static variables should be hidden, I thought the build system was
setup to make them by default, I'll send a v2.
Thanks,
Michael
next prev parent reply other threads:[~2024-01-15 21:34 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-15 21:09 Michael Jeanson
2024-01-15 21:20 ` H.J. Lu
2024-01-15 21:34 ` Michael Jeanson [this message]
2024-01-15 21:44 ` Michael Jeanson
2024-01-16 11:25 ` Florian Weimer
2024-01-16 15:28 ` Michael Jeanson
2024-01-22 22:11 ` [PATCH v2] " Michael Jeanson
2024-01-22 22:13 ` Michael Jeanson
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=308d8dd5-551c-403f-a634-23990be2db64@efficios.com \
--to=mjeanson@efficios.com \
--cc=hjl.tools@gmail.com \
--cc=libc-alpha@sourceware.org \
--cc=mathieu.desnoyers@efficios.com \
/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).