System and method for profiling code on symmetric...

Data processing: software development – installation – and managem – Software program development tool – Testing or debugging

Reexamination Certificate

Rate now

  [ 0.00 ] – not rated yet Voters 0   Comments 0

Details

C709S241000

Reexamination Certificate

active

06401240

ABSTRACT:

TECHNICAL FIELD OF THE INVENTION
This invention pertains in general to computer programming and more specifically to a code profiler for collecting performance metrics about a process executing on a symmetric multiprocessor computer system.
BACKGROUND OF THE INVENTION
Modern computer systems often have multiple central processing units (“CPUs”) that can execute different, or the same, parts of a process simultaneously. Such computers are called symmetric multiprocessor (“SMP”) systems. A single process executing on such a computer can have multiple threads of control simultaneously executing on different CPUs.
When designing for or porting software to SMP systems, it is advantageous to optimize the code such that it can take full advantage of the system. For example, a programmer wants to optimize the code such that process computations are balanced among the threads. Similarly, a programmer seeks to maximize the number of CPUs that actively work during particular code regions.
To achieve these ends, a programmer uses a code “profiler” to analyze the behavior of a process and remove performance bottlenecks. Such profilers typically work by determining the number of CPUs and CPU time used by a process, along with other performance information, for particular code regions. The programmer then uses the profiler's results to revise the process' structure and operation.
For example, a programmer can use a profiler to compare the CPU time with the real-world, or wall-clock, time used to execute a process. Ideally, the concurrency ratio, the ratio of CPU time to wall-clock time, is equal to the number of CPUs available to the process. If the ratio is less than the number of CPUs, then system overhead or performance bottlenecks are slowing the process and its threads.
Some prior art profilers, however, do not provide programmers with insight into the behavior of the process on a thread-by-thread basis. For example, an extremely naive approach of determining CPU usage followed by some profilers is to use a CPU's on board timer to sample the time before and after a code region. This approach determines the amount of time the process spent on that code region. This approach, however, fails to account for the amount of work performed by threads symmetrically executing on different CPUs. That is, the profiler will report that amount of wall-clock time spent on the task, but not the CPU time used by threads executing on other processors. Therefore, the information returned by the naive approach does not enable a programmer to determine which parts of a process are truly occupying the majority of the computer system's time.
Some modern profilers attempt to measure process performance on a thread-by-thread basis. However, such profilers possess different problems. Some profilers require large amounts of data space to hold performance information for each concurrent thread. Others require extreme synchronization to ensure that they produce accurate results. Still other profilers simply do not scale well to systems with many processors. These types of profilers are discussed in more detail in connection with the detailed description of the preferred embodiment.
Therefore, there is a need in the art for a profiler that provides a programmer with a complete analysis of CPU time and other performance metrics of a multithreaded process executing on a SMP computer system. More specifically, there is a need for a profiler that accurately determines performance metrics at the process and thread levels during a single run of the profiled process.
SUMMARY OF THE INVENTION
The above and other needs are met by a profiler that accurately measures performance metrics for all threads executing a process on a SMP computer system. The profiler uses dynamic instrumentation to cause threads to sample performance metrics before and after certain code regions. In addition, the profiler uses extensions to a parallel support layer to register a parent thread with its child threads. Each thread stores the measured performance metric, or delta, in a memory cell or cells corresponding to its region and its parent region. When the process is complete, the profiler scans through the memory storage areas and sums the deltas for each particular level of code. Then, the results may be analyzed at the thread or process level. In this manner, the profiler can be adapted to work with any process executing on the computer system.
A technical advantage of the present invention is a way to profile code on symmetric multiprocessor computer systems that accounts for all performance metrics within a code region on a thread-by-thread level.
Another technical advantage of the present invention is a way to profile code that yields concurrency ratios from 0 to ‘n’ threads.
Yet another technical advantage of the present invention is that it provides a summation of performance metrics for the entire process after a single run of the process.
Yet another technical advantage of the present invention is a way to profile code that minimizes synchronization and data exchange amongst threads.
Yet another technical advantage of the present invention is a way to profile code that works with read-only timers/counters that are maintained or accessed on a thread basis and does not require synchronization amongst threads.
Yet another technical advantage of the present invention is a way to profile code that scales well with an increasing number of threads and processors.
The foregoing has outlined rather broadly the features and technical advantages of the present invention in order that the detailed description of the invention that follows may be better understood. Additional features and advantages of the invention will be described hereinafter which form the subject of the claims of the invention. It should be appreciated by those skilled in the art that the conception and the specific embodiment disclosed may be readily utilized as a basis for modifying or designing other structures for carrying out the same purposes of the present invention. It should also be realized by those skilled in the art that such equivalent constructions do not depart from the spirit and scope of the invention as set forth in the appended claims.


REFERENCES:
patent: 5265249 (1993-11-01), Kumamoto
patent: 5355487 (1994-10-01), Keller et al.
patent: 5404529 (1995-04-01), Chernikoff et al.
patent: 5465258 (1995-11-01), Adams
patent: 90311178.9 (1990-10-01), None
International Search Report, App. No. EP 96 30 8586, Mar. 6, 1997.
Hansen, Gilbert J., Charles A. Linthicum, Gary Brooks. “Experience with a Performance Analyzer for Multithreaded Applications,” Convex Computer Corporation, IEEE Supercomputing 1990 Proceedings. 124-131.
Goldberg, Aaron J. and John L. Hennessy. “Mtool: An Integrated System for Performance Debugging Shared Memory Multiprocessor Applications,” IEEE, vol. 4, No. 1. (Jan. 1993). 28-40.

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

System and method for profiling code on symmetric... does not yet have a rating. At this time, there are no reviews or comments for this patent.

If you have personal experience with System and method for profiling code on symmetric..., we encourage you to share that experience with our LandOfFree.com community. Your opinion is very important and System and method for profiling code on symmetric... will most certainly appreciate the feedback.

Rate now

     

Profile ID: LFUS-PAI-O-2934138

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