Thread (7 messages) 7 messages, 3 authors, 2013-09-05

Re: [PATCH] openvswitch: fix sw_flow_key alignment

From: Jesse Gross <hidden>
Date: 2013-09-05 17:37:21

On Tue, Sep 3, 2013 at 3:06 PM, Jesse Gross [off-list ref] wrote:
On Fri, Aug 30, 2013 at 9:16 PM, David Miller [off-list ref] wrote:
quoted
From: Jesse Gross <redacted>
Date: Fri, 30 Aug 2013 16:20:25 -0700
quoted
I looked through the struct definition and I think that the idea of
manually padding as Geert did in his patch will be difficult to
maintain over time (and actually there are a few that he missed) since
there are a number of different structs/unions contained in there.
You have to be mindful of the gaps and wasted space for performance
reasons anyways.
Yes, although the approaches for performance and correctness are not
necessarily the same. For example, we're taking about potentially
packing the struct, in which case we would still have the same
alignment needs even without any gaps. If the correctness is clearly
handled (through an explicit align and build assert) then it's easier
to pack/rearrange/whatever for performance since the whole thing isn't
fragile.
I'd like to get this build failure fixed soon, so I'll just send out a
minimal fix that seems best to me in a couple of minutes.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help