<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 8, 2016 at 1:04 PM, Nico Weber <span dir="ltr"><<a href="mailto:thakis@chromium.org" target="_blank">thakis@chromium.org</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"><div class="gmail_extra"><div class="gmail_quote"><span class="">On Fri, Jul 8, 2016 at 3:57 PM, David Blaikie via cfe-commits <span dir="ltr"><<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span>On Thu, Jul 7, 2016 at 4:10 PM, Reid Kleckner <span dir="ltr"><<a href="mailto:rnk@google.com" target="_blank">rnk@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span>On Thu, Jul 7, 2016 at 3:45 PM, David Blaikie <span dir="ltr"><<a href="mailto:dblaikie@gmail.com" target="_blank">dblaikie@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr">Yeah - is this necessary for CodeView? (does something break, or do you just get simple names where you'd prefer full mangled or qualified names)<br><br>It was chosen pretty deliberately to do it this way (use unqualified names) for gmlt to keep size down. Have you got numbers for the size delta for CodeView with this change? I'd really prefer to make the same choice for both - it'd seem a bit arbitrary to choose our size optimization based on differences in the kind of workloads we happen to have on these two platforms.</div></blockquote><div><br></div></span><div>It's problematic for CodeView because there is no equivalent field like DW_AT_linkage_name in any of the symbol records. There is only the display name, which includes scope qualifiers.</div><div><br></div><div>I'm suggesting we reverse our decision for DWARF because our space saving optimization breaks standard stack dumpers on Linux (gdb and addr2line),</div></div></div></div></blockquote><div><br></div></span><div>What breakage are you referring to here?<br><br>If we're talking about printing out the simple name - that comes up even in llvm-symbolizer if a function is inlined. So I think that's an intentional tradeoff that would apply to CV as well.</div><span><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> and that seems like a Bad Thing. Instead we've told users to user llvm-symbolizer, which is OK, but kind of crappy. </div></div></div></div></blockquote><div><br></div></span><div>I imagine that depends on how much it costs us - we've been pretty careful about binary size growth/minimization/etc for a while now</div></div></div></div></blockquote><div><br></div></span><div>Does this add much size?</div></div></div></div></blockquote><div><br>I believe so, but don't have specific numbers. Alexey made this choice when it was originally implemented & I believe had the data back then.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> This only makes strings longer and doesn't force emission of types, right?</div></div></div></div></blockquote><div><br>Right<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> (From what I understand, types are what makes -fline-tables-only output much smaller.)</div></div></div></div></blockquote><div><br>That's the first step, yes, though even gmlt data is in the order of 10s of % (actually much worse in an optimized build - I think I measure it still at 200% or somesuch, that was motivating Cary's work on 2 level line tables), and most of that is strings, so making bigger (much bigger) strings can have a significant impact.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> Sorry about the uninformed question :-) If that's roughly correct though, maybe it'd be good to get an idea how much bigger debug info would get with qualified names</div></div></div></div></blockquote><div><br>For sure - that's the basic question: If you're going to change this, please measure it & make sure the change isn't going to have a drastically adverse effect on the size of the output.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> -- we can't use -fline-tables-only 'cause they make stacks look very bad, </div></div></div></div></blockquote><div><br>Also I'm curious why your use case/tolerance for "badness" here is different from what we've been using at Google for ASan, etc, for several years now. Do you have different requirements/needs here? Then maybe we need to figure out names for those needs & enshrine them in flags.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>and if qualified names in debug info would give us decent stacks while still being smaller,</div></div></div></div></blockquote><div><br>Smaller than full debug info, you mean? Or smaller than something else?<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> that'd be cool. (See also thread "rfc: Adding a mode to -gline-tables-only to include parameter names, namespaces" from a while ago.)</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><span class=""><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>, so it may be worth the tradeoff to say that llvm-symbolizer produces a better experience on this extra minimized data.</div><span><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>For CodeView, because the linkage name isn't present anywhere, we can't actually do any better with llvm-symbolizer, and we need the fully scoped name.</div></div></div></div>
</blockquote></span></div><br></div></div>
<br></span><span class="">_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits</a><br>
<br></span></blockquote></div><br></div></div>
</blockquote></div><br></div></div>