Eric Blake <[email protected]> wrote:
> On 3/7/19 6:28 AM, Juan Quintela wrote:
>> "Dr. David Alan Gilbert" <[email protected]> wrote:
>>> * Juan Quintela ([email protected]) wrote:
>>>> We need to send this field when we add compression support.  As we are
>>>> still on x- stage, we can do this kind of changes.
>>>>
>>>> Signed-off-by: Juan Quintela <[email protected]>
>>>
>>> OK, so that kind of makes sense - in that what you want to do is read
>>> the whole compressed chunk in one go.
>>>
>>> Consider it might be a good idea to add some spare entries here;
>>> say a uint64_t dummy[4] so that if you need any more fields in the
>>> future it'll be easy to add them without breaking compatibility.
>> 
>> We have a version field, so ... we can handle it relatively gratiously,
>> but I see your point.
>> 
>> How many?
>
> What is the current struct size? Is there a nice power-of-2 or
> cache-line-size multiple to round it out to?

MultiFDInit_t padded to 64 bytes. (7 uint8_t + 4 uint64_t padding)

Relatively easy to get it to a multiple of 2 and cacheline.

MultiFDPacket_t padded to 32 bytes (5 * 64). (4 uint64_t padding)

This one is too far away from a multiple of two (512bytes).  Would have
required 28 uint64_t of padding.

I am using this ones, ok?

Later, Juan.

Reply via email to