合理化三指令机

Sachin V. Chitnis, M. Satpathy, S. Oberoi
{"title":"合理化三指令机","authors":"Sachin V. Chitnis, M. Satpathy, S. Oberoi","doi":"10.1145/202529.202539","DOIUrl":null,"url":null,"abstract":"The declarative nature of functional programming languages causes many difficulties in their efficient implementation on conventional machines. The problem is much harder when the language has non-strict (lazy) semantics. Abstract machines serve as an intellectual aid in bridging the semantic gap between such languages and the conventional von Neumann architecture. However they become more and more complex with time as efficiency considerations force the instruction set of the machine to grow in size. In this paper we explain the phenomenon in context of the Three Instruction Machine (TIM). We then define a rationalized instruction set for TIM that allows us to view all enhancements to TIM in a uniform way. This instruction set is quite close to RISC instructions and clearly identifies the key operations on closures. Translation of functional programs to our rationalized instruction set opens up scope for various local and global optimizations. We illustrate this by showing how to build control flow graphs and perform optimizations on it. Lazy arguments in functional programs make it hard to predict evaluation order statistically. We define the notion of pseudo-lazy arguments to statically expose the control flow information, wherever possible, for doing better flow analysis.","PeriodicalId":398799,"journal":{"name":"ACM SIGPLAN Workshop on Intermediate Representations","volume":"13 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"1995-03-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"2","resultStr":"{\"title\":\"Rationalized three instruction machine\",\"authors\":\"Sachin V. Chitnis, M. Satpathy, S. Oberoi\",\"doi\":\"10.1145/202529.202539\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"The declarative nature of functional programming languages causes many difficulties in their efficient implementation on conventional machines. The problem is much harder when the language has non-strict (lazy) semantics. Abstract machines serve as an intellectual aid in bridging the semantic gap between such languages and the conventional von Neumann architecture. However they become more and more complex with time as efficiency considerations force the instruction set of the machine to grow in size. In this paper we explain the phenomenon in context of the Three Instruction Machine (TIM). We then define a rationalized instruction set for TIM that allows us to view all enhancements to TIM in a uniform way. This instruction set is quite close to RISC instructions and clearly identifies the key operations on closures. Translation of functional programs to our rationalized instruction set opens up scope for various local and global optimizations. We illustrate this by showing how to build control flow graphs and perform optimizations on it. Lazy arguments in functional programs make it hard to predict evaluation order statistically. We define the notion of pseudo-lazy arguments to statically expose the control flow information, wherever possible, for doing better flow analysis.\",\"PeriodicalId\":398799,\"journal\":{\"name\":\"ACM SIGPLAN Workshop on Intermediate Representations\",\"volume\":\"13 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"1995-03-01\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"2\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"ACM SIGPLAN Workshop on Intermediate Representations\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1145/202529.202539\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"ACM SIGPLAN Workshop on Intermediate Representations","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/202529.202539","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 2

摘要

函数式编程语言的声明性给它们在传统机器上的高效实现带来了许多困难。当语言具有非严格(惰性)语义时,这个问题要困难得多。抽象机器作为一种智力上的辅助,在这些语言和传统的冯·诺伊曼架构之间架起了语义上的桥梁。然而,随着时间的推移,由于效率的考虑迫使机器的指令集越来越大,它们变得越来越复杂。本文将在三指令机(TIM)的背景下解释这一现象。然后,我们为TIM定义了一个合理的指令集,它允许我们以统一的方式查看TIM的所有增强。该指令集非常接近RISC指令,并清楚地识别闭包上的关键操作。将函数程序转换为我们的合理指令集,为各种局部和全局优化开辟了空间。我们通过展示如何构建控制流图并对其执行优化来说明这一点。函数式程序中的惰性参数使得很难在统计上预测求值顺序。我们定义了伪惰性参数的概念,以便在可能的情况下静态地公开控制流信息,以便更好地进行流分析。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
Rationalized three instruction machine
The declarative nature of functional programming languages causes many difficulties in their efficient implementation on conventional machines. The problem is much harder when the language has non-strict (lazy) semantics. Abstract machines serve as an intellectual aid in bridging the semantic gap between such languages and the conventional von Neumann architecture. However they become more and more complex with time as efficiency considerations force the instruction set of the machine to grow in size. In this paper we explain the phenomenon in context of the Three Instruction Machine (TIM). We then define a rationalized instruction set for TIM that allows us to view all enhancements to TIM in a uniform way. This instruction set is quite close to RISC instructions and clearly identifies the key operations on closures. Translation of functional programs to our rationalized instruction set opens up scope for various local and global optimizations. We illustrate this by showing how to build control flow graphs and perform optimizations on it. Lazy arguments in functional programs make it hard to predict evaluation order statistically. We define the notion of pseudo-lazy arguments to statically expose the control flow information, wherever possible, for doing better flow analysis.
求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:604180095
Book学术官方微信