【24h】

Multivariate Amortized Resource Analysis

机译:多元摊销资源分析

获取原文
获取外文期刊封面目录资料

摘要

We study the problem of automatically analyzing the worst-case resource usage of procedures with several arguments. Existing automatic analyses based on amortization or sized types bound the resource usage or result size of such a procedure by a sum of unary functions of the sizes of the arguments. In this article we generalize this to arbitrary multivariate polynomial functions thus allowing bounds of the form mn which had to be grossly overestimated by m~2 + n~2 before. Our framework even encompasses bounds like Σ_(i,j≤n) m_im_j where the m_i are the sizes of the entries of a list of length n. This allows us for the first time to derive useful resource bounds for operations on matrices that are represented as lists of lists and to considerably improve bounds on other superlinear operations on lists such as longest common subsequence and removal of duplicates from lists of lists. Furthermore, resource bounds are now closed under composition which improves accuracy of the analysis of composed programs when some or all of the components exhibit superlinear resource or size behavior. The analysis is based on a novel multivariate amortized resource analysis. We present it in form of a type system for a simple first-order functional language with lists and trees, prove soundness, and describe automatic type inference based on linear programming. We have experimentally validated the automatic analysis on a wide range of examples from functional programming with lists and trees. The obtained bounds were compared with actual resource consumption. All bounds were asymptotically tight, and the constants were close or even identical to the optimal ones.
机译:我们研究带有几个参数的自动分析过程的最坏情况下的资源使用情况的问题。现有的基于摊销或大小类型的自动分析通过此类参数大小的一元函数的总和来限制此类过程的资源使用量或结果大小。在本文中,我们将其推广到任意多元多项式函数,从而允许形式mn的边界在以前必须被高估了m〜2 + n〜2。我们的框架甚至包含Σ_(i,j≤n)m_im_j之类的边界,其中m_i是长度为n的列表的条目的大小。这使我们首次可以得出有用的资源界限,以用于表示为列表列表的矩阵上的操作,并显着改善列表上其他超线性操作的范围,例如最长的公共子序列和从列表列表中删除重复项。而且,资源边界现在处于合成之下,当某些或所有组件表现出超线性的资源或大小行为时,可以提高组成程序分析的准确性。该分析基于新颖的多元摊销资源分析。我们以带有列表和树的简单一阶功能语言的类型系统的形式来呈现它,证明其健全性,并描述基于线性编程的自动类型推断。我们已经通过实验验证了自动分析的广泛应用,包括使用列表和树进行函数式编程。将获得的界限与实际资源消耗进行比较。所有边界都渐近严格,并且常数与最佳边界接近或什至相同。

著录项

相似文献

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

客服邮箱:kefu@zhangqiaokeyan.com

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

  • 服务号