blob: 345af0008bf58d8fba7ae298916b94c781de75a0 [file] [log] [blame]
Clement Courbet44b4c542018-06-19 11:28:59 +00001if (LLVM_TARGETS_TO_BUILD MATCHES "X86")
2 add_subdirectory(X86)
John Brawn346856d2018-07-02 13:53:46 +00003 set(LLVM_EXEGESIS_TARGETS "${LLVM_EXEGESIS_TARGETS} X86" PARENT_SCOPE)
Clement Courbet44b4c542018-06-19 11:28:59 +00004endif()
John Brawnc4ed6002018-07-03 10:10:29 +00005if (LLVM_TARGETS_TO_BUILD MATCHES "AArch64")
6 add_subdirectory(AArch64)
7 set(LLVM_EXEGESIS_TARGETS "${LLVM_EXEGESIS_TARGETS} AArch64" PARENT_SCOPE)
8endif()
Clement Courbet44b4c542018-06-19 11:28:59 +00009
Nico Weberb09a8c92018-09-15 19:04:27 +000010add_library(LLVMExegesis
11 STATIC
Clement Courbet37f0ca02018-05-15 12:08:00 +000012 Analysis.cpp
Clement Courbet0e69e2d2018-05-17 10:52:18 +000013 Assembler.cpp
Clement Courbetac74acd2018-04-04 11:37:06 +000014 BenchmarkResult.cpp
15 BenchmarkRunner.cpp
Clement Courbet96715412018-05-07 09:09:48 +000016 Clustering.cpp
Clement Courbetac74acd2018-04-04 11:37:06 +000017 Latency.cpp
18 LlvmState.cpp
Clement Courbet0e69e2d2018-05-17 10:52:18 +000019 MCInstrDescView.cpp
Clement Courbetac74acd2018-04-04 11:37:06 +000020 PerfHelper.cpp
Clement Courbet0e69e2d2018-05-17 10:52:18 +000021 RegisterAliasing.cpp
Clement Courbetd939f6d2018-09-13 07:40:53 +000022 SnippetGenerator.cpp
Guillaume Chateletcd488ef2018-09-17 11:09:32 +000023 RegisterValue.cpp
Clement Courbet44b4c542018-06-19 11:28:59 +000024 Target.cpp
Clement Courbetac74acd2018-04-04 11:37:06 +000025 Uops.cpp
Nico Weberb09a8c92018-09-15 19:04:27 +000026 )
Clement Courbetac74acd2018-04-04 11:37:06 +000027
Nico Weberb09a8c92018-09-15 19:04:27 +000028llvm_update_compile_flags(LLVMExegesis)
29llvm_map_components_to_libnames(libs
Clement Courbet908dd382018-04-04 12:58:41 +000030 Analysis
Clement Courbetac74acd2018-04-04 11:37:06 +000031 CodeGen
Clement Courbet908dd382018-04-04 12:58:41 +000032 Core
Clement Courbetac74acd2018-04-04 11:37:06 +000033 ExecutionEngine
Clement Courbet559d1e32018-05-15 07:40:21 +000034 GlobalISel
Clement Courbetac74acd2018-04-04 11:37:06 +000035 MC
Clement Courbet4273e1e2018-06-15 07:30:45 +000036 MCDisassembler
Clement Courbetac74acd2018-04-04 11:37:06 +000037 MCJIT
Clement Courbet908dd382018-04-04 12:58:41 +000038 Object
Clement Courbet4273e1e2018-06-15 07:30:45 +000039 ObjectYAML
Clement Courbetac74acd2018-04-04 11:37:06 +000040 Support
41 )
Nico Weberb09a8c92018-09-15 19:04:27 +000042
43if(LLVM_ENABLE_LIBPFM AND HAVE_LIBPFM)
44 list(APPEND libs pfm)
45endif()
46
47target_link_libraries(LLVMExegesis ${libs})
48set_target_properties(LLVMExegesis PROPERTIES FOLDER "Libraries")