<div dir="ltr">Hi,<br><br>Since the test only runs on Windows machine and the native separator on Windows is ‘\’, we shouldn’t change the test. I attached a patch that fixes the issue.<br><br>@Vedant, could you please review the patch? Please feel free to commit the patch if you are happy with it.<br><br>Thanks,<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Sep 9, 2016 at 10:46 AM, Yaron Keren <span dir="ltr"><<a href="mailto:yaron.keren@gmail.com" target="_blank">yaron.keren@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="rtl"><div dir="ltr"><div dir="ltr">Hi,</div><div dir="ltr"><br></div><div dir="ltr">this still fails due to wrong path seperator. I tried to apply the usual fix:</div><div dir="ltr"><br></div><div dir="ltr"><div dir="ltr">// TEXT-INDEX: {{/|\\}}tmp{{/|\\}}native_<wbr>separators.c</div><div><br></div><div>but then an assert fails</div><div><br></div><div><br></div></div><div dir="ltr"><div dir="ltr">$ "C:/llvm-clean/msvc/<wbr>RelWithDebInfo/bin\FileCheck.<wbr>EXE" "-check-prefixes=TEXT-INDEX" "-input-file=C:\llvm-clean\<wbr>msvc\test\tools\llvm-cov\<wbr>Output\native_separators.c.<wbr>tmp.dir/index.txt" "C:\llvm-clean\test\tools\<wbr>llvm-cov\native_separators.c" $ "C:/llvm-clean/msvc/<wbr>RelWithDebInfo/bin\llvm-cov.<wbr>EXE" "show" "-format=html" "C:\llvm-clean\test\tools\<wbr>llvm-cov/Inputs/native_<wbr>separators.covmapping" "-instr-profile=C:\llvm-clean\<wbr>msvc\test\tools\llvm-cov\<wbr>Output\native_separators.c.<wbr>tmp.profdata" "-filename-equivalence" "../C:/llvm-clean/msvc/<wbr>RelWithDebInfo/bin\llvm-<wbr>config.EXE/../C:/llvm-clean/<wbr>msvc/RelWithDebInfo/bin\llvm-<wbr>cov.EXE/native_separators.c" "-o" "C:\llvm-clean\msvc\test\<wbr>tools\llvm-cov\Output\native_<wbr>separators.c.tmp.dir"</div><div dir="ltr"># command stderr:</div><div dir="ltr">error: ../C:/llvm-clean/msvc/<wbr>RelWithDebInfo/bin\llvm-<wbr>config.EXE/../C:/llvm-clean/<wbr>msvc/RelWithDebInfo/bin\llvm-<wbr>cov.EXE/native_separators.c: invalid argument</div><div dir="ltr">warning: The file '/tmp/native_separators.c' isn't covered.</div><div dir="ltr"><br></div><div dir="ltr">$ "C:/llvm-clean/msvc/<wbr>RelWithDebInfo/bin\FileCheck.<wbr>EXE" "-check-prefixes=HTML-INDEX" "-input-file=C:\llvm-clean\<wbr>msvc\test\tools\llvm-cov\<wbr>Output\native_separators.c.<wbr>tmp.dir/index.html" "C:\llvm-clean\test\tools\<wbr>llvm-cov\native_separators.c"</div><div dir="ltr"><br></div><div dir="ltr">$ "C:/llvm-clean/msvc/<wbr>RelWithDebInfo/bin\llvm-cov.<wbr>EXE" "show" "-format=html" "C:\llvm-clean\test\tools\<wbr>llvm-cov/Inputs/native_<wbr>separators.covmapping" "-instr-profile=C:\llvm-clean\<wbr>msvc\test\tools\llvm-cov\<wbr>Output\native_separators.c.<wbr>tmp.profdata" "-filename-equivalence" "C:\llvm-clean\test\tools\<wbr>llvm-cov\native_separators.c" "-o" "C:\llvm-clean\msvc\test\<wbr>tools\llvm-cov\Output\native_<wbr>separators.c.tmp.dir"</div><div dir="ltr"># command stderr:</div><div dir="ltr">Assertion failed: Start + Len <= Line.size() && "Snippet extends past the EOL", file C:\llvm-clean\tools\llvm-cov\<wbr>SourceCoverageViewHTML.cpp, line 476</div><div><br></div></div><div dir="ltr"><br></div><div dir="ltr"><br></div><div>as Ying wrote, if the line</div><span class=""><div><br></div><div>// RUN: FileCheck -check-prefixes=TEXT-INDEX -input-file=%t.dir/index.txt %s<br></div><div><br></div></span><div>is removed the test passes.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Yaron</div><div><br></div><div dir="ltr"><br></div></font></span></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote"><div dir="ltr">2016-09-09 12:43 GMT+03:00 Ying Yi via llvm-commits <span dir="ltr"><<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>></span>:</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">

<p class="MsoNormal">Hi Vedant,</p><span><p class="MsoNormal"><br></p>

<p class="MsoNormal">>Could you help test this out? I don't have a Windows
machine available.</p>

</span><p class="MsoNormal">Of course. The test still fails but for a different reason. It
currently fails when running the following test:</p><p class="MsoNormal"><br></p>

<p class="MsoNormal">// RUN: llvm-cov show %S/Inputs/<a href="http://native_separators.co">native_separators.co</a><wbr>vmapping
-instr-profile=%t.profdata -o %t.dir</p>

<p class="MsoNormal">// RUN: FileCheck -check-prefixes=TEXT-INDEX
-input-file=%t.dir/index.txt %s</p>

<p class="MsoNormal">// TEXT-INDEX: \tmp\native_separators.c</p><p class="MsoNormal"><br></p>

<p class="MsoNormal">The test expects that the native separators are used in the
source files list in both text and html index pages.</p>

<p class="MsoNormal">With the latest llvm-cov, only the source file list in the
index.html file uses the native separators. The index.txt file does not use the
native separators in the source file list.</p><p class="MsoNormal"><br></p>

<p class="MsoNormal">If I remove the single test above, the rest of the native_separators.c
tests pass.</p>

<p class="MsoNormal"><br></p><p class="MsoNormal">Please let me know if you need any further information.</p>

<p class="MsoNormal"><br></p><p class="MsoNormal">Regard,</p>

<p class="MsoNormal">Maggie</p>

</div><div class="gmail_extra"><div><div><br><div class="gmail_quote">On Fri, Sep 9, 2016 at 2:43 AM, Vedant Kumar <span dir="ltr"><<a href="mailto:vsk@apple.com" target="_blank">vsk@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Maggie,<br>
<br>
Sorry for breaking this test!<br>
<br>
Could you help test this out? I don't have a Windows machine available.<br>
<br>
thanks!<br>
<span><font color="#888888">vedant<br>
</font></span><div><div><br>
> On Sep 8, 2016, at 6:32 PM, Vedant Kumar via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>> wrote:<br>
><br>
> Author: vedantk<br>
> Date: Thu Sep  8 20:32:47 2016<br>
> New Revision: 281008<br>
><br>
> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=281008&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-pr<wbr>oject?rev=281008&view=rev</a><br>
> Log:<br>
> [llvm-cov] Speculate fix for a Windows-only test (NFC)<br>
><br>
> This test should have broken after r280896. Fix up the test case<br>
> speculatively, since I don't have a way to test it.<br>
><br>
> I wonder why I didn't get any angry bot emails about this. Maybe none of<br>
> the win32 bots test llvm-cov? That could explain it, since the test says<br>
> it 'REQUIRES: system-windows', which is restricted to win32 hosts.<br>
><br>
> Also: why is 'system-windows' not defined for non-win32 Windows bots?<br>
><br>
> Modified:<br>
>    llvm/trunk/test/tools/llvm-cov<wbr>/native_separators.c<br>
><br>
> Modified: llvm/trunk/test/tools/llvm-cov<wbr>/native_separators.c<br>
> URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/tools/llvm-cov/native_separators.c?rev=281008&r1=281007&r2=281008&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-pr<wbr>oject/llvm/trunk/test/tools/ll<wbr>vm-cov/native_separators.c?rev<wbr>=281008&r1=281007&r2=281008&vi<wbr>ew=diff</a><br>
> ==============================<wbr>==============================<wbr>==================<br>
> --- llvm/trunk/test/tools/llvm-cov<wbr>/native_separators.c (original)<br>
> +++ llvm/trunk/test/tools/llvm-cov<wbr>/native_separators.c Thu Sep  8 20:32:47 2016<br>
> @@ -15,15 +15,13 @@<br>
><br>
> // TEXT-INDEX: \tmp\native_separators.c<br>
> // HTML-INDEX: >tmp\native_separators.c</a><br>
> -// HTML: <pre>Source: \tmp\native_separators.c</pre><br>
> -// HTML: tools\llvm-cov\Inputs\native_s<wbr>eparators.covmapping</pre><br>
> +// HTML: <pre>Source: \tmp\native_separators.c (Binary: native_separators.covmapping)<<wbr>/pre><br>
><br>
> int main() {}<br>
><br>
> // RUN: llvm-cov show %S/Inputs/<a href="http://native_separators.co" target="_blank">native_separators.co</a><wbr>vmapping -instr-profile=%t.profdata -filename-equivalence %s -o %t.dir<br>
> // RUN: FileCheck -check-prefixes=TEXT -input-file=%t.dir/coverage/tm<wbr>p/native_separators.c.txt %s<br>
> -// TEXT: {{^}}Source: \tmp\native_separators.c:{{$}}<br>
> -// TEXT: {{^}}Binary: {{.*}}tools\llvm-cov\Inputs\na<wbr>tive_separators.covmapping:{{$<wbr>}}<br>
> +// TEXT: Source: \tmp\native_separators.c (Binary: native_separators.covmapping)<br>
><br>
> // Re-purpose this file to test that "Go to first unexecuted line" feature.<br>
><br>
><br>
><br>
> ______________________________<wbr>_________________<br>
> llvm-commits mailing list<br>
> <a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-commits</a><br>
<br>
</div></div></blockquote></div><br><br clear="all"><br></div></div><span><font color="#888888">-- <br><div data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><font size="2"><span style="font-family:arial,helvetica,sans-serif"></span></font><font face="Calibri" size="2"><span style="font-size:11pt"><font size="2"><span style="font-size:10pt"><font color="#1F497D" face="Arial">Ying Yi<br>SN Systems - Sony Interactive Entertainment</font></span></font></span></font><br></div></div></div></div></div></div></div></div>
</font></span></div>
<br>______________________________<wbr>_________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-commits</a><br>
<br></blockquote></div><br></div>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><font size="2"><span style="font-family:arial,helvetica,sans-serif"></span></font><font face="Calibri" size="2"><span style="font-size:11pt"><font size="2"><span style="font-size:10pt"><font color="#1F497D" face="Arial">Ying Yi<br>SN Systems - Sony Interactive Entertainment</font></span></font></span></font><br></div></div></div></div></div></div></div></div>
</div>