[sugar] Memory allocation indicators

Michael Stone michael
Thu Mar 13 16:03:33 EDT 2008


> Also, it would be easy for Rainbow to enforce a pre-set hard limit on
> memory usage for each Activity separately.  

I've thought about it before, but I don't think it leads to a good UI at
the moment. The problem is that I don't think you really want to nuke
activities that hit their hardlimit, or to start returning ENOMEM to
ones that hit the soft (memory) limit.

That being said, the version of Rainbow in the 'faster' branch has some
support, courtesy of Marcus Leech, for configuring rlimits on the
activities its about to launch. Feel free to prove me wrong about the
UI effect. :)

> I think that this is very interesting, since it would allow us to
> ensure that OOM never happens, by only launching an activity if all
> activities could still max out their quota afterwards.  

This safety property only seems to be true if we can give reasonable
upper bounds on _all_ the software that we're trying to run, no?

Michael

P.S. - Ivan and I once kicked around the idea of modifying the 'hard'
'soft' limits notion into a 'sleepy' limit notion. In implementation,
this might consist of sending SIGSTOP rather than SIGKILL and blocking a
malloc() rather than returning ENOMEM until pressure is eased.
Unfortunately, this hasn't gone beyond the drawing board.




More information about the Sugar-devel mailing list