Register R13
Register R13
ORG.incR allocates registers up to R11. R12 is MT, R14 is SP, and R15 is LNK. What about R13, may I use it, or does it have a special purpose as well?
-
- Site Admin
- Posts: 497
- Joined: Fri Dec 31, 2010 12:30 pm
- Contact:
Re: Register R13
Refer to Section 8.1 Layout and run-time organization of the Project Oberon (2013) Documentation:
If you then look at the RISC5 compiler modification history you will see the following entry for 2018:
https://people.inf.ethz.ch/wirth/news.txt
However, I would not recommend using R13 for your own purposes unless you intend to maintain your own customised version of the RISC5 compiler as well.
Code: Select all
R13 base address for variables in the current module SB (static base)
Code: Select all
20180720 - Update compiler: ORP.Mod.txt and ORG.Mod.txt
Cash (* Cache? *) for base adr of global variables "curSB" has been removed from ORG.Mod.
Removal of this optimization makes compiler simpler.
However, I would not recommend using R13 for your own purposes unless you intend to maintain your own customised version of the RISC5 compiler as well.
Re: Register R13
Thanks for the pointers. I don't have intention to change the compiler to use R13, but I am grinding my teeth on an in-circuit debugger, and an otherwise unused register could be handy from assembly code. ![Wink ;)](./images/smilies/icon_e_wink.gif)
![Wink ;)](./images/smilies/icon_e_wink.gif)