Re: STACK IMPLEMENTATION



dk wrote:

I am trying to understand if i implement something like this in my
micro what would happen. My understanding is that i will lose the the
value of 'A'


CALL PUSH_A
.
.
.
CALL POP_A


PUSH_A : PUSH A
RET
POP_A: POP A
RET

You'll lose more than the value of A. You'll lose your job too probably. Think about what RET does, and from that guess whether you will ever get to call POP_A.

.