Method and apparatus for elimination of redundant branch instructions from a program
US5999739A · kind A · utility
Assignee
Inventors
Key dates
| Filing date | Nov 18, 1997 |
| Grant date | Dec 7, 1999 |
| Priority date | — |
| Expiry date | Nov 18, 2017 |
Classification
- Technology area (CPC G)Physics
- CPC primaryG06F8/443
- WIPO fieldComputer technology
- WIPO sectorElectrical engineering
Abstract
The procedure of the invention eliminates redundant conditional branch statements (CBSs) from a program, wherein the program includes (i) plural blocks of program statements, (ii) a definition statement (DEF) for each variable in the program that assigns a value to each variable, (iii) a defining point (DEFP) which is a first point in the program that a value is calculated, and (iv) plural CBSs. Each CBS transfers control to one of two target blocks of program statements, dependent upon an operation code and controlling variable that form a part of the test associated with the CBS. The procedure associates all DEFs which define a same value, with a DEFP for the same value and determines (i) a controlling variable upon which a test CBS is dependent, (ii) a DEF of the controlling variable of the test CBS and (iii) a DEFP for the DEF of the controlling variable. If a value first calculated at the DEFP found in (iii) is utilized by a CBS, the procedure finds which arm of the CBS reaches the test CBS; and then revises a block of program statements that include the test CBS, to eliminate at least a test required by the test CBS, and replace the conditional branch with an unconditional br…
Source: USPTO / EPO open patent data. Objective bibliographic and citation counts.