How memory address register(MAR) and program counter(PC) are different from each other?
Program counter (PC) stores the address of next instruction to be fetched from memory after the execution of current instruction.
This address from PC is loaded into the address register (AR): AR<--PC
The instruction from memory location given by address register (AR) is loaded into the instruction register (IR): IR<--M[AR]
The program counter is incremented to the address of next instruction: PC<--PC+1
PC: program counter(PC) holds the address of the next instruction ,which is to be executed or decoded.
IR: instruction register(IR) holds the instruction which is currently being executed or decoded.
MAR: memory address register (MAR) holds the address of the location in memory, which contains data, that is required by the current instruction being executed. simply MAR points to the memory location that contains data required.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With