[libcxx-commits] [libcxxabi] 65b1b3b - [libc++][libc++abi] Serialize the enable_assertions Lit parameter in the generated config

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Tue Mar 29 05:17:34 PDT 2022


Author: Louis Dionne
Date: 2022-03-29T08:17:25-04:00
New Revision: 65b1b3b961cf0337a007e5646431abf2b7aff334

URL: https://github.com/llvm/llvm-project/commit/65b1b3b961cf0337a007e5646431abf2b7aff334
DIFF: https://github.com/llvm/llvm-project/commit/65b1b3b961cf0337a007e5646431abf2b7aff334.diff

LOG: [libc++][libc++abi] Serialize the enable_assertions Lit parameter in the generated config

This means that re-running with llvm-lit in that configuration will
work as expected. This also enables assertions in libc++abi in the
Generic-assertions CI job, which was disabled previously.

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

Added: 
    

Modified: 
    libcxx/cmake/caches/Generic-assertions.cmake
    libcxx/test/CMakeLists.txt
    libcxxabi/test/CMakeLists.txt

Removed: 
    


################################################################################
diff  --git a/libcxx/cmake/caches/Generic-assertions.cmake b/libcxx/cmake/caches/Generic-assertions.cmake
index 18eb86601cf16..a1d348ea9b331 100644
--- a/libcxx/cmake/caches/Generic-assertions.cmake
+++ b/libcxx/cmake/caches/Generic-assertions.cmake
@@ -1,3 +1,2 @@
 set(LIBCXX_ENABLE_ASSERTIONS ON CACHE BOOL "")
-set(LIBCXX_TEST_PARAMS "enable_assertions=True" CACHE STRING "")
-set(LIBCXXABI_TEST_PARAMS "enable_assertions=True" CACHE STRING "")
+set(LIBCXXABI_ENABLE_ASSERTIONS ON CACHE BOOL "")

diff  --git a/libcxx/test/CMakeLists.txt b/libcxx/test/CMakeLists.txt
index 1c9445b542a0b..ebabc706d3f0b 100644
--- a/libcxx/test/CMakeLists.txt
+++ b/libcxx/test/CMakeLists.txt
@@ -104,6 +104,10 @@ if (NOT LIBCXX_ENABLE_DEBUG_MODE_SUPPORT)
   serialize_lit_param(enable_debug_tests False)
 endif()
 
+if (LIBCXX_ENABLE_ASSERTIONS)
+  serialize_lit_param(enable_assertions True)
+endif()
+
 if (CMAKE_CXX_COMPILER_TARGET)
   serialize_lit_param(target_triple "\"${CMAKE_CXX_COMPILER_TARGET}\"")
 else()

diff  --git a/libcxxabi/test/CMakeLists.txt b/libcxxabi/test/CMakeLists.txt
index 608e5f35fb1cb..c695069e64e44 100644
--- a/libcxxabi/test/CMakeLists.txt
+++ b/libcxxabi/test/CMakeLists.txt
@@ -79,6 +79,10 @@ if (NOT LIBCXXABI_ENABLE_EXCEPTIONS)
   serialize_lit_param(enable_exceptions False)
 endif()
 
+if (LIBCXXABI_ENABLE_ASSERTIONS)
+  serialize_lit_param(enable_assertions True)
+endif()
+
 serialize_lit_param(enable_experimental False)
 
 if (LLVM_USE_SANITIZER)


        


More information about the libcxx-commits mailing list