TSK3000A Instruction Set
All TSK3000A instructions are binary code compatible. Each instruction comprises a 32-bit word divided into an Opcode, which specifies the instruction type, and one or more operands, which further specify the operation of the instruction.
Instruction Format
Each of the TSK3000A's instructions is aligned on a word boundary and is 32 bits (single word) in length. There are three general instruction formats:
I-Type | – | this type of instruction includes an immediate value in the instruction word. I-type instructions include arithmetic operations such as ADDI, logical operations such as XORI, branch operations, and load and store operations. |
J-Type | – | this type of instruction is used where a 26-bit immediate field is required. J-type instructions are only used for absolute jump instructions (J and JAL). |
R-Type | – | this type of instruction specifies all arguments and results as registers. It includes a 5-bit immediate field used to specify the amount of shift for instructions such as SLL, SRA and SRL. A secondary opcode field is used to distinguish the instruction's operation when part of an instruction class. R-type instructions include arithmetic operations such as SUB, logical operations such as XOR as well as any other instructions that only use register operands. |
Any other instructions (those more complex or less frequently used) are constructed by using a combination of these three.
Figure 1 illustrates the three general formats that instructions can have.
Table 1 summarizes and describes the fields used in the encoding of instructions.
Field | Description |
---|---|
Opcode | 6-bit primary opcode |
rA | 5-bit index generally representing a 32-bit Source register |
rB | 5-bit index generally representing a 32-bit Source register |
rC | 5-bit index generally representing a 32-bit Destination register |
IMM5 | 5-bit instruction-specific immediate value – specifies amount of shift with respect to shift instructions |
IMM16 | 16-bit sign- or zero-extended immediate value used for:
|
IMM26 | 26-bit immediate value. Use as an index, it is subsequently shifted left by 2 bits to provide the low-order 28 bits of the target address for a jump instruction |
OpCode-2 | 6-bit secondary opcode used to specify the function of the instruction when part of an instruction class determined by the primary opcode field (for R-type instructions only) |
Instruction Set - Functional Groupings
Data Transfer Instructions
Arithmetic Instructions
Bitwise Logical Instructions
Move Instructions
Comparison Instructions
Shift Instructions
Jump Instructions
Relative Branch Instructions
Special Purpose Instructions
Generic Instructions
Instruction Set - Detailed Reference
The following is a list of all assembly language instructions that comprise the core of the TSK3000A instruction set – those instructions that have direct machine language equivalents. Click on a link to access detailed information about that instruction.
The following is a list of all generic instructions (pseudo instructions or macros) defined and supported by the Assembler for the TSK3000A. These instructions translate into one or more separate assembly language instructions (from the core set) in order to fulfil their task. Again, click on a link to access detailed information about that instruction.