Automated Memoization for Parameter Studies Implemented in Impure Languages

Mirko Stoffers, Daniel Schemmel, Oscar Soria Dustmann, Klaus Wehrle
{"title":"Automated Memoization for Parameter Studies Implemented in Impure Languages","authors":"Mirko Stoffers, Daniel Schemmel, Oscar Soria Dustmann, Klaus Wehrle","doi":"10.1145/2901378.2901386","DOIUrl":null,"url":null,"abstract":"In computer simulations many processes are highly repetitive. These repetitions are amplified further when a parameter study is conducted where the same model is repeatedly executed with varying parameters, especially when performing multiple runs to increase statistical confidence. Inevitably, such repetitions result in the execution of identical computations, with identical code, identical input, and hence identical output. Performing computations redundantly wastes resources and the execution time of a parameter study could be reduced if the redundancies were avoided. To this end, the idea of memoization was proposed decades ago. However, until today memoization is either performed manually or automated memoization approaches are used that can only handle pure functions. This means that only the function parameters and the return value may be input and output of the function whereas side effects are not allowed. In order to expand the scope of automated memoization to a larger class of programs, we propose an approach able to reliably detect the full input and output of a function, including reading and writing objects through arbitrarily indirect pointers with some preconditions. We show the feasibility of our approach and derive simple performance approximations enabling rough predictions of the expected benefit. By means of a simple case study performing an OFDM network simulation, we demonstrate the practical suitability of our approach, speeding up the execution of the whole parameter study by a factor of 75, while only doubling memory consumption.","PeriodicalId":325258,"journal":{"name":"Proceedings of the 2016 ACM SIGSIM Conference on Principles of Advanced Discrete Simulation","volume":"96 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2016-05-15","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"7","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 2016 ACM SIGSIM Conference on Principles of Advanced Discrete Simulation","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/2901378.2901386","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 7

Abstract

In computer simulations many processes are highly repetitive. These repetitions are amplified further when a parameter study is conducted where the same model is repeatedly executed with varying parameters, especially when performing multiple runs to increase statistical confidence. Inevitably, such repetitions result in the execution of identical computations, with identical code, identical input, and hence identical output. Performing computations redundantly wastes resources and the execution time of a parameter study could be reduced if the redundancies were avoided. To this end, the idea of memoization was proposed decades ago. However, until today memoization is either performed manually or automated memoization approaches are used that can only handle pure functions. This means that only the function parameters and the return value may be input and output of the function whereas side effects are not allowed. In order to expand the scope of automated memoization to a larger class of programs, we propose an approach able to reliably detect the full input and output of a function, including reading and writing objects through arbitrarily indirect pointers with some preconditions. We show the feasibility of our approach and derive simple performance approximations enabling rough predictions of the expected benefit. By means of a simple case study performing an OFDM network simulation, we demonstrate the practical suitability of our approach, speeding up the execution of the whole parameter study by a factor of 75, while only doubling memory consumption.
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
在非纯语言中实现参数研究的自动记忆
在计算机模拟中,许多过程是高度重复的。当进行参数研究时,使用不同的参数重复执行相同的模型,特别是在执行多次运行以增加统计置信度时,这些重复会进一步放大。不可避免地,这种重复导致执行相同的计算,使用相同的代码,相同的输入,因此相同的输出。冗余计算会浪费资源,避免冗余可以减少参数研究的执行时间。为此,几十年前就提出了记忆的想法。然而,到目前为止,记忆要么是手动执行的,要么是使用只能处理纯函数的自动记忆方法。这意味着只有函数参数和返回值可以作为函数的输入和输出,而副作用是不允许的。为了将自动记忆的范围扩展到更大的程序类别,我们提出了一种能够可靠地检测函数的全部输入和输出的方法,包括通过带有一些先决条件的任意间接指针读写对象。我们展示了我们的方法的可行性,并推导了简单的性能近似值,从而可以对预期的收益进行粗略的预测。通过执行OFDM网络仿真的简单案例研究,我们证明了我们的方法的实际适用性,将整个参数研究的执行速度提高了75倍,而内存消耗仅增加了一倍。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
自引率
0.00%
发文量
0
期刊最新文献
GraphPool: A High Performance Data Management For 3D Simulations The Future of Parallel Discrete Event Simulation Knowledge Discovery for Pareto Based Multiobjective Optimization in Simulation Session details: Session on Parallel Simulation 2 Session details: Session on Parallel Simulation 1
×
引用
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