On 12/19/22 19:29, Adrian Moreno wrote: > Currently, things like the number of handler and revalidator threads are > calculated based on the number of available CPUs. However, this number > is considered static and only calculated once, hence ignoring events > such as cpus being hotplugged, switched on/off or affinity mask > changing. > > On the other hand, checking the number of available CPUs multiple times > per second seems like an overkill. > Affinity should not change that often and, even if it does, the impact > of destroying and recreating all the threads so often is probably a > price too expensive to pay. > > I tested the impact of updating the threads every 5 seconds and saw > an impact in the main loop duration of <1% and a worst-case scenario > impact in throughput of < 5% [1]. This patch sets the default period to > 10 seconds just to be safer. > > [1] Tested in the worst-case scenario of disabling the kernel cache > (other_config:flow-size=0), modifying ovs-vswithd's affinity so the > number of handlers go up and down every 5 seconds and calculated the > difference in netperf's ops/sec. > > Signed-off-by: Adrian Moreno <[email protected]> > ---
Applied. Thanks! Best regards, Ilya Maximets. _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
