News for hackers. Stuff that matters.
Re:Rust and the Future of Systems Programming [video] by Matthias247 on Wednesday November 16, 2016 @04:37PM (#12971810)
> Your runtime simply needs to bound the amount of reclamation work done at any given time.

Wouldn't this transform the problem into a "no more predictable maximum memory usage" problem? As you can't really know if and when your GC will keep up it with the amount of work to do.

Re:Rust and the Future of Systems Programming [video] by naasking on Wednesday November 16, 2016 @05:16PM (#12972102)
Possibly, but maximum memory usage is rarely predictable anyway. I expect it might be even less predictable than maximum latency.

However, it may still be possible to conservatively bound your maximum memory usage too, as long as your reclamation-work phase keeps up with your program's allocation rate, then you achieve a steady-state.

Suppose some amount of reclamation is done on malloc(), a tunable parameter could measure the ratio of allocation speed of the running program and amount of unreclaimed garbage. This ratio would control how much reclamation work to do before returning from malloc() so you can fall into steady-state.

Re:Rust and the Future of Systems Programming [video] by lmm on Thursday November 17, 2016 @08:52AM (#12977397)
> Possibly, but maximum memory usage is rarely predictable anyway. I expect it might be even less predictable than maximum latency.

Well, if you don't need a bound on memory usage you can just never deallocate.

> Suppose some amount of reclamation is done on malloc(), a tunable parameter could measure the ratio of allocation speed of the running program and amount of unreclaimed garbage. This ratio would control how much reclamation work to do before returning from malloc() so you can fall into steady-state.

Sure, but that doesn't guarantee anything about what your maximum spikes are going to be. You can have a firm bound on memory consumption or a firm bound on latency, but you can't get both without doing some serious application-specific work.