×

Method and apparatus for an improved optimizing compiler

  • US 5,659,754 A
  • Filed: 03/31/1995
  • Issued: 08/19/1997
  • Est. Priority Date: 03/31/1995
  • Status: Expired due to Term
First Claim
Patent Images

1. A computer system having a central processing unit (CPU) and random access memory (RAM) coupled to said CPU, for use in compiling a target program to run on a target computer architecture having a fixed number of CPU registers, said target program having at least one basic block and wherein "use" blocks are inserted in a control flow graph which inhibit needless variable spilling to memory, said computer system comprising:

  • a compiler system resident in said computer system having a front end compiler, a code optimizer and a back end code generator; and

    said code optimizer configured to determine a set of live variables for said basic block in said target program, wherein said fixed number of CPU registers in said target computer architecture can be allocated to said set of live variables in a manner which minimizes a number of variables in said set of live variables that must be stored in said memory instead of in said fixed number of CPU registers,wherein said code optimizer inserts, in at least a portion of a control flow graph, a dummy block representing usage of a variable in said control flow graph prior to a phi-function node and determines said set of live variables by considering said dummy block, and wherein said code optimizer is further configured to perform a static single assignment transform on said target program and to add said phi function node to said control flow graph representation of said target program, and wherein said dummy block is a use block.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×