N
N
Narsn2019-05-18 12:53:29
assembler
Narsn, 2019-05-18 12:53:29

What happens when the PUSH AX and POP DX stack commands are executed?

Please explain in detail the situation in memory before and after the execution of the PUSH AX and POP DX stack commands, and what happens to the registers involved in this.
For example, there are initial data: SP=0010h, DS=0011h, DI=0022h, AX=0033h, BX=0044h, DX=0055h, SI=0066h (numbers are taken for beauty). What moves and where with PUSH AX and POP DX?
In theory, with PUSH AX, the value of SP is reduced by 2, and with POP DX, the value of SP is increased by 2, but what happens to the rest of the registers where the received SP value is written?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Rsa97, 2019-05-18
@Narsn

what happens to the rest of the registers
With PUSH AX - nothing, with POP DX - the value from the stack will be placed in DX.
where the received SP value is written
Back to SP.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question