Skip to content

Commit e877208

Browse files
committed
> Is the use of llvm-lto and opt here just to do testing before the clang and lld patches go in? If so, do we need cross project testing right now? Wondering if it would be better to just stick with the testing you have in this patch that is under llvm/test, and add the cross project testing using only external tools once those patches are in.
This test checks that the DTLTO code that the code that creates Clang command lines generates the expected options and that those options are accepted by clang. I wrote it to use llvm-lto and opt so it could be part of this commit before the clang and lld patches go in. However, I think it is a nice principle to only use external tools in cross-project-tests. I have removed the test from this PR with the intention of adding it back later. Additionally if we can use your idea (llvm#127749 (comment)) of storing the Clang `-c` step options and applying them to the remote backend compilations then this test will be rewritten to test that behaviour instead.
1 parent 88e6151 commit e877208

File tree

5 files changed

+3
-162
lines changed

5 files changed

+3
-162
lines changed

cross-project-tests/CMakeLists.txt

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,11 @@ set(CROSS_PROJECT_TEST_DEPS
1919
FileCheck
2020
check-gdb-llvm-support
2121
count
22-
llvm-config
2322
llvm-dwarfdump
24-
llvm-lto2
23+
llvm-config
2524
llvm-objdump
26-
not
27-
opt
2825
split-file
26+
not
2927
)
3028

3129
if ("clang" IN_LIST LLVM_ENABLE_PROJECTS)
@@ -96,13 +94,6 @@ add_lit_testsuite(check-cross-amdgpu "Running AMDGPU cross-project tests"
9694
DEPENDS clang
9795
)
9896

99-
# DTLTO tests.
100-
add_lit_testsuite(check-cross-dtlto "Running DTLTO cross-project tests"
101-
${CMAKE_CURRENT_BINARY_DIR}/dtlto
102-
EXCLUDE_FROM_CHECK_ALL
103-
DEPENDS ${CROSS_PROJECT_TEST_DEPS}
104-
)
105-
10697
# Add check-cross-project-* targets.
10798
add_lit_testsuites(CROSS_PROJECT ${CMAKE_CURRENT_SOURCE_DIR}
10899
DEPENDS ${CROSS_PROJECT_TEST_DEPS}

cross-project-tests/dtlto/README.md

Lines changed: 0 additions & 3 deletions
This file was deleted.

cross-project-tests/dtlto/dtlto-translate-options.ll

Lines changed: 0 additions & 142 deletions
This file was deleted.

cross-project-tests/dtlto/lit.local.cfg

Lines changed: 0 additions & 2 deletions
This file was deleted.

cross-project-tests/lit.cfg.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
config.test_format = lit.formats.ShTest(not llvm_config.use_lit_shell)
2020

2121
# suffixes: A list of file extensions to treat as test files.
22-
config.suffixes = [".c", ".cl", ".cpp", ".m", ".ll"]
22+
config.suffixes = [".c", ".cl", ".cpp", ".m"]
2323

2424
# excludes: A list of directories to exclude from the testsuite. The 'Inputs'
2525
# subdirectories contain auxiliary inputs for various tests in their parent
@@ -96,9 +96,6 @@ def get_required_attr(config, attr_name):
9696
if lldb_path is not None:
9797
config.available_features.add("lldb")
9898

99-
for tool in ["llvm-lto2", "opt"]:
100-
if llvm_config.use_llvm_tool(tool):
101-
config.available_features.add(tool)
10299

103100
def configure_dexter_substitutions():
104101
"""Configure substitutions for host platform and return list of dependencies"""

0 commit comments

Comments
 (0)