public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: "H.J. Lu" <hjl.tools@gmail.com>
To: Alan Modra <amodra@gmail.com>
Cc: Binutils <binutils@sourceware.org>
Subject: Re: V6 [PATCH] x86: Only allow S - A relocations against absolute symbol
Date: Thu, 2 Apr 2020 04:54:29 -0700	[thread overview]
Message-ID: <CAMe9rOqr8+mUw3ga-AnV=p3hWBPW-E2JfJ4Ko=s5yiXPXu+v4A@mail.gmail.com> (raw)
In-Reply-To: <20200402032454.GD4583@bubble.grove.modra.org>

On Wed, Apr 1, 2020 at 8:25 PM Alan Modra <amodra@gmail.com> wrote:
>
> Seen here on Ubuntu 18.04 when using a number of different gcc
> versions.
>
> FAIL: Run pr25749-1bb (-no-pie -fno-PIE)
> FAIL: Run pr25749-1bb (-pie -fPIE)
> FAIL: Run pr25749-2ab (-no-pie -fno-PIE)
> FAIL: Run pr25749-2ab (-pie -fPIE)

Ubuntu 18.04 has glibc 2.27 which doesn't have

commit e7feec374c635b6a29d65c39ae5e1855528fed39
Author: Maciej W. Rozycki <macro@mips.com>
Date:   Wed Apr 4 23:09:37 2018 +0100

    elf: Correct absolute (SHN_ABS) symbol run-time calculation [BZ #19818]

    Do not relocate absolute symbols by the base address.  Such symbols have
    SHN_ABS as the section index and their value is not supposed to be
    affected by relocation as per the ELF gABI[1]:

    "SHN_ABS
        The symbol has an absolute value that will not change because of
        relocation."

Glibc 2.28 and above are OK.

-- 
H.J.

  reply	other threads:[~2020-04-02 11:55 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-31  4:43 H.J. Lu
2020-03-31  6:17 ` Fangrui Song
2020-03-31 14:31   ` H.J. Lu
2020-03-31 23:25     ` V3 " H.J. Lu
2020-04-01  3:30       ` V4 " H.J. Lu
2020-04-01 14:06         ` V5 " H.J. Lu
2020-04-01 21:28           ` V6 " H.J. Lu
2020-04-02  3:24             ` Alan Modra
2020-04-02 11:54               ` H.J. Lu [this message]
2020-04-02 14:10                 ` 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='CAMe9rOqr8+mUw3ga-AnV=p3hWBPW-E2JfJ4Ko=s5yiXPXu+v4A@mail.gmail.com' \
    --to=hjl.tools@gmail.com \
    --cc=amodra@gmail.com \
    --cc=binutils@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).