[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 6502 Multitasking OS announce
In article <4innc7$hc4@no-names.nerdc.ufl.edu>
Michael Ellis <michael@anest4.anest.ufl.edu> writes:
>Of course, the SP is only an 8-bit register so it HAS to be at a fixed RAM address.
>I would consider copying the stack (only the bytes that are actually used) during
>a task switch becase no matter what you do you're going to end up copying context-
>related data at some point.
I am shure, that the 6502 processor was not designed for multitasking
purposes. As far as I see, each task needs it's own little world: A stack of
course; and space for code and data. Because there is only one stack
available, each stack related operation (JSR, TXS, ...) would only be allowed
for the dispatcher. It seems to be indeed a possible solution to transfer
the stack content for each task to reserved memory spaces. But copying the
stack for each task slows the system down. To get around this, I consider the
use of a p-machine like the UCSD system for the apple 2. The p code is machine
independent and relocable. It's not quite fast, but it works.
Holger Bruns