Ok Jim, the analogies make some sense, but where is the stacks ectry spposed to
be..?? Does there have to be one.. or should there be ? As best i can tell i
have no such entry anywhere. Any advantages or disadvantages of having (or
not having) a stacks entry ??
Thanks
Dave Hurst
Jim Meagher wrote:
> > -----Original Message-----
> > From: PCSOFT - PC software discussion list
> > [mailto:[log in to unmask]]On Behalf Of Roy Schriftman, MS,
> > MBA
> >
> > At 12:10 AM 4/28/98 -0400, you wrote:
> > >Can someone expand on what the stack setting is all about..???
> > >thanks,
> > >Dave Hurst
> > >
> > The variable A is allocated in a memory stack each time the subroutine is
> > called. In the above case an infinite number of times. The stacks
> > configuration command puts a limit on this process and the program will
> > crash when the limit is exceeded.
> >
> > Think of the stack as each time a process is started it takes a new piece
> > of paper from the stack to record any data unique to the process. The
> > stack is the number of pieces of paper you start with.
> >
>
> Yes and no.
>
> I like Roy's analogy to a stack of paper BUT...
> He has it backwards. When a piece of paper is written on, it is saved
> TO the stack not taken off of it. And the stack number is the maximum
> size of the storage area not how many sheets of paper you start with.
>
> A stack is simply a RAM memory area that the CPU or application
> (in this case, Windows) reserves and uses for storage of temporary
> data. It is used in a LIFO (last in first out) manner (hence the name
> stack) which means that it must pull off the top "sheet" first when
> retrieving the stored data.
>
> Granted, the history feature of a web browser is much more complex
> and has other features, but for demonstration purposes....
>
> An example of how a stack functions, is the BACK button on
> your web browser. Each time you move to a new web page,
> your browser records the address of the previous page on a "sheet"
> and puts it on the stack. Then each time you press the BACK button,
> the browser retrieves the top sheet from the "stack".
|