[PATCH] Write references to Native format in NativeReferenceIvarsV2.

Rui Ueyama ruiu at google.com
Mon Nov 18 13:53:46 PST 2013


There's no padding both in NativeReferenceIvarsV1 and
in NativeReferenceIvarsV2, so __attribute((packed)) would be no-op?


On Mon, Nov 18, 2013 at 1:51 PM, Shankar Easwaran
<shankare at codeaurora.org>wrote:

> I was mentioning similiar things to this for structs.
>
> struct foo {
> char c;
> int x;
> } __attribute__((packed));
>
>
> On 11/18/2013 3:46 PM, Rui Ueyama wrote:
>
>> On Mon, Nov 18, 2013 at 1:38 PM, Shankar Easwaran
>> <shankare at codeaurora.org>wrote:
>>
>>  Should we use attribute packed too. I am not sure if this will raise
>>> compatibility concerns across all the machines that build lld.
>>>
>>>  Which attributes are you referring to?
>>
>>
>>  Thanks
>>>
>>> Shankar Easwaran
>>>
>>>
>>> On 11/18/2013 3:05 PM, kledzik at apple.com wrote:
>>>
>>>      Beside compatibility with existing files (which we don't have yet),
>>>> there is another reason for V1 vs V2: size.  The NativeReferenceIvar is
>>>> twice the size (8 bytes vs 4 bytes).  There will be a lot of these in
>>>> files.  We should have both structs.  When a native object file is
>>>> written,
>>>> the Writer should see if everything is small enough that just
>>>> NativeReferenceIvarsV1 structs can be used.  If not, it uses
>>>> NativeReferenceIvarsV2. The Reader should always handle both.
>>>>
>>>> http://llvm-reviews.chandlerc.com/D2217
>>>> _______________________________________________
>>>> llvm-commits mailing list
>>>> llvm-commits at cs.uiuc.edu
>>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>>>
>>>>
>>>>
>>>>  --
>>> Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted
>>> by the Linux Foundation
>>>
>>>
>>>
>
> --
> Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted
> by the Linux Foundation
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131118/76e48eeb/attachment.html>


More information about the llvm-commits mailing list