{"title":"X10中的控制结构过载","authors":"Louis Mandel, Josh Milthorpe, O. Tardieu","doi":"10.1145/2931028.2931032","DOIUrl":null,"url":null,"abstract":"The X10 programming language offers a simple but expressive model of concurrency and distribution. Domain Specific Languages embedded in X10 (eDSL) can build upon this model to offer scheduling and placement facilities tailored to particular patterns of applications, e.g. stencils or graph traversals. They exploit X10's rich type system and closures to offer flexible and precise functional interfaces, however, they are restricted by X10's rigid syntax. In this work, we propose an overloading mechanism enabling eDSLs to redefine or extend the behavior of X10 control structures. Loops can be parallelized or distributed. Exception handlers can triage and process exceptions arising from concurrent tasks. While our overloading mechanism requires augmenting the X10 syntax with new forms, the change to the syntax is small and intuitive. Overall, the combination of syntax and semantics we propose improves code readability over traditional X10 at no cost in run time performance.","PeriodicalId":229668,"journal":{"name":"Proceedings of the 6th ACM SIGPLAN Workshop on X10","volume":"1 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2016-06-02","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"1","resultStr":"{\"title\":\"Control structure overloading in X10\",\"authors\":\"Louis Mandel, Josh Milthorpe, O. Tardieu\",\"doi\":\"10.1145/2931028.2931032\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"The X10 programming language offers a simple but expressive model of concurrency and distribution. Domain Specific Languages embedded in X10 (eDSL) can build upon this model to offer scheduling and placement facilities tailored to particular patterns of applications, e.g. stencils or graph traversals. They exploit X10's rich type system and closures to offer flexible and precise functional interfaces, however, they are restricted by X10's rigid syntax. In this work, we propose an overloading mechanism enabling eDSLs to redefine or extend the behavior of X10 control structures. Loops can be parallelized or distributed. Exception handlers can triage and process exceptions arising from concurrent tasks. While our overloading mechanism requires augmenting the X10 syntax with new forms, the change to the syntax is small and intuitive. Overall, the combination of syntax and semantics we propose improves code readability over traditional X10 at no cost in run time performance.\",\"PeriodicalId\":229668,\"journal\":{\"name\":\"Proceedings of the 6th ACM SIGPLAN Workshop on X10\",\"volume\":\"1 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2016-06-02\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"1\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Proceedings of the 6th ACM SIGPLAN Workshop on X10\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1145/2931028.2931032\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 6th ACM SIGPLAN Workshop on X10","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/2931028.2931032","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 1
摘要
X10编程语言提供了一个简单但具有表现力的并发性和分布模型。嵌入在X10中的领域特定语言(Domain Specific Languages, eDSL)可以建立在这个模型的基础上,为应用程序的特定模式(例如模板或图遍历)提供量身定制的调度和放置工具。它们利用X10丰富的类型系统和闭包来提供灵活和精确的功能接口,但是,它们受到X10严格语法的限制。在这项工作中,我们提出了一种重载机制,使edsl能够重新定义或扩展X10控制结构的行为。循环可以并行化,也可以分布式。异常处理程序可以对并发任务产生的异常进行分类和处理。虽然我们的重载机制需要使用新表单来扩展X10语法,但对语法的更改很小且直观。总的来说,我们提出的语法和语义的组合比传统的X10提高了代码的可读性,而没有以运行时性能为代价。
The X10 programming language offers a simple but expressive model of concurrency and distribution. Domain Specific Languages embedded in X10 (eDSL) can build upon this model to offer scheduling and placement facilities tailored to particular patterns of applications, e.g. stencils or graph traversals. They exploit X10's rich type system and closures to offer flexible and precise functional interfaces, however, they are restricted by X10's rigid syntax. In this work, we propose an overloading mechanism enabling eDSLs to redefine or extend the behavior of X10 control structures. Loops can be parallelized or distributed. Exception handlers can triage and process exceptions arising from concurrent tasks. While our overloading mechanism requires augmenting the X10 syntax with new forms, the change to the syntax is small and intuitive. Overall, the combination of syntax and semantics we propose improves code readability over traditional X10 at no cost in run time performance.