Peter Collingbourne via llvm-dev
2016-Nov-07 21:32 UTC
[llvm-dev] Errorifying the bitcode reader
Hi all, Just a heads up that I'm working on Errorifying the bitcode reader. Basically any errors that are currently being reported with the DiagnosticHandler would now be reported with an Error instead. It's turning out to be a rather large patch, but it should permit some much needed cleanups (e.g. not requiring an LLVMContext in some parts of the bitcode reader interface simply in order to provide a diagnostic handler) so I'm looking forward to the end result. Thanks, -- -- Peter -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20161107/959444f9/attachment.html>
Thanks Peter! (Both for the heads up and for doing this) — Mehdi> On Nov 7, 2016, at 1:32 PM, Peter Collingbourne <peter at pcc.me.uk> wrote: > > Hi all, > > Just a heads up that I'm working on Errorifying the bitcode reader. Basically any errors that are currently being reported with the DiagnosticHandler would now be reported with an Error instead. > > It's turning out to be a rather large patch, but it should permit some much needed cleanups (e.g. not requiring an LLVMContext in some parts of the bitcode reader interface simply in order to provide a diagnostic handler) so I'm looking forward to the end result. > > Thanks, > -- > -- > Peter
BTW I tried to do this a while ago, but held off on the patches because of the ThinLTO work I didn’t want to interfere with. The easiest way I could find to do it was to use Error internally, but stop at API boundaries. So all the BitCodeReader methods used publicly would still be std::error_code. That made for a manageable patch, then a follow on could propagate errors out of the API to the clients. Of course feel free to convert this however you feel is right. Just wanted to give some insight having done this before. Thanks, Pete> On Nov 7, 2016, at 1:35 PM, Mehdi Amini via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > Thanks Peter! > (Both for the heads up and for doing this) > > — > Mehdi > >> On Nov 7, 2016, at 1:32 PM, Peter Collingbourne <peter at pcc.me.uk> wrote: >> >> Hi all, >> >> Just a heads up that I'm working on Errorifying the bitcode reader. Basically any errors that are currently being reported with the DiagnosticHandler would now be reported with an Error instead. >> >> It's turning out to be a rather large patch, but it should permit some much needed cleanups (e.g. not requiring an LLVMContext in some parts of the bitcode reader interface simply in order to provide a diagnostic handler) so I'm looking forward to the end result. >> >> Thanks, >> -- >> -- >> Peter > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
Possibly Parallel Threads
- RFC: APIs for bitcode files containing multiple modules
- RFC: APIs for bitcode files containing multiple modules
- RFC: APIs for bitcode files containing multiple modules
- RFC: Adding a string table to the bitcode format
- RFC: APIs for bitcode files containing multiple modules