<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Sat, Jul 15, 2017 at 9:39 AM Chandler Carruth <<a href="mailto:chandlerc@gmail.com">chandlerc@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Sat, Jul 15, 2017 at 12:53 AM Teresa Johnson via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: tejohnson<br>
Date: Fri Jul 14 21:53:05 2017<br>
New Revision: 308078<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=308078&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=308078&view=rev</a><br>
Log:<br>
[ThinLTO] Ensure we always select the same function copy to import<br>
<br>
Summary:<br>
Check if the first eligible callee is under the instruction threshold.<br>
Checking this on the first eligible callee ensures that we don't end<br>
up selecting different callees to import when we invoke this routine<br>
with different thresholds due to reaching the callee via paths that<br>
are shallower or hotter (when there are multiple copies, i.e. with<br>
weak or linkonce linkage). We don't want to leave the decision of which<br>
copy to import up to the backend.<br>
<br>
Reviewers: mehdi_amini<br>
<br>
Subscribers: inglorion, fhahn, llvm-commits<br>
<br>
Differential Revision: <a href="https://reviews.llvm.org/D35436" rel="noreferrer" target="_blank">https://reviews.llvm.org/D35436</a><br>
<br>
Added:<br>
    llvm/trunk/test/Transforms/FunctionImport/Inputs/funcimport_resolved1.ll<br>
    llvm/trunk/test/Transforms/FunctionImport/Inputs/funcimport_resolved2.ll<br>
    llvm/trunk/test/Transforms/FunctionImport/funcimport_resolved.ll<br></blockquote><div><br></div></div></div><div dir="ltr"><div class="gmail_quote"><div>This newly added test appears to be flaky, showing some nondeterminism in the system. For example, this command will run the tests 100 times, and doing this I see roughly 5 failures:</div><div><br></div><div>% repeat 100 ./dev/bin/llvm-lit -s ../test/Transforms/FunctionImport<br></div><div><br></div><div>The build bots have been failing and then recovering because of this for some time, so I'm going to revert until we can get this fixed to lessen the build bot spam.</div></div></div></blockquote><div><br></div><div>Reverted in r308095, let me know if i can help tracking it down.</div></div></div>