A method for emulating software code under investigation in a computer system that includes computing hardware for an emulator (270, 370) and a hardware accelerator module, the method comprising: executing, by the computing hardware operating under a program control, a virtual execution environment in which a first portion of the software code under investigation is emulated by the emulator (270, 370); prior to executing a second portion of the software code without emulation, initializing the hardware accelerator module by loading data in registers and key memory locations from the virtual execution environment of the first portion of the software code such that the second portion of the software code can be executed without loss of context; executing, by the hardware accelerator module, the second portion of the software code without emulation until an exception occurs; determining, by the computing hardware operating under the program control, a measure of efficiency for executing the second portion of the software code without emulation by the hardware accelerator module until the exception occurs, wherein the measure of efficiency is determined by comparing a computational load of performance of the execution of the second portion of the software code with a computational load of the performance of initializing the hardware accelerator module; determining, by the computing hardware operating under the program control, suitability of executing the second portion of the software code without emulation by comparing the measure of efficiency with an efficiency threshold; and selectively invoking the hardware acceleration module for the second portion based on the determined suitability of executing the second portion of the software code. executing, by the computing hardware operating under a program control, a virtual execution environment in which a first portion of the software code under investigation is emulated by the emulator (270, 370); prior to executing a second portion of the software code without emulation, initializing the hardware accelerator module by loading data in registers and key memory locations from the virtual execution environment of the first portion of the software code such that the second portion of the software code can be executed without loss of context; executing, by the hardware accelerator module, the second portion of the software code without emulation until an exception occurs; determining, by the computing hardware operating under the program control, a measure of efficiency for executing the second portion of the software code without emulation by the hardware accelerator module until the exception occurs, wherein the measure of efficiency is determined by comparing a computational load of performance of the execution of the second portion of the software code with a computational load of the performance of initializing the hardware accelerator module; determining, by the computing hardware operating under the program control, suitability of executing the second portion of the software code without emulation by comparing the measure of efficiency with an efficiency threshold; and selectively invoking the hardware acceleration module for the second portion based on the determined suitability of executing the second portion of the software code.