arXivDaily arXiv每日学术速递 周一至周五更新
arXiv cs/0311044cs.PLcs.LO
收藏

利用不确定性的特殊化和约简推导高效逻辑程序

Derivation of Efficient Logic Programs by Specialization and Reduction of Nondeterminism

Alberto Pettorossi, Maurizio Proietti, Sophie Renault

摘要:

程序特化是一种程序转换方法,它通过利用编译时可用的有关输入数据的信息来提高程序效率。我们表明,目前的技术程序专业化的基础上部分评估不执行不确定性逻辑程序。然后,我们考虑一组转换规则,扩展用于部分评估,我们提出了一个策略,用于指导这些扩展规则的应用,从而得到非常有效的专门程序。效率的提高,有时是指数,是由于减少不确定性和事实上,这是由初始程序执行的计算树的不同分支,是由专门的程序在单个分支内执行。为了减少不确定性,我们还利用模式信息来指导展开过程。为了验证我们的技术,我们表明,我们可以自动获得非常有效的匹配程序和解析器的正则语言。我们已经执行的推导不能通过以前已知的部分评估技术来完成。

英文摘要:

Program specialization is a program transformation methodology which improves program efficiency by exploiting the information about the input data which are available at compile time. We show that current techniques for program specialization based on partial evaluation do not perform well on nondeterministic logic programs. We then consider a set of transformation rules which extend the ones used for partial evaluation, and we propose a strategy for guiding the application of these extended rules so to derive very efficient specialized programs. The efficiency improvements which sometimes are exponential, are due to the reduction of nondeterminism and to the fact that the computations which are performed by the initial programs in different branches of the computation trees, are performed by the specialized programs within single branches. In order to reduce nondeterminism we also make use of mode information for guiding the unfolding process. To exemplify our technique, we show that we can automatically derive very efficient matching programs and parsers for regular languages. The derivations we have performed could not have been done by previously known partial evaluation techniques.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑