24531904_j
24531904_j 24531904_j
INT n/INTO/INT 3—Call to Interrupt Procedure ( 続き ) IF 32-bit gate THEN CS:EIP ← Gate(CS:EIP); (* segment descriptor information also loaded *) ELSE (* 16-bit gate *) CS:IP ← Gate(CS:IP); (* segment descriptor information also loaded *) FI; IF 32-bit gate THEN Push(far pointer to old stack); (* old SS and ESP, 3 words padded to 4 *); Push(EFLAGS); Push(far pointer to return instruction); (* old CS and EIP, 3 words padded to 4*); Push(ErrorCode); (* if needed, 4 bytes *) ELSE(* 16-bit gate *) Push(far pointer to old stack); (* old SS and SP, 2 words *); Push(EFLAGS); Push(far pointer to return instruction); (* old CS and IP, 2 words *); Push(ErrorCode); (* if needed, 2 bytes *) FI; CPL ← CodeSegmentDescriptor(DPL); CS(RPL) ← CPL; IF interrupt gate THEN IF ← 0 (* interrupt flag to 0 (disabled) *); FI; TF ← 0; VM ← 0; RF ← 0; NT ← 0; I END; INTERRUPT-FROM-VIRTUAL-8086-MODE: (* Check segment selector and descriptor for privilege level 0 stack in current TSS *) IF current TSS is 32-bit TSS THEN TSSstackAddress ← new code segment (DPL ∗ 8) + 4 IF (TSSstackAddress + 7) > TSS limit THEN #TS(current TSS selector); FI; NewSS ← TSSstackAddress + 4; NewESP ← stack address; ELSE (* TSS is 16-bit *) TSSstackAddress ← new code segment (DPL ∗ 4) + 2 IF (TSSstackAddress + 4) > TSS limit THEN #TS(current TSS selector); FI; NewESP ← TSSstackAddress; NewSS ← TSSstackAddress + 2; FI; IF segment selector is null THEN #TS(EXT); FI; IF segment selector index is not within its descriptor table limits OR segment selector's RPL ≠ DPL of code segment, THEN #TS(SS selector + EXT); FI; Access segment descriptor for stack segment in GDT or LDT; IF stack segment DPL ≠ DPL of code segment, OR stack segment does not indicate writable data segment, THEN #TS(SS selector + EXT); FI; IF stack segment not present THEN #SS(SS selector+EXT); FI; 3:590 第 3 巻 : IA-32 基本命令リファレンス
INT n/INTO/INT 3—Call to Interrupt Procedure ( 続き ) IF 32-bit gate THEN IF new stack does not have room for 40 bytes (error code pushed) OR 36 bytes (no error code pushed); THEN #SS(segment selector + EXT); FI; ELSE (* 16-bit gate *) IF new stack does not have room for 20 bytes (error code pushed) OR 18 bytes (no error code pushed); THEN #SS(segment selector + EXT); FI; FI; IF instruction pointer is not within code segment limits THEN #GP(0); FI; IF CR4.VME = 0 THEN IF IOPL=3 THEN IF Gate DPL = 3 THEN (*CPL=3, VM=1, IOPL=3, VME=0, gate DPL=3) IF Target CPL != 0 THEN #GP(0); ELSE Goto VM86_INTERURPT_TO_PRIV0; FI; ELSE (*Gate DPL < 3*) #GP(0); FI; ELSE (*IOPL < 3*) #GP(0); FI; ELSE (*VME = 1*) (*Check whether interrupt is directed for INT n instruction only, (*executes virtual 8086 interupt, protected mode interrupt or faults*) Ptr
- Seite 552 und 553: FST/FSTP—Store Real ( 続き ) #A
- Seite 554 und 555: FSTCW/FNSTCW—Store Control Word (
- Seite 556 und 557: FSTENV/FNSTENV—Store FPU Environm
- Seite 558 und 559: FSTSW/FNSTSW—Store Status Word (
- Seite 560 und 561: FSUB/FSUBP/FISUB—Subtract ( 続
- Seite 562 und 563: FSUBR/FSUBRP/FISUBR—Reverse Subtr
- Seite 564 und 565: FSUBR/FSUBRP/FISUBR—Reverse Subtr
- Seite 566 und 567: FTST—TEST オペコード 命令
- Seite 568 und 569: FUCOM/FUCOMP/FUCOMPP—Unordered Co
- Seite 570 und 571: FWAIT—Wait 本章の 「WAIT」
- Seite 572 und 573: FXAM—Examine ( 続き ) 実アド
- Seite 574 und 575: FXCH—Exchange Register Contents (
- Seite 576 und 577: FXTRACT—Extract Exponent and Sign
- Seite 578 und 579: FYL2X—Compute y ∗ log 2 x ( 続
- Seite 580 und 581: FYL2XP1—Compute y ∗ log 2 (x +1
- Seite 582 und 583: IDIV—Signed Divide オペコー
- Seite 584 und 585: IDIV—Signed Divide ( 続き ) 実
- Seite 586 und 587: IMUL—Signed Multiply ( 続き ) 2
- Seite 588 und 589: IMUL—Signed Multiply ( 続き )
- Seite 590 und 591: IN—Input from Port ( 続き ) 操
- Seite 592 und 593: INC—Increment by 1 オペコー
- Seite 594 und 595: INS/INSB/INSW/INSD—Input from Por
- Seite 596 und 597: INS/INSB/INSW/INSD—Input from Por
- Seite 598 und 599: INT n/INTO/INT 3—Call to Interrup
- Seite 600 und 601: INT n/INTO/INT 3—Call to Interrup
- Seite 604 und 605: INT n/INTO/INT 3—Call to Interrup
- Seite 606 und 607: INT n/INTO/INT 3—Call to Interrup
- Seite 608 und 609: INT n/INTO/INT 3—Call to Interrup
- Seite 610 und 611: INVD—Invalidate Internal Caches (
- Seite 612 und 613: IRET/IRETD—Interrupt Return オ
- Seite 614 und 615: IRET/IRETD—Interrupt Return ( 続
- Seite 616 und 617: IRET/IRETD—Interrupt Return ( 続
- Seite 618 und 619: IRET/IRETD—Interrupt Return ( 続
- Seite 620 und 621: Jcc—Jump if Condition Is Met オ
- Seite 622 und 623: Jcc—Jump if Condition Is Met (
- Seite 624 und 625: JMP—Jump オペコード 命令
- Seite 626 und 627: JMP—Jump ( 続き ) 操作 IF nea
- Seite 628 und 629: JMP—Jump ( 続き ) END; TASK-GAT
- Seite 630 und 631: JMP—Jump ( 続き ) #PF ( フォ
- Seite 632 und 633: JMPE—Jump to Intel ® Itanium ®
- Seite 634 und 635: LAR—Load Access Rights Byte オ
- Seite 636 und 637: LAR—Load Access Rights Byte ( 続
- Seite 638 und 639: LDS/LES/LFS/LGS/LSS—Load Far Poin
- Seite 640 und 641: LEA—Load Effective Address オペ
- Seite 642 und 643: LEAVE—High Level Procedure Exit
- Seite 644 und 645: LES—Load Full Pointer 「LDS/LES/
- Seite 646 und 647: LGDT/LIDT—Load Global/Interrupt D
- Seite 648 und 649: LGS—Load Full Pointer 「LDS/LES/
- Seite 650 und 651: LLDT—Load Local Descriptor Table
INT n/INTO/INT 3—Call to Interrupt Procedure ( 続き )<br />
IF 32-bit gate<br />
THEN<br />
IF new stack does not have room for 40 bytes (error code pushed)<br />
OR 36 bytes (no error code pushed);<br />
THEN #SS(segment selector + EXT);<br />
FI;<br />
ELSE (* 16-bit gate *)<br />
IF new stack does not have room for 20 bytes (error code pushed)<br />
OR 18 bytes (no error code pushed);<br />
THEN #SS(segment selector + EXT);<br />
FI;<br />
FI;<br />
IF instruction pointer is not within code segment limits THEN #GP(0); FI;<br />
IF CR4.VME = 0<br />
THEN<br />
IF IOPL=3<br />
THEN<br />
IF Gate DPL = 3<br />
THEN (*CPL=3, VM=1, IOPL=3, VME=0, gate DPL=3)<br />
IF Target CPL != 0<br />
THEN #GP(0);<br />
ELSE Goto VM86_INTERURPT_TO_PRIV0;<br />
FI;<br />
ELSE (*Gate DPL < 3*)<br />
#GP(0);<br />
FI;<br />
ELSE (*IOPL < 3*)<br />
#GP(0);<br />
FI;<br />
ELSE (*VME = 1*)<br />
(*Check whether interrupt is directed for INT n instruction only,<br />
(*executes virtual 8086 interupt, protected mode interrupt or faults*)<br />
Ptr