13.07.2015 Views

Volume 3: General-Purpose and System Instructions - Stanford ...

Volume 3: General-Purpose and System Instructions - Stanford ...

Volume 3: General-Purpose and System Instructions - Stanford ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

AMD64 Technology 24594 Rev. 3.10 February 2005INTInterrupt to VectorTransfers execution to the interrupt h<strong>and</strong>ler specified by an 8-bit unsigned immediatevalue. This value is an interrupt vector number (00h to FFh), which the processor usesas an index into the interrupt-descriptor table (IDT).For detailed descriptions of the steps performed by INTn instructions, see thefollowing:• Legacy-Mode Interrupts: “Legacy Protected-Mode Interrupt Control Transfers” in<strong>Volume</strong> 2.• Long-Mode Interrupts: “Long-Mode Interrupt Control Transfers” in <strong>Volume</strong> 2.See also the descriptions of the INT3 instruction on page 304 <strong>and</strong> the INTOinstruction on page 164.Mnemonic Opcode DescriptionINT imm8 CD ib Call interrupt service routine specified by interrupt vector imm8.Action// See “Pseudocode Definitions” on page 49.INT_N_START:IF (REAL_MODE)INT_N_REALELSIF (PROTECTED_MODE)INT_N_PROTECTEDELSE // (VIRTUAL_MODE)INT_N_VIRTUALINT_N_REAL:temp_int_n_vector = byte-sized interrupt vector specified in the instruction,zero-extended to 64 bitstemp_RIP = READ_MEM.w [idt:temp_int_n_vector*4]// read target CS:RIP from the real-mode idttemp_CS = READ_MEM.w [idt:temp_int_n_vector*4+2]PUSH.w old_RFLAGSPUSH.w old_CSPUSH.w next_RIP156 INT

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!