Instruction Format: Single Accumulator Organization
Instruction Format: Single Accumulator Organization
The instruction format is depicted in a rectangular box, symbolizing the instruction bits in
memory words or a control register. The bits grouped are divided into three parts:
1. Addressing Mode: The addressing mode indicates how the data is represented.
2. Opcode: The opcode part indicates the operation type on the data.
3. Operand: The operand part indicates either the data or the address of the data.
Stack Organization
A computer with a stack organization has PUSH and POP instructions that require an address
field. Hence, the instruction PUSH X pushes the word at address X to the top of the stack. The
stack pointer updates automatically. In stack-organized computers, the operation type
instructions don’t require an address field as the operation is performed on the two items on
the top of the stack.
The MOV instruction transfers the operands to the memory from the processor registers. R1,
R2 registers.
LOAD A AC ← M *A+
ADD B AC ← A *C+ + M *B+
STORE T M *T+ ← AC
LOAD C AC ← M *C+
ADD D AC ← AC + M *D+
MUL T AC ← AC ∗ M [T]
STORE X M *X+ ← AC
All operations are done between the accumulator(AC) register and a memory operand.
M[ ] is any memory location.
M[T] addresses a temporary memory location for storing the intermediate result.
This instruction format has only one operand field. This address field uses two special
instructions to perform data transfer, namely:
LOAD: This is used to transfer the data to the accumulator.
STORE: This is used to move the data from the accumulator to the memory.
Example: Consider the below operations, which shows how X = (A + B) ∗ (C + D) expression will
be written for a stack-organized computer.