From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 107f24,6f568a2e6507575 X-Google-Attributes: gid107f24,public X-Google-Thread: f891f,6f568a2e6507575 X-Google-Attributes: gidf891f,public X-Google-Thread: 103376,6f568a2e6507575 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-04-25 10:26:21 PST Path: newsfeed.google.com!newsfeed.stanford.edu!cyclone.bc.net!newsfeed.direct.ca!look.ca!news1.tor.metronet.ca!nnrp1.tor.metronet.ca!not-for-mail Message-ID: <3AE708BB.1536FBF7@home.com> From: "Warren W. Gay VE3WWG" X-Mailer: Mozilla 4.75 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada,comp.lang.functional,comp.lang.misc Subject: Re: Thoughts and Opinions or something like that References: <3AE67F57.722A78D8@andrewcooke.free-online.co.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Wed, 25 Apr 2001 17:26:20 GMT NNTP-Posting-Host: 198.96.47.195 NNTP-Posting-Date: Wed, 25 Apr 2001 11:26:20 MDT Organization: MetroNet Communications Group Inc. Xref: newsfeed.google.com comp.lang.ada:6933 comp.lang.functional:5299 comp.lang.misc:1137 Date: 2001-04-25T17:26:20+00:00 List-Id: "chris.danx" wrote: > > Hi, >...snip... > > - support for coroutines (no single stack restrictions) > > > > I don't understand what you mean by "coroutines" but i assume from what comes > next it's got something to do with multiple stacks. I suppose i could try > something like having more than one SP in the RISC version and see how that > goes. Pop S2, for pop stack 2. Or more generically Pop An, where An is an > address register pointing to the stack. Then i could integrate more a specific, > better design in the WillowVM (VM version 2). Co-routines require multiple stacks, in the same way that threads do. What happens in practice, some arbitrary amount is offsetted from the current stack pointer (or its root), to start a new stack. In other words, one stack is subdivided into many, to accomodate additional co-routines (or additional threads). However, there is no law that says you have to implement stacks in this way, but there are sometimes performance benefits to this, depending upon your platform (memory pages behind the virtual pages are physically allocated as the stack grows deeper for example). However, you could accomodate the same effect with malloc() if your platform supports lazy virtual memory allocation (I believe *BSD and Linux do this). In any event, the bottom line is that you still have to decide on stack sizes at some point :< , or accept them by default. -- Warren W. Gay VE3WWG http://members.home.net/ve3wwg