mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-23 02:32:11 +00:00
gcc often inserts it's own names for sections (e.g.
gnu.linkonce.t.FunctionName). Convert them to "normal" LLVM names, otherwise linker won't be able to merge them. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32958 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c2ca99c15a
commit
cea9d1d634
@ -80,6 +80,11 @@ bool X86ATTAsmPrinter::runOnMachineFunction(MachineFunction &MF) {
|
|||||||
|
|
||||||
X86SharedAsmPrinter::decorateName(CurrentFnName, F);
|
X86SharedAsmPrinter::decorateName(CurrentFnName, F);
|
||||||
|
|
||||||
|
// Change GNU linkonce to LLVM linkonce name
|
||||||
|
if (F->hasSection() &&
|
||||||
|
(F->getSection().find(".gnu.linkonce.t") != std::string::npos))
|
||||||
|
SwitchToTextSection(getSectionForFunction(*F).c_str(), NULL);
|
||||||
|
else
|
||||||
SwitchToTextSection(getSectionForFunction(*F).c_str(), F);
|
SwitchToTextSection(getSectionForFunction(*F).c_str(), F);
|
||||||
|
|
||||||
switch (F->getLinkage()) {
|
switch (F->getLinkage()) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user