Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!dimacs.rutgers.edu!seismo!uunet!cbmvax!daveh From: daveh@cbmvax.commodore.com (Dave Haynie) Newsgroups: comp.sys.amiga.advocacy Subject: Re: How do we change the scheduler? (Was Re: Multitasking at home...) Message-ID: <17913@cbmvax.commodore.com> Date: 22 Jan 91 19:03:01 GMT References: <1991Jan18.231330.16290@Neon.Stanford.EDU> <7553@sugar.hackercorp.com> <1991Jan21.004720.25985@ncsuvx.ncsu.edu> <12880@life.ai.mit.edu> <1991Jan21.055854.14130@rice.edu> Reply-To: daveh@cbmvax.commodore.com (Dave Haynie) Distribution: usa Organization: Commodore, West Chester, PA Lines: 55 In article <1991Jan21.055854.14130@rice.edu> jsd@wahoo.rice.edu (Shawn Joel Dube) writes: >Seriously, I think cooperative is better. I think you got that backwards... >Take the following for example: >Two task are running. One is waiting on a keypress (via OS subroutine) >and the other is doing some serious number-crunching. With the Amiga, >valuable time is being spent doing nothing (waiting for a keypress). On the Amiga, no time is spent waiting for a keypress. If a task needs to wait synchronously for some I/O event, it is suspended, consuming no CPU time, until the I/O operation has completed. >With co-op multitasking, almost all of the cpu time is spent with the number >cruncher. The co-op system may indeed point the CPU at the crunching task. So will the Amiga OS, since the I/O bound tasks are waiting for I/O interrupts and signals before they get rescheduled. Now you press a key. The Amiga will get an interrupt, the waiting task will get signaled and, assuming its at the same or high priority than the CPU bound task, it'll get activated during the next time slice. On the co-op system, one of two things happens. Either the CPU bound task must have some event monitor subroutine in somewhere, wasting CPU time each time its called, or the I/O blocking task will have to wait for the CPU bound task to complete before processing the keypress. In either case, the Amiga gets the same combination of CPU and I/O bound tasks done faster, guaranteed, than the co-op system. >If programmed to do so, yes. I believe in the next release of the Mac OS, >the ability to have something like Window's Dynamic Data Link will exist >that the Amiga (correct if I'm wrong) doesn't have. Under 2.0x (which is out on the A3000 now, unlike Apple's System 7.0), the Amiga has facilities which do the same kind of thing. One such facility is file notification. Basically, this does the data linking via the filesystem, which happens to be the way many programs already handle this kind of problem. On Macs, Amigas, and other systems, you very often have a collection of programs to manipulate the various pieces of one final product. For example, a document processing program may import graphics from a drawing program and charts from a spreadsheet. When dealing with multitasking, multiuser, or networked systems, it became clear some time back that a simple file import mechanism could easily leave you with stale data. Because the files only get updated, at best, when an application is started up. On the Amiga, an application can not only import a file, but ask the filesystem to send it a message if that file ever changes. So if you change drawings over a network and I flip over to my spreadsheet and change the graph in the aforementioned example, when I flip back to the documentation processor, it'll already have the new versions there waiting for me if it knows about notification. -- Dave Haynie Commodore-Amiga (Amiga 3000) "The Crew That Never Rests" {uunet|pyramid|rutgers}!cbmvax!daveh PLINK: hazy BIX: hazy "What works for me might work for you" -Jimmy Buffett