llvm.org GIT mirror llvm / 98e29d3
Merging r360442: ------------------------------------------------------------------------ r360442 | maskray | 2019-05-10 10:09:25 -0700 (Fri, 10 May 2019) | 12 lines [MC][ELF] Copy top 3 bits of st_other to .symver aliases On PowerPC64 ELFv2 ABI, the top 3 bits of st_other encode the local entry offset. A versioned symbol alias created by .symver should copy the bits from the source symbol. This partly fixes PR41048. A full fix needs tracking of .set assignments and updating st_other fields when finish() is called, see D56586. Patch by Alfredo Dal'Ava JĂșnior Differential Revision: https://reviews.llvm.org/D59436 ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362669 91177308-0d34-0410-b5e6-96231b3b80d8 Tom Stellard 2 months ago
2 changed file(s) with 18 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
12701270 // This is the first place we are able to copy this information.
12711271 Alias->setExternal(Symbol.isExternal());
12721272 Alias->setBinding(Symbol.getBinding());
1273 Alias->setOther(Symbol.getOther());
12731274
12741275 if (!Symbol.isUndefined() && !Rest.startswith("@@@"))
12751276 continue;
0 # RUN: llvm-mc -filetype=obj -triple=powerpc64-unknown-freebsd13.0 %s -o %t
1 # RUN: llvm-objdump -t %t | FileCheck %s
2
3 # CHECK: 0000000000000000 gw F .text 00000000 0x60 __impl_foo
4 # CHECK: 0000000000000000 g F .text 00000000 0x60 foo
5 # CHECK: 0000000000000000 gw F .text 00000000 0x60 foo@FBSD_1.1
6
7 .globl foo
8 .type foo,@function
9 foo:
10 nop
11 nop
12 .localentry foo, 8
13
14 .symver __impl_foo, foo@FBSD_1.1
15 .weak __impl_foo
16 .set __impl_foo, foo