警官:一个很棒但错误的主意

Y. Klimiankou
{"title":"警官:一个很棒但错误的主意","authors":"Y. Klimiankou","doi":"10.1109/ISPRAS47671.2019.00007","DOIUrl":null,"url":null,"abstract":"The introduction of the \"constexpr\" feature in the C++11 standard has raised a great interest in the compile-time function execution in the programming languages communities. In this paper, we evaluate this feature and argue that while the compile-time evaluations are valuable optimization methods, its explicit support on the level of a programming language is a wrong decision. We show that compile-time evaluations must be enforced by the compiler automatically and transparently to the developer. Finally, we propose a programming language design principle stating that positive optimization \"hints\" must not be a part of programming language.","PeriodicalId":154688,"journal":{"name":"2019 Ivannikov Ispras Open Conference (ISPRAS)","volume":"30 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2019-12-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"Constexpr: A Great Good but Wrong Idea\",\"authors\":\"Y. Klimiankou\",\"doi\":\"10.1109/ISPRAS47671.2019.00007\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"The introduction of the \\\"constexpr\\\" feature in the C++11 standard has raised a great interest in the compile-time function execution in the programming languages communities. In this paper, we evaluate this feature and argue that while the compile-time evaluations are valuable optimization methods, its explicit support on the level of a programming language is a wrong decision. We show that compile-time evaluations must be enforced by the compiler automatically and transparently to the developer. Finally, we propose a programming language design principle stating that positive optimization \\\"hints\\\" must not be a part of programming language.\",\"PeriodicalId\":154688,\"journal\":{\"name\":\"2019 Ivannikov Ispras Open Conference (ISPRAS)\",\"volume\":\"30 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2019-12-01\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"2019 Ivannikov Ispras Open Conference (ISPRAS)\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1109/ISPRAS47671.2019.00007\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"2019 Ivannikov Ispras Open Conference (ISPRAS)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/ISPRAS47671.2019.00007","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

摘要

c++ 11标准中引入的“constexpr”特性引起了编程语言社区对编译时函数执行的极大兴趣。在本文中,我们评估了这一特性,并认为尽管编译时求值是有价值的优化方法,但在编程语言层面上对其的显式支持是一个错误的决定。我们说明编译时计算必须由编译器自动执行,并且对开发人员是透明的。最后,我们提出了一个编程语言设计原则,即积极的优化“提示”不能成为编程语言的一部分。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
Constexpr: A Great Good but Wrong Idea
The introduction of the "constexpr" feature in the C++11 standard has raised a great interest in the compile-time function execution in the programming languages communities. In this paper, we evaluate this feature and argue that while the compile-time evaluations are valuable optimization methods, its explicit support on the level of a programming language is a wrong decision. We show that compile-time evaluations must be enforced by the compiler automatically and transparently to the developer. Finally, we propose a programming language design principle stating that positive optimization "hints" must not be a part of programming language.
求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
自引率
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学术文献互助群
群 号:481959085
Book学术官方微信