aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Object/XCOFFObjectFile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Object/XCOFFObjectFile.cpp')
-rw-r--r--llvm/lib/Object/XCOFFObjectFile.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/llvm/lib/Object/XCOFFObjectFile.cpp b/llvm/lib/Object/XCOFFObjectFile.cpp
index 6e54e4a..86e8c2ea 100644
--- a/llvm/lib/Object/XCOFFObjectFile.cpp
+++ b/llvm/lib/Object/XCOFFObjectFile.cpp
@@ -214,7 +214,7 @@ uint64_t XCOFFObjectFile::getCommonSymbolSizeImpl(DataRefImpl Symb) const {
Expected<SymbolRef::Type>
XCOFFObjectFile::getSymbolType(DataRefImpl Symb) const {
- llvm_unreachable("Not yet implemented!");
+ // TODO: Return the correct symbol type.
return SymbolRef::ST_Other;
}
@@ -394,7 +394,7 @@ void XCOFFObjectFile::getRelocationTypeName(
Expected<uint32_t> XCOFFObjectFile::getSymbolFlags(DataRefImpl Symb) const {
uint32_t Result = 0;
- llvm_unreachable("Not yet implemented!");
+ // TODO: Return correct symbol flags.
return Result;
}
@@ -513,6 +513,11 @@ XCOFFObjectFile::getSymbolSectionName(XCOFFSymbolRef SymEntPtr) const {
}
}
+unsigned XCOFFObjectFile::getSymbolSectionID(SymbolRef Sym) const {
+ XCOFFSymbolRef XCOFFSymRef(Sym.getRawDataRefImpl(), this);
+ return XCOFFSymRef.getSectionNumber();
+}
+
bool XCOFFObjectFile::isReservedSectionNumber(int16_t SectionNumber) {
return (SectionNumber <= 0 && SectionNumber >= -2);
}