JP2005284925A - Computer system and program update method - Google Patents
Computer system and program update method Download PDFInfo
- Publication number
- JP2005284925A JP2005284925A JP2004100444A JP2004100444A JP2005284925A JP 2005284925 A JP2005284925 A JP 2005284925A JP 2004100444 A JP2004100444 A JP 2004100444A JP 2004100444 A JP2004100444 A JP 2004100444A JP 2005284925 A JP2005284925 A JP 2005284925A
- Authority
- JP
- Japan
- Prior art keywords
- function
- subroutine
- address
- memory
- program
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 70
- 230000009191 jumping Effects 0.000 claims abstract description 5
- 230000004044 response Effects 0.000 claims description 2
- 230000006870 function Effects 0.000 abstract description 172
- 230000008569 process Effects 0.000 abstract description 48
- 238000010586 diagram Methods 0.000 description 6
- 238000004891 communication Methods 0.000 description 4
- 230000008859 change Effects 0.000 description 3
- 238000001994 activation Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 101150061721 mmm1 gene Proteins 0.000 description 2
- 238000011112 process operation Methods 0.000 description 2
- 238000003860 storage Methods 0.000 description 2
- 230000004913 activation Effects 0.000 description 1
- 238000007796 conventional method Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
Images
Landscapes
- Stored Programmes (AREA)
Abstract
Description
本発明は、Linux・UNIX(登録商標)などのマルチプロセス・マルチCPU(Central Processing Unit)のOS(オペレーティングシステム)により、プログラムの実行を行うコンピュータシステムおいて、プロセスを停止することなく、実行プログラムを更新するプログラム更新方法に関するものである。 The present invention relates to an execution program without stopping a process in a computer system that executes a program by an OS (operating system) of a multi-process / multi-CPU (Central Processing Unit) such as Linux / UNIX (registered trademark). The present invention relates to a method for updating a program.
一般に、Linux・UNIX(登録商標)をOSとするコンピュータシステムは、実行中のプログラムを更新するときに、以下の手順を取る。
1)新しいプログラムをハードディスクにインストールする。
2)実行中の古いプログラムを停止する。
3)新しいプログラムを起動する。
In general, a computer system using Linux / UNIX (registered trademark) as an OS takes the following procedure when updating a running program.
1) Install a new program on the hard disk.
2) Stop the old program that is running.
3) Start a new program.
また、従来のプログラム更新方式として、特許文献「特開平7−319683号公報」に記載されるような方式がある。さらに特許文献「特開平7−152551号公報」に記載されるような方式がある。
従来のプログラム更新方式について図6〜図8を用いて説明する。図6は、従来技術によるコンピュータシステムの第1のプロセス内の構成を示す図である。図7は、従来技術によるコンピュータシステムの第2のプロセス内の構成を示す図である。図8は、従来技術によるコンピュータシステムの第3のプロセス内の構成を示す図である。図6〜図8に示されるプロセス内の構成は、スレッド15A、旧関数13、新関数14、関数追加スレッド15Bである。
Further, as a conventional program update method, there is a method as described in the patent document “Japanese Patent Laid-Open No. 7-319683”. Further, there is a system as described in the patent document “Japanese Patent Laid-Open No. 7-152551”.
A conventional program update method will be described with reference to FIGS. FIG. 6 is a diagram showing a configuration in a first process of a computer system according to the prior art. FIG. 7 is a diagram showing the configuration in the second process of the computer system according to the prior art. FIG. 8 is a diagram showing the configuration in the third process of the computer system according to the prior art. 6 to 8 are a
図6に示されるように、スレッド15Aにより呼び出される旧関数13のアドレスnnn1にある旧関数を、関数追加スレッド15Bにより呼び出される新関数14のアドレスmmm1にある新関数に置き換えるとする。特開平7−319683号公報に記載されるような方式では、図7に示されるステップS1のように旧関数13の上部の命令を、新関数14へジャンプするように書き換えることで、関数の置換えを実現している。よって、これ以後、プロセス内の全スレッドは、旧関数13のアドレスnnn2を読み込むと、新関数14の先頭アドレスへジャンプし、新関数14を呼び出すことになる。
As shown in FIG. 6, it is assumed that the old function at the address nnn1 of the
ここで、従来方式では、旧関数13の命令書き換え時に、レジスタに新関数14のアドレスを蓄積する命令(図7の旧関数13のアドレスnnn1に相当)、及びレジスタに登録されたアドレスへジャンプする命令(図7の旧関数13のアドレスnnn2に相当)の2つの命令を書き換えなければならない。一般に、CPUが一度に処理できる命令は、32ビットまたは64ビットまでであるが、2つの命令を書き換えるには、64ビット以上の命令が必要であり、同時に2つの命令を書き換えることはできない。そこで、マルチプロセッサ環境でプログラム更新を実施する場合、他プロセスが更新途中の関数を呼び出さないように、ロックする必要があり、図7に示されるステップS2のように更新途中の関数を呼び出そうとしてもロックされているため、サービス提供中のプロセスを停止させてしまう可能性がある。UNIX(登録商標)やLinuxをOSとするコンピュータシステムでは、コンテキストスイッチ(CPUが処理中のスレッドの処理をやめ、別のスレッドの処理を開始すること)の間隔は10msecであり、ロックさせられたプロセスは、10msec以上待機させられることとなる。
Here, in the conventional method, when the instruction of the
また、他のプロセスが更新途中の関数を呼び出さないためのロックをしない場合、図8に示されるステップS3ように、スレッド15Aが更新途中の関数を読み込んでしまうことがある。するとアドレスnnn1とアドレスnnn2の内容が一致しないため、サービス提供中のプロセスがエラーとなる可能性がある。
上述のように、特開平7−319683号公報に記載されるような方式を用いた場合、プログラム関数更新時、関数更新を実施するプロセスが、他のプロセスが更新途中の関数を呼び出さないように更新対象関数をロックする必要があるため、サービス提供中のプロセスが更新対象関数へアクセスすると、更新完了まで停止させられてしまうという課題があった。
また、更新対象関数をロックせずに関数更新を実施すると、サービス提供中のプロセスがエラーとなるという課題があった。
As described above, when a method as described in Japanese Patent Laid-Open No. 7-319683 is used, when updating a program function, the process that performs the function update prevents other processes from calling the function being updated. Since it is necessary to lock the update target function, there is a problem that if the process providing the service accesses the update target function, it is stopped until the update is completed.
Further, when the function update is performed without locking the update target function, there is a problem that a process that provides a service results in an error.
そこで、本発明では、インタフェース関数と関数シンボルのテーブルを用意し、関数更新時は、1つの命令のみを書き換えることで、サービス提供中のプロセスを停止せずに関数更新を実現する。 Therefore, in the present invention, a table of interface functions and function symbols is prepared, and at the time of function update, only one instruction is rewritten, thereby realizing function update without stopping the service providing process.
かかる課題を解決するため、本発明によるコンピュータシステムは、実行対象のプログラムに含まれるサブルーチン毎にそのサブルーチンが格納されているメモリ上の先頭アドレスを示すアドレス情報を保持するアドレス管理テーブルと、呼び出し対象のサブルーチンにジャンプさせるためのインタフェースサブルーチンを呼び出して実行するインタフェースサブルーチン呼び出し手段と、アドレス管理テーブルを参照して呼び出し対象のサブルーチンに対応するメモリ上の先頭アドレスを検出し、その検出された先頭アドレスのサブルーチンを呼び出しで実行するサブルーチン呼び出し手段と、更新対象のサブルーチンに対応する新たなサブルーチンをメモリ上にロードし、アドレス管理テーブルの該当するエントリアドレスを、新たなサブルーチンをロードした先頭アドレスに書き換えるテーブル更新手段とを備えることを特徴とする。 In order to solve such a problem, a computer system according to the present invention includes an address management table that holds address information indicating a head address on a memory in which a subroutine is stored for each subroutine included in a program to be executed, and a call target. The interface subroutine calling means for calling and executing the interface subroutine for jumping to the subroutine of the above, and the head address on the memory corresponding to the subroutine to be called are detected by referring to the address management table, and the detected head address A subroutine calling means for executing a subroutine by calling and a new subroutine corresponding to the subroutine to be updated are loaded into the memory, and the corresponding entry address of the address management table is loaded into the new support. Characterized in that it comprises a table updating means for rewriting the start address loaded routine.
また本発明によるプログラム更新方法は、実行対象のプログラムに含まれる各サブルーチン毎にそのサブルーチンが格納されているメモリ上の先頭アドレスを示すアドレス情報をメモリ上に登録し、実行対象のプログラムのサブルーチン呼び出し命令に応答して、呼び出し対象のサブルーチンにジャンプさせるためのインタフェースサブルーチンを呼び出して実行し、アドレス情報を参照して呼び出し対象のサブルーチンに対応するメモリ上の先頭アドレスを検出し、その検出された先頭アドレスのサブルーチンを呼び出して実行し、更新対象のサブルーチンに対応する新たなサブルーチンをメモリ上にロードし、アドレス情報の該当するエントリアドレスを、新たなサブルーチンをロードした先頭アドレスに書き換えることを特徴とする。 The program update method according to the present invention registers, for each subroutine included in the execution target program, address information indicating the top address on the memory in which the subroutine is stored on the memory, and calls the subroutine of the execution target program. In response to the instruction, the interface subroutine for jumping to the subroutine to be called is called and executed, the address information is referenced to detect the start address on the memory corresponding to the subroutine to be called, and the detected head Calling and executing the subroutine of the address, loading a new subroutine corresponding to the subroutine to be updated onto the memory, and rewriting the corresponding entry address of the address information to the head address loaded with the new subroutine .
発明の効果として、本発明のコンピュータシステムおよびプログラム更新方法によれば、サービス提供スレッドやプロセスを停止することなく、実行プログラムを更新することができ、プログラムの問題対処や機能変更・機能追加が可能となる。 As an effect of the invention, according to the computer system and the program update method of the present invention, it is possible to update the execution program without stopping the service providing thread and the process, and it is possible to cope with the problem of the program, change the function, and add the function. It becomes.
本発明によるLinux・UNIX(登録商標)をOSとするコンピュータシステムおよびプログラム更新方法は、インタフェース関数とシンボルテーブル(関数シンボルのテーブル)を備え、以下に記載される実施例1および実施例2を用いて説明される。 A computer system and program update method using Linux / UNIX (registered trademark) as an OS according to the present invention includes an interface function and a symbol table (function symbol table), and uses Examples 1 and 2 described below. Explained.
以下、本発明によるコンピュータシステムおよびプログラム更新方法の実施例1は、図1〜図3を用いて説明される。図1は本発明によるコンピュータシステムの構成を示す図である。図2は本発明によるコンピュータシステムのプロセス内の構成を示す図である。図3は本発明によるコンピュータシステムのプロセス動作を示すフローチャート図である。 Embodiment 1 of a computer system and a program update method according to the present invention will be described below with reference to FIGS. FIG. 1 is a diagram showing the configuration of a computer system according to the present invention. FIG. 2 is a diagram showing a configuration in the process of the computer system according to the present invention. FIG. 3 is a flowchart showing the process operation of the computer system according to the present invention.
まず、本発明によるコンピュータシステムの構成が、図1を用いて説明される。コンピュータシステムは、オンラインシステムを構築する複数のコンピュータシステムの1つであり、ネットワーク1を介して他のシステムと接続されている。
図1において、コンピュータシステムはCPU2、メインメモリ3、通信制御ユニット4、外部記憶装置としてハードディスク5が設けられており、これらはシステムバス6を介して相互接続されている。
First, the configuration of a computer system according to the present invention will be described with reference to FIG. The computer system is one of a plurality of computer systems that construct an online system, and is connected to other systems via the network 1.
In FIG. 1, a computer system is provided with a
CPU2は、このコンピュータシステム全体を制御するためのものであり、メインメモリ3のOS7や各種アプリケーションプログラムを実行する。メインメモリ3はOS7、実行対象のアプリケーションプログラム8、シンボルテーブル9を格納する。
The
OS7は、システム管理のための各種プログラムから構成されており、ここには本発明のプログラム実行を実現するために必要なインタフェース関数管理プログラム10と関数更新管理プログラム11が組み込まれている。
The OS 7 includes various programs for system management, and an interface
インタフェース関数管理プログラム10は、スレッドにより呼び出し対象の関数が呼び出されるときにインタフェース関数12を呼び出し、メインメモリ3に格納されたシンボルテーブル9を読み込み、該当するエントリアドレスを取得し、そのアドレスにジャンプさせる。一般に関数はサブルーチンとも呼ばれる。関数更新管理プログラム11は、新たな関数をハードディスク5またはネットワーク1からメインメモリ3の空き領域にロードして、シンボルテーブル9の該当するエントリアドレスを更新前の関数の先頭アドレスから新たな関数の先頭アドレスに変更する。
The interface
アプリケーションプログラム8においては、インタフェース関数12は、呼び出し対象の関数を呼び出すものであるが、その呼び出し先の関数のエントリアドレスは、インタフェース関数12には組み込まれておらず、そのエントリアドレスはシンボルテーブル9を参照することによって求められ、呼び出し対象の関数、例えば、旧関数13や新関数14へジャンプさせる。
In the application program 8, the
シンボルテーブル9は、アプリケーションプログラム8に含まれる関数毎に、メインメモリ3のエントリアドレスを格納する。そのエントリアドレスはインタフェース関数12が呼び出された時、どの関数へジャンプするかを知らせるための各呼び出し対象関数の先頭アドレスである。
The symbol table 9 stores the entry address of the main memory 3 for each function included in the application program 8. The entry address is the head address of each function to be called for informing which function to jump to when the
通信制御ユニット4は、ネットワーク1を介して他のシステムとの通信を実行するためのものであり、例えば、新関数14をネットワーク1からダウンロードするために用いられる。ハードディスク5は、コンピュータシステムの二次記憶装置として利用されるものであり、各種プログラムやファイルが格納されている。
The
次に、本発明によるコンピュータシステムのプロセス内の構成が、図2を用いて説明される。
図2において、本発明によるコンピュータシステムのプロセス内の構成は、シンボルテーブル9、1つ以上のインタフェース関数12、旧関数13や新関数14などの関数、インタフェース関数管理プログラム10が持つ通常のサービスを提供する1つ以上のスレッド15、関数更新管理プログラム11がもつ関数更新管理スレッド16である。
Next, the configuration in the process of the computer system according to the present invention will be described with reference to FIG.
In FIG. 2, the configuration in the process of the computer system according to the present invention includes a symbol table 9, one or
インタフェース関数12は、スレッド15が呼び出し対象の関数を呼び出すときに、常に呼び出される関数である。各スレッド15は、直接的に関数を呼び出すことはなく、最初にインタフェース関数12を呼び出し、インタフェース関数12の中の処理で、実際の呼び出し対象の関数へジャンプする。
The
シンボルテーブル9は、インタフェース関数12が呼び出されたとき、どの関数へジャンプするかを知らせるための各関数の先頭アドレスが格納されている。例えば、図2に示されるように、更新前の関数である旧関数foo13のエントリをシンボルテーブル9の1番目とする場合、シンボルテーブル9の1番目のエントリには関数fooの先頭アドレスxxx1が入力される。
The symbol table 9 stores the start address of each function for notifying which function to jump to when the
関数更新管理スレッド16は、関数更新時に更新処理を実行するスレッドである。また各スレッド15は、それぞれ非同期で処理を実行する。
The function
よって、スレッドが呼び出し対象の関数を呼び出す際の動作概要は以下のようになる。
サービスを提供するスレッド15は、まずインタフェース関数12を呼び出し、インタフェース関数12の中の処理で、実際の呼び出し対象の関数にジャンプする。インタフェース関数12は、スレッド15に呼び出されると、シンボルテーブル9を読み込み、該当するエントリアドレスを取得し、そのエントリアドレスへジャンプする。このとき、インタフェース関数12が読み込む先のシンボルテーブル9のエントリは固定である。例えば、旧関数foo13のインタフェース関数12はシンボルテーブル9の1番目のエントリを常に読み込む。
Therefore, the operation outline when the thread calls the function to be called is as follows.
The
また、旧関数foo13から新関数foo14への関数更新時の動作概要は、以下のようになる。
旧関数foo13から新関数foo14への関数更新時には、関数更新管理スレッド16が新関数foo14をメモリ上へロードする。次に、関数更新管理スレッド16は、シンボルテーブルの1番目のエントリを、新関数foo14の先頭アドレスmmm1へ変更する。以後、サービスを提供するスレッドは、関数fooのインタフェース関数12を呼び出すと、新関数foo14へジャンプするようになる。
An outline of the operation when updating the function from the old function foo13 to the new function foo14 is as follows.
When the function is updated from the old function foo13 to the new function foo14, the function
なお、一般にメモリ上の内容を書き換える場合、OS7やハードウェア側にて排他制御が提供されており、複数のスレッド15が同時に同一のメモリへアクセスすることはない。例えば、図示はされていないが、サービスを提供するスレッド15がインタフェース関数12を介してシンボルテーブル9へアクセスする処理と、関数更新管理スレッドがシンボルテーブル9書き換える処理が同時に発生した場合、必ず片方が待機させられる。
Generally, when rewriting the contents on the memory, exclusive control is provided on the OS 7 or the hardware side, and a plurality of
以下、図3を用いて、本発明によるコンピュータシステムのプロセスの動作が説明される。
図3において、ステップS101〜S105はプロセスの起動処理である。ステップS101はプロセスの起動である。ステップS102は、各関数・インタフェース関数12をメモリへロードする処理である。ステップS103は、ステップS102でロードした関数のアドレスをシンボルテーブル9に書き込む処理である。ステップS104は、関数更新管理スレッド16を起動させる。ステップS105は、サービスを提供する各種スレッド15を起動させる。
Hereinafter, the operation of the process of the computer system according to the present invention will be described with reference to FIG.
In FIG. 3, steps S101 to S105 are process activation processes. Step S101 is process activation. Step S102 is a process of loading each function /
ステップS106は、プロセスの終了判定を行う。ステップS106でプロセスを終了すると判定された時、ステップS110以降の終了処理へ移る。ステップS106でプロセスを終了しないと判定された時、ステップS107へ移る。 In step S106, a process end determination is performed. When it is determined in step S106 that the process is to be terminated, the process proceeds to an end process after step S110. When it is determined in step S106 that the process will not be terminated, the process proceeds to step S107.
ステップS107〜S109は、関数更新に関する処理である。ステップS107では、更新する関数があるかを判定する。ステップS107で更新する関数があると判定された時、ステップS108の関数更新処理へ移る。ステップ107で更新する関数がないと判定された時はステップS103へ戻る。ステップS108は、新関数をメモリへロードする処理である。ステップS109は、ステップS108でロードした関数の先頭アドレスを、シンボルテーブル9の所定のエントリへ入力する。 Steps S107 to S109 are processing related to function update. In step S107, it is determined whether there is a function to be updated. When it is determined in step S107 that there is a function to be updated, the process proceeds to function update processing in step S108. If it is determined in step 107 that there is no function to be updated, the process returns to step S103. Step S108 is processing for loading a new function into the memory. In step S109, the start address of the function loaded in step S108 is input to a predetermined entry in the symbol table 9.
ステップS110以降は、プロセスの終了処理である。ステップS110はサービスを提供する各種スレッド15を終了させる。ステップS111は、関数更新管理スレッド16を終了させる。ステップS112はプロセス自身の終了である。
Steps S110 and after are process end processing. In step S110, the
以上のように、本発明によるコンピュータシステムおよびプログラム更新方法を用いることにより、サービス提供スレッド15やプロセスを停止することなく、実行プログラムを更新することができ、プログラムの問題対処や機能変更・機能追加が可能となる。
As described above, by using the computer system and the program update method according to the present invention, it is possible to update the execution program without stopping the
以下、本発明によるコンピュータシステムおよびプログラム更新方法の実施例2は、図4および図5を用いて説明される。実施例1で説明されたコンピュータシステムおよびプログラム更新方法では、通常の関数に加え、図4に示すインタフェース関数12を予め用意する必要があった。実施例2では、実施例1で説明されたコンピュータシステムおよびプログラム更新方法において、インタフェース関数12を自動的に生成する機能および方法について説明される。図4は本発明によるコンピュータシステムのインタフェース関数とシンボルテーブルを示す図である。図5は本発明によるコンピュータシステムのインタフェース関数の自動生成動作を示すフローチャート図である。
Hereinafter, a second embodiment of the computer system and the program update method according to the present invention will be described with reference to FIGS. In the computer system and the program update method described in the first embodiment, the
まず、本発明によるコンピュータシステムのインタフェース関数とシンボルテーブルが、図4を用いて説明される。
図4に示されるインタフェース関数12(アセンブラコード)は、インタフェース関数12をアセンブラで表現したプログラムである。なお、このアセンブラは、米国インテル社製のpentium(登録商標)シリーズに用いられる、i386系アーキテクチャのアセンブラコードである。図4に示すように、インタフェース関数12は、シンボルテーブルのアドレスを解決するコードにより、シンボルテーブル9へのアドレスを解決し、シンボルテーブルのアドレス取得コードおよびシンボルテーブルの先頭からのオフセットで関数の先頭アドレス取得コードにより、シンボルテーブル9の所定のエントリへアクセスし、エントリから読み出したアドレスへジャンプする、といった処理となっている。
First, the interface function and symbol table of the computer system according to the present invention will be described with reference to FIG.
The interface function 12 (assembler code) shown in FIG. 4 is a program that expresses the
インタフェース関数12は、図4の関数情報17を除き、全て共通のコードとすることができる。また、関数情報17は、関数のシンボル名、及びシンボルテーブル9の先頭アドレスから、所定の関数のエントリのアドレスまでのオフセット値である。例えば、本実施例では、関数のシンボル名がfooであり、シンボルテーブル9の先頭アドレスから、関数fooのエントリのアドレスまでのオフセット値を「4」として説明する。
そこで、関数情報17を自動的に取得することで、インタフェース関数12を自動生成し、インタフェース関数を作成するための作業量を低減させる。
実施例2のプログラム運用中の動作、プログラム更新方法は、実施例1と同様である。ここでは、実施例1との差分である、インタフェース関数12の自動生成方法について説明する。
All the interface functions 12 can be a common code except for the function information 17 of FIG. The function information 17 is a symbol name of the function and an offset value from the start address of the symbol table 9 to the address of the entry of a predetermined function. For example, in this embodiment, the function symbol name is foo, and the offset value from the head address of the symbol table 9 to the address of the function foo entry is “4”.
Therefore, by automatically acquiring the function information 17, the
The operation during program operation and the program update method of the second embodiment are the same as those of the first embodiment. Here, an automatic generation method of the
以下、図5を用いて、本発明によるコンピュータシステムのインタフェース関数12の自動生成の動作が説明される。
図5において、ステップS201はインタフェース関数12の作成が開始されることを示す。ステップS202では、関数のライブラリから、関数シンボル名を取得する。ある特定の機能を持ったプログラムを、他のプログラムから利用できるように部品化し、複数のプログラム部品を一つのファイルにまとめたものである。ライブラリ自体は単独で実行することはできず、他のプログラムの一部として動作する。関数シンボル名は、例えばLinuxなどでは、nmコマンドをスクリプトに組み込むことで取得できる。
Hereinafter, the operation of automatically generating the
In FIG. 5, step S201 indicates that the creation of the
次にステップS203でインタフェース関数12のコードを出力するためのファイルをオープンする。ステップS204では、オフセット値Nを設定する。オフセット値とは、この関数のアドレスを入力したシンボルテーブル9のエントリが、シンボルテーブル9の最初のアドレスから何バイト目であるかを示す。なお、1エントリは4バイトである。例えば、図3のステップS103において、シンボルテーブル9の3番目のエントリにこの関数のアドレスが書き込まれる場合、オフセットは最初のエントリから2エントリ分ずれているので、2エントリ×4バイト=8となる。
In step S203, a file for outputting the code of the
図5のステップS205〜S207は、図4のアセンブラコードを生成する処理である。ステップS205は、読み込んでいない関数が存在するかどうかを判定する。読み込んでいない関数が存在しない場合、ステップS208以降の終了処理へ移る。読み込んでいない関数が存在する場合、ステップS206へ移る。ステップS206は、ライブラリから関数シンボルを読み込み、アセンブラコードを生成する。ステップS207は、オフセット値を加算する処理である。 Steps S205 to S207 in FIG. 5 are processes for generating the assembler code in FIG. In step S205, it is determined whether there is a function that has not been read. If there is no function that has not been read, the process proceeds to an end process after step S208. If there is a function that has not been read, the process proceeds to step S206. A step S206 reads a function symbol from the library and generates an assembler code. Step S207 is processing to add an offset value.
ステップS208、S209はインタフェース関数生成を終了する処理である。ステップS208では、アセンブラコードを出力したファイルをクローズする。ステップS209は本処理を終えたことを示している。 Steps S208 and S209 are processes for ending the interface function generation. In step S208, the file to which the assembler code has been output is closed. Step S209 indicates that this process has been completed.
実施例1で説明されたコンピュータシステムおよびプログラム更新方法の効果に加え、図5のような処理フローのプログラムを用意することで、以後、インタフェース関数12を容易に生成することが可能となる。
In addition to the effects of the computer system and the program update method described in the first embodiment, the
2…CPU、3メインメモリ、4…通信制御ユニット、5…ハードディスク、7…OS、8…アプリケーションプログラム、9…シンボルテーブル、10…関数ロード管理プログラム、11…関数更新管理プログラム、12…インタフェース関数、13…旧関数、14…新関数、15…スレッド、16…更新管理スレッド 2 ... CPU, 3 main memory, 4 ... communication control unit, 5 ... hard disk, 7 ... OS, 8 ... application program, 9 ... symbol table, 10 ... function load management program, 11 ... function update management program, 12 ... interface function , 13 ... old function, 14 ... new function, 15 ... thread, 16 ... update management thread
Claims (3)
呼び出し対象のサブルーチンにジャンプさせるためのインタフェースサブルーチンを呼び出して実行するインタフェースサブルーチン呼び出し手段と、
前記アドレス管理テーブルを参照して前記呼び出し対象のサブルーチンに対応するメモリ上の先頭アドレスを検出し、その検出された先頭アドレスのサブルーチンを呼び出して実行するサブルーチン呼び出し手段と、
更新対象のサブルーチンに対応する新たなサブルーチンをメモリ上にロードし、前記アドレス管理テーブルの該当するエントリアドレスを、前記新たなサブルーチンをロードした先頭アドレスに書き換えるテーブル更新手段と
を備えることを特徴とするコンピュータシステム。 An address management table that holds address information indicating the top address on the memory in which the subroutine is stored for each subroutine included in the program to be executed;
An interface subroutine calling means for calling and executing an interface subroutine for jumping to a subroutine to be called;
Subroutine calling means for detecting a top address on a memory corresponding to the subroutine to be called with reference to the address management table, and calling and executing a subroutine of the detected top address;
Table updating means for loading a new subroutine corresponding to a subroutine to be updated onto a memory and rewriting a corresponding entry address in the address management table to a head address loaded with the new subroutine. Computer system.
サブルーチンのライブラリからサブルーチンのシンボル名を取得し、該サブルーチンのメモリアドレスのオフセット値を設定し、前記ライブラリにある全てのサブルーチンを読み込むまで、前記インタフェースサブルーチンを作成する手段
を備えることを特徴とするコンピュータシステム。 The computer system of claim 1,
A computer comprising: a subroutine symbol name obtained from a subroutine library; an offset value of a memory address of the subroutine is set; and all the subroutines in the library are read. system.
前記実行対象のプログラムのサブルーチン呼び出し命令に応答して、呼び出し対象のサブルーチンにジャンプさせるためのインタフェースサブルーチンを呼び出して実行し、
前記アドレス情報を参照して前記呼び出し対象のサブルーチンに対応するメモリ上の先頭アドレスを検出し、
その検出された先頭アドレスのサブルーチンを呼び出して実行し、
更新対象のサブルーチンに対応する新たなサブルーチンをメモリ上にロードし、
前記アドレス情報の該当するエントリアドレスを、前記新たなサブルーチンをロードした先頭アドレスに書き換えること
を特徴とするプログラム更新方法。 For each subroutine included in the program to be executed, register the address information indicating the start address on the memory where the subroutine is stored on the memory,
In response to a subroutine call instruction of the program to be executed, an interface subroutine for jumping to the subroutine to be called is called and executed,
Referring to the address information to detect the top address on the memory corresponding to the subroutine to be called,
Call and execute the subroutine of the detected start address,
A new subroutine corresponding to the subroutine to be updated is loaded into the memory,
A program update method, wherein a corresponding entry address of the address information is rewritten to a head address loaded with the new subroutine.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2004100444A JP2005284925A (en) | 2004-03-30 | 2004-03-30 | Computer system and program update method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2004100444A JP2005284925A (en) | 2004-03-30 | 2004-03-30 | Computer system and program update method |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2005284925A true JP2005284925A (en) | 2005-10-13 |
Family
ID=35183215
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2004100444A Pending JP2005284925A (en) | 2004-03-30 | 2004-03-30 | Computer system and program update method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2005284925A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009277217A (en) * | 2008-03-31 | 2009-11-26 | Symantec Corp | Dynamic insertion and removal of virtual software sub-layer |
US9116725B1 (en) | 2011-03-15 | 2015-08-25 | Symantec Corporation | Systems and methods for using virtualization of operating-system-level components to facilitate software testing |
US9223966B1 (en) | 2014-05-04 | 2015-12-29 | Symantec Corporation | Systems and methods for replicating computing system environments |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH02193223A (en) * | 1989-01-20 | 1990-07-30 | Fujitsu Ltd | Program number calling system |
JPH06222916A (en) * | 1993-01-25 | 1994-08-12 | Nec Corp | On-line real-time processor |
JPH07152552A (en) * | 1993-11-29 | 1995-06-16 | Nec Corp | System for dynamically replacing subprogram |
JP2002222081A (en) * | 2000-11-22 | 2002-08-09 | Ricoh Co Ltd | Device and method for program generation, program implementing the same method on computer, image forming device, and address solving method |
-
2004
- 2004-03-30 JP JP2004100444A patent/JP2005284925A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH02193223A (en) * | 1989-01-20 | 1990-07-30 | Fujitsu Ltd | Program number calling system |
JPH06222916A (en) * | 1993-01-25 | 1994-08-12 | Nec Corp | On-line real-time processor |
JPH07152552A (en) * | 1993-11-29 | 1995-06-16 | Nec Corp | System for dynamically replacing subprogram |
JP2002222081A (en) * | 2000-11-22 | 2002-08-09 | Ricoh Co Ltd | Device and method for program generation, program implementing the same method on computer, image forming device, and address solving method |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009277217A (en) * | 2008-03-31 | 2009-11-26 | Symantec Corp | Dynamic insertion and removal of virtual software sub-layer |
US9081644B2 (en) | 2008-03-31 | 2015-07-14 | Symantec Corporation | Dynamic insertion and removal of virtual software sub-layers |
US9116725B1 (en) | 2011-03-15 | 2015-08-25 | Symantec Corporation | Systems and methods for using virtualization of operating-system-level components to facilitate software testing |
US9223966B1 (en) | 2014-05-04 | 2015-12-29 | Symantec Corporation | Systems and methods for replicating computing system environments |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11853774B2 (en) | Dynamically loaded plugin architecture | |
US5815702A (en) | Method and software products for continued application execution after generation of fatal exceptions | |
US7774636B2 (en) | Method and system for kernel panic recovery | |
US8286154B2 (en) | Apparatus and method for live loading of version upgrades in a process control environment | |
US8112745B2 (en) | Apparatus and method for capabilities verification and restriction of managed applications in an execution environment | |
US6253320B1 (en) | Operating system rebooting method | |
KR101782313B1 (en) | Apparatus and method for handling exception events | |
US7353507B2 (en) | Intercepting function cells | |
JP5093259B2 (en) | Communication path strengthening method between BIOS and BMC, apparatus and program thereof | |
JP5026494B2 (en) | Computer that starts at high speed | |
JP2003256225A (en) | Computer system, failure countermeasure and program for making computer system function | |
US6336215B1 (en) | Apparatus and method for on-line code only replacement of a running program using checkpoints | |
JP2006065462A (en) | Software system, software stopping method, program, and storage medium | |
US5953529A (en) | Data processor with a debug device and a stack area control unit and corresponding data processing method | |
JP4275451B2 (en) | Illegal memory access detection method and program thereof | |
JP2005284925A (en) | Computer system and program update method | |
JPH07152551A (en) | Computer system and program executing method | |
US7562209B2 (en) | Supporting different instruction set architectures during run time | |
WO2011025479A1 (en) | A plurality of interface files usable for access to bios | |
JP6691294B2 (en) | Information processing apparatus, dynamic link program, and program restart method | |
US20080127235A1 (en) | Methods, systems and computer program products for dynamic linkage | |
JP2002182931A (en) | Common os system call method | |
JPH1021067A (en) | Dynamic correction method for program | |
JP2655612B2 (en) | External reference update method | |
JP2011118830A (en) | Multitasking system and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7421 Effective date: 20060923 |
|
RD02 | Notification of acceptance of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7422 Effective date: 20060929 |
|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20061013 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20070202 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20091027 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20100518 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20100712 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20100928 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20110322 |