首页> 美国政府科技报告 >Using Cached Functions and Constructors for Incremental Attribute Evaluation
【24h】

Using Cached Functions and Constructors for Incremental Attribute Evaluation

机译:使用缓存函数和构造函数进行增量属性评估

获取原文

摘要

A technique for the efficient incremental evaluation of attribute grammars ispresented. The applied approach may also be effective in the evaluation of higher-order attribute grammars. The approach is an extension of a simpler algorithm for incremental evaluation, where functions, corresponding to visit sequences, are cached. Attributes are now either found in the cache or they are recomputed, so there is no longer a need to represent the attributed tree explicitly. Common subtrees can be shared. The following change is proposed: instead of explicitly representing the tree and calling visit sequence functions to compute the attributes, the tree is represented through a set of visit functions corresponding to the successive visits. These functions are constituted using the visit sequences as building blocks. This technique has two major advantages. Firstly, a visit function characterizes precisely that part of the tree that would actually be visited in the previous approach, thus increasing the number of cache hits. Secondly, copy rules may be removed during the construction phase. This results in short circuiting the copychains and in minimizing the number of recomputed functions.

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号