Brian Harvey wrote >I still don't get it, I'm afraid; why is a frame on the stack more >expensive than a frame on the heap? Is this some PC-specific thing >I don't know about? > I'm sorry, I'm not being clear. Let me start again. In procedural language implementations, when a procedure is called (non-tail recursively) a frame or record is pushed onto a stack. Each thread or process needs its own stack. When a thread suspends all the memory devoted to the stack is tied up until the process resumes and the procedure calls unwind. In ToonTalk and related languages, the only memory that a process needs is for 2 pointers: to the program (robots) and to the data (box). There is no stack. There is no other state. That is the point I was trying to make. Because of this 100,000 processes in ToonTalk is feasible. (The default city size only holds 400 houses but the largest size holds about a 250,000 houses.) What is a reasonable upper limit for the number of processes in Logo? Some reader may wonder why this matters for kids? Massive parallelism has been shown to useful when kids use StarLogo. In ToonTalk we can have parallelism to the same scale as StarLogo but MIMD (multiple instructions multiple data), not the much more limitted SIMD (single instruction multiple data) of StarLogo. ToonTalk enables one to put a few processes behind each pixel on the screen if you want. > >But I don't want to make you do everything functionally. What I want >is a language that doesn't impose one paradigm on me, but allows me >to choose what's best for the problem at hand. So, it's not that I >want you to leave anything out; I want you to make function composition >easier, also! But your argument about why concurrency is harmless in functional languages doesn't generalize to the multiple paradigm language you are suggesting. If you don't do everything functionally then concurrency is dangerous and complex. Unless you do things the way ToonTalk does. Best, -ken kahn --------------------------------------------------------------- Please post messages to the Logo forum to logo-l@gsn.org. Mail questions about the list administration to logofdn@gsn.org. To unsubscribe send unsubscribe logo-l to majordomo@gsn.org.
Global SchoolNet Foundation -
Linking Kids Around the World!
Copyright GSN - All Rights Reserved
- Comments
& Questions
Visit GSN's
Global
Schoolhouse for more exciting learning resources!
Search our Site
-
Home