File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -1531,7 +1531,7 @@ Compilation *Driver::BuildCompilation(ArrayRef<const char *> ArgList) {
15311531
15321532 // Check if the environment version is valid except wasm case.
15331533 llvm::Triple Triple = TC.getTriple ();
1534- if (!Triple.isWasm ()) {
1534+ if (!Triple.isWasm () && Triple. getEnvironment () != llvm::Triple::LLVM ) {
15351535 StringRef TripleVersionName = Triple.getEnvironmentVersionString ();
15361536 StringRef TripleObjectFormat =
15371537 Triple.getObjectFormatTypeName (Triple.getObjectFormat ());
Original file line number Diff line number Diff line change 2929// RUN: FileCheck --check-prefix=CHECK-WASM1 %s
3030
3131// CHECK-WASM1: "-triple" "wasm32-unknown-wasi-pthread"
32+
33+ // RUN: %clang --target=aarch64-unknown-linux-llvm -c %s -### 2>&1 | \
34+ // RUN: FileCheck --check-prefix=CHECK-AARCH64-LLVM %s
35+
36+ // CHECK-AARCH64-LLVM: "-triple" "aarch64-unknown-linux-llvm"
37+
38+ // RUN: %clang --target=x86_64-unknown-linux-llvm -c %s -### 2>&1 | \
39+ // RUN: FileCheck --check-prefix=CHECK-X86-64-LLVM %s
40+
41+ // CHECK-X86-64-LLVM: "-triple" "x86_64-unknown-linux-llvm"
You can’t perform that action at this time.
0 commit comments