<div dir="ltr"><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jun 19, 2020 at 4:28 AM Mehdi AMINI via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jun 18, 2020 at 11:41 AM Chris Lattner via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;"><br><div><br><blockquote type="cite"><div>On Jun 18, 2020, at 11:36 AM, Matt Arsenault <<a href="mailto:arsenm2@gmail.com" target="_blank">arsenm2@gmail.com</a>> wrote:</div><br><div><div style="overflow-wrap: break-word;"><br><div><br><blockquote type="cite"><div>On Jun 18, 2020, at 14:32, Chris Lattner via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>> wrote:</div><br><div><div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration:none">2) Instead of dumping the entire input by default, would it be reasonable to change the default “make check” to have FileCheck print the 10 lines before and after the mismatch? Most problems are close by the check failure. If you want to check extra fancy, dump the CHECK-LABEL region.</div><br></div></blockquote></div><br><div>In my experience, the entire CHECK-LABEL region is still way too much (e.g. MIR tests print a giant block of function information in the prolog). There needs to be a stricter line count clamping of some kind</div></div></div></blockquote><br></div><div>Sure, what I’m actually advocating here is a pile of heuristics that work well for humans: e.g. dump the label region if it is 20 lines or less. If it is large, then look at where the last match and the fuzzy next match are, and include that, .. etc. FileCheck has a lot of information that we’re not using and some elbow grease could make the default experience way nicer for humans.</div></div></blockquote><div><br></div><div>+1</div><div>That's what came out of the discussion in the revision as well. Getting the LABEL region (or some limited context) would likely be the ideal behavior.</div></div></div></blockquote><div><br></div><div>Here's a prototype for limiting the context:<br></div><div><br></div><div><a href="https://reviews.llvm.org/D82203">https://reviews.llvm.org/D82203</a></div><div><br></div><div>I'll spend more time on it if people like the idea.</div><div><br></div><div>Joel<br></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"><div dir="ltr"><div class="gmail_quote"><div> I looked into this last week but I suspect it requires some refactoring first, I may have time to look again next week if no one beats me to it.</div><div>I can see how having the failing CHECKs displayed after the input can be useful as well!<br></div><div><br></div><div>-- </div><div>Mehdi</div><div><br></div><div><br></div></div></div>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div></div>