llvm-project/libcxx/cmake/Modules
Louis Dionne e0184357fc [libc++] Link against libatomic when it is found
Before this patch, we tried detecting whether small atomics were available
without linking against libatomic. However, that's not really what we want
to know -- instead, we want to know what's required in order to support
atomics fully, which is to link against libatomic when it's provided.

That is both much simpler, and it doesn't suffer the problem that we would
not link against libatomic when small atomics didn't require it, which
lead to non-lockfree atomics never working.

Furthermore, because we understand that some platforms might not want to
(or be able to) ship non-lockfree atomics, we add that notion to the test
suite, independently of a potential extern library.

After this patch, we therefore:
(1) Link against libatomic when it is provided
(2) Independently detect whether non-lockfree atomics are supported in
    the test suite, regardless of whether that means we're linking against
    an external library or not (which is an implementation detail).

Differential Revision: https://reviews.llvm.org/D81190
2020-06-05 09:28:44 -04:00
..
CodeCoverage.cmake Change test coverage generation to use llvm-cov instead of gcov. 2017-03-11 03:24:18 +00:00
DefineLinkerScript.cmake [libc++] Fix linker script generation 2019-10-11 04:54:35 +00:00
HandleCompilerRT.cmake [CMake] Passthrough CFLAGS when checking the compiler-rt path 2018-11-14 00:09:26 +00:00
HandleLibCXXABI.cmake [libc++] NFC: fix typos 2020-05-01 13:10:30 -04:00
HandleLibcxxFlags.cmake [libc++][CMake] Refactor how we link against system libraries 2019-04-30 15:44:19 +00:00
HandleOutOfTreeLLVM.cmake Provide a meaningful diagnostic when LLVM_PATH doesn't point to a directory 2019-08-19 23:51:26 +00:00
MacroEnsureOutOfSourceBuild.cmake