[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] while (1) { $i++, $a{ $i } = $i } crashes Blue G3



> Joergen,
> 
> Sounds like cruel and unusual punishment to your Mac.  :-)

Was meant as a test. Someone said it'd be hard to cause a real memory
leak using Perl, so I wrote this little beast. (Yes - and the first
comma is supposed to be a semikolon)

> You might mention to the group:
>   1.  which version of MacPerl you are using

Vs.: 5.2.0r4 for PPC Patchlevel 5.004

>   2.  what application memory size you are using (and if problem changes
>       if you change preferred size.

Min :      1536 kB
Preferred: 5600 kB

No changes when changed to more.

>   3.  exactly which MacOS you've got on the Blue G3

8.5.1

>   4.  how much cache you have installed

64 MB physical / 64 MB virtual / estim. Cache 2048 kB

>   5.  what happens with minimum extensions

Minimum extensions do not change the prob.

>   6.  what other applications you are running/have run since the last boot

Finder only.

If I run that thing as 

    while (1) { $i++; $a{ $i } = $i; print $i };

it causes a freeze, when the first line seems to be filled.

when I make that

    while (1) { $i++; $a{ $i } = $i; print "$i\n" };

and monitor memory usage in "About this Computer" the loop runs until a
short time before all the allocated memory (5600 kB) is eaten up by the
hash, causing yet another freeze.

If I run the above (incl. \n) out of BBedit 4.0 Light, using the "Run
MacPerl Cmd-Shift-R" Extension it instantly freezes.

puzzled, 

Joergen

> >The following construct crashes my Mac and damages the Volume Bitmap.
> >
> >while (1) { $i++, $a{ $i } = $i };
> >
> >I thought it would cause MacPerl throwing the "Out of memory" message,
> >instead it freezes the thing. Cmd-Option-Esc no help, either.
> >
> >Is this a problem with MacPerl or with my Mac's (G3/300/64) memory
> >handling ?
> >
> >Reports from users of other systems only tell of extensive swapping but
> >no crash.
> >
> >Greetings,
> >
> >/(?=Joergen)/
> >--
> >-------------------------------------------------------------------
> >   "Everything is possible - even sometimes the impossible"
> >             HOELDERLIN EXPRESS - "Touch the void"
> >-------------------------------------------------------------------
> 
> --
> Regards, Larry F. Allen-Tonar        (larryat@cts.com) +1 760/746-6464 (voice)
>          Principal Designer                              +1 760/746-0766 (FAX,
>          P.O. Box 463072                                         upon request)
>          Escondido, CA  92046-3072


-- 
-------------------------------------------------------------------
   "Everything is possible - even sometimes the impossible"
             HOELDERLIN EXPRESS - "Touch the void"
-------------------------------------------------------------------

===== Want to unsubscribe from this list?
===== Send mail with body "unsubscribe" to macperl-request@macperl.org