[PATCH] D101763: [analyzer][ctu] Avoid parsing invocation list again and again during on-demand parsing of CTU
Balázs Benics via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon May 3 10:47:05 PDT 2021
steakhal added a comment.
Awesome! Seems good to me. Though I've got limited experience on CTU stuff.
It would be nice to have tests, but it seems pretty hard to come up with one for this. Given that this is just a 'performance' issue, I'm fine with it.
Somehow try to check if this resolved your original concern.
================
Comment at: clang/include/clang/CrossTU/CrossTranslationUnit.h:41
enum class index_error_code {
+ no_error = 0,
unspecified = 1,
----------------
What about `success`?
That way it would resonate well with the return's `success()`;
================
Comment at: clang/lib/CrossTU/CrossTranslationUnit.cpp:691
+ ExpectedInvocationList.takeError(),
+ [&](IndexError &E) { InvocationListParsingError = E.getCode(); });
+ return llvm::make_error<IndexError>(InvocationListParsingError);
----------------
Shouldn't be small enough to pass-by-value?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D101763/new/
https://reviews.llvm.org/D101763
More information about the cfe-commits
mailing list