×

Method and system for register allocation using multiple interference graphs

  • US 5,901,317 A
  • Filed: 03/25/1996
  • Issued: 05/04/1999
  • Est. Priority Date: 03/25/1996
  • Status: Expired due to Term
First Claim
Patent Images

1. A computer implemented method for use in a compiler for allocating real registers in a CPU to instructions of a target computer program which are to be executed on the CPU, said method comprising the steps of:

  • creating a representation of a primary interference graph having nodes representing virtual registers and primary edges linking nodes with concurrent latency, the number of edges of a given node being the degree of the node;

    creating a representation of a second interference graph having nodes representing virtual registers and secondary edges linking nodes with conditional conflicts;

    selecting nodes from the primary interference graph having degrees less than the number of CPU registers until all nodes have been selected; and

    allocating real registers to said selected nodes by first determining whether a register can be allocated for a selected node using the edges of both the primary and secondary interference graphs and, if so, allocating a real register on that basis; and

    , if not, allocating a real register using the edges of the primary graph alone.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×