[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug gold/22791] Don't error when a -pie executable uses a shared functi
From: |
rafael.espindola at gmail dot com |
Subject: |
[Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation |
Date: |
Tue, 06 Feb 2018 01:49:33 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=22791
--- Comment #9 from Rafael Ávila de Espíndola <rafael.espindola at gmail dot
com> ---
(In reply to Cary Coutant from comment #8)
> (In reply to Rafael Ávila de Espíndola from comment #5)
> > (In reply to Cary Coutant from comment #4)
> > > This would be fine if we knew for a fact that the relocation is on a call
> > > instruction. The problem is that R_X86_64_PC32 isn't always a call
> > > instruction.
> >
> > It still works. The library will see the address of the got entry.
>
> Which won't necessarily be the "official" PLT entry. Function point
> comparison may break.
Not sure what you mean by "official". The testcase I uploaded computes address
of an external function foo with
movslq bar(%rip), %rax
leaq bar(%rip), %rdi
addq %rax, %rdi
...
.data
.p2align 3
bar:
.long foo - .
and in a shared library foo is defined as
void foo(void *bar) {
printf("%p %p\n", bar, foo);
}
I always get the same value printed twice.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without a got, (continued)
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without a got, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without a got, amodra at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without a got, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without a got, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without a got, ccoutant at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, hjl.tools at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, ccoutant at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation,
rafael.espindola at gmail dot com <=
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, ccoutant at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, rafael.espindola at gmail dot com, 2018/02/05
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, hjl.tools at gmail dot com, 2018/02/06
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, ccoutant at gmail dot com, 2018/02/06
- [Bug gold/22791] Don't error when a -pie executable uses a shared function without PIC/PIE relocation, hjl.tools at gmail dot com, 2018/02/06
- [Bug gas/22791] PLT32 should be used for 32-bit PC-relative branches, hjl.tools at gmail dot com, 2018/02/07
- [Bug gas/22791] PLT32 should be used for 32-bit PC-relative branches, rafael.espindola at gmail dot com, 2018/02/07
- [Bug gas/22791] PLT32 should be used for 32-bit PC-relative branches, hjl.tools at gmail dot com, 2018/02/07
- [Bug gas/22791] PLT32 should be used for 32-bit PC-relative branches, cvs-commit at gcc dot gnu.org, 2018/02/13
- [Bug gas/22791] PLT32 should be used for 32-bit PC-relative branches, hjl.tools at gmail dot com, 2018/02/13