[PATCH] D61446: Generalize the pass registration mechanism used by Polly to any third-party tool
Chris Bieneman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 5 10:26:02 PDT 2019
beanz added inline comments.
================
Comment at: llvm/cmake/modules/AddLLVM.cmake:820
+
+ set(LLVM_ALL_EXTENSION_TARGETS clang;bugpoint;opt)
+ foreach(tool ${LLVM_ALL_EXTENSION_TARGETS})
----------------
I don't think we should hard code this list. It would be much better if we add an option to `llvm_add_executable` so that extension targets denote themselves.
================
Comment at: llvm/cmake/modules/AddLLVM.cmake:822
+ foreach(tool ${LLVM_ALL_EXTENSION_TARGETS})
+ if(TARGET ${tool})
+ set_property(TARGET ${tool} APPEND PROPERTY LLVM_COMPILER_EXTENSIONS ${llvm_extension_project})
----------------
`if(TARGET ...)` is order dependent. That's why you need to change tools/CMakeLists.txt, which you won't need to do if you change this to work how I suggested in my earlier comment.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61446/new/
https://reviews.llvm.org/D61446
More information about the cfe-commits
mailing list