The search functionality is under construction.

IEICE TRANSACTIONS on Information

Peephole Optimizer in Retargetable Compilers*

Tzer-Shyong CHEN, Feipei LAI, Shu-Lin HWANG, Rung-Ji SHANG

  • Full Text Views

    0

  • Cite this

Summary :

Abstract machine modelling is a technique used frequently in developing the retargetable compilers. By translating the abstract machine operations into target machine instructions, we can construct retargetable compilers. However, such a technique will cause two problems. First, the code produced by the compilers is inefficient. Next, in order to emit the efficient code, the compilation time is too long. In view of these two disadvantages, we apply PO (peephole optimizer) in our retargetable compilers to do code optimization. Peephole optimizer searches for the adjacent instruction candidates in the intermediate code, and then replaces them with equivalent instructions of less cost. Furthermore, the peephole description table consists of simple tree-rewriting rules which are easily retargeted into different machines. At the same time, we have proposed a simple peephole pattern matching algorithm to reduce the peephole pattern matching time. The experiment indicates that the machine code generated by our compiler runs faster than that by GNU c compiler (gcc).

Publication
IEICE TRANSACTIONS on Information Vol.E79-D No.9 pp.1248-1256
Publication Date
1996/09/25
Publicized
Online ISSN
DOI
Type of Manuscript
PAPER
Category
Sofware System

Authors

Keyword