[Patch] Make errors and crashes distinct even with LLVM_DISABLE_CRASH_REPORT

Reid Kleckner rnk at google.com
Thu Jul 25 11:34:49 PDT 2013


AvoidMessageBoxHook does "*Return = 1" while CRTReportHook sets it to zero.
 Setting it to one is what gives us the stack trace, but it may also
trigger the just in time debugger.  I'm really not sure what controls the
system crash dialog, unfortunately.  Does someone else know more?


On Thu, Jul 25, 2013 at 2:10 PM, Rafael EspĂ­ndola <
rafael.espindola at gmail.com> wrote:

> > I complicated things by adding yet another env var called
> > LLVM_ENABLE_CRT_REPORT, which tries to suppress the "abort, retry,
> ignore"
> > dialog raised by assertion failures when using the Visual CRT.  I think
> both
> > of these vars are basically trying to achieve the same behavior of
> > suppressing dialogs and slow system forensics gathering, so they could be
> > merged.
> >
> > Currently, LLVM_DISABLE_CRASH_REPORTING turns off stack dumping on
> Windows
> > but not on Mac.  This seems unintentional to me, and it means we don't
> get
> > crash stack traces from 'check-clang' on Windows.  It'd be nice to get
> those
> > without a dialog.
>
> What about the attached patch?
>
> It merges  LLVM_ENABLE_CRT_REPORT, gets a stack trace printed, "not
> --crash" works and at least on my
> system I don't get any dialog window.
>
> Cheers,
> Rafael
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130725/0239d618/attachment.html>


More information about the llvm-commits mailing list