JuliaData / MemPool.jl

High-performance parallel and distributed datastore for Julia
Other
23 stars 15 forks source link

poolset: Call GC when free mem is low #75

Closed jpsamaroo closed 9 months ago

jpsamaroo commented 11 months ago

This PR attempts to work around memory usage issues in a similar manner to the Julia GPU packages: when poolset is called, if we're running low on memory (according to a configurable threshold), then we do increasingly expensive calls to the GC to try to free up enough memory to avoid an OOM.

An enhancement that we could make is to keep trying to GC until we don't free any memory. To be investigated.

@stevenwhitaker @svilupp this might help with the OOM issues seen with your workloads.

@krynju I'm considering enabling this by default, do you have any objections to that?