<div dir="ltr">Interesting.<div>Looking at <a href="https://llvm.org/svn/llvm-project/zorg/trunk/zorg/buildbot/builders/sanitizers/buildbot_functions.sh">https://llvm.org/svn/llvm-project/zorg/trunk/zorg/buildbot/builders/sanitizers/buildbot_functions.sh</a></div>I see export ASAN_OPTIONS="check_initialization_order=true:<b>detect_stack_use_after_return=1</b>:detect_leaks=1"<div>So, it's already enabled on the bots. </div><div>But, I also see this: </div><div><pre style="color:rgb(0,0,0);word-wrap:break-word;white-space:pre-wrap">  if [ "$CHECK_LLD" != "0" ]; then
    echo @@@BUILD_STEP check-lld ${sanitizer_name}@@@
    # TODO(smatveev): change this to STEP_FAILURE once green
    (cd ${build_dir} && ninja check-lld) || <b>echo @@@STEP_WARNINGS@@@</b>
  fi</pre></div><div><br></div><div>So, check-lld is being run, but errors are not e-mailed to anyone. </div><div>Today there are errors from lsan, msan, and ubsan</div><div><a href="http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/11154">http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/11154</a><br></div><div><br></div><div>Once you (or someone) cleans up these errors we may enable check-lld to actually produce errors on buildbot. </div><div><br></div><div><br></div><div>--kcc </div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Mar 15, 2016 at 5:00 PM, Filipe Cabecinhas <span dir="ltr"><<a href="mailto:filcab+llvm.phabricator@gmail.com" target="_blank">filcab+llvm.phabricator@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Ah, I didn't even need to check. Lit passing the ASAN_OPTIONS flag was<br>
what allowed us to find the bug easily. Without setting ASAN_OPTIONS<br>
you wouldn't find the bug with ASan.<br>
<br>
Thank you,<br>
<br>
  Filipe<br>
<br>
On Tue, Mar 15, 2016 at 4:59 PM, Filipe Cabecinhas<br>
<div class="HOEnZb"><div class="h5"><<a href="mailto:filcab%2Bllvm.phabricator@gmail.com">filcab+llvm.phabricator@gmail.com</a>> wrote:<br>
> No. Lit actually passes them on to the environment:<br>
><br>
> utils/lit/lit/TestingConfig.py:<br>
>         pass_vars = ['LIBRARY_PATH', 'LD_LIBRARY_PATH', 'SYSTEMROOT', 'TERM',<br>
>                      'LD_PRELOAD', 'ASAN_OPTIONS', 'UBSAN_OPTIONS',<br>
>                      'LSAN_OPTIONS', 'ADB', 'ANDROID_SERIAL']<br>
>         for var in pass_vars:<br>
>             val = os.environ.get(var, '')<br>
>             # Check for empty string as some variables such as<br>
> LD_PRELOAD cannot be empty<br>
>             # ('') for OS's such as OpenBSD.<br>
>             if val:<br>
>                 environment[var] = val<br>
><br>
> I think we're safe.<br>
><br>
> Thank you,<br>
><br>
>   Filipe<br>
><br>
> On Tue, Mar 15, 2016 at 4:24 PM, Kostya Serebryany <<a href="mailto:kcc@google.com">kcc@google.com</a>> wrote:<br>
>> Cool!<br>
>> please make sure that the LLVM test harness does not unset ASAN_OPTIONS<br>
>><br>
>> On Tue, Mar 15, 2016 at 4:17 PM, Filipe Cabecinhas<br>
>> <<a href="mailto:filcab%2Bllvm.phabricator@gmail.com">filcab+llvm.phabricator@gmail.com</a>> wrote:<br>
>>><br>
>>> Hi Kostya,<br>
>>><br>
>>> ASan-ized lld gets past check-lld without problems, so we might not<br>
>>> need any cleanup :-)<br>
>>><br>
>>> Thank you,<br>
>>><br>
>>>   Filipe<br>
>>><br>
>>> On Tue, Mar 15, 2016 at 3:52 PM, Kostya Serebryany <<a href="mailto:kcc@google.com">kcc@google.com</a>> wrote:<br>
>>> ><br>
>>> ><br>
>>> > On Mon, Mar 14, 2016 at 7:29 PM, Filipe Cabecinhas<br>
>>> > <<a href="mailto:filcab%2Bllvm.phabricator@gmail.com">filcab+llvm.phabricator@gmail.com</a>> wrote:<br>
>>> >><br>
>>> >> It looks like it should, but I can't try it out now.<br>
>>> >> I can try it tonight or tomorrow morning at most. If you want, you can<br>
>>> >> compile llvm+lld with ASan and turn on the Asan option (double-check<br>
>>> >> that<br>
>>> >> you catch the bug first ;-) ).<br>
>>> >><br>
>>> >> CCing Kostya:<br>
>>> >> Should we add ASAN_OPTIONS=detect_stack_use_after_free=true to the<br>
>>> >> sanitizer bot?<br>
>>> ><br>
>>> ><br>
>>> > That would be lovely!<br>
>>> > Any volunteers for the cleanup?<br>
>>> ><br>
>>> >><br>
>>> >> It would have caught this bug a long time ago.<br>
>>> >> We might also need to do some cleanup before we can do it.<br>
>>> >><br>
>>> >> Thank you,<br>
>>> >><br>
>>> >>   Filipe<br>
>>> >><br>
>>> >><br>
>>> >><br>
>>> >> On Monday, 14 March 2016, Rui Ueyama <<a href="mailto:ruiu@google.com">ruiu@google.com</a>> wrote:<br>
>>> >>><br>
>>> >>> ruiu added a comment.<br>
>>> >>><br>
>>> >>> Does <a href="http://reviews.llvm.org/D18169" rel="noreferrer" target="_blank">http://reviews.llvm.org/D18169</a> solves PR26908?<br>
>>> >>><br>
>>> >>><br>
>>> >>> <a href="http://reviews.llvm.org/D18167" rel="noreferrer" target="_blank">http://reviews.llvm.org/D18167</a><br>
>>> >>><br>
>>> >>><br>
>>> >>><br>
>>> ><br>
>><br>
>><br>
</div></div></blockquote></div><br></div>