Index: /trunk/src/VBox/VMM/HWACCM.cpp
===================================================================
--- /trunk/src/VBox/VMM/HWACCM.cpp	(revision 15865)
+++ /trunk/src/VBox/VMM/HWACCM.cpp	(revision 15866)
@@ -282,15 +282,13 @@
         AssertRC(rc);
 
-# define HWACCM_REG_COUNTER(a, b) \
-        rc = STAMR3RegisterF(pVM, a, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS, STAMUNIT_OCCURENCES, "Profiling of vmlaunch", b, i); \
-        AssertRC(rc);
-
 # if HC_ARCH_BITS == 32 && defined(VBOX_ENABLE_64_BITS_GUESTS) && !defined(VBOX_WITH_HYBRID_32BIT_KERNEL)
         rc = STAMR3RegisterF(pVM, &pVCpu->hwaccm.s.StatWorldSwitch3264, STAMTYPE_PROFILE, STAMVISIBILITY_USED, STAMUNIT_TICKS_PER_CALL, "Profiling of the 32/64 switcher",
                              "/PROF/HWACCM/CPU%d/Switcher3264", i);
         AssertRC(rc);
-        HWACCM_REG_COUNTER(&pVCpu->hwaccm.s.StatTimeoutResume,           "/HWACCM/CPU%d/Timeout/Resume");
-        HWACCM_REG_COUNTER(&pVCpu->hwaccm.s.StatTimeoutSwitcher3264,     "/HWACCM/CPU%d/Timeout/Switch3264");
 # endif
+
+# define HWACCM_REG_COUNTER(a, b) \
+        rc = STAMR3RegisterF(pVM, a, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS, STAMUNIT_OCCURENCES, "Profiling of vmlaunch", b, i); \
+        AssertRC(rc);
 
         HWACCM_REG_COUNTER(&pVCpu->hwaccm.s.StatExitShadowNM,           "/HWACCM/CPU%d/Exit/Trap/Shw/#NM");
Index: /trunk/src/VBox/VMM/HWACCMInternal.h
===================================================================
--- /trunk/src/VBox/VMM/HWACCMInternal.h	(revision 15865)
+++ /trunk/src/VBox/VMM/HWACCMInternal.h	(revision 15866)
@@ -440,7 +440,4 @@
 typedef struct HWACCMCPU
 {
-    /** Time of entry into the ring 0 world switcher code. */
-    uint64_t                    u64TimeEntry;
-
     /** Old style FPU reporting trap mask override performed (optimization) */
     bool                        fFPUOldStyleOverride;
@@ -616,6 +613,4 @@
     STAMCOUNTER             StatDRxIOCheck;
 
-    STAMCOUNTER             StatTimeoutSwitcher3264;
-    STAMCOUNTER             StatTimeoutResume;
 
     R3PTRTYPE(PSTAMCOUNTER) paStatExitReason;
Index: /trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp
===================================================================
--- /trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp	(revision 15865)
+++ /trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp	(revision 15866)
@@ -39,5 +39,4 @@
 #include <iprt/asm.h>
 #include <iprt/string.h>
-#include <iprt/time.h>
 #include "HWVMXR0.h"
 
@@ -1894,5 +1893,4 @@
     RTGCUINTPTR errCode, instrInfo;
     bool        fSyncTPR = false;
-    bool        fPreemptPending = false;
     PHWACCM_CPUINFO pCpu = 0;
     unsigned    cResume = 0;
@@ -1968,7 +1966,4 @@
     }
 #endif
-
-    /* Fetch the current time so we can bail out when necessary. */
-    pVCpu->hwaccm.s.u64TimeEntry = RTTimeNanoTS();
 
     /* We can jump to this point to resume execution after determining that a VM-exit is innocent.
@@ -1985,9 +1980,6 @@
 
     /* Safety precaution; looping for too long here can have a very bad effect on the host */
-    if (    ++cResume > HWACCM_MAX_RESUME_LOOPS
-        ||  RTTimeNanoTS() - pVCpu->hwaccm.s.u64TimeEntry >= 2000000)
-    {
-        LogFlow(("delta %VX64\n", RTTimeNanoTS() - pVCpu->hwaccm.s.u64TimeEntry));
-        STAM_COUNTER_INC(&pVCpu->hwaccm.s.StatTimeoutResume);
+    if (++cResume > HWACCM_MAX_RESUME_LOOPS)
+    {
         STAM_COUNTER_INC(&pVCpu->hwaccm.s.StatExitMaxResume);
         rc = VINF_EM_RAW_INTERRUPT;
@@ -2165,11 +2157,9 @@
     STAM_PROFILE_ADV_START(&pVCpu->hwaccm.s.StatExit1, v);
 
-    if (VBOX_FAILURE(rc))
+    if (rc != VINF_SUCCESS)
     {
         VMXR0ReportWorldSwitchError(pVM, pVCpu, rc, pCtx);
         goto end;
     }
-    if (rc == VINF_VMX_PREEMPT_PENDING)
-        fPreemptPending = true;
 
     /* Success. Query the guest state and figure out what has happened. */
@@ -2247,11 +2237,4 @@
     {
         rc = PDMApicSetTPR(pVM, pVM->hwaccm.s.vmx.pAPIC[0x80] >> 4);
-        AssertRC(rc);
-    }
-
-    if (fPreemptPending)
-    {
-        fPreemptPending = false;
-        rc = VMMR0CallHost(pVM, VMMCALLHOST_VM_R0_PREEMPT, 0);
         AssertRC(rc);
     }
@@ -3608,13 +3591,4 @@
     Assert(!(pCache->TestOut.eflags & X86_EFL_IF));
 #endif
-
-    /* Check if we've been running too long. */
-    if (    rc == VINF_SUCCESS
-        &&  RTTimeNanoTS() - pVCpu->hwaccm.s.u64TimeEntry >= 2000000)
-    {
-        STAM_COUNTER_INC(&pVCpu->hwaccm.s.StatTimeoutSwitcher3264);
-        LogFlow(("delta (2) %VX64\n", RTTimeNanoTS() - pVCpu->hwaccm.s.u64TimeEntry));
-        return VINF_VMX_PREEMPT_PENDING;
-    }
     return rc;
 }
