[llvm] r204528 - Dwarf Debug: Remove some cargo-cult type uniquing. Scopes do not have
Manman Ren
manman.ren at gmail.com
Mon Mar 24 16:29:19 PDT 2014
On Mon, Mar 24, 2014 at 4:18 PM, Eric Christopher <echristo at gmail.com>wrote:
> On Mon, Mar 24, 2014 at 4:12 PM, Manman Ren <manman.ren at gmail.com> wrote:
> >
> >
> >
> > On Fri, Mar 21, 2014 at 3:16 PM, Adrian Prantl <aprantl at apple.com>
> wrote:
> >>
> >> Author: adrian
> >> Date: Fri Mar 21 17:16:32 2014
> >> New Revision: 204528
> >>
> >> URL: http://llvm.org/viewvc/llvm-project?rev=204528&view=rev
> >> Log:
> >> Dwarf Debug: Remove some cargo-cult type uniquing. Scopes do not have
> >> an ID, so this is a noop.
> >> Thanks Manman for catching this!
> >>
> >> Modified:
> >> llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
> >>
> >> Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
> >> URL:
> >>
> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=204528&r1=204527&r2=204528&view=diff
> >>
> >>
> ==============================================================================
> >> --- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)
> >> +++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Fri Mar 21 17:16:32
> >> 2014
> >> @@ -604,7 +604,7 @@ DIE *DwarfDebug::constructScopeDIE(Dwarf
> >> return NULL;
> >>
> >> // Unique scope where applicable.
> >> - DIScope DS(resolve(DIScope(Scope->getScopeNode()).getRef()));
> >> + DIScope DS(Scope->getScopeNode());
> >
> >
> > Right now, DICompositeType has an ID and it is also one kind of DIScope,
> so
> > the statement "scopes do not have an ID" sounds incorrect :]
> >
> > DISubprogram does not have an ID and we should remove the following noop:
> >
> > /// getOrCreateSubprogramDIE - Create new DIE using SP.
> > DIE *DwarfUnit::getOrCreateSubprogramDIE(DISubprogram SP) {
> > ...
> > // Unique declarations based on the ODR, where applicable.
> > SP = DISubprogram(DD->resolve(SP.getRef()));
> >
>
> Yeah, where are we on using references for all types? I thought when
> you'd finished that we used them everywhere
I thought so too, but I apparently missed DI[Global]Variable (thanks to
Adrian for fixing those).
but apparently not. We
> should get that fixed so there's less confusion here.
>
Yes.
Thanks,
Manman
>
> -eric
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140324/2214c8df/attachment.html>
More information about the llvm-commits
mailing list