Patent ID: 8201026

Claim:
A method comprising: partitioning a plurality of program instructions into a plurality of traces for execution by a virtual machine operating on a computing device, wherein the virtual machine has first and second modes of execution, and wherein each of the plurality of traces comprises one or more of the plurality of program instructions; compiling a first trace in the plurality of traces to native machine code for the computing device; applying the second mode of execution to the first trace; determining an error condition caused by executing the compiled first trace using the second mode of execution; associating the first trace with the error condition using a record for the first trace in a trace repository; creating a restore point for the first trace that represents a state of the virtual machine prior to completing application of the second mode of execution to the first trace; terminating the virtual machine after executing the compiled first trace past a point representing a native machine code instruction from which the virtual machine is unable to recover to the restore point; and after determining the error condition, applying the first mode of execution to the first trace to recover the virtual machine from the error condition.