A study on the effectively optimized algorithm for an incremental attribute grammar

점진적 속성문법을 위한 효과적인 최적화 알고리즘에 관한 연구

  • 장재춘 (영동전문대학 전자계산과) ;
  • 안희학 (관동대학교 컴퓨터공학과)
  • Published : 2001.09.01

Abstract

The effective way to apply incremental attribute grammar to a complex language process is the use of optimized algorithm. In optimized algorithm for incremental attribute grammar, the new input attribute tree should be exactly compared with the previous input attribute tree, in order to determine which subtrees from the old should be used in constructing the new one. In this paper the new optimized algorithm was reconstructed by analyzing the algorithm suggested by Carle and Pollock, and a generation process of new attribute tree d’copy was added. Through the performance evaluation for the suggested matching algorithm, the run time is approximately improved by 19.5%, compared to the result of existing algorithm.

복잡한 언어 처리에 점진적 속성 문법을 적용하기 위해서는 최적화 알고리즘을 사용하는 것이 효과적이다. 점진적 속성문법의 최적화 알고리즘에서는 새로운 입력 속성 트리가 기존 입력 속성 트리와 정확히 비교되어서 새로운 속성 트리를 구성할 대 기존 속성 트리의 어떤 서브트리를 사용해야 하는가를 결정한다. 본 논문에서는 Carle과 Pollock에 의해 제안된 알고리즘을 분석하여 효과적인 최적화 알고리즘으로 재구성하고, 새로은 속성 트리 d'copy의 생성 과정과, 속성트리 d'copy의 새로운 최적화 알고리즘을 추가하였다. 이 논문에서 제안한 매칭 알고리즘의 성능평가를 통하여 기존의 알고리즘 보다 제안한 최적화 알고리즘의 실행 시간을 약 19.5% 향상 시킬 수 있었다.

Keywords

References

  1. Aho, A. V., Sethi, R. and Ullman, J. D., 'Compilers Principles. Techniques, and Tools,' Addison-wesley publishing Co., 1986
  2. Teitelbaum, T. and Demers, A., 1983, 'Incremental context dependent analysis for language-based editors,' ACM Trans. Program. Lang. Syst., 5,3(July), pp.449-477 https://doi.org/10.1145/2166.357218
  3. Teitelbaum, T. and Chamman, R., 1990, 'Higher-order attribute grammars and editing environments,' processing of the SIGPLAN'90 Symposium on Programming Language Design and Implementation. ACM, New York, pp.197-208 https://doi.org/10.1145/93542.93567
  4. Carle, A. and Pollock, L., 1990, 'Incremental evaluators for hierarchical attribute grammars,' Tech. Rep. TR90-103, Rice Univ., Houston, Tex. Jan.
  5. Carle, A., 1992, 'Hierarchical attribute grammars : Dialects, applications and evaluation algorithms,' Ph.D. thesis, Dept. of Computer Science, Rice Univ., Houston, Tex.
  6. Carle, A. and Pollock, L., 1995a, 'A context-based incremental evaluators for hierachical attribute grammars,' J. Program. Lang., 3, pp.1-29
  7. Carle, A. and Pollock, L., 1995b, 'Matching-based incremental evaluators for hierarchical attribute grammar dialects,' ACM Trans. Program. Lang. Syst., 17,2, pp.394-429 https://doi.org/10.1145/201059.201071
  8. Jia, A. and Qian, J., 1985, 'Incremental evaluation of attributed grammars for incremental programming environments,' IEEE COMPSAC'85(Chicago, Ⅲ), IEEE, New York, pp.342-349