[PATCH] D142888: [compiler-rt] Fix scudo build on ARM

Leandro Lupori via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 27 07:22:48 PDT 2023


luporl marked 2 inline comments as done.
luporl added inline comments.


================
Comment at: compiler-rt/lib/scudo/standalone/CMakeLists.txt:49
+  set(SCUDO_LINK_LIBS ${COMPILER_RT_UNWINDER_LINK_LIBS} dl)
+elseif(COMPILER_RT_HAS_GWP_ASAN AND "${LLVM_NATIVE_ARCH}" STREQUAL "ARM")
+  # On ARM, we must link against an unwind lib when GWPAsan is used, otherwise
----------------
phosek wrote:
> I don't think this is the right condition. `LLVM_NATIVE_ARCH` defaults to host architecture where LLVM is being built, but that may be different from the architecture we're compiling compiler-rt for when cross-compiling.
> 
> We should likely be using `if (CAN_TARGET_arm)`. Should this apply to both `arm` and `armhf`?
We definitely want this for `armhf` too.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D142888



More information about the llvm-commits mailing list