Project

General

Profile

Actions

Bug #13481

closed

ld(1) should skip GCC local aliases when building symsort sections

Added by Rich Lowe 10 months ago. Updated 10 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
tools - gate/build tools
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

GCC now creates local aliases for some global symbols, so that it has a name that cannot be interposed etc, by which to refer to them.
We should prevent these from getting into symbol sort sections like .SUNW_dynsymsort

Actions #1

Updated by Electric Monk 10 months ago

  • Gerrit CR set to 1203
Actions #2

Updated by Rich Lowe 10 months ago

Toomas tested with his GCC10 tree.

I tested with a simple asm file to create both kinds of symbol

        .local foo.localalias
        .type foo.localalias,@function
foo.localalias:
        ret
        .size foo.localalias,.-foo.localalias

        .local foo.localalias.10
        .type foo.localalias.10,@function
foo.localalias.10:
        ret
        .size foo.localalias.10,.-foo.localalias.10
Actions #3

Updated by Rich Lowe 10 months ago

The asm file above grew to include symbols, "foo.localalias." "foo.localalias.t10" and "foo.localalias.10t" none of which should be elided.

Actions #4

Updated by Electric Monk 10 months ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

git commit a8facf2616619e45ebfa3de1fa4def4b433a0245

commit  a8facf2616619e45ebfa3de1fa4def4b433a0245
Author: Richard Lowe <richlowe@richlowe.net>
Date:   2021-02-08T20:43:30.000Z

    13481 ld(1) should skip GCC local aliases when building symsort sections
    Reviewed by: C Fraire <cfraire@me.com>
    Reviewed by: Jason King <jason.brian.king+illumos@gmail.com>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Approved by: Dan McDonald <danmcd@joyent.com>

Actions

Also available in: Atom PDF