<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Jan 30, 2017 at 6:08 PM, Duncan P. N. Exon Smith <span dir="ltr"><<a href="mailto:dexonsmith@apple.com" target="_blank">dexonsmith@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I'm having trouble paging this back in.<br>
<br>
IIRC, one goal was to improve compile time by checking fewer fields.</blockquote><div><br></div><div>I thought that was the point of the stuff in getHashValue() ?</div><div><br></div><div>That said, over the weekend I had some ideas about how to fix this debug info odr business in a (IMHO) more principled way. If I get a chance I'll send an RFC with a brain dump to llvm-dev.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Do you happen to know why the LinkageName wasn't sufficient here?  Sure, this fixes a crash, but why?<br></blockquote><div><br></div><div>If we clone a module and try to disambiguate just based on LinkageName we will consider the DISubprogram referring to the cloned DICompileUnit (via TemplateParams) and the one referring to the original DICompileUnit to be the same. That way we will end up with a cloned module containing a non-distinct DISubprogram from the original module, itself referring to a DICompileUnit not appearing in <a href="http://llvm.dbg.cu">llvm.dbg.cu</a> (i.e. the one from the original module), which fails the verifier.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Also, for debug info testcases that aren't handmade, we usually include the C/C++ source in comments so that it's easy to regenerate them.  Maybe if I saw the source I would understand the root cause.<br></blockquote><div><br></div><div>Okay, I'll also add the source. It's basically the test case from <a href="https://bugs.chromium.org/p/chromium/issues/detail?id=682773#c14">https://bugs.chromium.org/p/chromium/issues/detail?id=682773#c14</a> with the definitions removed.</div><div><br></div><div>Thanks,</div></div>-- <br><div class="gmail-m_807498182752138407gmail_signature"><div dir="ltr">-- <div>Peter</div></div></div>
</div></div>