[patch][PR10367] Fix the design of GlobalAlias

Rafael EspĂ­ndola rafael.espindola at gmail.com
Tue May 13 10:31:58 PDT 2014


> 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
-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm-1.patch
Type: application/octet-stream
Size: 18529 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140513/6c387bec/attachment.obj>


More information about the llvm-commits mailing list