arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2301.02194cs.PL
收藏

视为归纳族的内置类型

Builtin Types viewed as Inductive Families

Guillaume Allais

摘要:

用于依赖类型化语言的最先进的优化通道可以帮助擦除丰富不变数据结构和程序的典型冗余信息。这些自动化过程不会显著改变数据的结构,即使可以提供更有效的表示。使用定量类型论,我们演示了如何定义一个不变量丰富,类型检查时间数据结构包装一个有效的运行时表示与运行时无关的不变量。然后编译器可以在编译期间主动擦除所有此类不变量。与其他方法不同,最终表示的复杂性是完全可预测的,我们不要求两种表示具有相同的结构,但我们能够无缝编程,就像我们使用高级结构一样。

英文摘要:

State of the art optimisation passes for dependently typed languages can help erase the redundant information typical of invariant-rich data structures and programs. These automated processes do not dramatically change the structure of the data, even though more efficient representations could be available. Using Quantitative Type Theory, we demonstrate how to define an invariant-rich, typechecking time data structure packing an efficient runtime representation together with runtime irrelevant invariants. The compiler can then aggressively erase all such invariants during compilation. Unlike other approaches, the complexity of the resulting representation is entirely predictable, we do not require both representations to have the same structure, and yet we are able to seamlessly program as if we were using the high-level structure.

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

↑