<div dir="rtl"><div dir="ltr">We use creduce to reduce large crash code to a small example, <a href="https://embed.cs.utah.edu/creduce/">https://embed.cs.utah.edu/creduce/</a></div><div dir="ltr">Then you can run clang under a debugger compiling the small example and actually understand the crash. <br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div dir="ltr">2016-06-04 13:27 GMT+03:00 Martin J. O'Riordan via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@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 lang="EN-IE" link="#0563C1" vlink="#954F72"><div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif">Awful though it may seem, we sometimes do get crashes in the compiler, usually because of some unhandled scenario we never thought of.  Unfortunately this typically happens when compiling very large pieces of code, so narrowing down the context of the crash can be difficult.<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif">When CLang/LLVM crashes it very helpfully creates a temporary pre-processed file along with a shell script to run this file so the issue can be reproduced.  And when run there is (usually) a call-stack dump, particularly when the Debug build is run.<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif">But I would also like to have a clue about what file and line in the test-case corresponds to the context in which the crash occurs.  Is there any easy way of adding the ability to write the ‘DebugLoc’ information corresponding to the context or the crash, or is this information not available to the crash-handler? <u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif">Thanks,<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif">            MartinO<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Book Antiqua",serif"><u></u> <u></u></span></p></div></div><br>_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
<br></blockquote></div><br></div>