Data processing: software development – installation – and managem – Software program development tool – Translation of code
Reexamination Certificate
1999-10-07
2004-05-04
Ingberg, Todd (Department: 2124)
Data processing: software development, installation, and managem
Software program development tool
Translation of code
Reexamination Certificate
active
06732357
ABSTRACT:
BACKGROUND OF THE INVENTION
1. Technical Field
The present invention relates to an improved data processing system and, in particular, to a method and apparatus for optimizing performance in a data processing system. Still more particularly, the present invention provides a method and apparatus for a software program development tool for enhancing performance of a software program through software profiling.
2. Description of Related Art
In analyzing and enhancing performance of a data processing system and the applications executing within the data processing system, it is helpful to know which software modules within a data processing system are using system resources. Effective management and enhancement of data processing systems requires knowing how and when various system resources are being used. Performance tools are used to monitor and examine a data processing system to determine resource consumption as various software applications are executing within the data processing system. For example, a performance tool may identify the most frequently executed modules and instructions in a data processing system, or may identify those modules which allocate the largest amount of memory or perform the most I/O requests. Hardware performance tools may be built into the system or added at a later point in time. Software performance tools also are useful in data processing systems, such as personal computer systems, which typically do not contain many, if any, built-in hardware performance tools.
One known software performance tool is a trace tool. A trace tool may use more than one technique to provide trace information that indicates execution flows for an executing program. One technique keeps track of particular sequences of instructions by logging certain events as they occur, so-called event-based profiling technique. For example, a trace tool may log every entry into, and every exit from, a module, subroutine, method, function, or system component. Alternately, a trace tool may log the requester and the amounts of memory allocated for each memory allocation request. Typically, a time-stamped record is produced for each such event. Corresponding pairs of records similar to entry-exit records also are used to trace execution of arbitrary code segments, starting and completing I/O or data transmission, and for many other events of interest.
In order to improve performance of code generated by various families of computers, it is often necessary to determine where time is being spent by the processor in executing code, such efforts being commonly known in the computer processing arts as locating “hot spots.” Ideally, one would like to isolate such hot spots at the instruction and/or source line of code level in order to focus attention on areas which might benefit most from improvements to the code.
Another trace technique involves program sampling to identify certain locations in programs in which the programs appear to spend large amounts of time. This technique is based on the idea of interrupting the application or data processing system execution at regular intervals, so-called sample-based profiling. At each interruption, the program counter of the currently executing thread, a process that is part of a larger process or program, is recorded. Typically, these tools capture values that are resolved against a load map and symbol table information for the data processing system at post-processing time, and a profile of where the time is being spent is obtained from this analysis.
For example, isolating such hot spots down to the instruction level permits compiler writers to find significant areas of suboptimal code generation, at which they may focus their efforts to improve code generation efficiency. Another potential use of instruction level detail is to provide guidance to the designer of future systems. Such designers employ profiling tools to find characteristic code sequences and/or single instructions that require optimization for the available software for a given type of hardware.
There are often costs associated with measuring a system in that the measurement itself perturbs the system. This effect is well understood in the study of elementary particle physics and is known as the Heisenberg uncertainty principle. With software tracing, the cost associated with the tracing can severely affect the system being profiled. The effect can range from disruption of the cache and the instruction pipeline to more mundane effects such as the overhead associated with the tracing.
Although the writing of a single trace record may require a relatively short amount of time, the profiling process may cause the writing of thousands of trace records. The total amount of time spent outputting the trace records may then grow to a significant percentage of the time that may be attributed to particular routines. If such output overhead time is not determined and the execution times of the routines are not compensated for this overhead time, then the profile of the execution of the program may contain significant distortion as to the time spent within various routines. If the overhead time is significant, as compared to the time spent within the routine being measured, a significant distortion in the results would be realized if not compensated.
Therefore, it would be particularly advantageous to provide a method and system for determining the amount of output overhead incurred during the profiling of a program and for compensating for the overhead.
SUMMARY OF THE INVENTION
A method and system for compensating for trace overhead is provided by analyzing and compensating for the temporal overhead associated with generating or outputting trace information to a trace buffer or a trace file in the form of trace records. A trace record generally represents an occurrence of a profiling event attributable to a particular routine within a profiled program. A program is profiled with enablement of trace record generation during a first period of time and with disablement of trace record generation during a second period of time. The number of trace records output during the first period of time is determined, and a trace overhead calibration value is computed as an average time for writing the number of trace records output during the first period of time. The trace overhead calibration value may be stored for subsequent use in a profiling-related process in the data processing system. The trace overhead compensation value represents the amount of time required to generate a trace record, and the trace times retrieved from the trace records are adjusted to compensate for the amount of time required to generate those trace records.
REFERENCES:
patent: 4520441 (1985-05-01), Bandoh et al.
patent: 4558413 (1985-12-01), Schmidt et al.
patent: 4703417 (1987-10-01), Morganti et al.
patent: 4841439 (1989-06-01), Nishikawa et al.
patent: 4866599 (1989-09-01), Morganti et al.
patent: 4868738 (1989-09-01), Kish et al.
patent: 5003458 (1991-03-01), Yamaguchi et al.
patent: 5047919 (1991-09-01), Sterling et al.
patent: 5295230 (1994-03-01), Kung
patent: 5321834 (1994-06-01), Weiser et al.
patent: 5355487 (1994-10-01), Keller et al.
patent: 5465258 (1995-11-01), Adams
patent: 5481712 (1996-01-01), Silver et al.
patent: 5485616 (1996-01-01), Burke et al.
patent: 5493689 (1996-02-01), Waclawsky et al.
patent: 5506955 (1996-04-01), Chen et al.
patent: 5539907 (1996-07-01), Srivastava et al.
patent: 5553235 (1996-09-01), Chen et al.
patent: 5611061 (1997-03-01), Yasuda
patent: 5613118 (1997-03-01), Heisch et al.
patent: 5649085 (1997-07-01), Lehr
patent: 5689712 (1997-11-01), Heisch
patent: 5732273 (1998-03-01), Srivastava et al.
patent: 5737609 (1998-04-01), Reed et al.
patent: 5748878 (1998-05-01), Rees et al.
patent: 5761477 (1998-06-01), Wahbe et al.
patent: 5764944 (1998-06-01), Hwang et al.
patent: 5768500 (1998-06-01), Agrawal et al.
patent: 5940618 (1999-08-01), Blandy et al.
patent: 5940871 (1999-08-01), Goyal et al.
patent: 5948112 (1999-09-01), Shimada et al.
patent: 5966537 (1999-10-01), Ravicha
Berry Robert Francis
Gordon Jesse Mannes
Hussain Riaz Y.
Levine Frank Eliot
Urquhart Robert J.
Ingberg Todd
International Business Machines - Corporation
Leeuwen Leslie A. Van
Nichols Michael R.
Yee Duke W.
LandOfFree
Determining and compensating for temporal overhead in trace... does not yet have a rating. At this time, there are no reviews or comments for this patent.
If you have personal experience with Determining and compensating for temporal overhead in trace..., we encourage you to share that experience with our LandOfFree.com community. Your opinion is very important and Determining and compensating for temporal overhead in trace... will most certainly appreciate the feedback.
Profile ID: LFUS-PAI-O-3254424