summaryrefslogtreecommitdiff
path: root/libiberty/crc32.c
diff options
context:
space:
mode:
authoriains <iains@138bc75d-0d04-0410-961f-82ee72b054a4>2016-11-27 14:21:51 +0000
committeriains <iains@138bc75d-0d04-0410-961f-82ee72b054a4>2016-11-27 14:21:51 +0000
commit4f3ac3c871d691833e652b4de82794ce82b82ee6 (patch)
treedcec7dd9de9a0aeda8a665c8efb45d584526bb5f /libiberty/crc32.c
parent909ccf61309f9993ddca59cbb73eb9571a233cd9 (diff)
downloadgcc-4f3ac3c871d691833e652b4de82794ce82b82ee6.tar.gz
[Darwin, ld64] Make PIC indirections and constant labels linker-visible.
Indirections: If we have a situation like: global_weak_symbol: .... Lnon_weak_local: .... ld64 will be unable to split this into two atoms (because the "L" makes the second symbol 'invisible'). This means that legitimate direct accesses to the second symbol will appear to be non-allowed direct accesses to an atom of type weak, global which are not allowed. To avoid this, we make the indirections have a leading 'l' (lower-case L) which has a special meaning: linker can see this and use it to determine atoms, but it is not placed into the final symbol table. The implementation here is somewhat heavy-handed in that it will also mark indirections to the __IMPORT,__pointers section the same way which is really unnecessary, since ld64 _can_ split those into atoms as they are fixed size. FIXME: determine if this is a penalty worth extra code to fix. Similarly, with: .const weak_global_constant: .... LCxx: ... ld64 can't split the second, causing a warning when it's directly accessed. gcc/ 2016-11-27 Iain Sandoe <iain@codesourcery.com> PR target/71767 * config/darwin.c (imachopic_indirection_name): Make data section indirections linker-visible. * config/darwin.h (ASM_GENERATE_INTERNAL_LABEL): Make local constant labels linker-visible. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@242893 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty/crc32.c')
0 files changed, 0 insertions, 0 deletions