summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MachOWriter.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2007-02-03 02:39:40 +0000
committerBill Wendling <isanbard@gmail.com>2007-02-03 02:39:40 +0000
commitc27c70dc3dc08570594355a342f6b847dfb09c14 (patch)
tree2224d84ac2903a7a3eba1defc426cb1d752cb26c /llvm/lib/CodeGen/MachOWriter.cpp
parentf382ea30fd05c1acb755a9ab7de31053798bb38a (diff)
downloadbcm5719-llvm-c27c70dc3dc08570594355a342f6b847dfb09c14.tar.gz
bcm5719-llvm-c27c70dc3dc08570594355a342f6b847dfb09c14.zip
Pass in non-Mach-O-specific parameters to the GetTargetRelocation method.
llvm-svn: 33816
Diffstat (limited to 'llvm/lib/CodeGen/MachOWriter.cpp')
-rw-r--r--llvm/lib/CodeGen/MachOWriter.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/MachOWriter.cpp b/llvm/lib/CodeGen/MachOWriter.cpp
index bd7c5364968..d5958525a96 100644
--- a/llvm/lib/CodeGen/MachOWriter.cpp
+++ b/llvm/lib/CodeGen/MachOWriter.cpp
@@ -726,8 +726,13 @@ void MachOWriter::CalculateRelocations(MachOSection &MOS) {
TargetSection = MOSPtr->Index;
MR.setResultPointer((void*)Offset);
}
-
- GetTargetRelocation(MR, MOS, *SectionList[TargetSection-1], Scattered);
+
+ OutputBuffer RelocOut(MOS.RelocBuffer, is64Bit, isLittleEndian);
+ OutputBuffer SecOut(MOS.SectionData, is64Bit, isLittleEndian);
+ MachOSection &To = *SectionList[TargetSection - 1];
+
+ MOS.nreloc += GetTargetRelocation(MR, MOS.Index, To.addr, To.Index,
+ RelocOut, SecOut, Scattered);
}
}
OpenPOWER on IntegriCloud