[PATCH] D150505: [cmake] Disable GCC lifetime DSE

Xi Ruoyao via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat May 13 23:42:35 PDT 2023


xry111 added a comment.

In D150505#4340437 <https://reviews.llvm.org/D150505#4340437>, @thesamesam wrote:

> I can only reproduce it with a GCC-built LLVM.
>
> Anyway, given `LLVM_COMPILER_IS_GCC_COMPATIBLE` is true for Clang (see `llvm/cmake/modules/DetermineGCCCompatible.cmake`), it seems easiest for us to just check `CMAKE_COMPILER_IS_GNUCXX` instead (given Clang doesn't acknowledge `-fno-lifetime-dse` at all).
>
> I'll test that now.

Using `LLVM_COMPILER_IS_GCC_COMPATIBLE` will be helpful to prevent Clang from breaking itself when the lifetime DSE is added in the future.  I'm trying to figure out why CMAKE_CXX_FLAGS will affect the behavior of clang-tidy...


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D150505



More information about the llvm-commits mailing list