MaskRay added inline comments.

================
Comment at: clang/lib/Driver/ToolChains/Gnu.cpp:2091
+  static const char *const X32Triples[] = {
+      "x86_64-linux-gnux32",    "x86_64-unknown-linux-gnux32",
+      "x86_64-pc-linux-gnux32"};
----------------
Just add `x86_64-linux-gnux32`. It is sufficient for Debian. Only add others 
when needed.


================
Comment at: clang/lib/Driver/ToolChains/Linux.cpp:90
       return "x86_64-linux-android";
-    // We don't want this for x32, otherwise it will match x86_64 libs
-    if (TargetEnvironment != llvm::Triple::GNUX32 &&
-        D.getVFS().exists(SysRoot + "/lib/x86_64-linux-gnu"))
-      return "x86_64-linux-gnu";
+    if (TargetEnvironment == llvm::Triple::GNUX32) {
+      if (D.getVFS().exists(SysRoot + "/lib/x86_64-linux-gnux32"))
----------------
I have cleaned up the code a bit. You may need to rebase.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D52050

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
  • [PATCH] D52050: ... Fangrui Song via Phabricator via cfe-commits

Reply via email to