JP2004078751A - Reuse method of compiled program code, system, and program - Google Patents

Reuse method of compiled program code, system, and program Download PDF

Info

Publication number
JP2004078751A
JP2004078751A JP2002240640A JP2002240640A JP2004078751A JP 2004078751 A JP2004078751 A JP 2004078751A JP 2002240640 A JP2002240640 A JP 2002240640A JP 2002240640 A JP2002240640 A JP 2002240640A JP 2004078751 A JP2004078751 A JP 2004078751A
Authority
JP
Japan
Prior art keywords
file
program code
compiled
compiled program
code
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
Application number
JP2002240640A
Other languages
Japanese (ja)
Inventor
Shinji Tanaka
田中 慎司
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2002240640A priority Critical patent/JP2004078751A/en
Publication of JP2004078751A publication Critical patent/JP2004078751A/en
Pending legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To maintain compiled optimum program codes obtained by execution of an application program for a long time even at restart of the application program. <P>SOLUTION: A user interface section 11 directs a file operation controller 12 to store compiled program codes together with a filename specified at starting time. A file conversion section 13 acquires dynamically compiled program codes 22, convert them into a format which can be saved as a file. The file conversion section 13 also acquires a class version UID (unique ID), and a version of a current virtual instruction code execution environment 10 from an executive program class file 23, and a version management section 14 respectively, and imparts them to the converted compiled program code 22. The file operation controller 12 stores the acquired compiled program code 22 by the directed filename at a file system 20. <P>COPYRIGHT: (C)2004,JPO

Description

【0001】
【発明の属する技術分野】
本発明は、プログラム実行時の動的なデータ(プロファイル)を基に仮想命令コードの最適化および実マシン命令コードへの変換をプログラムを実行しながら動的に行う動的コンパイラを実装した仮想命令コード実行環境におけるコンパイル済みプログラムコード再利用方法、装置、およびプログラムに関するものである。
【0002】
【従来の技術】
プログラム実行時の動的なデータ(プロファイル)を基に仮想命令コードの最適化および実マシン命令コードへの変換をプログラムを実行しながら動的に行う従来の動的コンパイラを実装した仮想命令コード実行環境では、アプリケーションプログラムを実行することで得られた動的コンパイラによりコンパイルされたコンパイル済みプログラムコードが、同一アプリケーションプログラムを実行するために前出の仮想命令コード実行環境を再起動した場合でも引き継がれていない。
【0003】
【発明が解決しようとする課題】
そのため、再起動されたアプリケーションプログラムの初期実行速度が、長時間実行して最適化された状態の実行速度と比べて著しく遅い場合があった。
【0004】
このため、アプリケーションプログラムを再起動せずに、できるだけ長時間実行させておき、実行速度の最適な状態を保つ必要があるが、プログラム故障などの不測の事態が生じた場合には、やむを得ずアプリケーションを再起動することになる。また、サーバー系のプログラムは、プログラム故障などでサービスが利用できなかったときの復旧直後には、通常運用時以上に利用者が多くなり、本来はアプリケーションプログラムの高速な実行を要する部分である。
【0005】
このように従来の技術では、アプリケーションプログラムの起動直後の実行速度が遅いという問題がある。
【0006】
本発明の目的は、アプリケーションプログラムを長時間実行させて得た最適なコンパイル済みプログラムコードを、アプリケーションプログラムの再起動時でも維持するコンパイル済みプログラムコード再利用方法、装置、およびプログラムを提供することにある。
【0007】
【課題を解決するための手段】
本発明は、仮想命令コード実行環境内部で使用しているコンパイル済みプログラムコードを、外部ファイルとして保存可能な形式に変換し、ファイルシステム中にファイルとして保存し、また、仮想命令コード実行環境の起動時に、指定された外部ファイルを読み出し、動的コンパイラによるコンパイル済みプログラムコードとして使用可能な状態へ復元するものである。
【0008】
ここで、コンパイル済みプログラムコードは、実行時コンパイルによって、実行時に仮想命令コードから動的にコンパイルされた実マシン命令コードである。
【0009】
プログラム実行時の動的なデータ(プロファイル)を基に仮想命令コードの最適化および実マシン命令コードへの変換をプログラムを実行しながら動的に行う動的コンパイラーを実装した仮想命令コード実行環境の下でアプリケーションプログラムを高速に実行するために、仮想命令コードを実マシン命令コードへ変換し、コンパイルされるコンパイル済みプログラムコードを保存・再利用することにより、アプリケーションプログラムの再起動直後でも再起動前と変わらない高速なプログラム実行速度を保つことができる。
【0010】
【発明の実施の形態】
次に、本発明の実施の形態について図面を参照して説明する。
【0011】
図1は本発明の一実施形態の動的コンパイル結果再利用装置を含む仮想命令実行環境10およびファイルシステム20の構成図である。
【0012】
動的コンパイル結果再利用装置はユーザインタフェース部11とファイル操作制御部12とファイル変換部13とバージョン管理部14と整合性検証部15を有している。
【0013】
ユーザインタフェース部11は仮想命令コード実行環境10の起動時にユーザに指示されたファイルとともにコンパイル済みプログラムコードの保存指示をファイル操作制御部12へ出し、またユーザに指定されたファイル名とともにコンパイル済みプログラムコードの読み出し指示をファイル操作制御部12に出す。ファイル操作制御部12はコンパイル済みプログラムコードの保存指示を受けてファイル変換部13からファイルとして保存可能な形式に変換された動的コンパイル済みプログラムコード22を取得し、指定されたファイル名でファイルシステム20に保存する。また、ファイル操作制御部12は、コンパイル済みプログラムコードの読み出し指示を受けると、指定されたファイル名のファイルをファイルシステム20から読み出し、ファイル変換部13へ通知する。ファイル変換部13は通知されたファイルの内容からバージョン番号を抽出し、バージョン管理部14へ通知し、バージョン管理部14から返却されたバージョンチェック結果を判断し、互換性がないと判断した場合、ユーザインタフェース部11へエラーを通知し、バージョンチェックが正常な場合、ファイルから読み出された内容を内部データ形式のコンパイル済みプログラムコードに変換し、仮想メモリ上に動的コンパイル済みプログラムコード22としてコピーする。バージョン管理部14はファイル変換部13から通知されたバージョン番号が互換性のあるコンパイル済みプログラムコードかどうか判定し、チェック結果をファイル変換部13へ返却する。整合性検証部15は、ファイル変換部13で変換されたコンパイル済みプログラムコード22と実行しようとしているアプリケーションプログラムとの整合性を確認するために、全てのコンパイル済みプログラムコード22が実行プログラムクラスファイル23と一致しているかチェックし、チェック結果をファイル変換部13に返却する。
【0014】
図2は本実施形態におけるコンパイル済みプログラムコードの保存処理を示したものである。また、ファイルの保存形式を図3に示す。以下に処理の流れを説明する。
【0015】
ステップ1.  キー入力(Ctrl+¥)などによるユーザ指示を検出したユーザインタフェース部11は、起動時に指定されたファイル名とともにファイル操作制御部12へコンパイル済みプログラムコード保存の指示をする。
【0016】
ステップ2.  指示を受けたファイル操作制御部12は、ファイル変換部13からファイルとして保存可能な形式(バイト配列)に変換されたコンパイル済みプログラムコード22を取得する。
【0017】
ステップ3.  ファイル変換部13は、
(3―1) 仮想命令コード実行環境10内の動的コンパイル済みプログラムコード22を取得し、ファイルとして保存可能な形式(バイト配列)に変換する。また、
(3―2) クラスバージョンUIDを仮想命令コード実行環境10内の実行プログラムクラスファイル23から、
(3―3) 現仮想命令コード実行環境10のバージョンをバージョン管理部14からそれぞれ取得し、変換後のコンパイル済みプログラムコードに付与する。クラスバージョンUID(Unique  ID)は、クラスファイル作成時に生成され、クラスファイル内に変更が生じた場合には、別のUIDが付与されなければならない。UID生成アルゴリズムは、クラスファイルの全内容に対するハッシュコードでもよく、ソースファイルからクラスファイルを作成した時点の時刻情報でもよい。
【0018】
ステップ2では、上記の情報を付与した変換済みのコンパイル済みプログラムコード22をファイル操作制御部12が取得している。
【0019】
ステップ4.  ファイル操作制御部12は、取得されたコンパイル済みプログラムコード22を、指示されたファイル名で図3に示す形式でファイルシステム20に保存する。
【0020】
図4は、本実施形態における、コンパイル済みプログラムコードを保存したファイル21を読み出す処理を示したものである。また、図5〜8は、各処理のエラールートを示したものである。以下に処理の流れを説明する。
【0021】
ステップ1.  仮想命令コード実行環境起動時にユーザインタフェース部11を経由してパラメータとして指定されたファイル名とともに、ファイル操作制御部12へコンパイル済みプログラムコードの読み出し指示をする。
【0022】
ステップ2.  指示を受けたファイル操作制御部12は、指定されたファイル名のファイルをファイルシステム20から読み出す。指定されたファイル名のファイルが存在していない場合には、その旨をユーザインタフェース部11へ通知する(図5)。
【0023】
ステップ3.  指定されたファイルが存在している場合、ファイル操作制御部12は読み出した内容をファイル変換部13へ通知する。
【0024】
ステップ4.  ファイル変換部13は、ファイル内容からバージョン番号を抽出し、バージョン管理部14へバージョン番号を通知する。
【0025】
ステップ5.  バージョン管理部14は、通知されたバージョン番号が互換性のあるコンパイル済みプログラムコードかどうかチェックし、チェック結果をファイル変換部13へ返却する。
【0026】
ステップ6.  ファイル変換部13はバージョンチェック結果を判断し、互換性がないと判断された場合には、ユーザインタフェース部11へエラーを通知する(図6)。
【0027】
ステップ7.  バージョンチェックが正常の場合、ファイル変換部13はファイルから読み出された内容(バイト配列)を内部データ形式のコンパイル済みプログラムコードに変換し、仮想メモリ上に動的コンパイル済みプログラムコード22としてコピーする。もし、変換が不可能な内容であった場合には、ユーザインタフェース部11へその旨エラーを通知する(図7)。
【0028】
ステップ8.  コンパイル済みプログラムコード22の内部データ形式に変換ができた場合には、ファイル変換部13は変換されたコンパイル済みプログラムコード22と実行しようとするアプリケーションプログラムとの整合性を確認するために、整合性検証部15へ指示する。
【0029】
ステップ9.  検証要求を受けた整合性検証部15は、全てのコンパイル済みプログラムコード22の内容が実行プログラムクラスファイル23と一致しているかチェックする。また、チェック結果を起動元のファイル変換部13へ返却する。
【0030】
ステップ10.  ファイル変換部13は整合性検証結果を判定し、整合性がNGだった場合には、その旨エラーをユーザインタフェース部11へ通知する(図8)。また、整合性がOKの場合には、正常終了でユーザインタフェース部11へ制御を戻す。
【0031】
図9は、コンパイル済みプログラムコードと実行するアプリケーションプログラムの整合性を検証する処理を示したものである。
【0032】
整合性検証部15では、コンパイル済みプログラムコードを保存したときに実行していたアプリケーションプログラムが、コンパイル済みプログラムコード22を読み出したときと全く同じものであるか検証を行う。検証に用いるデータは、クラスごとに付与されるクラスバージョンUIDである。
【0033】
コンパイル済みプログラムコードの整合性検証手順は単純で、読み出されたコンパイル済みプログラムコード22内にあるクラス名からロードされているクラスファイルを特定し、その両方のクラスバージョンUIDが一致しているかどうか、全クラスバージョンUIDに対して行うだけである。
【0034】
なお、以上説明したコンパイル済みプログラムコード再利用方法は専用のハードウェアにより実現されるもの以外に、その機能を実現するためのプログラムを、コンピュータ読み取り可能な記録媒体に記録して、この記録媒体に記録されたプログラムをコンピュータシステムに読み込ませ、実行するものであってもよい。コンピュータ読み取り可能な記録媒体とは、フロッピーディスク、光磁気ディスク、CD―ROM等の記録媒体、コンピュータシステムに内蔵されるハードディスク装置等の記憶装置を指す。さらに、コンピュータ読み取り可能な記録媒体は、インターネットを介してプログラムを送信する場合のように、短時間の間、動的にプログラムを保持するもの(伝送媒体もしくは伝送波)、その場合のサーバとなるコンピュータシステム内部の揮発性メモリのように、一定時間プログラムを保持しているものも含む。
【0035】
【発明の効果】
以上説明したように、本発明によれば、プログラム実行時の動的なデータ(プロファイル)を基に仮想命令コードの最適化および実マシン命令コードへの変換をプログラムを実行しながら動的に行う動的コンパイラーを実装した仮想命令コード実行環境の下でアプリケーションプログラムを高速に実行するために、仮想命令コードを実マシン命令コードへ変換し、コンパイルされるコンパイル済みプログラムコードを保存・再利用することにより、アプリケーションプログラムの再起動直後でも再起動前と変わらない高速なプログラム実行速度を保つことができる。
【図面の簡単な説明】
【図1】本発明の一実施形態における仮想命令実行環境とファイルシステムの構成図である。
【図2】動的コンパイル済みプログラムコードの保存処理を示す図である。
【図3】ファイル保存形式を示す図である。
【図4】動的コンパイル済みプログラムコードの読み出し処理を示す図である。
【図5】指定ファイルエラーのエラールートを示す図である。
【図6】バージョンチェックエラーのエラールートを示す図である。
【図7】ファイル内容不正のエラールートを示す図である。
【図8】整合性検証エラーのエラールートを示す図である。
【図9】整合性検証方法の説明図である。
【符号の説明】
10  仮想命令実行環境
11  ユーザインタフェース部
12  ファイル操作制御部
13  ファイル変換部
14  バージョン管理部
15  整合性検証部
20  ファイルシステム
21  動的コンパイル済みプログラムコード保存ファイル
22  動的コンパイル済みプログラムコード
23  実行プログラムクラスファイル
[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention provides a virtual instruction implementing a dynamic compiler that dynamically optimizes a virtual instruction code and converts it into a real machine instruction code based on dynamic data (profile) at the time of program execution while executing the program. The present invention relates to a method, an apparatus, and a program for reusing a compiled program code in a code execution environment.
[0002]
[Prior art]
Virtual instruction code execution implemented with a conventional dynamic compiler that dynamically optimizes virtual instruction codes and converts them to real machine instruction codes based on dynamic data (profile) during program execution while executing the program In the environment, the compiled program code compiled by the dynamic compiler obtained by executing the application program is inherited even if the above-mentioned virtual instruction code execution environment is restarted to execute the same application program. Not.
[0003]
[Problems to be solved by the invention]
Therefore, the initial execution speed of the restarted application program may be significantly slower than the optimized execution speed in a long-running application program.
[0004]
For this reason, it is necessary to run the application program for as long as possible without restarting it, and to maintain the optimal execution speed. Will be restarted. In addition, the server-based program has a greater number of users than in normal operation immediately after recovery when service cannot be used due to a program failure or the like, and is a part that originally requires high-speed execution of application programs.
[0005]
As described above, in the related art, there is a problem that the execution speed of the application program immediately after startup is low.
[0006]
An object of the present invention is to provide a method, an apparatus, and a program for reusing a compiled program code that maintain an optimal compiled program code obtained by executing an application program for a long time even when the application program is restarted. is there.
[0007]
[Means for Solving the Problems]
The present invention converts a compiled program code used in a virtual instruction code execution environment into a format that can be stored as an external file, saves the file as a file in a file system, and starts the virtual instruction code execution environment. Sometimes, a specified external file is read out and restored to a state where it can be used as compiled program code by a dynamic compiler.
[0008]
Here, the compiled program code is a real machine instruction code dynamically compiled from a virtual instruction code at the time of execution by a runtime compilation.
[0009]
A virtual instruction code execution environment that implements a dynamic compiler that dynamically optimizes virtual instruction codes and converts them into real machine instruction codes based on dynamic data (profiles) during program execution while executing the program. Converts virtual instruction codes into real machine instruction codes and saves and reuses the compiled program code to execute the application program at high speed under the application program immediately before restarting even immediately after restarting the application program The same high-speed program execution speed can be maintained.
[0010]
BEST MODE FOR CARRYING OUT THE INVENTION
Next, embodiments of the present invention will be described with reference to the drawings.
[0011]
FIG. 1 is a configuration diagram of a virtual instruction execution environment 10 and a file system 20 including a dynamic compilation result reuse device according to an embodiment of the present invention.
[0012]
The dynamic compilation result reuse device includes a user interface unit 11, a file operation control unit 12, a file conversion unit 13, a version management unit 14, and a consistency verification unit 15.
[0013]
The user interface unit 11 issues an instruction to save the compiled program code together with the file specified by the user when the virtual instruction code execution environment 10 is started to the file operation control unit 12, and outputs the compiled program code together with the file name specified by the user. Is issued to the file operation control unit 12. The file operation control unit 12 receives the instruction to save the compiled program code, acquires the dynamically compiled program code 22 converted from the file conversion unit 13 into a format that can be saved as a file, and obtains the file system under the designated file name. Save to 20. Further, when receiving the instruction to read the compiled program code, the file operation control unit 12 reads the file having the specified file name from the file system 20 and notifies the file conversion unit 13 of the file. The file conversion unit 13 extracts a version number from the content of the notified file, notifies the version management unit 14, determines the version check result returned from the version management unit 14, and determines that there is no compatibility. An error is notified to the user interface unit 11, and if the version check is normal, the contents read from the file are converted into a compiled program code in an internal data format and copied as a dynamically compiled program code 22 on the virtual memory. I do. The version management unit 14 determines whether the version number notified from the file conversion unit 13 is a compatible compiled program code, and returns a check result to the file conversion unit 13. The consistency verification unit 15 converts all the compiled program codes 22 into the executable program class file 23 in order to check the consistency between the compiled program code 22 converted by the file conversion unit 13 and the application program to be executed. Is checked, and the check result is returned to the file conversion unit 13.
[0014]
FIG. 2 shows a process of storing the compiled program code in the present embodiment. FIG. 3 shows a file storage format. The processing flow will be described below.
[0015]
Step 1. The user interface unit 11 that has detected a user instruction by key input (Ctrl + ¥) or the like instructs the file operation control unit 12 to save the compiled program code together with the file name specified at the time of startup.
[0016]
Step 2. Upon receiving the instruction, the file operation control unit 12 obtains the compiled program code 22 converted from the file conversion unit 13 into a format (byte array) that can be stored as a file.
[0017]
Step 3. The file conversion unit 13
(3-1) Obtain the dynamically compiled program code 22 in the virtual instruction code execution environment 10 and convert it into a format (byte array) that can be saved as a file. Also,
(3-2) The class version UID is obtained from the execution program class file 23 in the virtual instruction code execution environment 10.
(3-3) Obtain the version of the current virtual instruction code execution environment 10 from the version management unit 14 and add it to the converted compiled program code. The class version UID (Unique ID) is generated when the class file is created, and when a change occurs in the class file, another UID must be given. The UID generation algorithm may be a hash code for the entire contents of the class file, or may be time information when the class file is created from the source file.
[0018]
In step 2, the file operation control unit 12 acquires the converted compiled program code 22 to which the above information has been added.
[0019]
Step 4. The file operation control unit 12 stores the acquired compiled program code 22 in the file system 20 in the format shown in FIG.
[0020]
FIG. 4 shows a process of reading the file 21 storing the compiled program code according to the present embodiment. FIGS. 5 to 8 show error routes of the respective processes. The processing flow will be described below.
[0021]
Step 1. When the virtual instruction code execution environment is activated, it instructs the file operation control unit 12 to read out the compiled program code together with the file name specified as a parameter via the user interface unit 11.
[0022]
Step 2. Upon receiving the instruction, the file operation control unit 12 reads a file having the specified file name from the file system 20. If a file with the specified file name does not exist, that fact is notified to the user interface unit 11 (FIG. 5).
[0023]
Step 3. If the specified file exists, the file operation control unit 12 notifies the file conversion unit 13 of the read content.
[0024]
Step 4. The file conversion unit 13 extracts the version number from the file contents and notifies the version management unit 14 of the version number.
[0025]
Step5. The version management unit 14 checks whether the notified version number is a compatible compiled program code, and returns a check result to the file conversion unit 13.
[0026]
Step 6. The file conversion unit 13 determines the result of the version check, and if it is determined that there is no compatibility, notifies the user interface unit 11 of an error (FIG. 6).
[0027]
Step 7. If the version check is normal, the file conversion unit 13 converts the content (byte array) read from the file into a compiled program code in an internal data format and copies it as a dynamically compiled program code 22 on the virtual memory. . If the content cannot be converted, an error is notified to the user interface unit 11 (FIG. 7).
[0028]
Step 8. When the conversion into the internal data format of the compiled program code 22 is completed, the file conversion unit 13 checks the consistency of the converted compiled program code 22 with the application program to be executed. Instruct the verification unit 15.
[0029]
Step 9. Upon receiving the verification request, the consistency verification unit 15 checks whether the contents of all the compiled program codes 22 match the execution program class file 23. Also, the check result is returned to the file conversion unit 13 of the activation source.
[0030]
Step 10. The file conversion unit 13 determines the result of the consistency verification, and if the consistency is unacceptable, notifies the user interface unit 11 of an error to that effect (FIG. 8). If the consistency is OK, the control is returned to the user interface unit 11 upon normal termination.
[0031]
FIG. 9 shows a process for verifying the consistency between the compiled program code and the application program to be executed.
[0032]
The consistency verification unit 15 verifies that the application program that was being executed when the compiled program code was saved is exactly the same as when the compiled program code 22 was read. The data used for the verification is a class version UID assigned to each class.
[0033]
The procedure for verifying the integrity of the compiled program code is simple: identifying the class file being loaded from the class name in the read compiled program code 22, and determining whether both class version UIDs match. , Only for all class version UIDs.
[0034]
In addition to the method of reusing the compiled program code described above, in addition to the method realized by dedicated hardware, a program for realizing the function is recorded on a computer-readable recording medium, and the recording medium is stored in the recording medium. The recorded program may be read by a computer system and executed. The computer-readable recording medium refers to a recording medium such as a floppy disk, a magneto-optical disk, a CD-ROM, or a storage device such as a hard disk device built in a computer system. Further, the computer-readable recording medium is one that dynamically holds the program for a short time (transmission medium or transmission wave), such as a case where the program is transmitted via the Internet, and serves as a server in that case. It also includes those that hold programs for a certain period of time, such as volatile memory inside a computer system.
[0035]
【The invention's effect】
As described above, according to the present invention, optimization of a virtual instruction code and conversion to a real machine instruction code are dynamically performed while executing a program, based on dynamic data (profile) at the time of program execution. In order to execute an application program at high speed under a virtual instruction code execution environment in which a dynamic compiler is implemented, convert the virtual instruction code into a real machine instruction code, and save and reuse the compiled program code to be compiled. Accordingly, a high program execution speed can be maintained even after the restart of the application program, which is the same as before the restart.
[Brief description of the drawings]
FIG. 1 is a configuration diagram of a virtual instruction execution environment and a file system according to an embodiment of the present invention.
FIG. 2 is a diagram illustrating a process of storing a dynamically compiled program code;
FIG. 3 is a diagram showing a file storage format.
FIG. 4 is a diagram showing a process of reading a dynamically compiled program code.
FIG. 5 is a diagram showing an error route of a designated file error.
FIG. 6 is a diagram showing an error route of a version check error.
FIG. 7 is a diagram showing an error route for invalid file contents.
FIG. 8 is a diagram showing an error route of an integrity verification error.
FIG. 9 is an explanatory diagram of a consistency verification method.
[Explanation of symbols]
Reference Signs List 10 virtual instruction execution environment 11 user interface unit 12 file operation control unit 13 file conversion unit 14 version management unit 15 consistency verification unit 20 file system 21 dynamically compiled program code storage file 22 dynamically compiled program code 23 execution program class File

Claims (9)

プログラム実行時の動的なデータを基に仮想命令コードの最適化および実マシン命令コードへの変換をプログラムを実行しながら動的に行うコンパイラを実装した仮想命令コード実行環境において、
動的コンパイルにより最適化済みのコンパイル済みプログラムコードを外部ファイルに保存し、仮想命令コード実行環境の起動時に、保存されている外部ファイルを読み出し、コンパイル結果を再利用するコンパイル済みプログラムコード再利用方法。
In a virtual instruction code execution environment that implements a compiler that dynamically optimizes a virtual instruction code and converts it into a real machine instruction code based on dynamic data during program execution while executing the program,
A method for reusing a compiled program code in which a compiled program code optimized by dynamic compilation is stored in an external file, and when the virtual instruction code execution environment is started, the stored external file is read and a compilation result is reused. .
仮想命令コード実行環境起動時に読み出した、コンパイル済みプログラムコードが保存されている外部ファイルのファイル形式およびファイルの内容が正当であるかを検証する、請求項1に記載のコンパイル済みプログラムコード再利用方法。2. The method for reusing a compiled program code according to claim 1, wherein the file format of the external file storing the compiled program code and the content of the file read out at the time of starting the virtual instruction code execution environment are verified. . 仮想命令コード実行環境起動時に読み出した、コンパイル済みプログラムコードが保存されている外部ファイルの内容と、実行しようとしているアプリケーションプログラムとの整合性の検証を行う、請求項1または2に記載のコンパイル済みプログラムコード再利用方法。3. The compiled instruction according to claim 1 or 2, wherein verification of consistency between the content of the external file in which the compiled program code is stored and read out at the time of starting the virtual instruction code execution environment and the application program to be executed is performed. How to reuse program code. コンパイル済みプログラムコードを保存した外部ファイルのバーションと、その外部ファイルを読み出した仮想命令コード実行環境のバージョンの互換性を検証する、請求項1から3のいずれか1項に記載のコンパイル済みプログラムコード再利用方法。The compiled program according to any one of claims 1 to 3, wherein the compatibility of the version of the external file storing the compiled program code with the version of the virtual instruction code execution environment from which the external file is read is verified. Code reuse method. プログラム実行時の動的なデータを基に仮想命令コードの最適化および実マシン命令コードへの変換をプログラムを実行しながら動的に行う動的コンパイラを実装した仮想命令コード実行環境において、
該仮想命令実行環境内の動的コンパイル済みプログラムコードを取得し、ファイルとして保存可能な形式に変換する手段と、
変換されたコンパイル済みプログラムコードを、指定されたファイル名で外部ファイルに保存し、また指定されたファイル名のファイルを前記外部ファイルから読み出す手段と、
前記外部ファイルから読み出されたファイルを内部データ形式のコンパイル済みプログラムコードに変換し、仮想メモリ上に動的コンパイル済みプログラムコードとしてコピーする手段を有する、コンパイル済みプログラムコード再利用装置。
In a virtual instruction code execution environment implementing a dynamic compiler that dynamically optimizes a virtual instruction code based on dynamic data at the time of program execution and converts it into a real machine instruction code while executing the program,
Means for obtaining a dynamically compiled program code in the virtual instruction execution environment and converting the program code into a format storable as a file;
Means for storing the converted compiled program code in an external file with a specified file name, and for reading a file with a specified file name from the external file;
An apparatus for reusing a compiled program code, comprising: means for converting a file read from the external file into a compiled program code in an internal data format and copying it as a dynamically compiled program code on a virtual memory.
仮想命令コード実行環境起動時に読み出した、コンパイル済みプログラムコードが保存されている外部ファイルのファイル形式およびファイルの内容が正当であるかを検証する手段を有する、請求項5に記載のコンパイル済みプログラムコード再利用装置。6. The compiled program code according to claim 5, further comprising means for verifying whether the file format and the contents of the external file in which the compiled program code is stored and read out at the time of starting the virtual instruction code execution environment are valid. Recycling device. 仮想命令コード実行環境起動時に読み出した、コンパイル済みプログラムコードが保存されている外部ファイルの内容と、実行しようとしているアプリケーションプログラムとの整合性の検証を行う手段を有する、請求項5または6に記載のコンパイル済みプログラムコード再利用装置。7. The apparatus according to claim 5, further comprising means for verifying the consistency between the content of the external file in which the compiled program code is read and read at the time of starting the virtual instruction code execution environment and the application program to be executed. Compiled program code reuse device. コンパイル済みプログラムコードを保存した外部ファイルのバーションと、その外部ファイルを読み出した仮想命令コード実行環境のバージョンの互換性を検証する手段を有する、請求項5から7のいずれか1項記載のコンパイル済みプログラムコード再利用装置。The compile according to any one of claims 5 to 7, further comprising means for verifying compatibility between a version of the external file storing the compiled program code and a version of the virtual instruction code execution environment from which the external file is read. Used program code reuse device. 請求項1から4のいずれか1項に記載のコンパイル済みプログラムコード再利用方法をコンピュータに実行させるためのプログラム。A program for causing a computer to execute the compiled program code reuse method according to any one of claims 1 to 4.
JP2002240640A 2002-08-21 2002-08-21 Reuse method of compiled program code, system, and program Pending JP2004078751A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002240640A JP2004078751A (en) 2002-08-21 2002-08-21 Reuse method of compiled program code, system, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002240640A JP2004078751A (en) 2002-08-21 2002-08-21 Reuse method of compiled program code, system, and program

Publications (1)

Publication Number Publication Date
JP2004078751A true JP2004078751A (en) 2004-03-11

Family

ID=32023369

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002240640A Pending JP2004078751A (en) 2002-08-21 2002-08-21 Reuse method of compiled program code, system, and program

Country Status (1)

Country Link
JP (1) JP2004078751A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010267264A (en) * 2009-05-15 2010-11-25 Internatl Business Mach Corp <Ibm> Method for constructing executable code for component-based application, computer-readable storage medium for executing the method, and compiler
JP2011221609A (en) * 2010-04-05 2011-11-04 International Business Maschines Corporation Dynamic compiler program, dynamic compilation method and dynamic compilation device
CN111142848A (en) * 2018-11-05 2020-05-12 深圳Tcl新技术有限公司 Software program compiling method, software program executing method and software program compiling device

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010267264A (en) * 2009-05-15 2010-11-25 Internatl Business Mach Corp <Ibm> Method for constructing executable code for component-based application, computer-readable storage medium for executing the method, and compiler
US8943482B2 (en) 2009-05-15 2015-01-27 International Business Machines Corporation Incrementally constructing executable code for component-based applications
JP2011221609A (en) * 2010-04-05 2011-11-04 International Business Maschines Corporation Dynamic compiler program, dynamic compilation method and dynamic compilation device
CN111142848A (en) * 2018-11-05 2020-05-12 深圳Tcl新技术有限公司 Software program compiling method, software program executing method and software program compiling device

Similar Documents

Publication Publication Date Title
KR101966754B1 (en) Generating and caching software code
CN101751273B (en) Safety guide device and method for embedded system
RU2520344C2 (en) Caching runtime generated code
JP5650240B2 (en) Technology for runtime provisioning of executable code using off-device services
US7117371B1 (en) Shared names
US8418169B2 (en) Management method for managing software module and information processor
EP2082318B1 (en) Register-based instruction optimization for facilitating efficient emulation of an instruction stream
US20200065124A1 (en) Shortening just-in-time code warm up time of docker containers
KR101823016B1 (en) Reducing web browsing overheads with external code certification
US20060161898A1 (en) Method and system for project library dependency management
JPH11242597A (en) Method for generation of flow graph of java byte code data
US7941792B2 (en) System and method for compiling program code ahead of time
JP2005085255A (en) Method and device for developing source program on target system base
JP4698925B2 (en) System and method for verifying authenticity of dynamically connectable executable images
KR20120054914A (en) File processing device for executing preprocessed file and recording medium for executing preprocessed file
JP2004078751A (en) Reuse method of compiled program code, system, and program
US7080370B1 (en) Method and apparatus for compiling source programs using one or more libraries
CN105447040A (en) Binary file management and update method and device, and binary file management system
US9940334B2 (en) Image forming apparatus and control method thereof
CN115544496A (en) Server-free computing method, device and equipment based on trusted execution environment
JP2003330736A (en) Unauthorized resource use preventing system, method and program therefor
JP2022150518A (en) Test processing program, test processing method, and information processing apparatus
Sewell et al. Cakes That Bake Cakes: Dynamic Computation in CakeML
JP2010140233A (en) Emulation system and emulation method
JP2007128537A (en) System and method for verifying authenticity of dynamically connectable execution image