[X86] Added i1 vector sextload tests
[oota-llvm.git] / test / CMakeLists.txt
1 if(LLVM_BUILD_EXAMPLES)
2   set(ENABLE_EXAMPLES 1)
3 endif()
4
5 configure_lit_site_cfg(
6   ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in
7   ${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg
8   )
9 configure_lit_site_cfg(
10   ${CMAKE_CURRENT_SOURCE_DIR}/Unit/lit.site.cfg.in
11   ${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
12   )
13
14 # Don't include check-llvm into check-all without LLVM_BUILD_TOOLS.
15 if(NOT LLVM_BUILD_TOOLS)
16   set(EXCLUDE_FROM_ALL ON)
17 endif()
18
19 # Set the depends list as a variable so that it can grow conditionally.
20 # NOTE: Sync the substitutions in test/lit.cfg when adding to this list.
21 set(LLVM_TEST_DEPENDS
22           llvm-config
23           UnitTests
24           BugpointPasses
25           LLVMHello
26           bugpoint
27           llc
28           lli
29           lli-child-target
30           llvm-ar
31           llvm-as
32           llvm-bcanalyzer
33           llvm-c-test
34           llvm-cov
35           llvm-cxxdump
36           llvm-diff
37           llvm-dis
38           llvm-dsymutil
39           llvm-dwarfdump
40           llvm-extract
41           llvm-lib
42           llvm-link
43           llvm-lto
44           llvm-mc
45           llvm-mcmarkup
46           llvm-nm
47           llvm-objdump
48           llvm-profdata
49           llvm-ranlib
50           llvm-readobj
51           llvm-rtdyld
52           llvm-size
53           llvm-split
54           llvm-symbolizer
55           llvm-tblgen
56           macho-dump
57           opt
58           FileCheck
59           count
60           not
61           yaml-bench
62           yaml2obj
63           obj2yaml
64           verify-uselistorder
65         )
66
67 # If Intel JIT events are supported, depend on a tool that tests the listener.
68 if( LLVM_USE_INTEL_JITEVENTS )
69   set(LLVM_TEST_DEPENDS ${LLVM_TEST_DEPENDS} llvm-jitlistener)
70 endif( LLVM_USE_INTEL_JITEVENTS )
71
72 if(TARGET LLVMgold)
73   set(LLVM_TEST_DEPENDS ${LLVM_TEST_DEPENDS} LLVMgold)
74 endif()
75
76 if(TARGET llvm-go)
77   set(LLVM_TEST_DEPENDS ${LLVM_TEST_DEPENDS} llvm-go)
78 endif()
79
80 if(APPLE)
81   set(LLVM_TEST_DEPENDS ${LLVM_TEST_DEPENDS} LTO)
82 endif()
83
84 if(TARGET ocaml_llvm)
85   set(LLVM_TEST_DEPENDS ${LLVM_TEST_DEPENDS}
86           ocaml_llvm
87           ocaml_llvm_all_backends
88           ocaml_llvm_analysis
89           ocaml_llvm_bitreader
90           ocaml_llvm_bitwriter
91           ocaml_llvm_executionengine
92           ocaml_llvm_irreader
93           ocaml_llvm_linker
94           ocaml_llvm_target
95           ocaml_llvm_ipo
96           ocaml_llvm_passmgr_builder
97           ocaml_llvm_scalar_opts
98           ocaml_llvm_transform_utils
99           ocaml_llvm_vectorize
100         )
101 endif()
102
103 if(LLVM_BUILD_EXAMPLES)
104   list(APPEND LLVM_TEST_DEPENDS
105     Kaleidoscope-Ch3
106     Kaleidoscope-Ch4
107     Kaleidoscope-Ch5
108     Kaleidoscope-Ch6
109     Kaleidoscope-Ch7
110     )
111 endif()
112
113 add_lit_testsuite(check-llvm "Running the LLVM regression tests"
114   ${CMAKE_CURRENT_BINARY_DIR}
115   PARAMS llvm_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg
116          llvm_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
117   DEPENDS ${LLVM_TEST_DEPENDS}
118   )
119 set_target_properties(check-llvm PROPERTIES FOLDER "Tests")
120
121 add_lit_testsuites(LLVM ${CMAKE_CURRENT_SOURCE_DIR}
122   PARAMS llvm_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg
123          llvm_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
124   DEPENDS ${LLVM_TEST_DEPENDS}
125   )
126
127 # Setup a legacy alias for 'check-llvm'. This will likely change to be an
128 # alias for 'check-all' at some point in the future.
129 add_custom_target(check)
130 add_dependencies(check check-llvm)
131 set_target_properties(check PROPERTIES FOLDER "Tests")