1 Answers
Option 3 : The stack pointer needs to be pre-decremented before writing registers in a PUSH, whereas a POP operation uses the address already in the stack pointer.
PUSH is pre decremented operation
Since it is 16 bit operation it takes 6 clock cycles for Fetch and decoding operation.
For PUSH operation:
|
T1 |
T2 |
T3 |
|
6 clock cycles |
3 clock cycles |
3 clock cycles |
|
Fetch and Decode |
Write operation |
Write operation |
Total no of clock cycles = 6+3+3= 12 clock cycles
Whereas POP is a post incremented operation and it takes only 4 clock cycles in fetch and decode operation.
For POP:
|
T1 |
T2 |
T3 |
|
4 clock cycles |
3 clock cycles |
3 clock cycles |
|
Fetch and Decode |
Write operation |
Write operation |
Total no of clock cycles = 4+3+3= 10 clock cycles
4 views
Answered