PSU: A Framework for Dynamic Software Updates in Multi-threaded C-Language Programs

Marcus Karpoff, J. N. Amaral, Kai-Ting Amy Wang, Rayson Ho, B. Dobry
{"title":"PSU: A Framework for Dynamic Software Updates in Multi-threaded C-Language Programs","authors":"Marcus Karpoff, J. N. Amaral, Kai-Ting Amy Wang, Rayson Ho, B. Dobry","doi":"10.1109/SBAC-PAD49847.2020.00040","DOIUrl":null,"url":null,"abstract":"A Dynamic Software Update (DSU) system enables an operator to modify a running program without interrupting its execution. However, creating a DSU system to allow programs written in the C programming language to be modified while they are executing is challenging. This paper presents the Portable Software Update (PSU) system, a new framework that allows the creation of C-language DSU programs. PSU offers a simple programming interface to build DSU versions of existing C programs. Once a program is built using PSU, updates can be applied by background threads that have negligible impact on the execution of the program. PSU supports multi-threaded and recursive programs without the use of safe points or thread blocking. PSU uses function indirection to redirect DSU functions calls to the newest version of the function code. Once a DSU function is invoked in a PSU program, it executes to completion using the version of the function that was active when it was invoked. However, if a new version is installed, any future calls to the same function always execute the newest version. This simple mechanism allows for quick loading of updates in PSU. PSU unloads obsolete version of DSU functions after they are no longer executing. This mechanism makes PSU the first DSU system for C-language programs that is able to unload older versions of code. This efficient use of resources enables many patches to be applied to a long-running application. A suite of specialized custom synthetic programs, and a DSU-enabled version of the MySQL database storage engine, are used to evaluate the overhead of the DSU-enabling features. The MySQL storage engine maintains over 95% of the performance of the non-DSU version and allows the entire storage engine to be updated while the database continues executing. PSU includes a simple and straightforward process for the modification of the storage engine that enables DSU.","PeriodicalId":202581,"journal":{"name":"2020 IEEE 32nd International Symposium on Computer Architecture and High Performance Computing (SBAC-PAD)","volume":"6 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2020-09-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"1","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2020 IEEE 32nd International Symposium on Computer Architecture and High Performance Computing (SBAC-PAD)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/SBAC-PAD49847.2020.00040","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 1

Abstract

A Dynamic Software Update (DSU) system enables an operator to modify a running program without interrupting its execution. However, creating a DSU system to allow programs written in the C programming language to be modified while they are executing is challenging. This paper presents the Portable Software Update (PSU) system, a new framework that allows the creation of C-language DSU programs. PSU offers a simple programming interface to build DSU versions of existing C programs. Once a program is built using PSU, updates can be applied by background threads that have negligible impact on the execution of the program. PSU supports multi-threaded and recursive programs without the use of safe points or thread blocking. PSU uses function indirection to redirect DSU functions calls to the newest version of the function code. Once a DSU function is invoked in a PSU program, it executes to completion using the version of the function that was active when it was invoked. However, if a new version is installed, any future calls to the same function always execute the newest version. This simple mechanism allows for quick loading of updates in PSU. PSU unloads obsolete version of DSU functions after they are no longer executing. This mechanism makes PSU the first DSU system for C-language programs that is able to unload older versions of code. This efficient use of resources enables many patches to be applied to a long-running application. A suite of specialized custom synthetic programs, and a DSU-enabled version of the MySQL database storage engine, are used to evaluate the overhead of the DSU-enabling features. The MySQL storage engine maintains over 95% of the performance of the non-DSU version and allows the entire storage engine to be updated while the database continues executing. PSU includes a simple and straightforward process for the modification of the storage engine that enables DSU.
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
PSU:多线程c语言程序动态软件更新框架
动态软件更新(DSU)系统使操作人员能够在不中断程序执行的情况下修改正在运行的程序。然而,创建一个DSU系统来允许用C编程语言编写的程序在执行时被修改是具有挑战性的。本文介绍了可移植软件更新系统(Portable Software Update, PSU),这是一个允许创建c语言DSU程序的新框架。PSU提供了一个简单的编程接口来构建现有C程序的DSU版本。一旦使用PSU构建了程序,就可以由对程序执行影响很小的后台线程应用更新。PSU支持多线程和递归程序,不使用安全点或线程阻塞。PSU使用函数间接将DSU函数调用重定向到最新版本的函数代码。一旦在PSU程序中调用了DSU函数,它将使用调用时活动的函数版本执行直至完成。但是,如果安装了新版本,则以后对同一函数的任何调用总是执行最新版本。这种简单的机制允许在PSU中快速加载更新。PSU卸载不再执行的DSU函数的过时版本。这种机制使PSU成为c语言程序的第一个能够卸载旧版本代码的DSU系统。这种对资源的有效利用使得可以将许多补丁应用于长时间运行的应用程序。使用一套专门定制的合成程序和支持dsu的MySQL数据库存储引擎版本来评估支持dsu的特性的开销。MySQL存储引擎保持了非dsu版本95%以上的性能,并允许在数据库继续执行的同时更新整个存储引擎。PSU包括一个简单而直接的过程,用于修改存储引擎,使DSU。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
自引率
0.00%
发文量
0
期刊最新文献
Analyzing the Loop Scheduling Mechanisms on Julia Multithreading Reliable and Energy-aware Mapping of Streaming Series-parallel Applications onto Hierarchical Platforms High-Performance Low-Memory Lowering: GEMM-based Algorithms for DNN Convolution Energy-Efficient Time Series Analysis Using Transprecision Computing On-chip Parallel Photonic Reservoir Computing using Multiple Delay Lines
×
引用
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