Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Лаб2012 / 25366517.pdf
Скачиваний:
80
Добавлен:
02.02.2015
Размер:
3.33 Mб
Скачать

PROCEDURE CALLS, INTERRUPTS, AND EXCEPTIONS

6.5.2LEAVE Instruction

The LEAVE instruction, which does not have any operands, reverses the action of the previous ENTER instruction. The LEAVE instruction copies the contents of the EBP register into the ESP register to release all stack space allocated to the procedure. Then it restores the old value of the EBP register from the stack. This simultaneously restores the ESP register to its original value. A subsequent RET instruction then can remove any arguments and the return address pushed on the stack by the calling program for use by the procedure.

6-26 Vol. 1

7

Programming With

General-Purpose

Instructions

Соседние файлы в папке Лаб2012