[RFC] random: use per lcore state

Stephen Hemminger stephen at networkplumber.org
Sat Sep 9 13:32:09 CEST 2023


On Sat, 9 Sep 2023 08:45:17 +0200
Mattias Rönnblom <hofors at lysator.liu.se> wrote:

> > Hmm.. correct me if I am wrong, but with current implementation,
> > rand state is also in non-huge memory:
> > static struct rte_rand_state rand_states[RTE_MAX_LCORE + 1];
> >   
> 
> Yes. The current pattern is certainly not perfect.

There is no good reason to put it in hugepage memory.
In fact, hugepage memory is a limited resource and you do want
different rand_states for primary and secondary processes.


More information about the dev mailing list