[PATCH] D139644: [InlineAdvisor] Allow loading advisors as plugins
Nico Weber via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 18 04:29:56 PST 2022
thakis added a comment.
The CMake setup here is pretty unusual. LLVM uses one target per cmake file almost everywhere, and many of the macros expect that. Maybe the plugin could be in a plugin/ subdir of the test and that might make things easier? clang/lib/Analysis/plugins/ has examples of that (which are loaded via lit).
(The two targets in unittests/Passes/CMakeLists.txt are _also_ unusual.)
> Thanks, looks good - just the thing about llvm-config.h.cmake, it's the canonical way to "convert" cmake flags to macro directives - so you wouldn't need to do :
That's not fully true. For things that are internal to llvm, that place is config.h I think. llvm-config.h is for places outside of LLVM.
(The two targets in unittests/Passes/CMakeLists.txt are _also_ unusual.)(The two targets in unittests/Passes/CMakeLists.txt are _also_ unusual.)
(And it's kind of not a great place since it means toggling a single cmake option means rebuilding all files that read any cmake setting, but it's the current setup.)
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D139644/new/
https://reviews.llvm.org/D139644
More information about the llvm-commits
mailing list