<div dir="ltr">(copied cfe-dev)<br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 12, 2016 at 10:12 AM, Asiri Rathnayake <span dir="ltr"><<a href="mailto:asiri.rathnayake@gmail.com" target="_blank">asiri.rathnayake@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Ed,<br><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Sat, Jul 9, 2016 at 12:51 AM, Ed Maste <span dir="ltr"><<a href="mailto:emaste@freebsd.org" target="_blank">emaste@freebsd.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On 6 July 2016 at 08:52, Asiri Rathnayake <<a href="mailto:asiri.rathnayake@gmail.com" target="_blank">asiri.rathnayake@gmail.com</a>> wrote:<br>
> Glad to be of help! :)<br>
><br>
> @Ed: You said:<br>
><br>
> "...heavily modified version of LLVM libunwind in NetBSD, which excludes the<br>
> HP unwind interface and requires much less stack space."<br>
><br>
> May be we should try and get them (stack usage improvements) into llvm<br>
> libunwind? We're interested!<br>
<br>
</span>It looks like the largest issue I encountered before is unresolved.<br>
Details are in the FreeBSD bug report:<br>
<a href="https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=206384" rel="noreferrer" target="_blank">https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=206384</a>.<br>
<br>
In src/DwarfParser.hpp kMaxRegisterNumber is still an unconditional<br>
120. We need to set it to an appropriate arch-specific value.<br></blockquote><div><br></div></div></div><div>Why not upstream this patch? :)</div><div><br></div><div>I tested this one AArch64 and it shaves off about 1KB of stack usage! It would be nice if there is some static check to make sure the correct number of registers are defined for each architecture (I do this through check_fit<T,M>::does_fit  template hackery for _LIBUNWIND_CONTEXT_SIZE).<br></div><div><br></div><div>I can do these improvements if you can open up a phabricator review for your patch. I'm not that familiar with the Dwarf unwinder yet, but I can work on that offline.</div><div><br></div><div>Cheers!</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>/ Asiri </div></font></span></div><br></div></div>
</blockquote></div><br></div></div>