📄 s14_03.htm
字号:
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"><HTML><HEAD><TITLE>80386 Programmer's Reference Manual -- Section 14.3</TITLE></HEAD><BODY><B>up:</B> <A HREF="c14.htm">Chapter 14 -- 80386 Real-Address Mode</A><BR><B>prev:</B> <A HREF="s14_02.htm">14.2 Registers and Instructions</A><BR><B>next:</B> <A HREF="s14_04.htm">14.4 Entering and Leaving Real-Address Mode</A><P><HR><P><H1>14.3 Interrupt and Exception Handling</H1>Interrupts and exceptions in 80386 real-address mode work as much as theydo on an 8086. Interrupts and exceptions vector to interrupt procedures viaan interrupt table. The processor multiplies the interrupt or exceptionidentifier by four to obtain an index into the interrupt table. The entriesof the interrupt table are far pointers to the entry points of interrupt orexception handler procedures. When an interrupt occurs, the processorpushes the current values of CS:IP onto the stack, disables interrupts,clears TF (the single-step flag), then transfers control to the locationspecified in the interrupt table. An <A HREF="IRET.htm">IRET</A> instruction at the end of thehandler procedure reverses these steps before returning control to theinterrupted procedure.<P>The primary difference in the interrupt handling of the 80386 compared tothe 8086 is that the location and size of the interrupt table depend on thecontents of the IDTR (IDT register). Ordinarily, this fact is not apparentto programmers, because, after RESET, the IDTR contains a base address of 0and a limit of 3FFH, which is compatible with the 8086. However, the <A HREF="LGDT.htm">LIDT</A>instruction can be used in real-address mode to change the base and limitvalues in the IDTR . Refer to <A HREF="c09.htm">Chapter 9</A> for details on the IDTR , and the<A HREF="LGDT.htm">LIDT</A> and <A HREF="SGDT.htm">SIDT</A> instructions. If an interrupt occurs and the correspondingentry of the interrupt table is beyond the limit stored in the IDTR, theprocessor raises exception 8.<P><HR><P><B>up:</B> <A HREF="c14.htm">Chapter 14 -- 80386 Real-Address Mode</A><BR><B>prev:</B> <A HREF="s14_02.htm">14.2 Registers and Instructions</A><BR><B>next:</B> <A HREF="s14_04.htm">14.4 Entering and Leaving Real-Address Mode</A></BODY>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -