摘要 |
PURPOSE:To reduce waiting for the confirmation of a register and to improve execution speed of an object program by making a work register at the time of object code conversion variable. CONSTITUTION:An analyzing section 21 inside of a compiler 2 reads a source program 1 and generates an intermediate text 24, and necessary registers are allotted in a register allotting section 22. In a process 231, the content of registers not allotted is accumulated in a table 25 and registers that can be used for address calculation are accumulated in a part 26 of the table 25. Then, it is judged whether a work register is to be used or not, and in the case where the register is used for address calculation, a register used earliest out of registers accumulated in the table 26 is taken out. When used for the purpose other than address calculation, a register used earliest out of registers accumulated in the table 25 is taken out. A register taken out in this way is made as a work register.
|