<div dir="ltr">Oh. Right you are.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Feb 18, 2013 at 12:36 AM, Charles Davis <span dir="ltr"><<a href="mailto:cdavis5x@gmail.com" target="_blank">cdavis5x@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">ENOPATCH<br>
<br>
Chip<br>
<div><div class="h5"><br>
On Feb 18, 2013, at 1:23 AM, David Blaikie wrote:<br>
<br>
> In the interests of centralizing the debug info metadata generation in one place (DIBuilder) the following patches (to DragonEgg, LLVM (to add a minor breaking API change), & Clang (to update for the breaking change) - any non-interesting API changes necessary have already been committed).<br>

><br>
> I'll be the first to admit that this is a fairly mechanical transformation, simply replacing the raw metadata generation inside DragonEgg's DIFactory with a nested DIBuilder. With further consideration it would be quite easy to remove DIFactory entirely & use DIBuilder directly. This would most obviously tidy up the switches in DIFactory::CreateCompositeType and DIFactory::CreateDerivedType.<br>

><br>
> Beyond that there's a couple of finer points:<br>
> 1) DIBuilder needed to be "finalized" - I chose to put that in DIFactory's dtor and add code to clean up the DIFactory at the appropriate point<br>
> 2) there's one case of raw MDNode creation for debug info metadata - see the comment in the DragonEgg patch starting "FIXME: Remove this conditional". If you remove it you can see the failure with a test case involving a pointer-to-member-variable typedef. (it seems the call to getOrCreateType at line 953 maybe needs to look through pointer-to-member-variable & create the type of the member being pointed to - that was a bit more involved that I was comfortable fixing, but fix welcome)<br>

><br>
> [side note: currently DragonEgg seems to produce all record types as "struct" debug info, never using "class" debug info - I'm sure this would account for several failures in the GDB test suite & some minor usability confusion for users<br>

><br>
> There is one test I'm still regressing (& a few that have improved with this patch) in the GDB 7.5 test suite: gdb.opt/inline-locals.exp, but I think that's just luck. It was mostly failing already, for slightly different reasons previously.]<br>

</div></div>> _______________________________________________<br>
> llvm-commits mailing list<br>
> <a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
> <a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
<br>
</blockquote></div><br></div>