[patch][PR10367] Fix the design of GlobalAlias
Reid Kleckner
rnk at google.com
Tue May 13 11:07:01 PDT 2014
On Tue, May 13, 2014 at 10:31 AM, Rafael EspĂndola <
rafael.espindola at gmail.com> wrote:
> > It was nice that `Alignment` was packed in here before.
> >
> > I wonder if it's worth the complexity of storing `Alignment` in
> > `GlobalValue`, even though it's only valid for `GlobalObject`? Maybe
> > using the `Value::SubclassData` model? I'm not sure how much this
> > bloat matters (1M globals => 8 MB).
>
> Probably. This revised patch fixes the style issue and uses the parent
> padding bits.
>
> The sizes I get with the patch on x86_64 are:
>
> Constant: 56
> GlobalValue: 64
> GlobalObject: 88
> GlobalVariable: 112
> Function: 152
>
> Without the patch they are
>
> Constant: 56
> GlobalValue: 88
> GlobalObject: X
> GlobalVariable: 112
> Function: 152
>
> Cheers,
> Rafael
>
The first patch looks good, I'm just opening the second patch.
I think previously you suggested splitting this into GlobalName /
GlobalValue instead of GlobalValue / GlobalObject. I kind of liked
GlobalName. Any reason to split this way instead? Does it avoid excessive
API churn?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140513/7457d160/attachment.html>
More information about the llvm-commits
mailing list