Out Of Memory conditions


Subject: Out Of Memory conditions
From: Mike Nordell (tamlin@algonet.se)
Date: Sat Feb 03 2001 - 04:57:55 CST


I just come to think of another, non-exception using, solution to our
(currently imaginary since it has never occured AFAIK, but still) OOM
condition.

We can provide code that on "new"-requested OOM calls calls our emergency
save. This of course requires the emergency save not to use any heap-memory
allocation, but I'm quite confident it already meets this requirement (how
on earth would it otherwise be able to save upon SEGV?).

We need to call either set_new_handler (for conforming compilers) or it's
underscore prepended counterpart MSVC.

I believe this should be done at the earliest possible moment in
main/WinMain or whatever your platforms startup code is called. What's your
view on this? Should we bother, or should we simply die if OOM occurs?

/Mike



This archive was generated by hypermail 2b25 : Sat Feb 03 2001 - 04:56:22 CST