[dpdk-dev] [dpdk-stable] [PATCH v2] app/procinfo: Fix memory leak by rte_service_init
Thomas Monjalon
thomas at monjalon.net
Fri Jan 26 18:26:54 CET 2018
26/01/2018 18:15, Van Haaren, Harry:
> From: Thomas Monjalon [mailto:thomas at monjalon.net]
> > 11/01/2018 20:47, Vipin Varghese:
> > > When procinfo is run multiple times against primary application, it
> > > consumes huge page memory by rte_service_init. Which is not released
> > > at exit of application.
> > >
> > > Invoking rte_service_finalize to real memory and prevent memory leak.
> >
> > I don't think it is correct to call rte_service_finalize in applications,
> > while rte_service_init is called in EAL.
> >
> > Maybe we need a new function in EAL.
>
> Yes correct - we need a rte_eal_deinit(), cleanup() or finalize() or something. This ties in with splitting EAL to be more modular on startup, and DPDK in general behaving more like a library and less like a single-monolith.
>
> For the 18.02 timeframe, the simplest solution to solve the secondary process mem-leak issue than to merge into these applications, unfortunately.
>
> The only other option I see is to add an rte_eal_finalize() function, and hide this call behind it, however it is quite late to add such a function, and what do we do with cases like rte_panic(), rte_exit(), or system signals like SIGINT, SIGHUP etc? It seems too complicated to add "quickly" to me.
>
> If there is technically a better solution viable in the given timeframe, I'm open to suggestions?
I think it is better to keep the leak in 18.02,
and takes time to fix it properly in 18.05.
If you really think it is a major bug, we can try to expose a new
EAL function now and refine it in 18.05.
More opinions?
More information about the dev
mailing list