perl-fuse icon indicating copy to clipboard operation
perl-fuse copied to clipboard

implement interpreter pool to reduce memory usage for threaded mode

Open frett opened this issue 10 years ago • 7 comments

FUSE treats threads as light-weight objects and creates/deletes them frequently. This leads to a new perl interpreter being created for all new threads, but never being reclaimed/reused when a thread goes away. So, a long running threaded mount continues to leak memory as new perl interpreters are continuously created.

To address that issue, this pull request implements an interpreter pool to satisfy requests when running in threaded mode. Threaded callbacks will attempt to use an inactive interpreter from the pool, or create a new one if none are available.

This pull request has been tested on the following versions of perl (all running on Fedora Core): 5.8.8 5.10.0 5.14.4 5.16.3

frett avatar Oct 05 '13 20:10 frett