Distill:面向认知模型的特定领域编译
Distill: Domain-Specific Compilation for Cognitive Models
摘要:
本文讨论了我们的建议和实现的蒸馏,特定领域的编译工具,基于LLVM加速认知模型。认知模型解释了认知功能的过程,并提供了一条通往类人人工智能的道路。然而,认知建模是费力的,需要许多类型的计算任务的组合,并且由于它依赖于像Python这样的高级语言而性能较差。为了在实现高性能的同时继续享受Python的灵活性,Distill使用特定领域的知识将基于Python的认知模型编译成LLVM IR,小心地剥离了动态类型和存储管理等增加实际模型开销的功能。正如我们所展示的,这使得模型执行速度显著加快。我们还表明,这样生成的代码,使使用经典的编译器数据流分析通过揭示认知模型中的数据流是有用的认知科学家的属性。Distill是公开可用的,正在被认知科学的研究人员使用,并导致目前正在评估集成到主线LLVM中的补丁。
英文摘要:
This paper discusses our proposal and implementation of Distill, a domain-specific compilation tool based on LLVM to accelerate cognitive models. Cognitive models explain the process of cognitive function and offer a path to human-like artificial intelligence. However, cognitive modeling is laborious, requiring composition of many types of computational tasks, and suffers from poor performance as it relies on high-level languages like Python. In order to continue enjoying the flexibility of Python while achieving high performance, Distill uses domain-specific knowledge to compile Python-based cognitive models into LLVM IR, carefully stripping away features like dynamic typing and memory management that add overheads to the actual model. As we show, this permits significantly faster model execution. We also show that the code so generated enables using classical compiler data flow analysis passes to reveal properties about data flow in cognitive models that are useful to cognitive scientists. Distill is publicly available, is being used by researchers in cognitive science, and has led to patches that are currently being evaluated for integration into mainline LLVM.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。