mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-28 07:17:32 +00:00
Fixed ObjectFile functions:
- getSymbolOffset() renamed as getSymbolFileOffset() - getSymbolFileOffset(), getSymbolAddress(), getRelocationAddress() returns same result for ELFObjectFile, MachOObjectFile and COFFObjectFile. - added getRelocationOffset() - fixed MachOObjectFile::getSymbolSize() - fixed MachOObjectFile::getSymbolSection() - fixed MachOObjectFile::getSymbolOffset() for symbols without section data. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145180 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -150,9 +150,9 @@ uint64_t LLVMGetSymbolAddress(LLVMSymbolIteratorRef SI) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
uint64_t LLVMGetSymbolOffset(LLVMSymbolIteratorRef SI) {
|
||||
uint64_t LLVMGetSymbolFileOffset(LLVMSymbolIteratorRef SI) {
|
||||
uint64_t ret;
|
||||
if (error_code ec = (*unwrap(SI))->getOffset(ret))
|
||||
if (error_code ec = (*unwrap(SI))->getFileOffset(ret))
|
||||
report_fatal_error(ec.message());
|
||||
return ret;
|
||||
}
|
||||
@@ -172,6 +172,13 @@ uint64_t LLVMGetRelocationAddress(LLVMRelocationIteratorRef RI) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
uint64_t LLVMGetRelocationOffset(LLVMRelocationIteratorRef RI) {
|
||||
uint64_t ret;
|
||||
if (error_code ec = (*unwrap(RI))->getOffset(ret))
|
||||
report_fatal_error(ec.message());
|
||||
return ret;
|
||||
}
|
||||
|
||||
LLVMSymbolIteratorRef LLVMGetRelocationSymbol(LLVMRelocationIteratorRef RI) {
|
||||
SymbolRef ret;
|
||||
if (error_code ec = (*unwrap(RI))->getSymbol(ret))
|
||||
|
Reference in New Issue
Block a user