On Fri, Dec 13, 2013 at 6:08 PM, Ben Pfaff <b...@nicira.com> wrote:
> On Fri, Dec 13, 2013 at 02:17:16PM +0100, Helmut Schaa wrote:
>> Reduces binary size. Use a static inline function instead of
>> a macro to not get "unused variable" warning everywhere.
>>
>> Signed-off-by: Helmut Schaa <helmut.sc...@googlemail.com>
>> ---
>>
>> Not sure if this is the best idea but in my builds it reduces libopenvswitch
>> by around 10%.
>
> I guess I'm OK with this, but please update the comment, which currently
> says "Not affected by NDEBUG."

Will do.

> If you want to reduce size as much as possible, it might be better to
> update the callers to avoid those warnings.

There is quite a big number of callers:

# grep -r ovs_assert * | wc -l
2324

Replacing ovs_assert with an empty inline function (in the header)
effectively optimizes out the whole call for all callers. And this way
the change is not that intrusive ...

Helmut
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to