summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Remarks/BitstreamRemarkParser.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [Remarks] Allow empty temporary remark filesFrancis Visoiu Mistrih2019-11-221-0/+5
| | | | | | | When parsing bitstream remarks, allow external remark files to be empty, which means there are no remarks to be parsed. In the same way, dsymutil should not produce a remark file.
* Remarks - fix static analyzer warnings. NFCI.Simon Pilgrim2019-11-091-4/+4
| | | | | | | - Fix uninitialized variable warnings. - Reuse BitstreamEntry iterator to avoid Wshadow warning. - Match declaration + definition arg names in BitstreamRemarkParser::processCommonMeta - Make BitstreamRemarkParser(StringRef) constructor explicit
* Remarks - fix shadow variable warnings. NFCI.Simon Pilgrim2019-11-091-11/+13
| | | | Avoid conflict with llvm::remarks::Magic global variable.
* [Remarks] Add support for prepending a path to external filesFrancis Visoiu Mistrih2019-10-161-6/+16
| | | | | | | | | This helps with testing and debugging for paths that are assumed absolute. It also uses a FileError to provide the file path it's trying to open. llvm-svn: 375008
* Fix MSVC "not all control paths return a value" warning. NFCI.Simon Pilgrim2019-09-091-0/+1
| | | | llvm-svn: 371454
* [Remarks] Fix warning for uint8_t < 0 comparisonFrancis Visoiu Mistrih2019-09-091-4/+4
| | | | | | http://lab.llvm.org:8011/builders/clang-with-thin-lto-ubuntu/builds/19109/steps/build-stage1-compiler/logs/stdio llvm-svn: 371443
* [Remarks] Add parser for bitstream remarksFrancis Visoiu Mistrih2019-09-091-0/+586
The bitstream remark serializer landed in r367372. This adds a bitstream remark parser that parser bitstream remark files to llvm::remarks::Remark objects through the RemarkParser interface. A few interesting things to point out: * There are parsing helpers to parse the different types of blocks * The main parsing helper allows us to parse remark metadata and open an external file containing the encoded remarks * This adds a dependency from the Remarks library to the BitstreamReader library * The testing strategy is to create a remark entry through YAML, parse it, serialize it to bitstream, parse that back and compare the objects. * There are close to no tests for malformed bitstream remarks, due to the lack of textual format for the bitstream format. * This adds a new C API for parsing bitstream remarks: LLVMRemarkParserCreateBitstream. * This bumps the REMARKS_API_VERSION to 1. Differential Revision: https://reviews.llvm.org/D67134 llvm-svn: 371429
OpenPOWER on IntegriCloud