[BUG] squeak crashes entirely

Matthew McNaughton mcnaught at cs.ualberta.ca
Sun Sep 9 22:25:58 UTC 2001


On Fri, 7 Sep 2001, Andrew C. Greenberg wrote:

> Unusual.  Can you advise as to your system, configuration, Squeak VM and 
> version?

I have Linux 2.2 &etc.
"about this system" -> "Squeak3.0 of 4 February 2001 latest update #3552".
I don't know if that will help.

It all started when I was working through John Maloney's BankAccount
tutorial. I couldn't help but notice that while it shows off the ability
of the Number type hierarchy to easily compute and represent 100
factorial, it never shows off the ability of a Morph to be 100 factorial
pixels high. So I tried it. Ouch! I've boiled the code down to this:

| m |
m _ AlignmentMorph newRow
	hResizing: #shrinkWrap;
	vResizing: #shrinkWrap;
	cellPositioning: #bottomRight.
m addMorph: (Morph new extent: 30@(100 factorial)).
m openInWorld.

Do that in a workspace in a scratch image! You should get a white window
in the top left of my screen saying

***System error handling failed***
and then a stack dump. It's hard to get out of this.

So I read through the responsible code, and saw that, okay, it doesn't
like if a coordinate is not a SmallInteger. So I gave it a SmallInteger:

| m |
m _ AlignmentMorph newRow
	hResizing: #shrinkWrap;
	vResizing: #shrinkWrap;
	cellPositioning: #bottomRight.
m addMorph: (Morph new extent: 30@(1000000000)).
m openInWorld.

It draws it! Nice. Now try to drag it. That crashes the VM hard.

I whittled the code down a bit, and got some more interesting results:

| m |
m _ AlignmentMorph newRow.
m addMorph: (Morph new extent: 30@(100 factorial)).
m openInWorld.

Now the bad part is that this is recoverable, the pink error window will
pop up, you can press "Proceed" or "Abandon" a couple of times and it
recovers. However, some remnant of the Morph is left over on the screen,
but not drawn, it is invisible.  So if you click on it unawares, it will
crash the vm hard just as the previous case, because it seems to be trying
to form a huuuuge bitmap. Now the problem is, if you save your image in
the interim because you thought that everything was okay, you are screwed.

I don't have any plans to fix this in the near term, but I thought I'd
share.

> On Friday, September 7, 2001, at 08:00  AM, Matthew McNaughton wrote:
> 
> > Symptom:
> >
> > Squeak seems to run out of memory when it tries draw certain things. I
> > have an image where if you click in a certain place, it will blow up. I
> > haven't figured out exactly why, but it seems to be trying to create a
> > huge bitmap. The interpreter prints a few thousand lines of stack dump 
> > to
> > stderr and then exits:
> >
> > out of memory
> >
> > 1096643980 Integer><
> > 1096643888 LargePositiveInteger><
> > 1096643796 Magnitude>>=
> > 1096643704 LargePositiveInteger>>=
> > 1096643612 Behavior>basicNew:
> > 1096643520 Behavior>basicNew:
> >
> > ... thousands ...
> >
> > 1086524096 Behavior>basicNew:
> > 1086524004 Behavior>basicNew:
> > 1086523584 Behavior>basicNew:
> > 1086523428 Behavior>new:
> > 1086523336 Form>setExtent:depth:
> > 1086523244 Form class>extent:depth:
> > 1086523152 Form>allocateForm:
> > 1086523060 HandMorph>savePatchFrom:
> > 1086523676 [] in WorldState>displayWorld:submorphs:
> > 1086522968 OrderedCollection>collect:
> > 1086522752 WorldState>displayWorld:submorphs:
> > 1086522660 PasteUpMorph>privateOuterDisplayWorld
> > 1086522568 PasteUpMorph>displayWorld
> > 1086522452 SystemWindow>passivate
> > 1086522360 SystemWindow>activate
> > 1086518668 SystemWindow>openInWorld:extent:
> > 1086518524 SystemWindow>openInWorldExtent:
> > 1086507508 Debugger>buildMorphicNotifierLabelled:message:
> > 1086507092 Debugger>openNotifierContents:label:
> > 1086506868 Debugger class>openInterrupt:onProcess:
> > 1086506712 Project class>interruptName:
> > 1086506548 CurrentProjectRefactoring class>currentInterruptName:
> > 1086274936 SystemDictionary>lowSpaceWatcher
> > 1086275028 [] in SystemDictionary>installLowSpaceWatcher
> > 1086275120 [] in BlockContext>newProcess

-- 
Matthew McNaughton <mcnaught at cs.ualberta.ca>






More information about the Squeak-dev mailing list