[Coco] [Color Computer] OS-9 Question, GCC stuff

James Diffendaffer jdiffendaffer at yahoo.com
Fri Jul 22 18:03:53 EDT 2005

Thanks Ben!  I didn't know what the registers contained on startup or
which could be used so that's really good to know.  

The stack pointer usage was different than I was expecting though I'll
need to make a couple changes there.  Thankfully it's only hard coded
in a couple places and I might just change that so that it's set from
one location if it doesn't break anything.  That makes it more
portable within the Motorola CPU family anyway.

--- In ColorComputer at yahoogroups.com, "Benoit Bleau" <benbleau at g...>
> James,
> In the OS9 level II development system, chapter 8 of RMA says:
> ...
> When OS-9 executes a process, the MPU Registers contain the bounds
of the
> data area. Register U contains the beginning address and Register Y
> the ending. OS-9 sets the SP register to the ending address + 1,
unless you
> use a parameter.  The direct page register contains the page number
of the
> beginning page. If you used no parameters, Y, X, and SP are the same
> The OS-9 shell always passes at least an end-of-line character in the
> parameter area.
> If Register U is maintained throughout the program, you can use
> constant-offset-indexed addressing.
> You can write part of the program's initialization routing to
compute the
> actual addresses of the data structure and stire these addresses in
> locations in the direct page. Then obtain the addresses later using
> direct-page addressing mode instructions.
> ...
> I would say that this means that yes, you can use DP :)
> -Ben

Brought to you by the 6809, the 6803 and their cousins! 
Yahoo! Groups Links

<*> To visit your group on the web, go to:

<*> To unsubscribe from this group, send an email to:
    ColorComputer-unsubscribe at yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:

More information about the Coco mailing list