[PATCH] D86313: [runtimes] Allow LLVM_BUILTIN_TARGETS to include Darwin

Petr Hosek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 20 13:39:51 PDT 2020


phosek added a comment.

I agree that the current situation is not optimal, I was never happy with the `default` case which is confusing for a lot of people I talked to. I would like to come up with a better solution, but I'm not sure if special casing the `x86_64-apple-darwin` is sufficient though. With Apple Silicon, I assume we're going to be building runtimes as universal binaries that target multiple architectures.

We could consider completely decoupling runtimes from targets. Originally, each runtime build was identified only by its target, so you'd use `RUNTIMES_${target}_${variable}` to set target-specific variables. That became insufficient when we introduced the support for multilib, so now you also have a name and you can use `RUNTIMES_${target}+${name}_${variable}`. We could switch to `RUNTIMES_${name}_${variable}` and it'd be the responsibility of the user to set the target explicitly if they want it (FWIW it's something we already have to do in our build <https://github.com/llvm/llvm-project/blob/master/clang/cmake/caches/Fuchsia-stage2.cmake#L101> anyway because of Windows where the CMake behavior when you set `CMAKE_${LANG}_COMPILER_TARGET` breaks the build). If not, they get the default behavior, matching the `default` case today. What do you think?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D86313



More information about the llvm-commits mailing list