[Oberon] RISC5
eas lab
lab.eas at gmail.com
Thu May 1 05:02:45 CEST 2014
On 4/28/14, Chris Burrows <chris at cfbsoftware.com> wrote:
>> -----Original Message-----
>> From: eas lab [mailto:lab.eas at gmail.com]
>> Sent: Monday, 28 April 2014 3:55 PM
>> To: chris at cfbsoftware.com; ETH Oberon and related systems
>> Subject: Re: [Oberon] RISC5
>>
>> ?! Where's the <Store Instruction> : Rx->MemN OK, none of the listed
>> instructions of: PO.Computer.pdf , RISC.Mod.txt consider accessing
>> memory.
>
> Store (ST) is defined in Chapter 9 'A RISC-Architecture as Target' in
> Section 9.3 "Memory Instructions' in the document CompilerConstruction2.pdf
>
> In RISC.Mod.txt there are three sections of code corresponding to the three
> different groups of instructions. Each section is identified with a
> comment:
>
> (*~p: register instruction*)
>
> (*p & ~q: memory instruction*)
>
> (* p & q: branch instruction*)
>
> The store and load instructions are interpreted in the 'memory instruction'
> group.
>
> Regards,
>
> Chris Burrows
> CFB Software
> http://www.cfbsoftware.com
Thanks. The fact that I didn't find it, without your assistance, confirms
the disadvantage of <writing tech-info in OBERON, like writing a music
score in natural-language>.
eg.
ELSIF ~ODD(IR DIV 4000'0000H) THEN (*p & ~q: memory instruction*)
adr := (R[b] + IR MOD 100000H) DIV 4;
IF ~ODD(IR DIV 2000'0000H) THEN
IF adr >= 0 THEN (*load*) R[a] := M[adr]; N := A < 0; Z := A = 0
ELSE (*input*) ...
Instead of: bN=mem; b(N-1)=load/input
Since your'e an ARM expert, and related to P-codes: I didn't get an answer
to this from the rPi Newsgroup:-
[without getting married to another architectures syntax] HOW2 write the
P-code/byte-strings for:
A. LoadImmediate ByteTo RegR <- 2 args
B. LoadByte fromAbsMemAdr <- 1 arg
C. StoreByte toAbsMemAdr <- 1 arg
..
and extend it to do eg:-
x55 -> R1
R1 -> <some memory-mapped port>
<someother memory-mapped port> -> R2
<compare R1 <-> R2>
<branchOnEqual manuallyCalculatedForward/Backward>
So that eg. the A,B,C p-Codes above could be just picked-off
a menu, and the args filled in.
Thanks,
== Chris Glur.
More information about the Oberon
mailing list