You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[test] Fix various module cache bugs and inconsistencies
Currently, lit tests don't set neither the module cache for building
inferiors nor the module cache used by lldb when running tests.
Furthermore, we have several places where we rely on the path to the
module cache being always the same, rather than passing the correct
value around. This makes it hard to specify a different module cache
path when debugging a a test.
This patch reworks how we determine and pass around the module cache
paths and fixes the omission on the lit side. It also adds a sanity
check to the lit and dotest suites.
Differential revision: https://reviews.llvm.org/D66966
llvm-svn: 370394
Copy file name to clipboardExpand all lines: lldb/lit/CMakeLists.txt
+3
Original file line number
Diff line number
Diff line change
@@ -15,6 +15,9 @@ endif()
15
15
get_property(LLDB_DOTEST_ARGS GLOBAL PROPERTY LLDB_DOTEST_ARGS_PROPERTY)
16
16
set(dotest_args_replacement ${LLVM_BUILD_MODE})
17
17
18
+
set(LLDB_TEST_MODULE_CACHE_LLDB "${LLDB_TEST_BUILD_DIRECTORY}/module-cache-lldb"CACHEPATH"The Clang module cache used by the Clang embedded in LLDB while running tests.")
19
+
set(LLDB_TEST_MODULE_CACHE_CLANG "${LLDB_TEST_BUILD_DIRECTORY}/module-cache-clang"CACHEPATH"The Clang module cache used by the Clang while building tests.")
20
+
18
21
if(LLDB_BUILT_STANDALONE)
19
22
# In paths to our build-tree, replace CMAKE_CFG_INTDIR with our configuration name placeholder.
Copy file name to clipboardExpand all lines: lldb/packages/Python/lldbsuite/test/dotest_args.py
+5
Original file line number
Diff line number
Diff line change
@@ -147,6 +147,11 @@ def create_parser():
147
147
metavar='Test build directory',
148
148
default='lldb-test-build.noindex',
149
149
help='The root build directory for the tests. It will be removed before running.')
150
+
group.add_argument(
151
+
'--module-cache-dir',
152
+
dest='module_cache_dir',
153
+
metavar='The clang module cache directory used by LLDB',
154
+
help='The clang module cache directory used by LLDB. This is not the one used by the makefiles. Defaults to <test build directory>/module-cache-lldb.')
0 commit comments