Intel 64 and IA-32 Architectures Software Developers Manual Volume 3B, System Programming Guide Part 2

Table Of Contents
Vol. 3 23-13
VM EXITS
VM exits due to attempts to execute INS or OUTS for which the relevant
segment (ES for INS; DS for OUTS unless overridden by an instruction prefix)
is usable. The field receives the value of the linear address generated by
ES:(E)DI (for INS) or segment:(E)SI (for OUTS; the default segment is DS
but can be overridden by a segment override prefix). (If the relevant
segment is not usable, the value is undefined.) On processors that support
Intel 64 architecture, bits 63:32 are cleared if the logical processor was not in
64-bit mode before the VM exit.
VM exits due to EPT violations that set bit 7 of the exit qualification (see
Table 23-7; these are all EPT violations except those resulting from an
attempt to load the PDPTEs as of execution of the MOV CR instruction). The
linear address may translate to the guest-physical address whose access
caused the EPT violation. Alternatively, translation of the linear address may
reference a paging-structure entry whose access caused the EPT violation.
For all other VM exits, the field is undefined.
Guest-physical address. For a VM exit due to an EPT violation or an EPT
misconfiguration, this field receives the guest-physical address that caused the
EPT violation or EPT misconfiguration. For all other VM exits, the field is
undefined.
23.2.2 Information for VM Exits Due to Vectored Events
Section 20.9.2 defines fields containing information for VM exits due to the following
events: exceptions (including those generated by the instructions INT3, INTO,
BOUND, and UD2); external interrupts that occur while the “acknowledge interrupt
on exit” VM-exit control is 1; and non-maskable interrupts (NMIs). Such VM exits
include those that occur on an attempt at a task switch that causes an exception
before generating the VM exit due to the task switch that causes the VM exit.
The following items detail the use of these fields:
VM-exit interruption information (format given in Table 20-14). The following
items detail how this field is established for VM exits due to these events:
For an exception, bits 7:0 receive the exception vector (at most 31). For an
NMI, bits 7:0 are set to 2. For an external interrupt, bits 7:0 receive the
interrupt number.
Bits 10:8 are set to 0 (external interrupt), 2 (non-maskable interrupt), 3
(hardware exception), or 6 (software exception). Hardware exceptions
comprise all exceptions except breakpoint exceptions (#BP; generated by
INT3) and overflow exceptions (#OF; generated by INTO); these are
software exceptions. Note that BOUND range exceeded exceptions (#BR;
generated by BOUND) and invalid opcode exceptions (#UD) generated by
UD2 are hardware exceptions.