# US 2016/0253176 A1 · Forming instruction groups based on decode time instruction optimization

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

- Number: US 2016/0253176 A1
- Document ID: US20160253176A1
- Status: Published application
- Kind: A1
- Application number: 15/148,328
- Filed: 2016-05-06
- Published: 2016-09-01
- Earliest claimed: 2013-06-28
- Assignees: International Business Machines Corporation
- Applicants: International Business Machines Corporation
- Inventors: Michael K. Gschwind
- Web page: https://patentgrep.com/patent/US20160253176A1

## CPC

- G06F 9/3867: {using instruction pipelines}
- G06F 8/443: {Optimisation}
- G06F 8/4441: {Reducing the execution time required by the program code}
- G06F 9/30145: {Instruction analysis, e.g. decoding, instruction word fields}
- G06F 9/3016: {Decoding the operand specifier, e.g. specifier format}
- G06F 9/30196: {using decoder, e.g. decoder per instruction set, adaptable or programmable decoders}
- G06F 9/3802: {Instruction prefetching}
- G06F 9/3822: {Parallel decoding, e.g. parallel decode units}
- G06F 9/3853: {of compound instructions}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Instructions are grouped into instruction groups based on optimizations that may be performed. An instruction is obtained, and a determination is made as to whether the instruction is to be included in a current instruction group or another instruction group. This determination is made based on whether the instruction is a candidate for optimization, such as decode time instruction optimization. If it is determined that the instruction is to be included in another group, then the other group is formed to include the instruction.

## Claims

### Claim 1

A computer program product for facilitating processing in a processing environment, said computer program product comprising:
a computer readable storage medium readable by a processing circuit and storing instructions for execution by the processing circuit for performing a method comprising:
obtaining an instruction to be executed in the processing environment;
determining whether the instruction is to be included in a current group of instructions or a new group of instructions, wherein the determining is based on whether the instruction is a candidate for optimization with another instruction according to an optimization criterion;
based on determining the instruction is to be included in the new group of instructions, forming the new group of instructions, the new group of instructions including the instruction and the other instruction; and
based on forming the new group of instructions, executing at least one instruction associated with the new group of instructions.

### Claim 2 (depends on 1)

The computer program product of claim 1, wherein the determining comprises determining whether the instruction represents a beginning of a potential optimization sequence that includes the instruction and the other instruction, and wherein the forming forms the new group of instructions based on the instruction representing the beginning of the potential optimization sequence.

### Claim 3 (depends on 2)

The computer program product of claim 2, wherein the determining whether the instruction represents the beginning of the potential optimization sequence comprises checking a marker associated with the instruction, the marker indicating whether the instruction starts the potential optimization sequence.

### Claim 4 (depends on 3)

The computer program product of claim 3, wherein the method further comprises marking the instruction with the marker, the marker indicating one of: the instruction is considered as representing the beginning of the potential optimization sequence, or the instruction is not considered as representing the beginning of the potential optimization sequence, and wherein the marking is performed at instruction fetch.

### Claim 5 (depends on 1)

The computer program product of claim 1, wherein the determining whether the instruction is to be included in the current group of instructions or the new group of instructions further comprises:
checking whether an instruction sequence to be optimized that includes at least the instruction and the other instruction fits in the current group; and
forming the new group based on determining the instruction is a candidate for optimization and the instruction sequence does not fit in the current group.

### Claim 6 (depends on 5)

The computer program product of claim 5, wherein the checking includes checking a marker associated with the instruction, the marker indicating a length of the instruction sequence.

### Claim 7 (depends on 6)

The computer program product of claim 6, wherein the method further comprises:
determining a number of instructions in the instruction sequence; and
marking the instruction with a selected marker that indicates the number of instructions, the marking being performed at instruction fetch.

### Claim 8 (depends on 1)

The computer program product of claim 1, wherein the optimization criterion is specified in one or more templates, and wherein at least one template of the one or more templates is to be used to determine whether the instruction is a candidate for optimization.

### Claim 9 (depends on 1)

The computer program product of claim 1, wherein the optimization criterion optimizes the instruction and the other instruction by creating at least one internal operation that represents at least a portion of the instruction and at least a portion of the other instruction.

### Claim 10 (depends on 1)

The computer program product of claim 1, wherein the optimization is performed at decode time.

### Claim 11

A computer system for facilitating processing in a processing environment, said computer system comprising:
a memory; and
a processor in communications with the memory, wherein the computer system is configured to perform a method, said method comprising:
obtaining an instruction to be executed in the processing environment;
determining whether the instruction is to be included in a current group of instructions or a new group of instructions, wherein the determining is based on whether the instruction is a candidate for optimization with another instruction according to an optimization criterion;
based on determining the instruction is to be included in the new group of instructions, forming the new group of instructions, the new group of instructions including the instruction and the other instruction; and
based on forming the new group of instructions, executing at least one instruction associated with the new group of instructions.

### Claim 12 (depends on 11)

The computer system of claim 11, wherein the determining comprises determining whether the instruction represents a beginning of a potential optimization sequence that includes the instruction and the other instruction, and wherein the forming forms the new group of instructions based on the instruction representing the beginning of the potential optimization sequence.

### Claim 13 (depends on 12)

The computer system of claim 12, wherein the determining whether the instruction represents the beginning of the potential optimization sequence comprises checking a marker associated with the instruction, the marker indicating whether the instruction starts the potential optimization sequence.

### Claim 14 (depends on 13)

The computer system of claim 13, wherein the method further comprises marking the instruction with the marker, the marker indicating one of: the instruction is considered as representing the beginning of the potential optimization sequence, or the instruction is not considered as representing the beginning of the potential optimization sequence, and wherein the marking is performed at instruction fetch.

### Claim 15 (depends on 11)

The computer system of claim 11, wherein the determining whether the instruction is to be included in the current group of instructions or the new group of instructions further comprises:
checking whether an instruction sequence to be optimized that includes at least the instruction and the other instruction fits in the current group; and
forming the new group based on determining the instruction is a candidate for optimization and the instruction sequence does not fit in the current group.

### Claim 16 (depends on 15)

The computer system of claim 15, wherein the checking includes checking a marker associated with the instruction, the marker indicating a length of the instruction sequence.

### Claim 17 (depends on 16)

The computer system of claim 16, wherein the method further comprises:
determining a number of instructions in the instruction sequence; and
marking the instruction with a selected marker that indicates the number of instructions, the marking being performed at instruction fetch.

### Claim 18 (depends on 11)

The computer system of claim 11, wherein the optimization criterion optimizes the instruction and the other instruction by creating at least one internal operation that represents at least a portion of the instruction and at least a portion of the other instruction.

### Claim 19 (depends on 11)

The computer system of claim 11, wherein the optimization criterion optimizes the instruction and the other instruction by creating at least one internal operation that represents at least a portion of the instruction and at least a portion of the other instruction.

### Claim 20 (depends on 11)

The computer system of claim 11, wherein the optimization is performed at decode time.
