package
Version:
v0.1.4
Opens a new window with list of versions in this module.
Published: Jan 4, 2022
License: MIT
Opens a new window with license information.
Imports: 13
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
OpcodeStrings returns a slice of all String values of the enum
RegStrings returns a slice of all String values of the enum
const (
BadFmt Fmt = iota
LoadFmt
StoreFmt
MoveFmt
CompareFmt
BinaryFmt
UnaryFmt
CallFmt
NoFmt
)
const (
Nop Opcode = iota
Rets
Error
Halt
Rcsr
Wcsr
Move
Loadc
Jump
Imm
Call
Imm2
Load
Store
Loadb
Storeb
Add
Sub
Addc
Subc
Xor
And
Or
Shl
Shr
Asr
IfEq
IfNe
IfLt
IfGe
IfUlt
IfUge
Not
Neg
Swap
IfGt
IfLe
IfUgt
IfUle
Return
NumOps
)
OpcodeString retrieves an enum value from the enum constants string name.
Throws an error if the param is not part of the enum.
OpcodeValues returns all values of the enum
IsAOpcode returns "true" if the value is listed in the enum definition. "false" otherwise
const (
RA Reg = iota
A0
A1
A2
S0
S1
S2
S3
T0
T1
T2
T3
T4
T5
GP
SP
)
RegString retrieves an enum value from the enum constants string name.
Throws an error if the param is not part of the enum.
RegValues returns all values of the enum
IsAReg returns "true" if the value is listed in the enum definition. "false" otherwise
Source Files
¶
Click to show internal directories.
Click to hide internal directories.