[PATCH] D99364: [clang][cache] Update Fuchsia-stage2.cmake to create hwasan multilibs

Leonard Chan via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 3 14:55:56 PDT 2021


leonardchan updated this revision to Diff 349700.
leonardchan added a comment.

Update to remove instrumentation on globals. It's likel we may not need the `hwasan+relative-vtables` multilibs when the next clang roll comes around.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D99364/new/

https://reviews.llvm.org/D99364

Files:
  clang/cmake/caches/Fuchsia-stage2.cmake


Index: clang/cmake/caches/Fuchsia-stage2.cmake
===================================================================
--- clang/cmake/caches/Fuchsia-stage2.cmake
+++ clang/cmake/caches/Fuchsia-stage2.cmake
@@ -244,7 +244,37 @@
     list(APPEND RUNTIME_BUILD_ID_LINK "${target}")
   endforeach()
 
-  set(LLVM_RUNTIME_MULTILIBS "asan;noexcept;compat;asan+noexcept;relative-vtables;relative-vtables+noexcept;relative-vtables+asan;relative-vtables+asan+noexcept" CACHE STRING "")
+  # HWAsan
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan_LLVM_BUILD_COMPILER_RT OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan_LLVM_USE_SANITIZER "HWAddress" CACHE STRING "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan_LIBCXXABI_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan_LIBCXX_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+
+  # HWASan+noexcept
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan+noexcept_LLVM_BUILD_COMPILER_RT OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan+noexcept_LLVM_USE_SANITIZER "HWAddress" CACHE STRING "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan+noexcept_LIBCXXABI_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan+noexcept_LIBCXX_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan+noexcept_LIBCXXABI_ENABLE_EXCEPTIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+hwasan+noexcept_LIBCXX_ENABLE_EXCEPTIONS OFF CACHE BOOL "")
+
+  # HWASan+relative-vtables
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan_LLVM_BUILD_COMPILER_RT OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan_LLVM_USE_SANITIZER "HWAddress" CACHE STRING "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan_LIBCXXABI_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan_LIBCXX_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan_CMAKE_CXX_FLAGS "${RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan_CMAKE_CXX_FLAGS} -fexperimental-relative-c++-abi-vtables -mllvm --hwasan-globals=0" CACHE STRING "")
+
+  # HWASan+relative-vtables+noexcept
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_LLVM_BUILD_COMPILER_RT OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_LLVM_USE_SANITIZER "HWAddress" CACHE STRING "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_LIBCXXABI_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_LIBCXX_ENABLE_NEW_DELETE_DEFINITIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_LIBCXXABI_ENABLE_EXCEPTIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_LIBCXX_ENABLE_EXCEPTIONS OFF CACHE BOOL "")
+  set(RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_CMAKE_CXX_FLAGS "${RUNTIMES_aarch64-unknown-fuchsia+relative-vtables+hwasan+noexcept_CMAKE_CXX_FLAGS} -fexperimental-relative-c++-abi-vtables -mllvm --hwasan-globals=0" CACHE STRING "")
+
+  set(LLVM_RUNTIME_MULTILIBS "asan;noexcept;compat;asan+noexcept;relative-vtables;relative-vtables+noexcept;relative-vtables+asan;relative-vtables+asan+noexcept;hwasan;hwasan+noexcept;relative-vtables+hwasan;relative-vtables+hwasan+noexcept" CACHE STRING "")
   set(LLVM_RUNTIME_MULTILIB_asan_TARGETS "x86_64-unknown-fuchsia;aarch64-unknown-fuchsia" CACHE STRING "")
   set(LLVM_RUNTIME_MULTILIB_noexcept_TARGETS "x86_64-unknown-fuchsia;aarch64-unknown-fuchsia" CACHE STRING "")
   set(LLVM_RUNTIME_MULTILIB_compat_TARGETS "x86_64-unknown-fuchsia;aarch64-unknown-fuchsia" CACHE STRING "")
@@ -253,6 +283,10 @@
   set(LLVM_RUNTIME_MULTILIB_relative-vtables+noexcept_TARGETS "x86_64-unknown-fuchsia;aarch64-unknown-fuchsia" CACHE STRING "")
   set(LLVM_RUNTIME_MULTILIB_relative-vtables+asan_TARGETS "x86_64-unknown-fuchsia;aarch64-unknown-fuchsia" CACHE STRING "")
   set(LLVM_RUNTIME_MULTILIB_relative-vtables+asan+noexcept_TARGETS "x86_64-unknown-fuchsia;aarch64-unknown-fuchsia" CACHE STRING "")
+  set(LLVM_RUNTIME_MULTILIB_hwasan_TARGETS "aarch64-unknown-fuchsia" CACHE STRING "")
+  set(LLVM_RUNTIME_MULTILIB_hwasan+noexcept_TARGETS "aarch64-unknown-fuchsia" CACHE STRING "")
+  set(LLVM_RUNTIME_MULTILIB_relative-vtables+hwasan_TARGETS "aarch64-unknown-fuchsia" CACHE STRING "")
+  set(LLVM_RUNTIME_MULTILIB_relative-vtables+hwasan+noexcept_TARGETS "aarch64-unknown-fuchsia" CACHE STRING "")
 endif()
 
 set(LLVM_BUILTIN_TARGETS "${BUILTIN_TARGETS}" CACHE STRING "")


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D99364.349700.patch
Type: text/x-patch
Size: 4776 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210603/8416cde1/attachment.bin>


More information about the cfe-commits mailing list