diff options
author | David Majnemer <david.majnemer@gmail.com> | 2014-11-06 21:46:55 +0000 |
---|---|---|
committer | David Majnemer <david.majnemer@gmail.com> | 2014-11-06 21:46:55 +0000 |
commit | 504165df71bd8f852141f2a9fb74a8448c9896f1 (patch) | |
tree | c5717d281a2fc1be2911fe1419a67c161ed92b7f /llvm/lib/Object | |
parent | d1e71108d07ba14c4f46ab372799bbc4b24e4afa (diff) | |
download | bcm5719-llvm-504165df71bd8f852141f2a9fb74a8448c9896f1.tar.gz bcm5719-llvm-504165df71bd8f852141f2a9fb74a8448c9896f1.zip |
Object, COFF: Don't consider AuxFunctionDefinition for getSymbolSize
mingw lies about the size of a function's AuxFunctionDefinition. Ignore
the field and rely on our heuristic to determine the symbol's size.
llvm-svn: 221485
Diffstat (limited to 'llvm/lib/Object')
-rw-r--r-- | llvm/lib/Object/COFFObjectFile.cpp | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/llvm/lib/Object/COFFObjectFile.cpp b/llvm/lib/Object/COFFObjectFile.cpp index 7a0892dd98d..eea84c78762 100644 --- a/llvm/lib/Object/COFFObjectFile.cpp +++ b/llvm/lib/Object/COFFObjectFile.cpp @@ -240,16 +240,6 @@ std::error_code COFFObjectFile::getSymbolSize(DataRefImpl Ref, Result = Symb.getValue(); return object_error::success; } - if (Symb.isFunctionDefinition()) { - ArrayRef<uint8_t> AuxData = getSymbolAuxData(Symb); - if (!AuxData.empty()) { - const auto *CAFD = - reinterpret_cast<const coff_aux_function_definition *>( - AuxData.data()); - Result = CAFD->TotalSize; - return object_error::success; - } - } // Let's attempt to get the size of the symbol by looking at the address of // the symbol after the symbol in question. |