Re: On the issue of low memory situations

From: Robert de Vries (rhdv@rhdv.cistron.nl)
Date: Sat Mar 18 2000 - 10:11:17 EST


On Fri, 17 Mar 2000, Linda Walsh wrote:

> Nicholas Vinen wrote:
> >
> > On Fri, 17 Mar 2000, Linda Walsh wrote:
> >
> > > I haven't read through this whole thread, so this may have been
> > > suggested, but why not have a new signal "SIGNMEM". Can't be caught but
> > > can be ignored. Default is to take the signal and terminate the program
> > > that faulted. If ignored, put process to sleep until the memory request
> > > can be satisfied. Then something like 'X' or apache could ignore, while
> > > 'gcc' would just die.
> >
> > Well, it might even be useful to be able to catch it.
> ---
> It's possible to define a 'catch' behavior, but it couldn't be
> guaranteed, since calling the signal handler would demand space on the
> stack which could result in another needed page.

You can easily guarantee that the signal can be caught by allocating a
special signal handling stack using sigaltstack().

        Robert

-- 
Robert de Vries
rhdv@rhdv.cistron.nl

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Mar 23 2000 - 21:00:24 EST