Content deleted Content added
#suggestededit-add 1.0 Tags: Mobile edit Mobile app edit Android app edit |
m Disambiguating links to SUSE (link changed to SUSE S.A.) using DisamAssist. |
||
(6 intermediate revisions by 5 users not shown) | |||
Line 5:
== Introduction ==
Any running program can be thought of a [[tuple]] <math>(\delta, P)</math>, where <math>\delta</math> is the current program state and <math>P</math> is the current program code. Dynamic software updating systems transform a running program <math>(\delta, P)</math> to a new version <math>(\delta', P')</math>. In order to do this, the state must be transformed into the representation <math>P'</math> expects. This requires a ''state transformer'' function. Thus, DSU transforms a program <math>(\delta, P)</math> to <math>(S (\delta), P')</math>. An update is considered '''valid''' if and only if the running program <math>(S (\delta), P')</math> can be reduced to a point tuple <math>(\delta, P')</math> that is reachable from the starting point of the new version of the program, {{nobr|1=<math>(\delta_{init}, P')</math>.<ref name="gupta">{{cite journal
| author-last1 = Gupta | author-first1 = Deepak
| author-last2 = Jalote | author-first2 = Pankaj
Line 17:
| url-status = dead
| year = 1996 | doi = 10.1109/32.485222
}}</ref>}}
The ___location in a program where a dynamic update occurs is referred to as an '''update point'''. Existing DSU implementations vary widely in their treatment of update points. In some systems, such as [[#UpStare|UpStare]] and [[#PoLUS|PoLUS]], an update can occur at any time during execution. [[#Ginseng|Ginseng]]'s compiler will attempt to infer good locations for update points, but can also use programmer-specified update points. [[#Kitsune and Ekiden|Kitsune and Ekiden]] require developers to manually specify and name all update points.
Line 30:
The problem space addressed by dynamic updating can be thought of as an intersection of several others. Examples include [[checkpointing]], [[dynamic linking]], and [[Persistence (computer science)|persistence]]. As an example, a database that must be [[backward-compatible]] with previous versions of its on-disk file format, must accomplish the same type of state transformation expected of a dynamic updating system. Likewise, a program that has a plugin architecture, must be able to load and execute new code at runtime.
Similar techniques are sometimes also employed for the purpose of [[dynamic dead-code elimination]] to remove conditionally [[dead code|dead]] or [[unreachable code]] at load or runtime, and recombine the remaining code to minimize its [[memory footprint]] or improve speed.<ref name="Paul_1997_FreeKEYB">{{citation
| title = FreeKEYB - Enhanced DOS keyboard and console driver
| edition = v6.5
Line 37:
| type = User Manual
| date = 1997-10-13 | orig-year = first published 1991
}} [https://web.archive.org/web/20190309194320/http://sta.c64.org/dosprg/fk657p1.zip<!-- FreeKEYB 6.57p1 Beta as of 2004-08-17 with outdated and incomplete documentation -->] (NB. The K3PLUS successor FreeKEYB is a fully reconfigurable driver with many dynamically loadable special features. It implements a unique form of byte-level granular [[dynamic dead code elimination]] and [[relocation (computing)|relocation]] techniques at [[load-time]] as well as [[self-modifying code]] and reconfigurability at [[runtime (computing)|run-time]] to minimize its memory footprint close to the [[canonical form]] depending on the hardware, operating system, other environment and driver configuration as well as the selected feature set and locale (about sixty configuration switches with hundreds of options for an almost unlimited number of possible combinations). The build process utilizes a [[macro assembler]] as well as a framework of automatic pre- and post-processing tools analyzing the temporary binaries to generate dependency and [[code morphing]] [[meta data]] to be embedded into the resulting [[executable file]] alongside the [[binary code]] and a self-discarding, [[instruction relaxation|relaxing]] and [[relocating loader]] to dynamically (re)combine, (over)load, modify, update or unload the runtime image (code and data) of the driver as requested. The complexity is hidden in a single self-contained file so that for a user the handling is the same as for a normal (semi-)monolithic driver/[[
| title = FreeKEYB - Advanced international DOS keyboard and console driver
| edition = v7 preliminary
Line 154:
{{Category see also|Linux kernel live patching}}
[[Ksplice]] is a DSU system that targets only the [[Linux kernel]], making itself one of the specialized DSU systems that support an [[operating system kernel]] as the target program. Ksplice uses source-level [[diff]]s to determine changes between current and updated versions of the Linux kernel, and then uses binary rewriting to insert the changes into the running kernel.<ref name="ksplice">{{cite book
| title = Ksplice: automatic rebootless kernel updates▼
| author-first1 = Jeff | author-last1 = Arnold
| author-first2 = M. Frans | author-last2 = Kaashoek | author-link2 = Frans Kaashoek
|
| year = 2009
▲ | journal = Proceedings of the 4th ACM European Conference on Computer Systems
▲ | pages = 187 | doi = 10.1145/1519065.1519085
| hdl = 1721.1/51698 | url = https://www.ksplice.com/doc/ksplice.pdf
| isbn = 9781605584829 | s2cid = 7720018 }}</ref> Ksplice was maintained by a commercial venture founded by its original authors, Ksplice Inc., which was acquired by [[Oracle Corporation]] in July 2011.<ref>{{cite news
| url = http://www.oracle.com/us/corporate/Acquisitions/ksplice/index.html
| title = Oracle and Ksplice
Line 172:
}}</ref>
[[SUSE S.A.|SUSE]] developed [[kGraft]] as an open-source alternative for live kernel patching, and [[Red Hat]] did likewise with [[kpatch]]. They both allow function-level changes to be applied to a running Linux kernel, while relying on live patching mechanisms established by [[ftrace]]. The primary difference between kGraft and kpatch is the way they ensure runtime consistency of the updated code sections while [[hot patch]]es are applied. kGraft and kpatch were submitted for inclusion into the [[Linux kernel mainline]] in April 2014 and May 2014, respectively,<ref name="lwn-597123">{{cite web
| url = https://lwn.net/Articles/597123/
| title = kpatch: dynamic kernel patching
|