# US 2008/0307203 A1 · Scaling Instruction Intervals to Identify Collection Points for Representative Instruction Traces

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2008/0307203 A1
- Document ID: US20080307203A1
- Status: Published application
- Kind: A1
- Application number: 11/758,031
- Filed: 2007-06-05
- Published: 2008-12-11
- Earliest claimed: 2007-06-05
- Assignees: International Business Machines Corporation
- Inventors: Robert H. Bell, JR.; Wen-Tzer T. Chen; Richard J. Eickemeyer; Venkat R. Indukuru; Pattabi M. Seshadri; Madhavi G. Valluri
- Web page: https://patentgrep.com/patent/US20080307203A1

## CPC

- G06F 11/36: Prevention of errors by analysis, debugging or testing of software
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A method, system, and computer program product are provided for identifying instructions to obtain representative traces. A phase instruction budget is calculated for each phase in a set of phases. The phase instruction budget is based on a weight associated with each phase and a global instruction budget. A starting index and an ending index are identified for instructions within a set of intervals in each phase in order to meet the phase instruction budget for that phase, thereby forming a set of interval indices. A determination is made as to whether the instructions within the set of interval indices meet the global instruction budget. Responsive to the global instruction budget being met, the set of interval indices are output as collection points for the representative traces.

## Claims

### Claim 1

A method, in a data processing system, for identifying instructions to obtain representative traces, the method comprising:
calculating a phase instruction budget for each phase in a set of phases, wherein the phase instruction budget is based on a weight associated with each phase and a global instruction budget;
identifying a starting index and an ending index for instructions within a set of intervals in each phase in order to meet the phase instruction budget for that phase, thereby forming a set of interval indices;
determining if the instructions within the set of interval indices meet the global instruction budget; and
responsive to the global instruction budget being met, outputting the set of interval indices as collection points for the representative traces.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
determining if a set of warm-up instructions are to be included with the instructions in the global instruction budget; and
responsive to the indication that warm-up instructions are to be included, adjusting the starting index by a predetermined number of instructions or to the end of the prior interval in the set of intervals.

### Claim 3 (depends on 1)

The method of claim 1, wherein identifying the starting index and the ending index for instructions within the set of intervals in each phase comprises:
determining if a number of instructions in a most representative interval within the set of intervals is equal to the phase instruction budget; and
responsive to the instructions within the most representative interval being equal to the phase instruction budget, identifying a beginning of the most representative interval as the starting index and an end of the most representative interval as the ending index.

### Claim 4 (depends on 1)

The method of claim 1, wherein identifying the starting index and the ending index for instructions within the set of intervals in each phase comprises:
determining if a number of instructions in a most representative interval within the set of intervals is more than the phase instruction budget; and
responsive to the instructions within the most representative interval being more than the phase instruction budget, identifying a beginning of the most representative interval as the starting index and scaling the most representative interval to a point where the number of instructions equals the phase instruction budget, wherein the point is the ending index.

### Claim 5 (depends on 1)

The method of claim 1, wherein identifying the starting index and the ending index for instructions within the set of intervals in each phase comprises:
determining if a number of instructions in more than one most representative intervals within the set of intervals is equal to the phase instruction budget; and
responsive to the instructions within the more than one most representative intervals being equal to the phase instruction budget, identifying a beginning of the more than one most representative intervals as the starting index and an end of the more than one most representative intervals as the ending index.

### Claim 6 (depends on 1)

The method of claim 1, wherein identifying the starting index and the ending index for instructions within the set of intervals in each phase comprises:
determining if a number of instructions in more than one most representative intervals within the set of intervals is more than the phase instruction budget; and
responsive to the instructions within the more than one most representative intervals being more than the phase instruction budget, identifying a beginning of the more than one most representative intervals as the starting index and scaling the more than one most representative intervals to a point where the number of instructions equals the phase instruction budget, wherein the point is the ending index.

### Claim 7 (depends on 1)

The method of claim 1, further comprising:
responsive to the global instruction budget failing to be met, determining if the sum of the instructions within the set of interval indices is less than the global instruction budget; and
responsive to the sum of the instructions within the set of interval indices being less than the global instruction budget, increasing the instructions within one interval of one phase in the set of phases in order to meet the instruction budget.

### Claim 8 (depends on 1)

The method of claim 1, further comprising:
responsive to the global instruction budget failing to be met, determining if the sum of the instructions within the set of interval indices is more than the global instruction budget; and
responsive to the sum of the instructions within the set of interval indices being more than the global instruction budget, decreasing the instructions within one interval of one phase in the set of phases in order to meet the instruction budget.

### Claim 9

A computer program product comprising a computer useable medium having a computer readable program, wherein the computer readable program, when executed in a data processing system, causes the data processing system to:
calculate a phase instruction budget for each phase in a set of phases, wherein the phase instruction budget is based on a weight associated with each phase and a global instruction budget;
identify a starting index and an ending index for instructions within a set of intervals in each phase in order to meet the phase instruction budget for that phase, thereby forming a set of interval indices;
determine if the instructions within the set of interval indices meet the global instruction budget; and
responsive to the global instruction budget being met, output the set of interval indices as collection points for the representative traces.

### Claim 10 (depends on 9)

The computer program product of claim 9, wherein the computer readable program further causes the data processing system to:
determine if a set of warm-up instructions are to be included with the instructions in the global instruction budget; and
responsive to the indication that warm-up instructions are to be included, adjust the starting index by a predetermined number of instructions or to the end of the prior interval in the set of intervals.

### Claim 11 (depends on 9)

The computer program product of claim 9, wherein the computer readable program to identify the starting index and the ending index for instructions within the set of intervals in each phase further causes the data processing system to:
determine if a number of instructions in a most representative interval within the set of intervals are equal to the phase instruction budget;
responsive to the instructions within the most representative interval being equal to the phase instruction budget, identify a beginning of the most representative interval as the starting index and an end of the most representative interval as the ending index;
determine if the number of instructions in the most representative interval within the set of intervals is more than the phase instruction budget;
responsive to the instructions within the most representative interval being more than the phase instruction budget, identify the beginning of the most representative interval as the starting index and scaling the most representative interval to a point where the number of instructions equals the phase instruction budget, wherein the point is the ending index;
determine if the number of instructions in more than one most representative intervals within the set of intervals is equal to the phase instruction budget; and
responsive to the instructions within the more than one most representative intervals being equal to the phase instruction budget, identify the beginning of the more than one most representative intervals as the starting index and an end of the more than one most representative intervals as the ending index.

### Claim 12 (depends on 9)

The computer program product of claim 9, wherein the computer readable program to identify the starting index and the ending index for instructions within the set of intervals in each phase further causes the data processing system to:
determine if a number of instructions in more than one most representative intervals within the set of intervals is more than the phase instruction budget; and
responsive to the instructions within the more than one most representative intervals being more than the phase instruction budget, identify a beginning of the more than one most representative intervals as the starting index and scaling the more than one most representative intervals to a point where the number of instructions equals the phase instruction budget, wherein the point is the ending index.

### Claim 13 (depends on 9)

The computer program product of claim 9, wherein the computer readable program further causes the data processing system to:
responsive to the global instruction budget failing to be met, determine if the sum of the instructions within the set of interval indices is less than the global instruction budget; and
responsive to the sum of the instructions within the set of interval indices being less than the global instruction budget, increase the instructions within one interval of one phase in the set of phases in order to meet the instruction budget.

### Claim 14 (depends on 9)

The computer program product of claim 9, wherein the computer readable program further causes the data processing system to:
responsive to the global instruction budget failing to be met, determine if the sum of the instructions within the set of interval indices is more than the global instruction budget; and
responsive to the sum of the instructions within the set of interval indices being more than the global instruction budget, decrease the instructions within one interval of one phase in the set of phases in order to meet the instruction budget.

### Claim 15

A system, comprising:
a processor; and
a memory coupled to the processor, wherein the memory comprises instructions which, when executed by the processor, cause the processor to:
calculate a phase instruction budget for each phase in a set of phases, wherein the phase instruction budget is based on a weight associated with each phase and a global instruction budget;
identify a starting index and an ending index for instructions within a set of intervals in each phase in order to meet the phase instruction budget for that phase, thereby forming a set of interval indices;
determine if the instructions within the set of interval indices meet the global instruction budget; and
responsive to the global instruction budget being met, output the set of interval indices as collection points for the representative traces.

### Claim 16 (depends on 15)

The system of claim 15, wherein the instructions further cause the processor to:
determine if a set of warm-up instructions are to be included with the instructions in the global instruction budget; and
responsive to the indication that warm-up instructions are to be included, adjust the starting index by a predetermined number of instructions or to the end of the prior interval in the set of intervals.

### Claim 17 (depends on 15)

The system of claim 15, wherein the instructions to identify the starting index and the ending index for instructions within the set of intervals in each phase further cause the processor to:
determine if a number of instructions in a most representative interval within the set of intervals are equal to the phase instruction budget;
responsive to the instructions within the most representative interval being equal to the phase instruction budget, identify a beginning of the most representative interval as the starting index and an end of the most representative interval as the ending index;
determine if the number of instructions in the most representative interval within the set of intervals is more than the phase instruction budget;
responsive to the instructions within the most representative interval being more than the phase instruction budget, identify the beginning of the most representative interval as the starting index and scaling the most representative interval to a point where the number of instructions equals the phase instruction budget, wherein the point is the ending index;
determine if the number of instructions in more than one most representative intervals within the set of intervals is equal to the phase instruction budget; and
responsive to the instructions within the more than one most representative intervals being equal to the phase instruction budget, identify the beginning of the more than one most representative intervals as the starting index and an end of the more than one most representative intervals as the ending index.

### Claim 18 (depends on 15)

The system of claim 15, wherein the instructions to identifying the starting index and the ending index for instructions within the set of intervals in each phase further cause the processor to:
determine if a number of instructions in more than one most representative intervals within the set of intervals is more than the phase instruction budget; and
responsive to the instructions within the more than one most representative intervals being more than the phase instruction budget, identify a beginning of the more than one most representative intervals as the starting index and scaling the more than one most representative intervals to a point where the number of instructions equals the phase instruction budget, wherein the point is the ending index.

### Claim 19 (depends on 15)

The system of claim 15, wherein the instructions further cause the processor to:
responsive to the global instruction budget failing to be met, determine if the sum of the instructions within the set of interval indices is less than the global instruction budget; and
responsive to the sum of the instructions within the set of interval indices being less than the global instruction budget, increase the instructions within one interval of one phase in the set of phases in order to meet the instruction budget.

### Claim 20 (depends on 15)

The system of claim 15, wherein the instructions further cause the processor to:
responsive to the global instruction budget failing to be met, determine if the sum of the instructions within the set of interval indices is more than the global instruction budget; and
responsive to the sum of the instructions within the set of interval indices being more than the global instruction budget, decrease the instructions within one interval of one phase in the set of phases in order to meet the instruction budget.
