[llvm] r190330 - Debug Info: move DIScope::getContext to DwarfDebug.

Manman Ren manman.ren at gmail.com
Mon Sep 9 14:27:34 PDT 2013


Yes, my next step is to move DISubprogram::getContext to return a ScopeRef.
I actually like the suggestion of updating DIScope::getContext to return a
ScopeRef (partially revert r190330) and I will submit a patch for that.

Thanks,
Manman


On Mon, Sep 9, 2013 at 2:11 PM, David Blaikie <dblaikie at gmail.com> wrote:

>
>
>
> On Mon, Sep 9, 2013 at 2:05 PM, Manman Ren <manman.ren at gmail.com> wrote:
>
>>
>>
>>
>> On Mon, Sep 9, 2013 at 1:16 PM, David Blaikie <dblaikie at gmail.com> wrote:
>>
>>>
>>>
>>>
>>> On Mon, Sep 9, 2013 at 12:23 PM, Manman Ren <manman.ren at gmail.com>wrote:
>>>
>>>> Author: mren
>>>> Date: Mon Sep  9 14:23:58 2013
>>>> New Revision: 190330
>>>>
>>>> URL: http://llvm.org/viewvc/llvm-project?rev=190330&view=rev
>>>> Log:
>>>> Debug Info: move DIScope::getContext to DwarfDebug.
>>>>
>>>
>>> This seems a little unfortunate. Though admittedly it's not actually a
>>> feature of all DIScopes to have, themselves, a context.
>>>
>>> What would happen if DIScope::getContext returned a DIScopeRef instead
>>> of a DIScope? It shouldn't need the map then, right? Seems like it would be
>>> a smaller change.
>>>
>> It is possible to return DIScopeRef if we add an constructor to build
>> DIScopeRef from DIScope.
>> I will check how easy this option is.
>>
>
> Only temporarily, though, right? Since at some point all contexts will
> have to be DIScopeRefs, since they may be DITypes (& thus may be type
> references) at which point this can be removed & DIScope::getContext will
> be written exactly as it was before, no extra conversions, etc, needed.
>
> I would consider just doing all the context references in one go, but so
> long as you remember to come back & clean that conversion/constructor up
> once all the scope context references are migrated, that's OK.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130909/9e2575c1/attachment.html>


More information about the llvm-commits mailing list