22/09/2026 12:42, Morten Brørup: > From: Stephen Hemminger [mailto:[email protected]] > > --- a/lib/mempool/rte_mempool.h > > +++ b/lib/mempool/rte_mempool.h > > @@ -230,13 +230,11 @@ struct __rte_cache_aligned rte_mempool_info { > > * The RTE mempool structure. > > */ > > struct __rte_cache_aligned rte_mempool { > > - char name[RTE_MEMPOOL_NAMESIZE]; /**< Name of mempool. */ > > union { > > void *pool_data; /**< Ring or pool to store > > objects. */ > > uint64_t pool_id; /**< External mempool identifier. > > */ > > }; > > - void *pool_config; /**< optional args for ops > > alloc. */ > > - const struct rte_memzone *mz; /**< Memzone where pool is > > alloc'd. */ > > + struct rte_mempool_cache *local_cache; /**< Per-lcore local cache > > */ > > unsigned int flags; /**< Flags of the mempool. */ > > int socket_id; /**< Socket id passed at create. > > */ > > uint32_t size; /**< Max size of the mempool. */ > > @@ -257,7 +255,9 @@ struct __rte_cache_aligned rte_mempool { > > */ > > int32_t ops_index; > > > > - struct rte_mempool_cache *local_cache; /**< Per-lcore local cache > > */ > > + void *pool_config; /**< optional args for ops > > alloc. */ > > + const struct rte_memzone *mz; /**< Memzone where pool is > > alloc'd. */ > > + char name[RTE_MEMPOOL_NAMESIZE]; /**< Name of mempool. */ > > > > uint32_t populated_size; /**< Number of populated > > objects. */ > > struct rte_mempool_objhdr_list elt_list; /**< List of objects in > > pool */ > > I have submitted a patch introducing a new "sizeof_cache_per_lcore" field [1]. > This new field must be close to the "local_cache" field. > > Also, for mempool cache misses, the "ops_index" and "pool_data" fields should > be close together. Optimally also close to the "local_cache" field, so they > have been fetched with it. > > [1]: > https://patchwork.dpdk.org/project/dpdk/patch/[email protected]/ > > AFAIK, only these four fields hot in the dataplane: > - local_cache, sizeof_cache_per_lcore (new field): > Used for access to objects in cache. > - ops_index, pool_data/pool_id: > Used on cache miss for access to objects in backing store. > > The other fields are not used in the dataplane, and can be moved down below > these four, which should be first. > > Note: The cache_size field is currently hot, but my patch makes it cold.
These changes in mempool are marged in main. So this memzone series needs to be rebased.

