Method to optimize execution of a program on a host computer, using resources of a remote optimization server
Original Publication Date: 2007-Feb-09
Included in the Prior Art Database: 2007-Feb-09
AbstractA method is disclosed for optimizing the execution of a program through recompilation, either once or continuously, on a computer that does not have the ability or the resources to recompile the program. The method consists of collecting runtime information during execution of the program, forwarding the data collected to another computer capable of recompiling the program, generating a new executable tailored to the computer where the runtime data was collected, and returning from the remote computer a new version of the program to replace the existing one.
Method to optimize execution of a program on a host computer , using resources of a remote optimization server
Programs are typically distributed in an executable (binary) form, wherein the program is ready to be sent directly to the hardware of a computer for execution. While it is possible to write a program in the executable form, the tediousness of such a task is avoided by writing the program in a high-level language and employing a compiler to convert the statements of the high-level language into the executable form. Thus, a compiler should be familiar with the instruction set architecture that is executed directly by the machine, so that it can produce the appropriate executable code.
In addition to translating a program from a high-level language to an executable form, a compiler also performs some optimizations on the executable in order to make the program execute faster. There are many forms of optimizations which can be performed on a program; some of the more important optimizations exploit knowledge of how the hardware of the computer itself, commonly referred to as the microarchitecture of the computer, is organized. When the microarchitecture of the computer is used for optimizing a program, the resulting executable works best on any computer that has the same microarchitecture. It will function correctly on any other computer that supports the same instruction set architecture, even if it has a different microarchitecture, but may not work as well as another executable which has been specifically optimized for the particular microarchitecture.
Additionally, the executable produced by a compiler is frequently optimized for the conditions of
execution assumed by the compiler, especially in regard to the nature of the input data presented
to the program. Changes in the organization or the characteristics of the data could render the
executable to be sub-optimal. Profile-driven feedback is a technique that allows monitoring the
execution behavior of the program, collecting a profile of such execution, and feeding the profile
back to the compiler. The compiler re-optimizes the program for the conditions observed during
profiling. This approach is generally used before an executable is shipped to end-users, because
end-users generally do not have the capability to recompile the code at their site. Consequently,
it is not possible to profile the program on the actual end-user environment and optimize the program according to such profile.
There is a need, therefore, for a solution that allows a program to operate efficiently on any computer and under any input conditions, without burdening the resources of computer where the program is executing.
Description of the Invention
In the method disclosed here, a program is distributed as an executable for a given instruction set architecture. The executable is enhanced with mechanisms that collect information about the behav...