summaryrefslogtreecommitdiff
path: root/test/Object
AgeCommit message (Collapse)Author
2016-10-18One more additional error check for invalid Mach-O files for aKevin Enderby
load command that use the MachO:: linkedit_data_command type but is not used in llvm libObject code but used in llvm tool code. This is for the LC_CODE_SIGNATURE load command. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284529 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-18Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load commands that use the MachO::routines_command and and MachO::routines_command_64 types but are not used in llvm libObject code but used in llvm tool code. This includes the LC_ROUTINES and LC_ROUTINES_64 load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284504 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-18[llvm-readobj] - Teach readobj to print ↵George Rimar
PT_OPENBSD_RANDOMIZE/PT_OPENBSD_WXNEEDED headers. These are OpenBSD specific program headers and currently we support them in LLD. Description of headers (just in case) available here: http://man.openbsd.org/OpenBSD-current/man5/elf.5 OpenBSD commits were: For PT_OPENBSD_RANDOMIZE: https://github.com/openbsd/src/commit/c494713c450d98da3f2e1451ee8c7fb675a7c461 For PT_OPENBSD_WXNEEDED: https://github.com/openbsd/src/commit/2a5a8fc7e30928c2cff57cfe5fb491c90d8478ad Differential revision: https://reviews.llvm.org/D25616 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284471 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-17Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load commands that use the MachO::sub_framework_command, MachO::sub_umbrella_command, MachO::sub_library_command and MachO::sub_client_command types but are not used in llvm libObject code but used in llvm tool code. This includes the LC_SUB_FRAMEWORK, LC_SUB_UMBRELLA, LC_SUB_LIBRARY and LC_SUB_CLIENT load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284431 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-17[Object/ELF] - Check Header->e_shoff value earlier and do not crash.George Rimar
Patch checks that section pointer is aligned properly. This should be done before getStringTable() call. Differential revision: https://reviews.llvm.org/D25462 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284387 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-17Recommit r284371 "[Object/ELF] - Check that e_shnum is null when e_shoff is."George Rimar
With fix: hex edited the precompiled inputs from another testcases to pass new checks. Original commit message: [Object/ELF] - Check that e_shnum is null when e_shoff is. Spec says (http://www.sco.com/developers/gabi/1998-04-29/ch4.eheader.html) : e_shnum This member holds the number of entries in the section header table. Thus the product of e_shentsize and e_shnum gives the section header table's size in bytes. If a file has no section header table, e_shnum holds the value zero. Revealed using "id_000037,sig_11,src_000015,op_havoc,rep_8" from PR30540 That was the reason of crash in lld on incorrect input file. Binary reduced using afl-min. Differential revision: https://reviews.llvm.org/D25090 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284374 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-17Revert r284371 "[Object/ELF] - Check that e_shnum is null when e_shoff is."George Rimar
It broke build bot: http://lab.llvm.org:8011/builders/clang-with-lto-ubuntu/builds/908/steps/test-stage1-compiler/logs/stdio git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284373 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-17[Object/ELF] - Check that e_shnum is null when e_shoff is.George Rimar
Spec says (http://www.sco.com/developers/gabi/1998-04-29/ch4.eheader.html) : e_shnum This member holds the number of entries in the section header table. Thus the product of e_shentsize and e_shnum gives the section header table's size in bytes. If a file has no section header table, e_shnum holds the value zero. Revealed using "id_000037,sig_11,src_000015,op_havoc,rep_8" from PR30540 That was the reason of crash in lld on incorrect input file. Binary reduced using afl-min. Differential revision: https://reviews.llvm.org/D25090 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284371 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-17[Object/ELF] - Do not crash on invalid section index.George Rimar
If object has wrong (large) string table index and also incorrect large value for amount of sections in total, then section index passes the check: if (Index >= getNumSections()) return object_error::invalid_section_index; But result pointer then is far after end of file data, what result in a crash. Differential revision: https://reviews.llvm.org/D25081 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284369 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-14[Support/ELF/AMDGPU] Add 32-bit lo/hi got and pc relative relocationsKonstantin Zhuravlyov
Added relocation names: - R_AMDGPU_GOTPCREL32_LO - R_AMDGPU_GOTPCREL32_HI - R_AMDGPU_REL32_LO - R_AMDGPU_REL32_HI AMDGPU isa only supports 32-bit immediates. In order to access 64-bit address we need to generate 32-bit lo/hi relocations, and do the right math (separate patch). Currently we only generate one 32 bit relocation for lower bits for each access, losing higher bits. Hence we need relocations listed above. Differential Revision: https://reviews.llvm.org/D25546 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284191 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-11Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load commands that uses the MachO::linker_option_command type but not used in llvm libObject code but used in llvm tool code. This includes just LC_LINKER_OPTION load command. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283939 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-11Reverted r283740 [Object/ELF] - Do not crash on invalid Header->e_shoff value.George Rimar
Bot does not like it: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/17075 /mnt/b/sanitizer-buildbot3/sanitizer-x86_64-linux-fast/build/llvm/test/Object/invalid.test:70:32: error: expected string not found in input INVALID-SEC-ADDRESS-ALIGNMENT: Invalid address alignment of section headers ^ <stdin>:1:1: note: scanning from here /mnt/b/sanitizer-buildbot3/sanitizer-x86_64-linux-fast/build/llvm/include/llvm/Object/ELF.h:412:7: runtime error: upcast of misaligned address 0x000002d8b899 for type 'llvm::object::Elf_Shdr_Impl<llvm::object::ELFType<llvm::support::endianness::little, true> >', which requires 2 byte alignment ^ <stdin>:1:125: note: possible intended match here /mnt/b/sanitizer-buildbot3/sanitizer-x86_64-linux-fast/build/llvm/include/llvm/Object/ELF.h:412:7: runtime error: upcast of misaligned address 0x000002d8b899 for type 'llvm::object::Elf_Shdr_Impl<llvm::object::ELFType<llvm::support::endianness::little, true> >', which requires 2 byte alignment git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283858 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-10[Object/ELF] - Do not crash on invalid Header->e_shoff value.George Rimar
sections_begin() may return unalignment pointer when Header->e_shoff isinvalid. That may result in a crash in clients, for example we have one in LLD: assert((PtrWord & ~PointerBitMask) == 0 && "Pointer is not sufficiently aligned"); fails when trying to push_back Elf_Shdr* (unaligned) into TinyPtrVector. Patch forces check for alignment of Header->e_shoff. Differential revision: https://reviews.llvm.org/D25368 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283740 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-06Centralize sh_entsize checking.Rafael Espindola
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283455 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-06Refactor to use getSectionContentsAsArray.Rafael Espindola
This centralizes quite a bit of error checking. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283454 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-04Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load commands that uses the MachO::encryption_info_command and MachO::encryption_info_command types but not used in llvm libObject code but used in llvm tool code. This includes just LC_ENCRYPTION_INFO and LC_ENCRYPTION_INFO_64 load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283250 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-04[Object/ELF] - Do not crash on invalid sh_offset value of REL[A] section.George Rimar
Previously code would access invalid memory and may crash, patch fixes the issue. Differential revision: https://reviews.llvm.org/D25187 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283204 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-04[Object/ELF] - Avoid possible crash in getExtendedSymbolTableIndex().George Rimar
When using broken input object found using AFL, getExtendedSymbolTableIndex() crashed because ShndxTable was empty as object does not contain SHT_SYMTAB_SHNDX section. Differential revision: https://reviews.llvm.org/D25189 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283196 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-29Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load command that uses the MachO::entry_point_command type but not used in llvm libObject code but used in llvm tool code. This includes just the LC_MAIN load command. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282766 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-29Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load command that uses the Mach::source_version_command type but not used in llvm libObject code but used in llvm tool code. This includes just the LC_SOURCE_VERSION load command. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282736 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-28Next set of additional error checks for invalid Mach-O files for theKevin Enderby
load command that uses the Mach::rpath_command type but not used in llvm libObject code but used in llvm tool code. This includes just the LC_RPATH load command. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282649 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-28Next set of additional error checks for invalid Mach-O files for theKevin Enderby
other load commands that use the Mach::version_min_command type but not used in llvm libObject code but used in llvm tool code. This includes LC_VERSION_MIN_MACOSX, LC_VERSION_MIN_IPHONEOS, LC_VERSION_MIN_TVOS and LC_VERSION_MIN_WATCHOS load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282635 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-27Next set of additional error checks for invalid Mach-O files for theKevin Enderby
other load commands that use the MachO::dylinker_command type but not used in llvm libObject code but used in llvm tool code. This includes LC_ID_DYLINKER, LC_LOAD_DYLINKER and LC_DYLD_ENVIRONMENT load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282553 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-26Next set of additional error checks for invalid Mach-O files for theKevin Enderby
other load commands that use the Mach::linkedit_data_command type but not used in llvm libObject code but used in llvm tool code. This includes LC_FUNCTION_STARTS, LC_SEGMENT_SPLIT_INFO and LC_DYLIB_CODE_SIGN_DRS load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282441 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-21Next set of additional error checks for invalid Mach-O files for bad LC_UUIDKevin Enderby
load commands. Added a missing check and made the check for more than one like other other “more than one” checks. And of course added test cases. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282104 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-20Next set of additional error checks for invalid Mach-O files for bad load ↵Kevin Enderby
commands that use the Mach::dylib_command type for the load commands that are currently used in the MachOObjectFile constructor. This contains the missing checks for LC_ID_DYLIB, LC_ID_DYLIB, etc. load commands and the fields for the Mach::dylib_command type. Also checks that only an MH_DYLIB or MH_STUB_DYLIB has an LC_ID_DYLIB load command (and others filetype don’t) and there is not more than one of these load commands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282008 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-15[IRObjectFile] Handle undefined weak symbols in RecordStreamer.Davide Italiano
Differential Revision: https://reviews.llvm.org/D24594 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@281629 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-14[Stackmap] Added callsite counts to emitted function information.Sanjoy Das
Summary: It was previously not possible for tools to use solely the stackmap information emitted to reconstruct the return addresses of callsites in the map, which is necessary to use the information to walk a stack. This patch adds per-function callsite counts when emitting the stackmap section in order to resolve the problem. Note that this slightly alters the stackmap format, so external tools parsing these maps will need to be updated. **Problem Details:** Records only store their offset from the beginning of the function they belong to. While these records and the functions are output in program order, it is not possible to determine where the end of one function's records are without the callsite count when processing the records to compute return addresses. Patch by Kavon Farvardin! Reviewers: atrick, ributzka, sanjoy Subscribers: nemanjai Differential Revision: https://reviews.llvm.org/D23487 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@281532 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-13Next set of additional error checks for invalid Mach-O files for bad load ↵Kevin Enderby
commands that use the Mach::dyld_info_command type for the load commands that are currently use in the MachOObjectFile constructor. This contains the missing checks for LC_DYLD_INFO and LC_DYLD_INFO_ONLY load commands and the fields for the Mach::dyld_info_command type. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@281400 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-31Next set of additional error checks for invalid Mach-O files for bad load ↵Kevin Enderby
commands that use the Mach::linkedit_data_command type for the load commands that are currently used in the MachOObjectFile constructor. This contains the missing checks for LC_DATA_IN_CODE and LC_LINKER_OPTIMIZATION_HINT load commands and the fields for the Mach::linkedit_data_command type. Checking for other load commands that use this type will be added later. Also fixed a couple of places that was using sizeof(MachOObjectFile::LoadCommandInfo) that should have been using sizeof(MachO::load_command). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@280267 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-30Add a test file, macho-invalid-dysymtab-extreloff-nextrel,Kevin Enderby
I forgot to do an svn add on. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@280167 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-30Next set of additional error checks for invalid Mach-O files for bad ↵Kevin Enderby
LC_DYSYMTAB’s. This contains the missing checks for LC_DYSYMTAB load command fields. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@280161 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-26Next set of additional error checks for invalid Mach-O files for bad ↵Kevin Enderby
LC_SYMTAB’s. This contains the missing checks for LC_SYMTAB load command fields. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@279854 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-17[AMDGPU] llvm-objdump: Skip amd_kernel_code_t only at the begining of kernel ↵Sam Kolton
symbol. Summary: This change fix bug in AMDGPU disassembly. Previously, presence of symbols other than kernel symbols caused objdump to skip begining of those symbols. Reviewers: tstellarAMD, vpykhtin, Bigcheese, ruiu Subscribers: kzhuravl, arsenm Differential Revision: http://reviews.llvm.org/D21966 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@278921 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-12Next set of additional error checks for invalid Mach-O files.Kevin Enderby
This contains the two missing checks for LC_SEGMENT load command fields. And checks for the Mach-O sections fields that would make them invalid. With the new checks, some of the existing malformed file checks now trips one of these instead of the issue it was having before so those tests were adjusted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@278557 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-05Add the first of what will be a long line of additional error checks for ↵Kevin Enderby
invalid Mach-O files. This is where an LC_SEGMENT load command has a fileoff field that extends past the end of the file. Also fix llvm-nm and llvm-size to remove the errorToErrorCode() call so error messages are printed. And needed to update a few test cases now that they do print the error messages just a bit differently. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@277845 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-03RecordStreamer: handle inline asm "lazy_reference" and mark symbols as "used"Mehdi Amini
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@277564 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-07Add checks to the MachOObjectFile() constructor to make sure load commands sizesKevin Enderby
are the correct multiple. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274798 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-28Finish cleaning up most of the error handling in libObject’s ↵Kevin Enderby
MachOUniversalBinary and its clients to use the new llvm::Error model for error handling. Changed getAsArchive() from ErrorOr<...> to Expected<...> so now all interfaces there use the new llvm::Error model for return values. In the two places it had if (!Parent) this is actually a program error so changed from returning errorCodeToError(object_error::parse_failed) to calling report_fatal_error() with a message. In getObjectForArch() added error messages to its two llvm::Error return values instead of returning errorCodeToError(object_error::arch_not_found) with no error message. For the llvm-obdump, llvm-nm and llvm-size clients since the only binary files in Mach-O Universal Binaries that are supported are Mach-O files or archives with Mach-O objects, updated their logic to generate an error when a slice contains something like an ELF binary instead of ignoring it. And added a test case for that. The last error stuff to be cleaned up for libObject’s MachOUniversalBinary is the use of errorOrToExpected(Archive::create(ObjBuffer)) which needs Archive::create() to be changed from ErrorOr<...> to Expected<...> first, which I’ll work on next. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274079 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-27Change all but the last ErrorOr<...> use for MachOUniversalBinary to ↵Kevin Enderby
Expected<...> to allow a good error message to be produced. I added the one test case that the object file tools could produce an error message. The other two errors can’t be triggered if the input file is passed through sys::fs::identify_magic(). But the malformedError("bad magic number") does get triggered by the logic in llvm-dsymutil when dealing with a normal Mach-O file. The other "File too small ..." error would take a logic error currently to produce and is not tested for. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273946 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-27[yaml2obj] Missed updating a few test cases in r273915Chris Bieneman
This should fix the broken bots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273918 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-27[yaml2obj] Remove --format option in favor of YAML tagsChris Bieneman
Summary: Our YAML library's handling of tags isn't perfect, but it is good enough to get rid of the need for the --format argument to yaml2obj. This patch does exactly that. Instead of requiring --format, it infers the format based on the tags found in the object file. The supported tags are: !ELF !COFF !mach-o !fat-mach-o I have a corresponding patch that is quite large that fixes up all the in-tree test cases. Reviewers: rafael, Bigcheese, compnerd, silvas Subscribers: compnerd, llvm-commits Differential Revision: http://reviews.llvm.org/D21711 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273915 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-22[IRObjectFile] Propagate .weak attribute correctly for ASM symbols.Davide Italiano
PR: 28256 Differential Revision: http://reviews.llvm.org/D21616 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273474 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-20Forgot to svn add one of my test files for the change in r273207.Kevin Enderby
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273208 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-20Add support for Darwin’s 64-bit universal files with 64-bit offsets and ↵Kevin Enderby
sizes for the objects. Darwin added support in its Xcode 8.0 tools (released in the beta) for universal files where offsets and sizes for the objects are 64-bits to allow support for objects contained in universal files to be larger then 4gb. The change is very straight forward. There is a new magic number that differs by one bit, much like the 64-bit Mach-O files. Then there is a new structure that follow the fat_header that has the same layout but with the offset and size fields using 64-bit values instead of 32-bit values. rdar://26899493 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273207 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-17Support/ELF: Add AMDGPU relocation definitions to match documentationTom Stellard
Reviewers: arsenm, kzhuravl, rafael Subscribers: llvm-commits, kzhuravl Differential Revision: http://reviews.llvm.org/D21443 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273066 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-17Add support for Darwin’s static library table of contents with 64-bit ↵Kevin Enderby
offsets to the archive members. Darwin added support in its Xcode 8.0 tools (released in the beta) for static library table of contents with 64-bit offsets to the archive members. The change is very straight forward. The table of contents member is named ___.SYMDEF_64 or "___.SYMDEF_64 SORTED" and same layout is used but with fields using 64 bit values instead of 32 bit values. rdar://26869808 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273058 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-17[IRObjectFile] Handle .weak in RecordStreamer.Davide Italiano
Differential Revision: http://reviews.llvm.org/D21476 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@273027 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-16Remove redundant -mattr options from llvm-objdump commands.Daniel Sanders
The -mattr options in these four tests have no effect on the output of llvm-objdump. In the case of the two Mips tests, removing the -mattr option left duplicate RUN lines so the duplicates have been removed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272906 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-16[llvm-objdump] Support detection of feature bits from the object and ↵Daniel Sanders
implement this for Mips. Summary: The Mips implementation only covers the feature bits described by the ELF e_flags so far. Mips stores additional feature bits such as MSA in the .MIPS.abiflags section. Also fixed a small bug this revealed where microMIPS wouldn't add the EF_MIPS_MICROMIPS flag when using -filetype=obj. Reviewers: echristo, rafael Subscribers: rafael, mehdi_amini, dsanders, sdardis, llvm-commits Differential Revision: http://reviews.llvm.org/D21125 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272880 91177308-0d34-0410-b5e6-96231b3b80d8