arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1908.04546cs.PLcs.PF
收藏

面向库可移植性的类型导向程序合成和约束生成

Type-Directed Program Synthesis and Constraint Generation for Library Portability

Bruce Collie, Philip Ginsbach, Michael F. P. O'Boyle

摘要:

几十年来,快速数值库一直是科学计算的基石,但这是有代价的。程序可能与特定于供应商的软件生态系统相关联,从而导致污染的、不可移植的代码。随着我们进入异构计算的时代,利用专用硬件所需的加速器库数量激增。我们需要一个系统,允许开发人员利用不断变化的加速器库,而不会过度专门化他们的代码。由于我们无法提前知道未来库的行为,本文开发了一个方案,帮助开发人员将他们的代码与新库相匹配,而不需要这些库的源代码。此外,它可以从使用现有库的程序中恢复等效代码,并自动将它们移植到新接口。它首先使用程序合成来确定库的含义,然后将合成的描述映射成广义约束,用于搜索程序以提供给开发人员的替换机会。我们将这种方法应用于科学计算和深度学习领域的现有大型应用程序。使用我们的方法,我们显示加速范围从1.1 $\times$到超过10 $\times$的端到端的性能时,使用加速器库。

英文摘要:

Fast numerical libraries have been a cornerstone of scientific computing for decades, but this comes at a price. Programs may be tied to vendor specific software ecosystems resulting in polluted, non-portable code. As we enter an era of heterogeneous computing, there is an explosion in the number of accelerator libraries required to harness specialized hardware. We need a system that allows developers to exploit ever-changing accelerator libraries, without over-specializing their code. As we cannot know the behavior of future libraries ahead of time, this paper develops a scheme that assists developers in matching their code to new libraries, without requiring the source code for these libraries. Furthermore, it can recover equivalent code from programs that use existing libraries and automatically port them to new interfaces. It first uses program synthesis to determine the meaning of a library, then maps the synthesized description into generalized constraints which are used to search the program for replacement opportunities to present to the developer. We applied this approach to existing large applications from the scientific computing and deep learning domains. Using our approach, we show speedups ranging from 1.1$\times$ to over 10$\times$ on end to end performance when using accelerator libraries.

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

↑