[ELF] -r: don't define __global_pointer$
authorFangrui Song <i@maskray.me>
Tue, 22 Nov 2022 20:37:51 +0000 (12:37 -0800)
committerFangrui Song <i@maskray.me>
Tue, 22 Nov 2022 20:37:51 +0000 (12:37 -0800)
commitd9ef5574d4e37af394d7bd53ab7e2534949c5c63
treea01ea03dba8a5b2b0e9e34592c4d85281e6228bb
parent0c011335c9c6b0c0598f8fa7393af5e8aad428a2
[ELF] -r: don't define __global_pointer$

This symbol is supposed to be defined by the final executable link. The new
behavor matches GNU ld.
lld/ELF/Symbols.cpp
lld/ELF/Symbols.h
lld/ELF/Writer.cpp
lld/test/ELF/riscv-gp.s