×

Compiler with improved live range interference investigation

  • US 5,642,512 A
  • Filed: 07/27/1995
  • Issued: 06/24/1997
  • Est. Priority Date: 09/13/1994
  • Status: Expired due to Fees
First Claim
Patent Images

1. A compiler for compiling a program composed of a plurality of instructions into a machine language program, comprising:

  • jump instruction detection means for detecting jump instructions in the program and a jump destination instruction for each of the jump instructions;

    division means for dividing the program into basic blocks based on the jump instructions and the jump destination instructions detected by the jump instruction detection means;

    live range detection means for detecting, for every variable in the program, a live range which is a range for which a variable in the program is valid, and for expressing a detection result for each variable as a set of instruction position information showing positions of instructions included in the live range;

    basic block internal live variable detection means for detecting every variable for which the live range detected by the live range detection means is positioned entirely within one of the basic blocks and for expressing a detection result for each of the basic blocks as a basic block internal live variable group corresponded to an appropriate basic block;

    inter-basic block live variable detection means for detecting every variable for which the live range detected by the live range detection means extends between basic blocks and for expressing a detection result as an inter-basic block live variable group;

    first live range interference judgement means for taking two variables at a time from the inter-basic block live variable group and, by finding an intersection set of sets of instruction position information corresponding to the live ranges of two variables, for judging whether there is interference between the live ranges;

    second live range interference judgement means for taking two variables at a time from a basic block internal live variable group corresponded to a same basic block and, by calculating an intersection set of sets of instruction position information corresponding to the live ranges of the two variables, for judging whether there is interference between the live ranges; and

    third live range interference judgement means for taking one variable at a time from a basic block internal live variable group corresponded to a basic block and one variable at a time from the inter-basic block live variable group and, by calculating an intersection set of sets of instruction position information corresponding to the live ranges of the two variables, for judging whether there is interference between the live ranges,wherein the compiler executes resource assignment using judgement results of the first, the second and the third live range interference judgement means.

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