[ovs-dev] [PATCH v5 6/6] meta-flow: Avoid unnecessary large memset.
Jarno Rajahalme
jrajahalme at nicira.com
Wed Aug 26 23:07:07 UTC 2015
> On Aug 26, 2015, at 1:08 PM, Ben Pfaff <blp at nicira.com> wrote:
>
> On Fri, Aug 21, 2015 at 03:25:23PM -0700, Jarno Rajahalme wrote:
>> mf_mask_field_and_prereqs() used to memset a static variable again and
>> again. Now that mf_value is larger (due to tun_metadata field), this
>> is more expensive. Avoid this by using static initialization.
>>
>> mf_mask_field_and_prereqs() is used only for set field and reg move,
>> which never deal with the tun_metadata field as a whole.
>>
>> Signed-off-by: Jarno Rajahalme <jrajahalme at nicira.com>
>
> The critical change here is a few lines buried in refactoring. I guess
> that's OK in this case but it would be even better if these changes were
> separated.
>
> Acked-by: Ben Pfaff <blp at nicira.com>
I separated them to two different patches and pushed both to master. Thanks for the review!
Jarno
More information about the dev
mailing list