-
iret
鎖定
IRET(interrupt return)中斷返回,中斷服務程序的最後一條指令。
- 外文名
- interrupt return
- 縮 寫
- iret
iret指令介紹
彙編指令IRET
【指令格式】IRET
【指令功能】IRET(interrupt return)中斷返回,中斷服務程序的最後一條指令。IRET指令將推入堆棧的段地址和偏移地址彈出,使程序返回到原來發生中斷的地方。其作用是從中斷中恢復中斷前的狀態,具體作用有如下三點:
1.恢復IP(instruction pointer):IP←((SP)+1:(SP)),SP←SP+2
2.恢復CS(code segment):CS←((SP)+1:(SP)), SP←SP+2
FR←((SP)+1:(SP)),SP←SP+2
4.恢復ESP(返回權限發生變化)
5.恢復SS(返回權限發生變化)
以上操作按順序進行。
iret指令手冊原文
the IRET instruction pops the return instruction pointer, return code segment selector, and EFLAGS image from the stack to the EIP, CS, and EFLAGS registers, respectively, and then resumes execution of the interrupted program or procedure. If the return is to another privilege level, the IRET instruction also pops the stack pointer and SS from the stack, before resuming program execution.
- 詞條統計
-
- 瀏覽次數:次
- 編輯次數:14次歷史版本
- 最近更新: 阿妧云