Code instrumentation system with non intrusive means and cache memory optimization for dynamic monitoring of code segments
First Claim
1. A method for dynamically monitoring performance of a code segment executing in an information handling system, said method comprising the steps of:
- (a) collecting data regarding the code segment to be monitored;
(b) selecting a final memory placement for one or more instrumentation code segments and one or more instrumentation data segments, wherein the final memory placement includes one or more memory areas in which to place the instrumentation code segments and the instrumentation data segments, and wherein said selecting step includes the steps of;
(c) choosing a possible memory placement for the instrumentation code segments and the instrumentation data segments;
(d) determining an effect of one or more external factors based on the possible memory placement;
(e) if the effect is below a predetermined acceptable level, then setting the final memory placement to the possible memory segment;
(f) if the effect is not below the predetermined acceptable level, then determining if there are one or more additional possible memory placements;
(g) if there are additional possible memory placements, then repeating steps (c) through (g) until the effect is below the predetermined acceptable level;
(h) if there are not additional possible memory placements, then performing the following steps;
(i) placing the instrumentation code segments and the instrumentation data segments into one of the possible memory placements determined in step (c);
(j) executing the code segment to be monitored;
(k) calculating an execution time;
(l) repeating steps (i) through (k) for each possible memory placement;
(m) setting the final memory placement equal to the possible memory segment which results in a lowest execution time; and
(n) executing the code segment to be monitored, along with one or more of the instrumentation code segments.
1 Assignment
0 Petitions
Accused Products
Abstract
The present invention is directed to a system and method for monitoring performance in an information handling system in a minimally intrusive manner. The method of the present invention includes a collection phase, a placement phase, and an instrumentation phase. During the collection phase, a workload (i.e. code segment) is traced, and instruction and data accesses are determined. During the placement phase, the trace data is passed to a cache simulator. The cache simulator uses the trace data, along with hardware and instrumentation characteristics, to determine an optimal placement for instrumentation code and data. If the desired conflict level is not attainable, the best possible placement is found by executing the code to be monitored with a variety of instrumentation code and data placements until the least intrusive placement is found. The best possible placement is then used during the instrumentation phase to actually execute the instrumented code.
-
Citations
12 Claims
-
1. A method for dynamically monitoring performance of a code segment executing in an information handling system, said method comprising the steps of:
-
(a) collecting data regarding the code segment to be monitored; (b) selecting a final memory placement for one or more instrumentation code segments and one or more instrumentation data segments, wherein the final memory placement includes one or more memory areas in which to place the instrumentation code segments and the instrumentation data segments, and wherein said selecting step includes the steps of; (c) choosing a possible memory placement for the instrumentation code segments and the instrumentation data segments; (d) determining an effect of one or more external factors based on the possible memory placement; (e) if the effect is below a predetermined acceptable level, then setting the final memory placement to the possible memory segment; (f) if the effect is not below the predetermined acceptable level, then determining if there are one or more additional possible memory placements; (g) if there are additional possible memory placements, then repeating steps (c) through (g) until the effect is below the predetermined acceptable level; (h) if there are not additional possible memory placements, then performing the following steps; (i) placing the instrumentation code segments and the instrumentation data segments into one of the possible memory placements determined in step (c); (j) executing the code segment to be monitored; (k) calculating an execution time; (l) repeating steps (i) through (k) for each possible memory placement; (m) setting the final memory placement equal to the possible memory segment which results in a lowest execution time; and (n) executing the code segment to be monitored, along with one or more of the instrumentation code segments. - View Dependent Claims (2, 3, 4)
-
-
5. An information handling system, comprising:
-
one or more processors, each processor containing a cache memory; memory means; one or more images of an operating system for controlling the operation of said processors; at least one system bus connecting the elements of the system for efficient operation; means for collecting data regarding a code segment to be monitored; means for selecting a final memory placement for one or more instrumentation code segments and one or more instrumentation data segments, wherein the final memory placement includes one or more memory areas in which to place the instrumentation code segments and the instrumentation data segments, and wherein said means for selecting includes; means for choosing a possible memory placement for the instrumentation code segments and the instrumentation data segments; means for determining an effect of one or more external factors based on the possible memory placement; means for setting the final memory placement to the possible memory placement if the effect is below a predetermined acceptable level; means for determining if there are one or more additional possible memory placements; means for repeatedly choosing the possible memory placement, and for determining the effect of the external factors, until the effect is below the predetermined acceptable level; means for executing the code segment to be monitored, and determining an execution time, for each of the possible memory placements determined by said means for choosing; means for setting the final memory placement equal to the possible memory segment which results in the lowest execution time; and means for executing the code segment to be monitored, along with one or more of the instrumentation code segments. - View Dependent Claims (6, 7, 8)
-
-
9. A computer program product, in a computer-usable medium, comprising:
-
means for collecting data regarding a code segment to be monitored; means for selecting a final memory placement for one or more instrumentation code segments and one or more instrumentation data segments, wherein the final memory placement includes one or more memory areas in which to place the instrumentation code segments and the instrumentation data segments, and wherein said means for selecting includes; means for choosing a possible memory placement for the instrumentation code segments and the instrumentation data segments; means for determining an effect of one or more external factors based on the possible memory placement; means for setting the final memory placement to the possible memory placement if the effect is below a predetermined acceptable level; means for determining if there are one or more additional possible memory placements; means for repeatedly choosing the possible memory placement, and for determining the effect of the external factors, until the effect is below the predetermined acceptable level; means for executing the code segment to be monitored, and determining an execution time, for each of the possible memory placements determined by said means for choosing; means for setting the final memory placement equal to the possible memory segment which results in the lowest execution time; and means for executing the code segment to be monitored, along with one or more of the instrumentation code segments. - View Dependent Claims (10, 11, 12)
-
Specification