1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 11:02:59 +02:00
llvm-mirror/unittests/Support/CMakeLists.txt
Pavel Labath 79a60cfd95 Add Chrono.h - std::chrono support header
Summary:
std::chrono mostly covers the functionality of llvm::sys::TimeValue and
lldb_private::TimeValue. This header adds a bit of utility functions and
typedefs, which make the usage of the library and porting code from TimeValues
easier.

Rationale:
- TimePoint typedef - precision of system_clock is implementation defined -
  using a well-defined precision helps maintain consistency between platforms,
  makes it interact better with existing TimeValue classes, and avoids cases
  there a time point is implicitly convertible to a specific precision on some
  platforms but not on others.
- system_clock::to_time_t only accepts time_points with the default system
  precision (even though time_t has only second precision on all platforms we
  support). To avoid the need for explicit casts, I have added a toTimeT()
  wrapper function. toTimePoint(time_t) was not strictly necessary, but I have
  added it for symmetry.

Reviewers: zturner, mehdi_amini

Subscribers: beanz, mgorny, llvm-commits, modocache

Differential Revision: https://reviews.llvm.org/D25416

llvm-svn: 284590
2016-10-19 13:58:55 +00:00

63 lines
1.2 KiB
CMake

set(LLVM_LINK_COMPONENTS
Support
)
add_llvm_unittest(SupportTests
AlignOfTest.cpp
AllocatorTest.cpp
ArrayRecyclerTest.cpp
BlockFrequencyTest.cpp
BranchProbabilityTest.cpp
Casting.cpp
Chrono.cpp
CommandLineTest.cpp
CompressionTest.cpp
ConvertUTFTest.cpp
DataExtractorTest.cpp
DwarfTest.cpp
EndianStreamTest.cpp
EndianTest.cpp
ErrorTest.cpp
ErrorOrTest.cpp
FileOutputBufferTest.cpp
Host.cpp
LEB128Test.cpp
LineIteratorTest.cpp
LockFileManagerTest.cpp
MD5Test.cpp
ManagedStatic.cpp
MathExtrasTest.cpp
MemoryBufferTest.cpp
MemoryTest.cpp
Path.cpp
ProcessTest.cpp
ProgramTest.cpp
RegexTest.cpp
ReplaceFileTest.cpp
ScaledNumberTest.cpp
SourceMgrTest.cpp
SpecialCaseListTest.cpp
StreamingMemoryObjectTest.cpp
StringPool.cpp
SwapByteOrderTest.cpp
TargetParserTest.cpp
Threading.cpp
ThreadLocalTest.cpp
ThreadPool.cpp
TimerTest.cpp
TimeValueTest.cpp
TypeNameTest.cpp
TrailingObjectsTest.cpp
UnicodeTest.cpp
YAMLIOTest.cpp
YAMLParserTest.cpp
formatted_raw_ostream_test.cpp
raw_ostream_test.cpp
raw_pwrite_stream_test.cpp
raw_sha1_ostream_test.cpp
xxhashTest.cpp
)
# ManagedStatic.cpp uses <pthread>.
target_link_libraries(SupportTests ${PTHREAD_LIB})