[bug][FIX] stack overflow crashes Squeak. ( test to confirm bug and fix on Unix/Linux )

lewis at mail.msen.com lewis at mail.msen.com
Thu Jul 1 22:11:57 UTC 2004


Attached is a change set that I used to debug the stack overflow problem
and confirm the fix. This only runs on a Unix VM with OSProcess loaded,
but the overflow problem is a bit tricky to debug so I'm posting this in
case someone wants to reproduce what I did.

Basically this just writes debug trace messages to standard output so I
can keep track of what process is running what method in what order.
Just some good ol' fashioned Fortran debugging, but what the heck, it
worked.

>From the preamble:

This is what I used to debug the stack overflow problem. Load OSProcess
first, then load this change set.

Intended for use on Unix/Linux. Run the Squeak vm with a fixed memory
allocation (squeak -memory 30m) in order to force the out-of-memory
condition.

Open a ProcessBrowser, then evaluate 'Smalltalk createStackOverflow'. 
You should see messages on stdout that confirm that the runaway
recursion keeps going even after the low space semaphore has be
signaled.

Now apply the LowSpaceWatcherFix change set, and evaluate 'Smalltalk
createStackOverflow'. The low space watcher should catch the runaway
method right away.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: StackOverflowDebugging-dtl.cs.gz
Type: application/octet-stream
Size: 1691 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20040701/b52e4450/StackOverflowDebugging-dtl.cs.obj


More information about the Squeak-dev mailing list