summaryrefslogtreecommitdiffstats
path: root/llvm/lib/TextAPI
Commit message (Collapse)AuthorAgeFilesLines
* [TextAPI][elfabi] Fix YAML support for weak symbolsArmando Montanez2018-12-211-0/+1
| | | | | | | | | | | Weak symbols are supposed to be supported in the ELF TextAPI implementation, but the YAML handler didn't read or write the `Weak` member of ELFSymbol. This change adds the YAML mapping and updates tests to ensure correct behavior. Differential Revision: https://reviews.llvm.org/D56020 llvm-svn: 349950
* [TextAPI][elfabi] Make SoName optionalArmando Montanez2018-12-111-1/+1
| | | | | | | | | | | This change makes DT_SONAME treated as an optional trait for ELF TextAPI stubs. This change accounts for the fact that shared objects aren't guaranteed to have a DT_SONAME entry. Tests have been updated to check for correct behavior of an optional soname. Differential Revision: https://reviews.llvm.org/D55533 llvm-svn: 348817
* [TextAPI][elfabi] Fix build by adding std::move() to r348735Armando Montanez2018-12-101-1/+1
| | | | llvm-svn: 348736
* [TextAPI][elfabi] Make TBE handlers functions that return ErrorsArmando Montanez2018-12-101-4/+5
| | | | | | | | | | | | Since TBEHandler doesn't maintain state or otherwise have any need to be a class right now, the read and write functions have been moved out and turned into standalone functions. Additionally, the TBE read function has been updated to return an Expected value for better error handling. Tests have been updated to reflect these changes. Differential Revision: https://reviews.llvm.org/D55450 llvm-svn: 348735
* [llvm-tapi] Don't try to override SequenceTraits for std::stringSam Clegg2018-12-071-17/+0
| | | | | | | | | | | | | | | | For some reason this doesn't seem to work with LLVM_LINK_LLVM_DYLIB build. See https://logs.chromium.org/logs/chromium/bb/client.wasm.llvm/linux/37764/+/recipes/steps/LLVM_regression_tests/0/stdout What is more it seems that overriding these traits for core types (including std::string) is not supported/recommend by YAMLTraits.h. See line 1918 which has the assertion: "only use LLVM_YAML_IS_SEQUENCE_VECTOR for types you control" Differential Revision: https://reviews.llvm.org/D55381 llvm-svn: 348630
* Revert "[llvm-tapi] Don't override SequenceTraits for std::string"Armando Montanez2018-12-071-17/+12
| | | | | | Revert r348551 since it triggered some warnings that don't appear to have a quick fix. llvm-svn: 348560
* [llvm-tapi] Don't override SequenceTraits for std::stringArmando Montanez2018-12-061-12/+17
| | | | | | | | | | | | | | Change the ELF YAML implementation of TextAPI so NeededLibs uses flow sequence vector correctly instead of overriding the YAML implementation for std::vector<std::string>>. This should fix the test failure with the LLVM_LINK_LLVM_DYLIB build mentioned in D55381. Still passes existing tests that cover this. Differential Revision: https://reviews.llvm.org/D55390 llvm-svn: 348551
* [TextAPI] Remove a superfluous semicolon, fixing GCC warnings. NFC.Martin Storsjo2018-12-031-1/+1
| | | | llvm-svn: 348179
* [llvm-tapi] initial commit, supports ELF text stubsArmando Montanez2018-12-034-0/+234
| | | | | | | | | | | | | | | | | | | http://lists.llvm.org/pipermail/llvm-dev/2018-September/126472.html TextAPI is a library and accompanying tool that allows conversion between binary shared object stubs and textual counterparts. The motivations and uses cases for this are explained thoroughly in the llvm-dev proposal [1]. This initial commit proposes a potential structure for the TAPI library, also including support for reading/writing text-based ELF stubs (.tbe) in addition to preliminary support for reading binary ELF files. The goal for this patch is to ensure the project architecture appropriately welcomes integration of Mach-O stubbing from Apple's TAPI [2]. Added: - TextAPI library - .tbe read support - .tbe write (to raw_ostream) support [1] http://lists.llvm.org/pipermail/llvm-dev/2018-September/126472.html [2] https://github.com/ributzka/tapi Differential Revision: https://reviews.llvm.org/D53051 llvm-svn: 348170
* Revert r347823 "[TextAPI] Switch back to a custom Platform enum."Hans Wennborg2018-11-2911-1394/+0
| | | | | | | | | It broke the Windows buildbots, e.g. http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/21829/steps/test/logs/stdio This also reverts the follow-ups: r347824, r347827, and r347836. llvm-svn: 347874
* Revert "[TextAPI] Fix a memory leak in the TBD reader."Juergen Ributzka2018-11-291-4/+2
| | | | llvm-svn: 347838
* [TextAPI] Fix a memory leak in the TBD reader.Juergen Ributzka2018-11-291-2/+4
| | | | | | | This fixes an issue where we were leaking the YAML document if there was a parsing error. llvm-svn: 347837
* [TextAPI] Switch back to a custom Platform enum.Juergen Ributzka2018-11-293-25/+26
| | | | | | | | | Moving to PlatformType from BinaryFormat had some UB fallout when handing unknown platforms or malformed input files. This should fix the sanitizer bots. llvm-svn: 347836
* [TextAPI] TBD Reader/WriterJuergen Ributzka2018-11-2911-0/+1393
| | | | | | | | | | | | | | | | | Add basic infrastructure for reading and writting TBD files (version 1 - 3). The TextAPI library is not used by anything yet (besides the unit tests). Tool support will be added in a separate commit. The TBD format is currently documented in the implementation file (TextStub.cpp). https://reviews.llvm.org/D53945 Update: This contains changes to fix issues discovered by the bots: - add parentheses to silence warnings. - rename variables - use PlatformType from BinaryFormat llvm-svn: 347823
* Revert "[TextAPI] TBD Reader/Writer"Juergen Ributzka2018-11-2811-1398/+0
| | | | | | Reverting to unbreak bots. llvm-svn: 347809
* [TextAPI] TBD Reader/WriterJuergen Ributzka2018-11-2811-0/+1398
Add basic infrastructure for reading and writting TBD files (version 1 - 3). The TextAPI library is not used by anything yet (besides the unit tests). Tool support will be added in a separate commit. The TBD format is currently documented in the implementation file (TextStub.cpp). https://reviews.llvm.org/D53945 llvm-svn: 347808
OpenPOWER on IntegriCloud