<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Oct 16, 2017 at 6:41 AM, Krzysztof Parzyszek <span dir="ltr"><<a href="mailto:kparzysz@codeaurora.org" target="_blank">kparzysz@codeaurora.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">The problem was that cmake would not re-run to update the Makefiles (or ninja equivalents). If I just deleted the CFIVerifyTests executable, ninja would still rebuild it.<br></blockquote><div><br></div><div>That's not how llvm-lit works.  If it finds a matching file in the tree, it runs it.</div><div><br></div><div>The buildbot owners need to delete CFIVerifyTests -- either by removing the build directory (as you did below), deleting the file -- even ninja clean won't help, since cmake no longer knows anything about the file.</div><div><br></div><div>You can test this locally if you want (assumes you are building X86):</div><div><br></div><div>1) intentionally break CFIVerifyTests, then run ninja check-llvm-unit to verify the test breaks:</div><div><br></div></div></div><blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px"><div class="gmail_extra"><div class="gmail_quote"><div><div>diff --git a/unittests/tools/llvm-cfi-verify/FileAnalysis.cpp b/unittests/tools/llvm-cfi-verify/FileAnalysis.cpp</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>index 66fdc42ccfc..f0db3f55990 100644</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>--- a/unittests/tools/llvm-cfi-verify/FileAnalysis.cpp</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>+++ b/unittests/tools/llvm-cfi-verify/FileAnalysis.cpp</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>@@ -47,7 +47,7 @@ namespace {</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div> class ELFx86TestFileAnalysis : public FileAnalysis {</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div> public:</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>   ELFx86TestFileAnalysis()</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>-      : FileAnalysis(Triple("x86_64--"), SubtargetFeatures()) {}</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>+      : FileAnalysis(Triple("xxx86_64--"), SubtargetFeatures()) {}</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div><br></div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>   // Expose this method publicly for testing.</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>   void parseSectionContents(ArrayRef<uint8_t> SectionBytes,</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><br></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><br></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div>$ ninja check-llvm-unit</div></div></div></blockquote><div class="gmail_extra"><div class="gmail_quote"><div><br></div><div>2) revert change from step 1, intentionally break cmake test so it won't get rebuilt, and verify test still fails (this is the case for broken buildbots -- a failing test that cmake doesn't know about and doesn't rebuild):</div><div><br></div></div></div><blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px"><div class="gmail_extra"><div class="gmail_quote"><div><div>diff --git a/unittests/tools/llvm-cfi-verify/CMakeLists.txt b/unittests/tools/llvm-cfi-verify/CMakeLists.txt</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>index 0f389592bdd..f22c160ec06 100644</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>--- a/unittests/tools/llvm-cfi-verify/CMakeLists.txt</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>+++ b/unittests/tools/llvm-cfi-verify/CMakeLists.txt</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>@@ -11,7 +11,7 @@ set(LLVM_LINK_COMPONENTS</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>   Support</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>   )</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div><br></div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>-list(FIND LLVM_TARGETS_TO_BUILD "X86" x86_idx)</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>+list(FIND LLVM_TARGETS_TO_BUILD "xxX86" x86_idx)</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div> if (NOT x86_idx LESS 0)</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>   add_llvm_unittest(CFIVerifyTests</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>     FileAnalysis.cpp)</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><br></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><br></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><div>$ ninja check-llvm-unit</div></div></div></div><div class="gmail_extra"><div class="gmail_quote"><div><br></div></div></div></blockquote><div class="gmail_extra"><div class="gmail_quote"><div>3) delete the bad test and verify it no longer fails (this is all buildbot owners need to do):</div><div><br></div></div></div><blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px"><div class="gmail_extra"><div class="gmail_quote"><div>$ rm ./unittests/tools/llvm-cfi-verify/CFIVerifyTests</div></div></div><div class="gmail_extra"><div class="gmail_quote"><div>$ ninja check-llvm-unit</div></div></div></blockquote><div class="gmail_extra"><div class="gmail_quote"><div><br></div><div>4) undo the change from step 2.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
I tried to "touch CMakeCache.txt" on the Hexagon bots, but even that didn't cause cmake to reconfigure. I had to remove the contents of the build directory to finally get the bot to turn green.<br></blockquote><div><br></div><div>Yes, this works because you also deleted CFIVerifyTests.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
There should be an option to force a completely clean build, this is not the first time we've had this kind of a problem.<br></blockquote><div><br></div><div>This wouldn't help, since once you tell cmake to ignore something, it will no longer build or remove it, i.e., it doesn't know anything about it.</div><div><br></div><div>hth...</div><div>don</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
-Krzysztof<span class="gmail-"><br>
<br>
<br>
On 10/15/2017 6:17 PM, Don Hinton wrote:<br>
</span><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span class="gmail-">
Since the red bots are incremental and don't clean up after themselves, someone needs to delete CFIVerifyTests, or the lit will just keep running the old one -- lit's just looking for files with a "Test" suffix in the unittests directory.<br>
<br>
<br></span><div><div class="gmail-h5">
On Sun, Oct 15, 2017 at 11:23 AM, Krzysztof Parzyszek via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a> <mailto:<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llv<wbr>m.org</a>>> wrote:<br>
<br>
    Author: kparzysz<br>
    Date: Sun Oct 15 11:23:16 2017<br>
    New Revision: 315870<br>
<br>
    URL: <a href="http://llvm.org/viewvc/llvm-project?rev=315870&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-pr<wbr>oject?rev=315870&view=rev</a><br>
    <<a href="http://llvm.org/viewvc/llvm-project?rev=315870&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-p<wbr>roject?rev=315870&view=rev</a>><br>
    Log:<br>
    Phony change to CMakeLists.txt to (hopefully) trigger regeneration<br>
<br>
    Ninja doesn't seem to recognize a change in a CMakeLists.txt in a<br>
    subdirectory, so r315861 is not having any effect.<br>
<br>
<br>
    Modified:<br>
         llvm/trunk/CMakeLists.txt<br>
<br>
    Modified: llvm/trunk/CMakeLists.txt<br>
    URL:<br>
    <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/CMakeLists.txt?rev=315870&r1=315869&r2=315870&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-pr<wbr>oject/llvm/trunk/CMakeLists.tx<wbr>t?rev=315870&r1=315869&r2=3158<wbr>70&view=diff</a><br>
    <<a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/CMakeLists.txt?rev=315870&r1=315869&r2=315870&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-p<wbr>roject/llvm/trunk/CMakeLists.t<wbr>xt?rev=315870&r1=315869&r2=315<wbr>870&view=diff</a>><br>
    ==============================<wbr>==============================<wbr>==================<br>
    --- llvm/trunk/CMakeLists.txt (original)<br>
    +++ llvm/trunk/CMakeLists.txt Sun Oct 15 11:23:16 2017<br>
    @@ -1012,3 +1012,4 @@ endif()<br>
      if (MSVC)<br>
        include(InstallRequiredSystem<wbr>Libraries)<br>
      endif()<br>
    +<br>
<br>
<br>
    ______________________________<wbr>_________________<br>
    llvm-commits mailing list<br></div></div>
    <a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a> <mailto:<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llv<wbr>m.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>
    <<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><wbr>><br>
<br>
<br><span class="gmail-HOEnZb"><font color="#888888">
</font></span></blockquote><span class="gmail-HOEnZb"><font color="#888888">
<br>
-- <br>
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation<br>
</font></span></blockquote></div><br></div></div>