<div dir="ltr">This might have broken the test on Windows:<div><br></div><div><div>Command 1 Stderr:</div><div>C:\src\chrome\src\third_party\llvm\tools\clang\test\Driver\wasm-toolchain.c:3:13: error: expected string not found in in</div><div>put</div><div>// AS_LINK: lld" "-flavor" "ld" "[[temp]]" "-o" "a.out"</div><div> ^</div><div><stdin>:5:476: note: scanning from here</div><div> "C:/src/chrome/src/third_party/llvm-bootstrap/./bin/clang.EXE" "-cc1as" "-triple" "wasm32-unknown-unknown" "-filetype"</div><div>"obj" "-main-file-name" "wasm-toolchain.c" "-target-cpu" "generic" "-dwarf-version=4" "-fdebug-compilation-dir" "C:\\src</div><div>\\chrome\\src\\third_party\\llvm-bootstrap\\tools\\clang\\test\\Driver" "-dwarf-debug-producer" "clang version 3.8.0 (tr</div><div>unk 256248)" "-mrelocation-model" "static" "-o" "C:\\Users\\thakis\\AppData\\Local\\Temp\\wasm-toolchain-f6ec86.o" "C:\\</div><div>src\\chrome\\src\\third_party\\llvm\\tools\\clang\\test\\Driver\\wasm-toolchain.c"</div><div><br></div><div><br></div><div><br></div><div> ^</div><div><stdin>:5:476: note: with variable "temp" equal to "C:\\\\Users\\\\thakis\\\\AppData\\\\Local\\\\Temp\\\\wasm-toolchain-</div><div>f6ec86.o"</div><div> "C:/src/chrome/src/third_party/llvm-bootstrap/./bin/clang.EXE" "-cc1as" "-triple" "wasm32-unknown-unknown" "-filetype"</div><div>"obj" "-main-file-name" "wasm-toolchain.c" "-target-cpu" "generic" "-dwarf-version=4" "-fdebug-compilation-dir" "C:\\src</div><div>\\chrome\\src\\third_party\\llvm-bootstrap\\tools\\clang\\test\\Driver" "-dwarf-debug-producer" "clang version 3.8.0 (tr</div><div>unk 256248)" "-mrelocation-model" "static" "-o" "C:\\Users\\thakis\\AppData\\Local\\Temp\\wasm-toolchain-f6ec86.o" "C:\\</div><div>src\\chrome\\src\\third_party\\llvm\\tools\\clang\\test\\Driver\\wasm-toolchain.c"</div><div><br></div><div><br></div><div><br></div><div> ^</div><div><stdin>:6:63: note: possible intended match here</div><div> "C:\\src\\chrome\\src\\third_party\\llvm-bootstrap\\bin\\lld.exe" "-flavor" "ld" "C:\\Users\\thakis\\AppData\\Local\\Te</div><div>mp\\wasm-toolchain-f6ec86.o" "-o" "a.out"</div><div> ^</div></div><div><br></div><div>I think I fixed this in 256286, but I'm a bit surprised this wasn't caught by any LLVM bots. Can you check why this wasn't caught?</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Dec 21, 2015 at 6:30 PM, Dan Gohman via cfe-commits <span dir="ltr"><<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: djg<br>
Date: Mon Dec 21 17:30:41 2015<br>
New Revision: 256216<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=256216&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=256216&view=rev</a><br>
Log:<br>
[WebAssembly] Remove the -target command-line flag from the ld commandline.<br>
<br>
This flag isn't needed, or permitted, with the "ld" flavor of lld.<br>
<br>
Also, add a basic ld commandline test.<br>
<br>
Added:<br>
cfe/trunk/test/Driver/wasm-toolchain.c<br>
Modified:<br>
cfe/trunk/lib/Driver/Tools.cpp<br>
<br>
Modified: cfe/trunk/lib/Driver/Tools.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=256216&r1=256215&r2=256216&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=256216&r1=256215&r2=256216&view=diff</a><br>
==============================================================================<br>
--- cfe/trunk/lib/Driver/Tools.cpp (original)<br>
+++ cfe/trunk/lib/Driver/Tools.cpp Mon Dec 21 17:30:41 2015<br>
@@ -6516,8 +6516,6 @@ void wasm::Linker::ConstructJob(Compilat<br>
ArgStringList CmdArgs;<br>
CmdArgs.push_back("-flavor");<br>
CmdArgs.push_back("ld");<br>
- CmdArgs.push_back("-target");<br>
- CmdArgs.push_back(Args.MakeArgString(getToolChain().getTripleString()));<br>
AddLinkerInputs(getToolChain(), Inputs, Args, CmdArgs);<br>
CmdArgs.push_back("-o");<br>
CmdArgs.push_back(Output.getFilename());<br>
<br>
Added: cfe/trunk/test/Driver/wasm-toolchain.c<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/wasm-toolchain.c?rev=256216&view=auto" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/wasm-toolchain.c?rev=256216&view=auto</a><br>
==============================================================================<br>
--- cfe/trunk/test/Driver/wasm-toolchain.c (added)<br>
+++ cfe/trunk/test/Driver/wasm-toolchain.c Mon Dec 21 17:30:41 2015<br>
@@ -0,0 +1,3 @@<br>
+// RUN: %clang -### -target wasm32-unknown-unknown -x assembler %s 2>&1 | FileCheck -check-prefix=AS_LINK %s<br>
+// AS_LINK: clang{{.*}}" "-cc1as" {{.*}} "-o" "[[temp:[^"]*]]"<br>
+// AS_LINK: lld" "-flavor" "ld" "[[temp]]" "-o" "a.out"<br>
<br>
<br>
_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@lists.llvm.org">cfe-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits</a><br>
</blockquote></div><br></div>