MARIE: Registers

MARIE has seven registers, each serving a unique purpose in instruction processing:

  1. Accumulator (AC): An 16-bit register used to store intermediate arithmetic and logic results.
  2. Memory Address Register (MAR): A 12-bit register that holds the address in memory where data will be read from or written to.
  3. Memory Buffer Register (MBR): A 16-bit register that holds data to be written or that as just read from memory.
  4. Program Counter (PC): A 12-bit register that contains the address of the next instruction to be executed.
  5. Instruction Register (IR): A 16-bit register that holds the current instruction being executed.
  6. Input Register (InREG): An 8-bit register used for receiving input from the user.
  7. Output Register (OutREG): An 8-bit register used for displaying output to the user.

MARIE also has a Status register (probably 8-bit long) to keep track of various flags (e.g., zero, sign, etc.) Each register plays an important role in the fetch–decode–execute cycle and enables MARIE to carry out its operations efficiently.