WarpUp (13/72)

From:Steffen Haeuser
Date:05 Apr 00 at 07:50:01
Subject:Re: PPC Crashes when Multitasking

owner-warpup-list@haage-partner.com wrote :

Hi!

ow> My suggestion was just because I've very recently discover this pb. But BTW
ow> I had also another possible explication (yes, one more) and in fact i'm
ow> really wondering if this could cause pbs in the future: The Stack! Yes, it
ow> is now well known that all the Warp-os (and some Power-up) software seems
ow> to need a really huge stack (500000 on most case). So what happen if you

This is more Compiler-Specific than Kernel-Specific. Programs compiled with
StormC, vbcc (both used with WarpUP) and gcc (used with WarpUP and PowerUP) do
not support a command to raise the stack automatically. Of course it is
possible to check before starting a program if the stack is big enough, or
even launching the program inside a second task - using for example a GUI -
which automatically raises the stack, but few people do it. You will notice
that "stack problem" also by gcc-68k compiled programs, BTW.

My own solution to this is to use as default-shell the shell "KingCon" which
sets the default-stack to 30000 for programs started from the Shell which is
enough for most programs. If it is not enough a nice solution is providing a
GUI (AmiHeretic for example supports a stack-raising GUI).

ow> launch 2 or more of those "stack-hungry" apps? Do you have to define a
ow> 500000 stack for each PPC apps running on your system, or do they share a
ow> unique stack, and so have we to increase that stack a bit more?
ow> I think this question not only concern ROJ's problem.

The Stack is not global to your system. It is specific to the task (the Shell)
from which you start the program. It is an area inside a Task where things
like local variables for recursions are stored. Each task has it's own stack.

For the CLI Shell the default stack is 4096. Which is really too low for
most bigger programs.

Steffen Haeuser