Implement getLazyBitcodeModule() and parseBitcodeFile() in terms of it.
Details
Diff Detail
- Build Status
Buildable 1286 Build 1286: arc lint + arc unit
Event Timeline
llvm/include/llvm/Bitcode/BitcodeReader.h | ||
---|---|---|
48 | Can you document these two fields? | |
llvm/lib/Bitcode/Reader/BitcodeReader.cpp | ||
850 | Why not in the initializer list? | |
6607 | I think it is used only on error, isn't it? We may be able to pass the IdentificationBit to the BitcodeReader and have it jump there to get the ProducerIdentification only if needed. Might not worth the effort though. | |
llvm/test/Bitcode/invalid.test | ||
38 | I'm surprised by this change, is it really intended? I suspect that some of your change is losing coverage here. (Same on most of the changes below) |
llvm/include/llvm/Bitcode/BitcodeReader.h | ||
---|---|---|
48 | Will do | |
llvm/lib/Bitcode/Reader/BitcodeReader.cpp | ||
850 | This field belongs to BitcodeReaderBase. | |
6607 | We also need to check the epoch in the identification block. I suppose we could have two functions, one that checks the epoch and the other that pulls the producer string, but again it doesn't seem worth the effort. | |
llvm/test/Bitcode/invalid.test | ||
38 | Unfortunately some of our invalid bitcode files also have an invalid block size in addition to the problem under test, so we get an error trying to skip past the module in getBitcodeModuleList(). I'll see if I can restore coverage for these, but it may be some work as it will require binary patching of our test files. |
llvm/test/Bitcode/invalid.test | ||
---|---|---|
38 | Yeah that's really annoying. |
llvm/test/Bitcode/invalid.test | ||
---|---|---|
38 | Sounds reasonable to me. |
Can you document these two fields?