快速、灵活、多语言的仪器支持,适用于自动化仪和其他工具
Fast, Flexible, Polyglot Instrumentation Support for Debuggers and other Tools
摘要:
内容:与运行程序交互的软件开发工具,如调试器、分析器和动态分析框架,被认为需要在实现复杂性(成本)、功能、可用性和性能之间进行艰难的权衡。在许多后果中,工具通常交付较晚(如果有的话),功能有限,需要非标准配置,并对运行程序造成严重的性能成本。询价:灵活的工具支持能否成为现代高性能程序设计语言实现框架的一个实用的、一流的内在需求?方法:我们扩展了Truffle语言实现框架,它与GraalVM执行环境一起使非常高性能的语言实现成为可能。Truffle的新工具框架与语言无关,旨在从与语言实现相同的技术中获得高性能。Truffle Instrumentation包括:(1)通过向执行AST动态添加“包装器”节点来低开销地捕获执行事件;(2)对语言实现框架的扩展,其允许每种语言的专门化,主要用于值和名称的视觉显示等;以及(3)用于实现多种工具而无需VM修改的通用API和支持服务。知识:现在,生产环境中的客户端可以插入(动态地,具有线程安全性)一个捕获和报告抽象指定的执行事件的检测探针。完全优化的代码中的探测器在实际用于访问(或修改)执行状态之前会产生非常低的开销。事件捕获使得能够构建许多GraalVM服务和工具,这些服务和工具可以单独或组合地用于所有已实现的语言。插装也被证明对于实现一些传统的棘手的语言功能以及一些GraalVM服务(例如对运行程序所消耗的资源进行限制)很有价值。接地:用于调试(通过多个客户端)、分析、语句计数、动态分析和其他工具现在是GraalVM的一部分,或者正在积极开发中。第三方也使用Truffle Instrumentation来实现创新工具。重要性:Truffle Instrumentation的经验验证了这样一个概念,即预先考虑开发人员工具支持可以改变对高性能语言实用、高效工具可用性的期望。工具开发成为语言实现的一个自然部分,只需要很少的额外工作,并提供早期和持续可用性的优势。
英文摘要:
Context: Software development tools that interact with running programs such as debuggers, profilers, and dynamic analysis frameworks are presumed to demand difficult tradeoffs among implementation complexity (cost), functionality, usability, and performance. Among the many consequences, tools are often delivered late (if ever), have limited functionality, require non-standard configurations, and impose serious performance costs on running programs. Inquiry: Can flexible tool support become a practical, first class, intrinsic requirement for a modern highperformance programming language implementation framework? Approach: We extended the Truffle Language Implementation Framework, which together with the GraalVM execution environment makes possible very high performance language implementations. Truffle's new Instrumentation Framework is language-agnostic and designed to derive high performance from the same technologies as do language implementations. Truffle Instrumentation includes: (1) low overhead capture of execution events by dynamically adding "wrapper" nodes to executing ASTs; (2) extensions to the Language Implementation Framework that allow per-language specialization, primarily for visual display of values and names, among others; and (3) versatile APIs and support services for implementing many kinds of tools without VM modification. Knowledge: It is now possible for a client in a production environment to insert (dynamically, with thread safety) an instrumentation probe that captures and reports abstractly specified execution events. A probe in fully optimized code imposes very low overhead until actually used to access (or modify) execution state. Event capture has enabled construction of numerous GraalVM services and tools that work for all implemented languages, either singly or in combination. Instrumentation has also proved valuable for implementing some traditionally tricky language features, as well as some GraalVM services such as placing bounds on resources consumed by running programs. Grounding: Tools for debugging (via multiple clients), profiling, statement counting, dynamic analysis, and others are now part of GraalVM or are in active development. Third parties have also used Truffle Instrumentation for innovative tool implementations. Importance: Experience with Truffle Instrumentation validates the notion that addressing developer tools support as a forethought can change expectations about the availability of practical, efficient tools for high-performance languages. Tool development becomes a natural part of language implementation, requiring little additional effort and offering the advantage of early and continuous availability.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。