The use of the parsing method for the optimal code generation and common subexpression elimination

Общая информация

 Аннотация


    Research on methods to automatically generate compiler back-ends has shown that the performance of code generators combining a fast tree-pattern matching algorithm with a dynamic programming algorithm is comparable to very fast production compilers. We investigate BEG and Twig systems that use such method. Then we propose to use the parsing with ambiguous attributed tree grammars for code generation, resorting to classical terminology from formal language theory. An attribute grammar is supplemented with cost-attributes, their rules and cost criteria to select the best possible derivation tree. The algorithm of Cocke, Younger and Kasami(CYK) modified to accepts tree grammars is used for the parsing of an intermediate program. Code selection and register allocation are studied when common subexpressions are taken into account.

 Ключевые слова

    compiler back-end, code generator, tree-pattern matching, tree grammar, algorithm of Cocke, Younger and Kasami
  Полный текст
Полный текст публикации     в формате html

Home page
Наш адрес:
119991 ГСП-1 Москва В-71, Ленинский просп., 14
Телефон: 938-0309 (Справ. бюро)
Факс: (495)954-3320 (Лен.пр.,14), (495)938-1844 (Лен.пр.,32а)
Назад