object RISCISA
- Alphabetic
- By Inheritance
- RISCISA
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
case class
ADD
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Add the values in registers b and c, store the result in register a.
-
case class
ADDI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Add the value in register b and the value im, store the result in register a.
-
case class
AND
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Bitwise AND the values in registers b and c, store the (integer) remainder in register a.
-
case class
ANDI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Bitwise AND the value in registers b and the value im, store the (integer) remainder in register a.
-
type
AssemCode = Seq[Assembler]
An assembler code sequence.
An assembler code sequence. Includes comments and labels.
-
sealed abstract
class
Assembler
extends AnyRef
Machine instructions.
-
case class
BEQ
(label: Label) extends Branch with Product with Serializable
If the Z condition code is set, set the program counter to its value plus four times disp.
-
case class
BGE
(label: Label) extends Branch with Product with Serializable
If the N condition code is clear, set the program counter to its value plus four times disp.
-
case class
BGT
(label: Label) extends Branch with Product with Serializable
If both of the Z and N condition codes are clear, set the program counter to its value plus four times disp.
-
case class
BLE
(label: Label) extends Branch with Product with Serializable
If either of the Z or N condition codes is set, set the program counter to its value plus four times disp.
-
case class
BLT
(label: Label) extends Branch with Product with Serializable
If the N condition code is set, set the program counter to its value plus four times disp.
-
case class
BNE
(label: Label) extends Branch with Product with Serializable
If the Z condition code is clear, set the program counter to its value plus four times disp.
-
case class
BR
(label: Label) extends Branch with Product with Serializable
Set the program counter to its value plus disp.
-
case class
BSR
(label: Label) extends Branch with Product with Serializable
Set R31 to the value of the program counter plus one.
Set R31 to the value of the program counter plus one. Set the program counter to its value plus disp.
-
sealed abstract
class
Branch
extends Instr
Common type for all branch instructions.
-
case class
CHKI
(b: RegNo, im: Imm) extends Instr with Product with Serializable
If register a contains a value that is negative or greater than or equal to the value im, set register a to zero.
-
case class
CMP
(b: RegNo, c: RegNo) extends Instr with Product with Serializable
Set the Z condition code if the contents of registers b and c are equal.
Set the Z condition code if the contents of registers b and c are equal. Set the N condition code if the content of register b is less than the content of register c.
-
case class
CMPI
(b: RegNo, im: Imm) extends Instr with Product with Serializable
Set the Z condition code if the content of register b and the value im are equal, otherwise clear Z.
Set the Z condition code if the content of register b and the value im are equal, otherwise clear Z. Set the N condition code if the content of register b is less than the value im, otherwise clear N.
-
type
Code = Seq[Instr]
A machine code sequence.
-
case class
Comment
(text: String) extends Pseudo with Product with Serializable
Comment.
-
case class
DIV
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Divide the values in registers b and c, store the (integer) result in register a.
-
case class
DIVI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Divide the value in register b and the value im, store the (integer) result in register a.
- type Disp = Int
-
type
Imm = Short
Operand types
- sealed abstract class Instr extends Assembler
-
case class
LDB
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Load register a with the byte value stored in memory at the address given by the contents of register b plus the value im.
-
case class
LDW
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Load register a with the word value stored in memory at the address given by the contents of register b plus the value im.
Load register a with the word value stored in memory at the address given by the contents of register b plus the value im. The lowest two bits of the address are ignored.
-
case class
Label
(num: Int, disp: Int = 1) extends Instr with Product with Serializable
Branch target labels.
Branch target labels. If the
dispfield is -1 then this label has not been resolved. Otherwise,dispgives the offset from the start of the code block. -
case class
MOD
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Divide the values in registers b and c, store the (integer) remainder in register a.
-
case class
MODI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Divide the value in registers b and the value im, store the (integer) remainder in register a.
-
case class
MOV
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Shift the value in register c by b and store the result in register a.
-
case class
MOVI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Shift the value im by b and store the result in register a.
-
case class
MUL
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Muliply the values in registers b and c, store the result in register a.
-
case class
MULI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Multiply the value in register b and the value im, store the result in register a.
-
case class
MVN
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Shift the value in register c by b and store the negation of the result in register a.
-
case class
MVNI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Shift the value im by b and store the negation of the result in register a.
-
case class
OR
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Bitwise OR the values in registers b and c, store the (integer) remainder in register a.
-
case class
ORI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Bitwise OR the value in registers b and the value im, store the (integer) remainder in register a.
-
case class
POP
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Load register a with the word value stored in register b.
Load register a with the word value stored in register b. The lowest two bits of the address are ignored. Subtract (???) im from the contents of register b and store the result in register b.
-
case class
PSH
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Add im to the contents of register b and store the result in register b.
Add im to the contents of register b and store the result in register b. Store the value in register a into memory at the address given by the contents of register b. The lowest two bits of the address are ignored.
-
sealed abstract
class
Pseudo
extends Assembler
Pseudo instructions.
Pseudo instructions. These aren't really RISC machine instructions but are used to insert comments and labels into a RISC assembly code program
-
case class
RD
(a: RegNo) extends Instr with Product with Serializable
Read an integer variable from standard input and store the value in register a.
-
case class
RET
(c: RegNo) extends Instr with Product with Serializable
Set the program counter to the value in register c.
Set the program counter to the value in register c. If that value is zero, halt the machine.
-
type
RegNo = Int
Register numbers (0-31).
Register numbers (0-31). Program counter is R28.
-
case class
STB
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Store the least-significant byte of the contents of register a to memory at the address given by the contents of register b plus the value im.
-
case class
STW
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Store the contents of register a to memory at the address given by the contents of register b plus the value im.
Store the contents of register a to memory at the address given by the contents of register b plus the value im. The lowest two bits of the address are ignored.
-
case class
SUB
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Subtract the values in registers b and c, store the result in register a.
-
case class
SUBI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Subtract the value in register b and the value im, store the result in register a.
-
case class
Target
(label: Label) extends Pseudo with Product with Serializable
Branch target label.
-
case class
WRD
(c: RegNo) extends Instr with Product with Serializable
Write a decimal representation of the value in register c to standard output.
-
case class
WRH
(c: RegNo) extends Instr with Product with Serializable
Write a hexadecimal representation of the value in register c to standard output.
-
case class
WRL
() extends Instr with Product with Serializable
Write a newline to standard output.
-
case class
XOR
(a: RegNo, b: RegNo, c: RegNo) extends Instr with Product with Serializable
Bitwise XOR the values in registers b and c, store the (integer) remainder in register a.
-
case class
XORI
(a: RegNo, b: RegNo, im: Imm) extends Instr with Product with Serializable
Bitwise XOR the value in registers b and the value im, store the (integer) remainder in register a.
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
-
def
prettyprint(emitter: Emitter, code: AssemCode): Unit
Pretty-print a list of assembly code instructions to an emitter.
- def sayReg(reg: RegNo): String
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )