<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Mar 4, 2015, at 4:39 PM, Zachary Turner <<a href="mailto:zturner@google.com" class="">zturner@google.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">BTW, I have just uploaded <a href="http://reviews.llvm.org/D8068" class="">http://reviews.llvm.org/D8068</a> to LLVM which implements backtracing of self <span style="font-size:13.1999998092651px;line-height:19.7999992370605px" class="">on Windows </span>(previously only backtracing of other threads was supported).  So once that goes through, if we switch this code to using llvm::sys::PrintBacktrace(),</div></div></blockquote><div><br class=""></div><div>I don’t think we should make this change.</div><div>Host::Backtrace prints to an lldb_private::Stream which is our preferred API for accumulating output - the LLVM version of this seems to print to a FILE* which is much less general</div><div><br class=""></div><div>I understand using LLVM facilities where it makes sense, but we should not be doing so blindly when the net effect is a loss of functionality for us</div><div><br class=""></div><div>If you can implement Host::Backtrace in general on all platforms via LLVM, feel free to do so - but we should still go through lldb's Host::Backtrace for this, and Host::Backtrace should still use our Stream<i class="">s</i></div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""> we should have a standard backtrace format across all platforms that LLVM supports.<br class=""><div class=""><br class=""></div><div class="">I like this feature now that I understand the use case, thanks for introducing it.</div></div><br class=""></div></blockquote><div><br class=""></div><div>We had a power outage here in Cupertino, which delayed my reply</div><div>Glad to hear we all agree on this :-)</div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote">On Wed, Mar 4, 2015 at 3:31 PM Siva Chandra <<a href="mailto:sivachandra@google.com" class="">sivachandra@google.com</a>> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Wed, Mar 4, 2015 at 2:59 PM, Enrico Granata <<a href="mailto:egranata@apple.com" target="_blank" class="">egranata@apple.com</a>> wrote:<br class="">
> +#ifdef LLDB_CONFIGURATION_DEBUG<br class="">
> +#define lldbassert(x) assert(x)<br class="">
> +#else<br class="">
> +#define lldbassert(x) lldb_private::lldb_assert(x, #x, __FUNCTION__, __FILE__, __LINE__)<br class="">
> +#endif<br class="">
<br class="">
Why should we have this ifdef? As in, why shouldn't we use lldb_assert<br class="">
unconditionally, always (giving us the benefit of backtraces always)?<br class="">
______________________________<u class=""></u>_________________<br class="">
lldb-commits mailing list<br class="">
<a href="mailto:lldb-commits@cs.uiuc.edu" target="_blank" class="">lldb-commits@cs.uiuc.edu</a><br class="">
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits" target="_blank" class="">http://lists.cs.uiuc.edu/<u class=""></u>mailman/listinfo/lldb-commits</a><br class="">
</blockquote></div>
</div></blockquote></div><br class=""><div class="">
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Thanks,</div><div class=""><i class="">- Enrico</i><br class="">📩 egranata@<font color="#ff2600" class=""></font>.com ☎️ 27683</div><div class=""><br class=""></div></div></div></div></div></div><br class="Apple-interchange-newline"><br class="Apple-interchange-newline">
</div>
<br class=""></body></html>