summaryrefslogtreecommitdiff
path: root/lib/MC/WinCOFFObjectWriter.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2010-09-30 02:22:20 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2010-09-30 02:22:20 +0000
commit7070387f08f7dc797b554ed8013cba9f8b74121a (patch)
treeb2551756c1093c8e4396c9c2596eca5f8657fd51 /lib/MC/WinCOFFObjectWriter.cpp
parent7ebc863c156c5ccd127045ddb8d663c3b49ac5f3 (diff)
downloadllvm-7070387f08f7dc797b554ed8013cba9f8b74121a.tar.gz
llvm-7070387f08f7dc797b554ed8013cba9f8b74121a.tar.bz2
llvm-7070387f08f7dc797b554ed8013cba9f8b74121a.tar.xz
Make it possible for the MCObjectWriter to decide if a given fixup is fully
resolved or not. Different object files have different restrictions and different native assemblers have different idiosyncrasies we want to emulate for now. Move the existing MachO logic to the new place and implement an ELF one that gets fixups to globals right. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115131 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC/WinCOFFObjectWriter.cpp')
-rw-r--r--lib/MC/WinCOFFObjectWriter.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/MC/WinCOFFObjectWriter.cpp b/lib/MC/WinCOFFObjectWriter.cpp
index 6bebe46f96..1cc5c09a08 100644
--- a/lib/MC/WinCOFFObjectWriter.cpp
+++ b/lib/MC/WinCOFFObjectWriter.cpp
@@ -181,6 +181,11 @@ public:
MCValue Target,
uint64_t &FixedValue);
+ virtual bool IsFixupFullyResolved(const MCAssembler &Asm,
+ const MCValue Target,
+ bool IsPCRel,
+ const MCFragment *DF) const;
+
void WriteObject(const MCAssembler &Asm, const MCAsmLayout &Layout);
};
}
@@ -690,6 +695,13 @@ void WinCOFFObjectWriter::RecordRelocation(const MCAssembler &Asm,
coff_section->Relocations.push_back(Reloc);
}
+bool WinCOFFObjectWriter::IsFixupFullyResolved(const MCAssembler &Asm,
+ const MCValue Target,
+ bool IsPCRel,
+ const MCFragment *DF) const {
+ return false;
+}
+
void WinCOFFObjectWriter::WriteObject(const MCAssembler &Asm,
const MCAsmLayout &Layout) {
// Assign symbol and section indexes and offsets.