background image

25-6 Vol. 3C

VMX NON-ROOT OPERATION

VMX-preemption timer. A VM exit occurs when the timer counts down to zero. See Section 25.5.1 for details 
of operation of the VMX-preemption timer.
Debug-trap exceptions and higher priority events take priority over VM exits caused by the VMX-preemption 
timer. VM exits caused by the VMX-preemption timer take priority over VM exits caused by the “NMI-window 
exiting” VM-execution control and lower priority events. 
These VM exits wake a logical processor from the same inactive states as would a non-maskable interrupt. 
Specifically, they wake a logical processor from the shutdown state and from the states entered using the HLT 
and MWAIT instructions. These VM exits do not occur if the logical processor is in the wait-for-SIPI state.

In addition, there are controls that cause VM exits based on the readiness of guest software to receive interrupts:

If the “interrupt-window exiting” VM-execution control is 1, a VM exit occurs before execution of any instruction 
if RFLAGS.IF = 1 and there is no blocking of events by STI or by MOV SS (see Table 24-3). Such a VM exit 
occurs immediately after VM entry if the above conditions are true (see Section 26.6.5).
Non-maskable interrupts (NMIs) and higher priority events take priority over VM exits caused by this control. 
VM exits caused by this control take priority over external interrupts and lower priority events. 
These VM exits wake a logical processor from the same inactive states as would an external interrupt. Specifi-
cally, they wake a logical processor from the states entered using the HLT and MWAIT instructions. These 
VM exits do not occur if the logical processor is in the shutdown state or the wait-for-SIPI state.

If the “NMI-window exiting” VM-execution control is 1, a VM exit occurs before execution of any instruction if 
there is no virtual-NMI blocking and there is no blocking of events by MOV SS (see Table 24-3). (A logical 
processor may also prevent such a VM exit if there is blocking of events by STI.) Such a VM exit occurs 
immediately after VM entry if the above conditions are true (see Section 26.6.6).
VM exits caused by the VMX-preemption timer and higher priority events take priority over VM exits caused by 
this control. VM exits caused by this control take priority over non-maskable interrupts (NMIs) and lower 
priority events. 
These VM exits wake a logical processor from the same inactive states as would an NMI. Specifically, they wake 
a logical processor from the shutdown state and from the states entered using the HLT and MWAIT instructions. 
These VM exits do not occur if the logical processor is in the wait-for-SIPI state.

25.3 

CHANGES TO INSTRUCTION BEHAVIOR IN VMX NON-ROOT OPERATION

The behavior of some instructions is changed in VMX non-root operation. Some of these changes are determined 
by the settings of certain VM-execution control fields. The following items detail such changes:

1

CLTS. Behavior of the CLTS instruction is determined by the bits in position 3 (corresponding to CR0.TS) in the 
CR0 guest/host mask and the CR0 read shadow:
— If bit 3 in the CR0 guest/host mask is 0, CLTS clears CR0.TS normally (the value of bit 3 in the CR0 read 

shadow is irrelevant in this case), unless CR0.TS is fixed to 1 in VMX operation (see Section 23.8), in which 
case CLTS causes a general-protection exception.

— If bit 3 in the CR0 guest/host mask is 1 and bit 3 in the CR0 read shadow is 0, CLTS completes but does not 

change the contents of CR0.TS.

— If the bits in position 3 in the CR0 guest/host mask and the CR0 read shadow are both 1, CLTS causes a 

VM exit.

INVPCID. Behavior of the INVPCID instruction is determined first by the setting of the “enable INVPCID” 
VM-execution control:
— If the “enable INVPCID” VM-execution control is 0, INVPCID causes an invalid-opcode exception (#UD). 

This exception takes priority over any other exception the instruction may incur.

1. Under the dual-monitor treatment of SMIs and SMM, SMIs also cause SMM VM exits if they occur in VMX root operation outside SMM. 

If the processor is using the default treatment of SMIs and SMM, SMIs are delivered as described in Section 34.14.1.

1. Some of the items in this section refer to secondary processor-based VM-execution controls. If bit 31 of the primary processor-

based VM-execution controls is 0, VMX non-root operation functions as if these controls were all 0. See Section 24.6.2.