[PATCH] D34446: [Support] sys::getProcessTriple should return a macOS triple using the system's version of macOS

Nico Weber via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 14 08:03:11 PDT 2021


thakis added inline comments.
Herald added subscribers: ributzka, kristina.
Herald added a project: LLVM.


================
Comment at: llvm/trunk/lib/Support/Unix/Host.inc:58
+  std::string TargetTripleString =
+      updateTripleOSVersion(LLVM_DEFAULT_TARGET_TRIPLE);
 
----------------
This is the function that clang calls to determine its default triple (here: http://llvm-cs.pcc.me.uk/tools/clang/lib/Frontend/CompilerInvocation.cpp#3410)

LLVM_DEFAULT_TARGET_TRIPLE is what we tell people to set when they build cross compilers. It's what we use to make sure our compiler isn't dependent on the host OS version.

Changing this here to rewrite LLVM_DEFAULT_TARGET_TRIPLE to use the host OS version seems like the wrong thing to do, from the perspective of clang's default triple. Do you agree?


Repository:
  rL LLVM

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

https://reviews.llvm.org/D34446



More information about the llvm-commits mailing list