首页 > 最新文献

Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages最新文献

英文 中文
Garbage collection and efficiency in dynamic metacircular runtimes: an experience report 动态元循环运行时的垃圾收集和效率:一份经验报告
Javier Pimás, Javier Burroni, Jean-Baptiste Arnaud, Stefan Marr
In dynamic object-oriented languages, low-level mechanisms such as just-in-time compilation, object allocation, garbage collection (GC) and method dispatch are often handled by virtual machines (VMs). VMs are typically implemented using static languages, allowing only few changes at run time. In such systems, the VM is not part of the language and interfaces to memory management or method dispatch are fixed, not allowing for arbitrary adaptation. Furthermore, the implementation can typically not be inspected or debugged with standard tools used to work on application code. This paper reports on our experience building Bee, a dynamic Smalltalk runtime, written in Smalltalk. Bee is a Dynamic Metacircular Runtime (DMR) and seamlessly integrates the VM into the application and thereby overcomes many restrictions of classic VMs, for instance by allowing arbitrary code modifications of the VM at run time. Furthermore, the approach enables developers to use their standard tools for application code also for the VM, allowing them to inspect, debug, understand, and modify a DMR seamlessly. We detail our experience of implementing GC, compilation, and optimizations in a DMR. We discuss examples where we found that DMRs can improve understanding of the system, provide tighter control of the software stack, and facilitate research. We also show that the Bee DMR matches and surpass the performance of a widely used Smalltalk VM.
在动态面向对象语言中,诸如即时编译、对象分配、垃圾收集(GC)和方法调度等低级机制通常由虚拟机(vm)处理。虚拟机通常使用静态语言实现,只允许在运行时进行少量更改。在这样的系统中,VM不是语言的一部分,并且内存管理或方法分派的接口是固定的,不允许任意调整。此外,通常无法使用用于处理应用程序代码的标准工具检查或调试实现。本文报告了我们构建Bee的经验,Bee是一个用Smalltalk编写的动态Smalltalk运行时。Bee是一个动态元循环运行时(DMR),它无缝地将VM集成到应用程序中,从而克服了传统VM的许多限制,例如允许在运行时对VM进行任意代码修改。此外,该方法使开发人员能够将他们的标准工具用于应用程序代码,也用于VM,从而允许他们无缝地检查、调试、理解和修改DMR。我们详细介绍了在DMR中实现GC、编译和优化的经验。我们讨论了一些例子,在这些例子中,我们发现dmr可以提高对系统的理解,提供对软件堆栈的更严格控制,并促进研究。我们还表明,Bee DMR匹配并超过了广泛使用的Smalltalk虚拟机的性能。
{"title":"Garbage collection and efficiency in dynamic metacircular runtimes: an experience report","authors":"Javier Pimás, Javier Burroni, Jean-Baptiste Arnaud, Stefan Marr","doi":"10.1145/3133841.3133845","DOIUrl":"https://doi.org/10.1145/3133841.3133845","url":null,"abstract":"In dynamic object-oriented languages, low-level mechanisms such as just-in-time compilation, object allocation, garbage collection (GC) and method dispatch are often handled by virtual machines (VMs). VMs are typically implemented using static languages, allowing only few changes at run time. In such systems, the VM is not part of the language and interfaces to memory management or method dispatch are fixed, not allowing for arbitrary adaptation. Furthermore, the implementation can typically not be inspected or debugged with standard tools used to work on application code. This paper reports on our experience building Bee, a dynamic Smalltalk runtime, written in Smalltalk. Bee is a Dynamic Metacircular Runtime (DMR) and seamlessly integrates the VM into the application and thereby overcomes many restrictions of classic VMs, for instance by allowing arbitrary code modifications of the VM at run time. Furthermore, the approach enables developers to use their standard tools for application code also for the VM, allowing them to inspect, debug, understand, and modify a DMR seamlessly. We detail our experience of implementing GC, compilation, and optimizations in a DMR. We discuss examples where we found that DMRs can improve understanding of the system, provide tighter control of the software stack, and facilitate research. We also show that the Bee DMR matches and surpass the performance of a widely used Smalltalk VM.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"94 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"122404299","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
The semantics of name resolution in grace 名称解析的语义是优雅的
V. Vergu, Michiel Haisma, E. Visser
Grace is a dynamic object oriented programming language designed to aid programming education. We present a formal model of and give an operational semantics for its object model and name resolution algorithm. Our main contributions are a systematic model of Grace’s name resolution using scope graphs, relating linguistic features to other languages, and an operationalization of this model in the form of an operational semantics which is readable and executable. The semantics are extensively tested against a reference Grace implementation.
Grace是一种动态的面向对象编程语言,旨在帮助编程教育。我们给出了一个形式化模型,并给出了其对象模型的操作语义和名称解析算法。我们的主要贡献是一个使用作用域图的Grace名称解析的系统模型,将语言特征与其他语言联系起来,并以可读和可执行的操作语义的形式将该模型进行操作化。针对参考Grace实现对语义进行了广泛的测试。
{"title":"The semantics of name resolution in grace","authors":"V. Vergu, Michiel Haisma, E. Visser","doi":"10.1145/3133841.3133847","DOIUrl":"https://doi.org/10.1145/3133841.3133847","url":null,"abstract":"Grace is a dynamic object oriented programming language designed to aid programming education. We present a formal model of and give an operational semantics for its object model and name resolution algorithm. Our main contributions are a systematic model of Grace’s name resolution using scope graphs, relating linguistic features to other languages, and an operationalization of this model in the form of an operational semantics which is readable and executable. The semantics are extensively tested against a reference Grace implementation.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"1 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"128798141","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 1
Object equivalence: revisiting object equality profiling (an experience report) 对象等价:重新访问对象等价分析(一份经验报告)
A. Infante, Alexandre Bergel
Modern object-oriented programming languages greatly alleviate the memory management for programmers. Despite the efficiency of garbage collection and Just-In-Time program analyzes, memory still remains prone to be wasted. A bloated memory may have severe consequences, including frequent execution lags due to a high pressure on the garbage collector and suboptimal object dependencies. We found that dynamically monitoring object production sites and the equivalence of the produced objects is key to identify wasted memory consumption caused by redundant objects. We implemented optimizations for reducing the memory consumption of six applications, achieving a reduction over 40% in half of the applications without having any prior knowledge of these applications. Our results partially replicate the results obtained by Marinov and O'Callahan and explore new ways to identify redundant objects.
现代面向对象编程语言极大地减轻了程序员的内存管理。尽管垃圾收集和实时程序分析效率很高,但内存仍然容易被浪费。膨胀的内存可能会产生严重的后果,包括由于垃圾收集器的高压力和次优对象依赖关系而导致的频繁执行延迟。我们发现动态监控对象的生产站点和生产对象的等价性是识别冗余对象造成的内存浪费的关键。我们实现了减少6个应用程序内存消耗的优化,在没有事先了解这些应用程序的情况下,在一半的应用程序中实现了超过40%的内存消耗减少。我们的结果部分复制了Marinov和O'Callahan的结果,并探索了识别冗余物体的新方法。
{"title":"Object equivalence: revisiting object equality profiling (an experience report)","authors":"A. Infante, Alexandre Bergel","doi":"10.1145/3133841.3133844","DOIUrl":"https://doi.org/10.1145/3133841.3133844","url":null,"abstract":"Modern object-oriented programming languages greatly alleviate the memory management for programmers. Despite the efficiency of garbage collection and Just-In-Time program analyzes, memory still remains prone to be wasted. A bloated memory may have severe consequences, including frequent execution lags due to a high pressure on the garbage collector and suboptimal object dependencies. We found that dynamically monitoring object production sites and the equivalence of the produced objects is key to identify wasted memory consumption caused by redundant objects. We implemented optimizations for reducing the memory consumption of six applications, achieving a reduction over 40% in half of the applications without having any prior knowledge of these applications. Our results partially replicate the results obtained by Marinov and O'Callahan and explore new ways to identify redundant objects.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"52 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"121928291","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 8
Challenges and progress toward efficient gradual typing (invited talk) 高效渐进式打字的挑战与进展(特邀演讲)
Jeremy G. Siek
Mixing static and dynamic type checking in the same language is catching on, with the TypeScript and Flow variants of JavaScript, the MyPy and Reticulated variants of Python, the Strongtalk and Gradualtalk variants of Smalltalk, as well as Typed Racket, Typed Clojure, and Perl 6. The gradual typing approach to such mixing seeks to protect the statically typed code from the dynamically typed code, allowing compilers to leverage type information when optimizing the static code. Unfortunately, ensuring soundness requires runtime checking at the boundaries of typed and untyped code, and the cost of this checking can drown out the performance benefits of optimization. For example, in Typed Racket, some partially typed programs are 1000X slower than the untyped or fully typed version of the same program. But all is not lost! In this talk I present the results of ongoing research to tame the runtime overheads of gradual typing in the context of a prototype compiler, named Grift, that we are developing at Indiana University.
在同一种语言中混合静态和动态类型检查正在流行起来,JavaScript的TypeScript和Flow变体,Python的MyPy和Reticulated变体,Smalltalk的Strongtalk和Gradualtalk变体,以及Typed Racket, Typed Clojure和Perl 6。这种混合的渐进类型方法旨在保护静态类型代码不受动态类型代码的影响,从而允许编译器在优化静态代码时利用类型信息。不幸的是,确保可靠性需要在类型化和非类型化代码的边界上进行运行时检查,而这种检查的成本可能会淹没优化带来的性能好处。例如,在Typed Racket中,一些部分类型化的程序比相同程序的无类型化或完全类型化版本慢1000倍。但并不是一切都完了!在这次演讲中,我将展示一项正在进行的研究的结果,该研究是在一个名为Grift的原型编译器的背景下,控制渐进式输入的运行时开销。这是我们在印第安纳大学开发的。
{"title":"Challenges and progress toward efficient gradual typing (invited talk)","authors":"Jeremy G. Siek","doi":"10.1145/3133841.3148570","DOIUrl":"https://doi.org/10.1145/3133841.3148570","url":null,"abstract":"Mixing static and dynamic type checking in the same language is catching on, with the TypeScript and Flow variants of JavaScript, the MyPy and Reticulated variants of Python, the Strongtalk and Gradualtalk variants of Smalltalk, as well as Typed Racket, Typed Clojure, and Perl 6. The gradual typing approach to such mixing seeks to protect the statically typed code from the dynamically typed code, allowing compilers to leverage type information when optimizing the static code. Unfortunately, ensuring soundness requires runtime checking at the boundaries of typed and untyped code, and the cost of this checking can drown out the performance benefits of optimization. For example, in Typed Racket, some partially typed programs are 1000X slower than the untyped or fully typed version of the same program. But all is not lost! In this talk I present the results of ongoing research to tame the runtime overheads of gradual typing in the context of a prototype compiler, named Grift, that we are developing at Indiana University.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"19 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"123007767","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 2
Semantics of asynchronous JavaScript 异步JavaScript的语义
Matthew C. Loring, Mark Marron, Daan Leijen
JavaScript code running in the Node.js runtime is a major platform for developers building cloud, mobile, or IoT applications. A fundamental concept in Node.js programming is the use of asynchronous callbacks and event loops to provide highly responsive applications. While conceptually simple, this programming model contains numerous subtleties and behaviors that are defined implicitly by the current Node.js implementation. This paper presents the first comprehensive formalization of the Node.js asynchronous execution model and defines a high-level notion of async-contexts to formalize fundamental relationships between asynchronous executions in an application. These formalizations provide a foundation for the construction of static or dynamic program analysis tools, support the exploration of alternative Node.js event loop implementations, and provide a high-level conceptual framework for reasoning about relationships between the execution of asynchronous callbacks in a Node.js application.
在Node.js运行时中运行的JavaScript代码是开发人员构建云、移动或物联网应用程序的主要平台。Node.js编程的一个基本概念是使用异步回调和事件循环来提供高响应的应用程序。虽然这个编程模型在概念上很简单,但它包含了许多由当前Node.js实现隐式定义的微妙之处和行为。本文提出了Node.js异步执行模型的第一个全面形式化,并定义了异步上下文的高级概念,以形式化应用程序中异步执行之间的基本关系。这些形式化为构建静态或动态程序分析工具提供了基础,支持探索可选的Node.js事件循环实现,并为推理Node.js应用程序中异步回调执行之间的关系提供了高级概念框架。
{"title":"Semantics of asynchronous JavaScript","authors":"Matthew C. Loring, Mark Marron, Daan Leijen","doi":"10.1145/3133841.3133846","DOIUrl":"https://doi.org/10.1145/3133841.3133846","url":null,"abstract":"JavaScript code running in the Node.js runtime is a major platform for developers building cloud, mobile, or IoT applications. A fundamental concept in Node.js programming is the use of asynchronous callbacks and event loops to provide highly responsive applications. While conceptually simple, this programming model contains numerous subtleties and behaviors that are defined implicitly by the current Node.js implementation. This paper presents the first comprehensive formalization of the Node.js asynchronous execution model and defines a high-level notion of async-contexts to formalize fundamental relationships between asynchronous executions in an application. These formalizations provide a foundation for the construction of static or dynamic program analysis tools, support the exploration of alternative Node.js event loop implementations, and provide a high-level conceptual framework for reasoning about relationships between the execution of asynchronous callbacks in a Node.js application.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"248 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"129024435","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 29
The JavaScriptCore virtual machine (invited talk) JavaScriptCore虚拟机(特邀演讲)
F. Pizlo
JavaScriptCore (JSC) is an open-source high-performance implementation of JavaScript. JSC is used in the WebKit open source browser engine as well as a system framework on macOS and iOS. This talk will give a broad high-level overview of JSC’s performance-oriented architecture, including specific details about the object model, garbage collector, optimizing compilers, type inference, and deoptimization.
JavaScriptCore (JSC)是JavaScript的一个开源高性能实现。JSC用于WebKit开源浏览器引擎以及macOS和iOS上的系统框架。本讲座将对JSC面向性能的体系结构进行全面的概述,包括对象模型、垃圾收集器、优化编译器、类型推断和反优化的具体细节。
{"title":"The JavaScriptCore virtual machine (invited talk)","authors":"F. Pizlo","doi":"10.1145/3170472.3148567","DOIUrl":"https://doi.org/10.1145/3170472.3148567","url":null,"abstract":"JavaScriptCore (JSC) is an open-source high-performance implementation of JavaScript. JSC is used in the WebKit open source browser engine as well as a system framework on macOS and iOS. This talk will give a broad high-level overview of JSC’s performance-oriented architecture, including specific details about the object model, garbage collector, optimizing compilers, type inference, and deoptimization.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"358 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"122813051","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 1
Dynamic atomicity: optimizing swift memory management 动态原子性:优化快速内存管理
D. Ungar, D. Grove, H. Franke
Swift is a modern multi-paradigm programming language with an extensive developer community and open source ecosystem. Swift 3's memory management strategy is based on Automatic Reference Counting (ARC) augmented with unsafe APIs for manually-managed memory. We have seen ARC consume as much as 80% of program execution time. A significant portion of ARC's direct performance cost can be attributed to its use of atomic machine instructions to protect reference count updates from data races. Consequently, we have designed and implemented dynamic atomicity, an optimization which safely replaces atomic reference-counting operations with nonatomic ones where feasible. The optimization introduces a store barrier to detect possibly intra-thread references, compiler-generated recursive reference-tracers to find all affected objects, and a bit of state in each reference count to encode its atomicity requirements. Using a suite of 171 microbenchmarks, 9 programs from the Computer Language Benchmarks Game, and the Richards benchmark, we performed a limit study by unsafely making all reference counting operations nonatomic. We measured potential speedups of up to 220% on the microbenchmarks, 120% on the Benchmarks Game and 70% on Richards. By automatically reducing ARC overhead, our optimization both improves Swift 3's performance and reduces the temptation for performance-oriented programmers to resort to unsafe manual memory management. Furthermore, the machinery implemented for dynamic atomicity could also be employed to obtain cheaper thread-safe Swift data structures, or to augment ARC with optional cycle detection or a backup tracing garbage collector.
Swift是一种现代多范式编程语言,拥有广泛的开发者社区和开源生态系统。Swift 3的内存管理策略基于自动引用计数(ARC),增加了用于手动管理内存的不安全api。我们已经看到ARC消耗了多达80%的程序执行时间。ARC的直接性能成本的很大一部分可以归因于它使用原子机器指令来保护引用计数更新免受数据竞争的影响。因此,我们设计并实现了动态原子性,这种优化可以在可行的情况下安全地用非原子引用计数操作替换原子引用计数操作。该优化引入了一个存储屏障来检测可能的线程内引用,引入了编译器生成的递归引用跟踪器来查找所有受影响的对象,并在每个引用计数中引入了一些状态来编码其原子性需求。使用一组171个微基准测试、计算机语言基准测试游戏中的9个程序和Richards基准测试,我们通过不安全地将所有引用计数操作设置为非原子操作来执行极限研究。我们在微基准测试中测量了高达220%的潜在加速,在基准游戏中测量了120%,在Richards中测量了70%。通过自动减少ARC开销,我们的优化既提高了Swift 3的性能,又减少了面向性能的程序员诉诸不安全的手动内存管理的诱惑。此外,为动态原子性实现的机制还可以用于获得更便宜的线程安全Swift数据结构,或者通过可选的周期检测或备份跟踪垃圾收集器来增强ARC。
{"title":"Dynamic atomicity: optimizing swift memory management","authors":"D. Ungar, D. Grove, H. Franke","doi":"10.1145/3133841.3133843","DOIUrl":"https://doi.org/10.1145/3133841.3133843","url":null,"abstract":"Swift is a modern multi-paradigm programming language with an extensive developer community and open source ecosystem. Swift 3's memory management strategy is based on Automatic Reference Counting (ARC) augmented with unsafe APIs for manually-managed memory. We have seen ARC consume as much as 80% of program execution time. A significant portion of ARC's direct performance cost can be attributed to its use of atomic machine instructions to protect reference count updates from data races. Consequently, we have designed and implemented dynamic atomicity, an optimization which safely replaces atomic reference-counting operations with nonatomic ones where feasible. The optimization introduces a store barrier to detect possibly intra-thread references, compiler-generated recursive reference-tracers to find all affected objects, and a bit of state in each reference count to encode its atomicity requirements. Using a suite of 171 microbenchmarks, 9 programs from the Computer Language Benchmarks Game, and the Richards benchmark, we performed a limit study by unsafely making all reference counting operations nonatomic. We measured potential speedups of up to 220% on the microbenchmarks, 120% on the Benchmarks Game and 70% on Richards. By automatically reducing ARC overhead, our optimization both improves Swift 3's performance and reduces the temptation for performance-oriented programmers to resort to unsafe manual memory management. Furthermore, the machinery implemented for dynamic atomicity could also be employed to obtain cheaper thread-safe Swift data structures, or to augment ARC with optional cycle detection or a backup tracing garbage collector.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"5 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"122050049","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 6
Decoding Lua: formal semantics for the developer and the semanticist 解码Lua:面向开发人员和语义学家的形式语义
Mallku Soldevila, Beta Ziliani, Bruno Silvestre, Daniel Fridlender, Fabio Mascarenhas
We provide formal semantics for a large subset of the Lua programming language, in its version 5.2. We validate our model by mechanizing it and testing it against the test suite of the reference interpreter of Lua, obtaining evidence that our model accurately represents the language. We target both a PL semanticist "not necessarily versed in Lua", and a Lua developer - not necessarily versed in semantic frameworks. To the former, we present the peculiarities of the language, and how we model them in a modular small-step operational semantics, using concepts from Felleisen-Hieb's reduction semantics with evaluation contexts. Moreover, we mechanize and test the model in PLT Redex, the de facto tool for reduction semantics. To the reader unfamiliar with such concepts, we provide a gentle introduction to the model. It is our hope that developers of the different Lua implementations and dialects understand the model and consider it both for testing their work and for experimenting with new language features.
我们在Lua编程语言的5.2版中为它的一个大子集提供了形式化语义。我们通过机械化模型并针对Lua参考解释器的测试套件对其进行测试来验证我们的模型,从而获得我们的模型准确地表示该语言的证据。我们的目标是PL语义学家(不一定精通Lua)和Lua开发人员(不一定精通语义框架)。对于前者,我们介绍了语言的特点,以及我们如何使用来自Felleisen-Hieb的具有评估上下文的约简语义的概念,在模块化的小步骤操作语义中对它们进行建模。此外,我们在PLT Redex中机械化并测试了该模型,PLT Redex是语义还原的实际工具。对于不熟悉这些概念的读者,我们将对该模型进行简单介绍。我们希望使用不同Lua实现和方言的开发人员能够理解这个模型,并将其用于测试他们的工作和试验新的语言特性。
{"title":"Decoding Lua: formal semantics for the developer and the semanticist","authors":"Mallku Soldevila, Beta Ziliani, Bruno Silvestre, Daniel Fridlender, Fabio Mascarenhas","doi":"10.1145/3133841.3133848","DOIUrl":"https://doi.org/10.1145/3133841.3133848","url":null,"abstract":"We provide formal semantics for a large subset of the Lua programming language, in its version 5.2. We validate our model by mechanizing it and testing it against the test suite of the reference interpreter of Lua, obtaining evidence that our model accurately represents the language. We target both a PL semanticist \"not necessarily versed in Lua\", and a Lua developer - not necessarily versed in semantic frameworks. To the former, we present the peculiarities of the language, and how we model them in a modular small-step operational semantics, using concepts from Felleisen-Hieb's reduction semantics with evaluation contexts. Moreover, we mechanize and test the model in PLT Redex, the de facto tool for reduction semantics. To the reader unfamiliar with such concepts, we provide a gentle introduction to the model. It is our hope that developers of the different Lua implementations and dialects understand the model and consider it both for testing their work and for experimenting with new language features.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"151 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-06-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"122919792","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 8
A concurrency-agnostic protocol for multi-paradigm concurrent debugging tools 多范式并发调试工具的并发不可知协议
Stefan Marr, Carmen Torres Lopez, Dominik Aumayr, E. G. Boix, H. Mössenböck
Today's complex software systems combine high-level concurrency models. Each model is used to solve a specific set of problems. Unfortunately, debuggers support only the low-level notions of threads and shared memory, forcing developers to reason about these notions instead of the high-level concurrency models they chose. This paper proposes a concurrency-agnostic debugger protocol that decouples the debugger from the concurrency models employed by the target application. As a result, the underlying language runtime can define custom breakpoints, stepping operations, and execution events for each concurrency model it supports, and a debugger can expose them without having to be specifically adapted. We evaluated the generality of the protocol by applying it to SOMns, a Newspeak implementation, which supports a diversity of concurrency models including communicating sequential processes, communicating event loops, threads and locks, fork/join parallelism, and software transactional memory. We implemented 21 breakpoints and 20 stepping operations for these concurrency models. For none of these, the debugger needed to be changed. Furthermore, we visualize all concurrent interactions independently of a specific concurrency model. To show that tooling for a specific concurrency model is possible, we visualize actor turns and message sends separately.
今天的复杂软件系统结合了高级并发模型。每个模型都用于解决一组特定的问题。不幸的是,调试器只支持线程和共享内存的低级概念,这迫使开发人员不得不考虑这些概念,而不是他们选择的高级并发模型。本文提出了一种与并发无关的调试器协议,该协议将调试器与目标应用程序所使用的并发模型解耦。因此,底层语言运行库可以为它所支持的每个并发模型定义自定义断点、步进操作和执行事件,调试器可以公开它们,而无需专门进行调整。我们通过将其应用于somn来评估该协议的通用性,somn是Newspeak的一种实现,它支持多种并发模型,包括通信顺序进程、通信事件循环、线程和锁、fork/join并行性和软件事务性内存。我们为这些并发模型实现了21个断点和20个步进操作。对于这些情况,都不需要更改调试器。此外,我们将独立于特定并发模型的所有并发交互可视化。为了显示特定并发模型的工具是可能的,我们将参与者的轮换和消息发送分别可视化。
{"title":"A concurrency-agnostic protocol for multi-paradigm concurrent debugging tools","authors":"Stefan Marr, Carmen Torres Lopez, Dominik Aumayr, E. G. Boix, H. Mössenböck","doi":"10.1145/3133841.3133842","DOIUrl":"https://doi.org/10.1145/3133841.3133842","url":null,"abstract":"Today's complex software systems combine high-level concurrency models. Each model is used to solve a specific set of problems. Unfortunately, debuggers support only the low-level notions of threads and shared memory, forcing developers to reason about these notions instead of the high-level concurrency models they chose. This paper proposes a concurrency-agnostic debugger protocol that decouples the debugger from the concurrency models employed by the target application. As a result, the underlying language runtime can define custom breakpoints, stepping operations, and execution events for each concurrency model it supports, and a debugger can expose them without having to be specifically adapted. We evaluated the generality of the protocol by applying it to SOMns, a Newspeak implementation, which supports a diversity of concurrency models including communicating sequential processes, communicating event loops, threads and locks, fork/join parallelism, and software transactional memory. We implemented 21 breakpoints and 20 stepping operations for these concurrency models. For none of these, the debugger needed to be changed. Furthermore, we visualize all concurrent interactions independently of a specific concurrency model. To show that tooling for a specific concurrency model is possible, we visualize actor turns and message sends separately.","PeriodicalId":117125,"journal":{"name":"Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages","volume":"63 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-06-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"126791565","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 14
期刊
Proceedings of the 13th ACM SIGPLAN International Symposium on on Dynamic Languages
全部 Acc. Chem. Res. ACS Applied Bio Materials ACS Appl. Electron. Mater. ACS Appl. Energy Mater. ACS Appl. Mater. Interfaces ACS Appl. Nano Mater. ACS Appl. Polym. Mater. ACS BIOMATER-SCI ENG ACS Catal. ACS Cent. Sci. ACS Chem. Biol. ACS Chemical Health & Safety ACS Chem. Neurosci. ACS Comb. Sci. ACS Earth Space Chem. ACS Energy Lett. ACS Infect. Dis. ACS Macro Lett. ACS Mater. Lett. ACS Med. Chem. Lett. ACS Nano ACS Omega ACS Photonics ACS Sens. ACS Sustainable Chem. Eng. ACS Synth. Biol. Anal. Chem. BIOCHEMISTRY-US Bioconjugate Chem. BIOMACROMOLECULES Chem. Res. Toxicol. Chem. Rev. Chem. Mater. CRYST GROWTH DES ENERG FUEL Environ. Sci. Technol. Environ. Sci. Technol. Lett. Eur. J. Inorg. Chem. IND ENG CHEM RES Inorg. Chem. J. Agric. Food. Chem. J. Chem. Eng. Data J. Chem. Educ. J. Chem. Inf. Model. J. Chem. Theory Comput. J. Med. Chem. J. Nat. Prod. J PROTEOME RES J. Am. Chem. Soc. LANGMUIR MACROMOLECULES Mol. Pharmaceutics Nano Lett. Org. Lett. ORG PROCESS RES DEV ORGANOMETALLICS J. Org. Chem. J. Phys. Chem. J. Phys. Chem. A J. Phys. Chem. B J. Phys. Chem. C J. Phys. Chem. Lett. Analyst Anal. Methods Biomater. Sci. Catal. Sci. Technol. Chem. Commun. Chem. Soc. Rev. CHEM EDUC RES PRACT CRYSTENGCOMM Dalton Trans. Energy Environ. Sci. ENVIRON SCI-NANO ENVIRON SCI-PROC IMP ENVIRON SCI-WAT RES Faraday Discuss. Food Funct. Green Chem. Inorg. Chem. Front. Integr. Biol. J. Anal. At. Spectrom. J. Mater. Chem. A J. Mater. Chem. B J. Mater. Chem. C Lab Chip Mater. Chem. Front. Mater. Horiz. MEDCHEMCOMM Metallomics Mol. Biosyst. Mol. Syst. Des. Eng. Nanoscale Nanoscale Horiz. Nat. Prod. Rep. New J. Chem. Org. Biomol. Chem. Org. Chem. Front. PHOTOCH PHOTOBIO SCI PCCP Polym. Chem.
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1