Method and apparatus for performing byte-code optimization...

Data processing: software development – installation – and managem – Software program development tool – Translation of code

Reexamination Certificate

Rate now

  [ 0.00 ] – not rated yet Voters 0   Comments 0

Details

Other Related Categories

C717S152000, C717S152000

Type

Reexamination Certificate

Status

active

Patent number

06240548

Description

ABSTRACT:

CROSS REFERENCE TO RELATED APPLICATIONS
This application is related to U.S. patent application Ser. No. 08/944,332, entitled “Inline Database for Receiver Types in Object-Oriented Systems,” U.S. patent application Ser. No. 08/944,335, entitled “Mixed Execution Stack and Exception Handling,” U.S. patent application Ser. No. 08/944,326, entitled “Method and Apparatus for Implementing Multiple Return Sites,” U.S. patent application Ser. No. 08/944,331, entitled “Site Specific Message Dispatch in Object-Oriented Systems,” U.S. patent application Ser. No. 08/944,334, entitled “Method and Apparatus for Dynamically Optimizing Byte-Coded Programs,” U.S. patent application Ser. No. 08/944,330, entitled “Method and Apparatus for Dynamically Optimizing Compiled Activations,” all filed concurrently herewith, U.S. patent application Ser. No. 08/884,856, entitled “Interpreting Functions Utilizing a Hybrid of Virtual and Native Machine Instructions,” filed Jun. 30, 1997, and U.S. patent application Ser. No. 08/885,000, entitled “Interpreter Generation and Implementation Utilizing Interpreter States and Register Caching,” filed Jun. 30, 1997, which are all incorporated herein by reference for all purposesin their entirety.
BACKGROUND OF THE INVENTION
1. Field of Invention
The present invention relates generally to methods and apparatus for optimizing the execution of software applications. More particularly, the present invention relates to methods and apparatus for performing compilations or other activities during pauses in the overall execution of a computer program to optimize the use of computer system resources.
2. Description of Relevant Art
Computer systems are often linked across a network, e.g., local area networks, intranets and internets, of computer systems such that they may share resources such as software applications. In general, software applications, or computer programs, may be delivered in different formats to different computer systems, due to the fact that each computer system requires software applications to be in a specific format. Alternatively, the computer programs may be delivered to a computer system in a machine-independent form, i.e., as byte codes, in order to enable one form of a computer program to be utilized by many different computer systems.
When computer programs are delivered in a machine-independent form, the programs may be interpreted directly, or the programs may be translated into machine-dependent code, i.e., “machine code.” Programs which are interpreted directly occupy less space in a computer system than programs which are translated into machine code. However, programs which are interpreted directly have slower execution speeds than programs which are translated into machine code, in most cases. As such, the determination of whether or not to interpret a computer program directly, in lieu of translating the computer program into machine code, is often based on the relative importance of space in relation to execution speed.
One approach to compilation is to compile methods within a program that is actively executing when they are first called for execution. This approach is frequently referred to as either dynamic or “runtime” compilation. One problem with dynamic compilation is that the compilation overhead associated with the program may become excessive. That is, when a relatively large number of methods must be compiled at about the same time, the overhead associated with the compilation of the program may be at a level that adversely affects the overall execution of the program. In general, an overuse of system resources for compilation may lead to a less efficient, slower execution of the program. In addition, the time consumed by a compiler which is compiling methods during active program execution may introduce user-visible pauses into the execution of the program. By way of example, when a user inputs a command into the program while the compilation overhead of the program is high, there may be a delay in the response to the user input. Such delays in response may be annoying to a user. Therefore, mechanisms that improve the apparent efficiency of dynamic compilation of methods in a computer program would be desirable.
SUMMARY OF THE INVENTION
To achieve the foregoing and other objects of the invention, methods and apparatus for dynamically compiling methods during idle periods in the execution of a computer program are disclosed. The described methods are particularly suitable for use in computer systems that are arranged to execute both interpreted and compiled byte codes. According to one aspect of the present invention, an idle or low overhead period in the processing of a computer program is identified. One or more methods that have been identified for compilation are then dynamically compiled during the identified idle period In some embodiments, methods to be dynamically compiled are referenced in one or more lists. The lists may be prioritized to facilitate the compilation of the highest priority methods first. In one embodiment, a pair of compilation lists are provided with a first one of the compilation lists being a database list created prior to processing the computer program while the other being an execution list created during the processing of the computer program.
In one embodiment, if an interrupt is received during the compilation of a method, the compilation is allowed to continue for a predetermined period of time. If the compilation is not completed during the predetermined period of time, then the compilation is aborted.
In some embodiments, a determination is made regarding whether a method identified for compilation has previously been compiled after a period of low activity has been identified. When it is determined that the method has not been previously compiled, the compilation is initialized. If the first method has already been compiled, a second method is selected during the period of low activity, and the compilation of the second method is initiated if the second method has not been previously compiled.
In other embodiments, a priority value is determined for each of a plurality of methods associated with the computer program. The highest priority methods are then executed first. In one such embodiment, the priority value for each method is determined by processing an invocation counter associated for each method during the period of low activity.
According to still another aspect of the present invention, a computer system for dynamically compiling byte-coded methods during a period of low activity in the processing of a computer program includes a mechanism for identifying a period of low activity. The system further includes a mechanism for identifying a method for compilation during the period of low activity. A compiler is arranged to initialize a compilation of the identified method during the period of low activity. In one embodiment, the system also includes an interrupt processor which is arranged to handle interrupt signals received during the compilation of the identified method, and an aborting mechanism which aborts the compilation of the method when necessary.
These and other advantages of the present invention will become apparent upon reading the following detailed descriptions and studying the various figures of the drawings.


REFERENCES:
patent: 4658351 (1987-04-01), Teng
patent: 5394537 (1995-02-01), Courts et al.
patent: 5586328 (1996-12-01), Caron et al.
patent: 5694603 (1997-12-01), Reiffin
patent: 5933635 (1999-08-01), Holzle et al.
patent: 5995754 (1999-11-01), Holzle et al.
patent: 5995997 (1999-11-01), Horvitz
patent: 6009517 (1999-12-01), Bak et al.
Title: Reconcilling responsiveness with performance in pure object oriented languages, au: Holzle et al, ACM, Jul., 96.

LandOfFree

Say what you really think

Search LandOfFree.com for the USA inventors and patents. Rate them and share your experience with other people.

Rating

Method and apparatus for performing byte-code optimization... does not yet have a rating. At this time, there are no reviews or comments for this patent.

If you have personal experience with Method and apparatus for performing byte-code optimization..., we encourage you to share that experience with our LandOfFree.com community. Your opinion is very important and Method and apparatus for performing byte-code optimization... will most certainly appreciate the feedback.

Rate now

     

Profile ID: LFUS-PAI-O-2513745

  Search
All data on this website is collected from public sources. Our data reflects the most accurate information available at the time of publication.