JP4125056B2 - Log acquisition method - Google Patents

Log acquisition method Download PDF

Info

Publication number
JP4125056B2
JP4125056B2 JP2002191130A JP2002191130A JP4125056B2 JP 4125056 B2 JP4125056 B2 JP 4125056B2 JP 2002191130 A JP2002191130 A JP 2002191130A JP 2002191130 A JP2002191130 A JP 2002191130A JP 4125056 B2 JP4125056 B2 JP 4125056B2
Authority
JP
Japan
Prior art keywords
log
function
memory
address
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.)
Expired - Fee Related
Application number
JP2002191130A
Other languages
Japanese (ja)
Other versions
JP2004038314A (en
Inventor
利明 飯塚
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2002191130A priority Critical patent/JP4125056B2/en
Priority to US10/465,280 priority patent/US7188279B2/en
Priority to EP03254034A priority patent/EP1376365A3/en
Priority to CN03149336.XA priority patent/CN1276355C/en
Publication of JP2004038314A publication Critical patent/JP2004038314A/en
Application granted granted Critical
Publication of JP4125056B2 publication Critical patent/JP4125056B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Debugging And Monitoring (AREA)

Description

【0001】
【発明の属する技術分野】
本発明は、複数にモジュール分けされたソフトウェアの処理ログを取得するための技術に関するものである。
【0002】
【従来の技術】
従来より、再現率の低いソフトウェアの障害に対しては、ソフトウェアの処理ログを取得し、当該処理ログを解析することによって、障害の原因をつきとめ、その対策を講じてきた。
【0003】
【発明が解決しようとする課題】
しかし、上記従来の処理ログの取得には以下のような問題点がある。
(1)ユーザの動作環境でもログを取得しつづけるためには、ソフトウェアのモジュール自体に手を加え、処理ログ取得ルーチンを追加しなければならず、処理ログ取得のための作業負荷が大きかった。
(2)処理ログ取得はモジュール毎に行うため、生成されたログはモジュール単位のものとなってしまい、ソフトウェア全体の処理を、完全に時間順のログとして取得するのが困難である。このため、全体の処理ログとしての見通しが悪く、ログを解析して障害の原因を発見するまでのプロセスに工数がかかっていた。
【0004】
本発明は、上記課題を鑑みてなされたものであり、複数にモジュール分けされたソフトウェアの処理ログを容易に取得でき、かつ、ソフトウェアの障害の原因の解析のための工数を削減することが可能なログ取得方法、ならびに該方法をコンピュータによって実現させるためのプログラム、および該プログラムを格納した記憶媒体を提供することを目的とする。
【0005】
【課題を解決するための手段】
上記の目的を達成するために本発明に係るログ取得方法は以下のような構成を備える。即ち、
関数を記憶したダイナミックリンクライブラリと、該関数のアドレスを記憶したインポート関数アドレステーブルと、該ダイナミックリンクライブラリ内の関数を呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記ダイナミックリンクライブラリ内の各関数に対応するログ取得のための関数を当該ダイナミックリンクライブラリ内にロードし、前記インポート関数アドレステーブル上に記憶された各関数のアドレスを、対応する前記ログ取得のための関数のアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象の関数に対する前記インポート関数アドレステーブル上の書き換え後の前記対応するログ取得のための関数のアドレスに基づいて、前記ログ取得のための関数を呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータが構造体として定義されているか否かを判断する工程と、
前記ログ取得手段が、前記パラメータが構造体として定義されている場合、前記関数定義において該構造体のメモリ配置を規定したパッキングオプションに基づいて、該構造体の内容を前記ログメモリに配置し、該メモリに配置された構造体の内容を前記ディスク装置にログとして記録する工程と、
前記ログ取得手段が、前記呼び出し手段により呼び出された前記ログ取得のための関数に対応する前記呼び出し対象の関数を呼び出して、該呼び出し対象の関数を前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータまたは戻り値が構造体として定義されているか否かを第2の判断する工程と、
前記配置手段が、前記パラメータまたは戻り値が構造体として定義されている場合、前記関数定義において該構造体のメモリ配置を規定したパッキングオプションに基づいて、該構造体の内容を前記ログメモリに配置し、該メモリに配置された構造体の内容を前記ディスク装置にログとして記録する工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程とを備える。
【0006】
【発明の実施の形態】
【第1の実施形態】
本実施形態は、あるモジュールから別のモジュール内に存在する関数の呼び出しが行われる際の仕組みである、メモリに保持されたインポート関数アドレス、または仮想関数アドレステーブル(Virtual Address Table)を利用して、モジュール間の関数呼び出しをフックしてログに記録することで、ソフトウェアのモジュール自体に手を加えることなく、ソフトウエア全体の処理を、時間順のログとして取得することを可能にするものである。以下に具体的に説明する。
【0007】
<システム構成>
図1は、本発明の各実施形態にかかるログ取得方法を実現するコンピュータ(ソフトウェア評価システム)の構成をあらわす図である。説明を簡略化するために、本実施形態では、本ソフトウェア評価システムが1台のPC内部に構築されるものとするが、本発明のログ取得方法の特徴は1台のPC内部に構築されるか、あるいは複数のPCにネットワークシステムとして構築されるかによらず有効である。
【0008】
本ソフトウェア評価システムを搭載するコンピュータには、CPU1、チップセット2、RAM3、ハードディスクコントローラ4、ディスプレイコントローラ5、ハードディスクドライブ6、CD−ROMドライブ7、ディスプレイ8が搭載されている。また、CPUとチップセットを繋ぐ信号線11、チップセット2とRAM3とを繋ぐ信号線12、チップセット2と各種周辺機器とを繋ぐ周辺機器バス13、ハードディスクコントローラ4とハードディスクドライブ6とを繋ぐ信号線14、ハードディスクコントローラ4とCD−ROMドライブ7とを繋ぐ信号線15、ディスプレイコントローラ5とディスプレイ8とを繋ぐ信号線16が搭載されている。
【0009】
<関数処理に対する処理ログ取得>
本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムを説明するために、まず図2によって、複数のモジュールに分かれたソフトウェアが、通常の状態でどのようにメモリにロードされるかを説明する。
【0010】
通常、複数のモジュールに分かれたソフトウェアは、全体の制御を行う実行ファイルEXE(23)と、モジュールとして存在しEXEの補完的な役割を担うダイナミックリンクライブラリDLL(27)とに分かれており、メモリにはEXEとDLLの両方がロードされる。EXEはコードセグメント(28)とデータセグメント(29)、そしてインポート関数アドレステーブル(22)から成っている。更に、インポート関数アドレステーブルは、関数の所属するDLLによって分かれており(21, 24)、DLLごとにそれぞれの関数がロードされたアドレスが書かれている(30〜35)。DLLの関数の実体は、DLLごとに分かれて(25, 26)ロードされ、それぞれの関数は該当するDLLの一部としてロードされる(36〜41)。この図では、1本のEXEがA.DLL及びB.DLLの2つのダイナミックリンクライブラリ内の関数を使用している例を示しており、実際に使用される関数はFunc AA, Func AB, Func AC, Func BA, Func BB, Func BCの6個となっている。
【0011】
EXEのコードセグメント内にあるコードが関数Func AAを呼び出す場合には、まずインポート関数アドレステーブル内に書かれたFunc AAのアドレス(30)が読み込まれる。ここには実際にはA.DLLの一部として読み込まれたFunc AAコード(36)のアドレスが書かれており、そのアドレスをコールすることによって、EXEのコードはA.DLLのFunc AAを呼び出すことができる。
【0012】
図3は、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのメモリ構成をあらわす図であり、図2とは、ログ取得用のコードに対してIAT Patch(Import Address Table Patch)という手法を用いて、関数呼び出しをリダイレクトしているという点で異なっている。
【0013】
ログ取得が開始されると、メモリ内にはIAT Patch用のDLLであるC.DLL(58)がロードされる。C.DLLはインポート関数アドレステーブル(52)内に書かれた関数のアドレスを、C.DLL内のログ取得コードであるFunc CAA, Func CAB, Func CAC, Func CBA,Func CBB, Func CBCのアドレスに書き換える(61〜66)。C.DLL内のFunc CAA, Func CAB, Func CAC, Func CBA, Func CBB, Func CBCのコード(73〜78)は、ログを記録すると共に、元々の関数呼び出しを受けるべくメモリにロードされている、該当する関数であるFunc AA, Func AB, Func AC, Func BA, Func BB, Func BC(67〜72)を呼び出す。
【0014】
図4Aは、図3におけるIAT Patchの処理をあらわす図、図4Bはログ取得処理の流れを示すフローチャートである。説明を簡略化するために、この図ではEXEがA.DLL内のFunc AAを呼び出す際に、IAT Patchによるログ取得コードがどのように動作するかの例をあらわしている。
【0015】
EXE(図4Aの91)がFunc AAをコールすると(図4Aの94)、C.DLL内にあるログ取得コードがDLL名/関数名をメモリに保存し(図4BのステップS402)、呼び出し時刻をメモリに保存し、呼び出し時のパラメータをメモリに保存し、呼び出し時のポインタパラメータの指すメモリ内容を、別メモリに保存する(図4Aの95、図4BのステップS403)。その後C.DLLは本来呼び出されるはずであった、A.DLL(図4Aの93)内のFunc AAをコールする(図4Aの96、図4BのステップS404)。A.DLLのFunc AA処理(図4Aの97)が終了し、C.DLLに制御がリターンすると(図4Aの98)、C.DLLはリターン時の時刻をメモリに保存し、戻り値をメモリに保存し、リターン時にポインタパラメータが指すメモリ内容を、別メモリに保存する(図4Aの99)。その後、C.DLLは保存したログ情報をファイルに書き込み(図4Aの100、図4BのステップS405)、あたかもA.DLLのFunc AAが通常通りに終了したかのように、EXEにリターンする(101)。
【0016】
図5は、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの内部構成をあらわす図である。通常は実行形式のEXE(113)が、DLL−1(116)やDLL−2(117)内の関数を呼び出すが、ここではAPIトレーサと呼ばれるログ取得コードを埋め込み(114)、処理ログを生成している(115)。APIトレーサは、DLL−1やDLL−2の関数定義を記述したファイル(111)と、どのDLLのどの関数のインポート関数テーブルを書き換えてログを取得するかの設定シナリオ(トレースシナリオ112)を元に動作する。
【0017】
<メソッド処理に対する処理ログ取得>
次に、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおいて、実行ファイルEXE(118)がCOM(Component Object Model)サーバでエクスポートされているインターフェースのインスタンス作成時に、どのようにメモリにロードされるかを説明するために、まず、図6によって、通常の状態でどのようにメモリにロードされるかを説明する。
【0018】
通常、インターフェースのインスタンス作成を行うと、COMサーバ内で、要求されたインターフェース(121, 122)と、そのメソッド(:オブジェクト指向プログラミングにおいて、オブジェクトの実行する手続きを記述したプログラム、130〜135)が作成され、それらは、メモリ上に両方がロードされる。ここで、virtual address table(仮想アドレステーブル)は作成された各インターフェース毎に作られ(118, 120)、作成要求を行ったEXEに渡される。このvirtual addres tableには各メソッドの作成されたアドレスが書かれている(124〜129)。EXEはこれら情報を利用し、各インターフェースに対して呼び出しを行う。この図では、1本のEXEがInterface A及びInterface Bの2つのインターフェースのインスタンスを作成しており、そのインターフェース内部のメソッドを使用している例を示しており、実際に使用されているメソッドは、Method AA, Method AB, Method AC, Method BA, Method BB, Method BCとなっている。
【0019】
EXEのコードが関数Method AAを呼び出す場合には、まずvirtual address table内に書かれたMethod AAのアドレス(124)が読み込まれる。ここには実際にはCOMサーバのInterface Aの一部として作成されたMethod AAコード(130)のアドレスが書かれており、そのアドレスをコールすることによって、EXEのコードはInterface AのMethod AAを呼び出すことができる。
【0020】
図7は、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのメモリ構成をあらわす図であり、図6とは、ログ取得用のコードに対してVTable Patch(virtual address table Patch)という手法を用いて、メソッド呼び出しをリダイレクトしているという点で異なっている。
【0021】
ログ取得が開始されると、メモリ内にはVTable Patch用のDLL(143)がロードされる。このDLLはvirtual address table(136, 138)内に書かれたメソッドのアドレスを、DLL内のログ取得コードであるMethod A'A, Method A'B, MethodA'C, Method B'A, Method B'B, Method B'Cのアドレスに書き換える(145〜150)。DLL内のMethod A'A,Method A'B, Method A'C, Method B'A, Method B'B, Method B'Cのコード(157〜162)は、ログを記録すると共に、元々のメソッド呼び出しを受けるべくメモリにロードされている、該当するメソッドであるMethod AA, Method AB, Method AC, Method BA, Method BB, MethodBC(157〜162)を呼び出す。
【0022】
図8Aは、図7におけるVTable Patchの処理をあらわす図、図8Bはログ取得処理の流れを示すフローチャートである。説明を簡略化するために、この図ではEXEがCOMサーバ内のInterface AのMethodAAを呼び出す際に、VTable Patchによるログ取得コードがどのように動作するかの例をあらわしている。
【0023】
EXE(図8Aの163)がMethod AAをコールすると(図8Aの166)、DLL内にあるログ取得コードがモジュール名/インターフェース名/メソッド名をメモリに保存し(図8BのステップS802)、呼び出し時刻をメモリに保存し、呼び出し時のパラメータをメモリに保存し、呼び出し時のポインタパラメータの指すメモリ内容を、別メモリに保存する(図8Aの167、図8BのステップS803))。その後DLLは本来呼び出されるはずであった、COMサーバ(図8Aの165)内のMethod AAをコールする(図8Aの168、図8BのステップS804))。COMサーバのMethod AA処理(図8Aの169)が終了し、DLLに制御がリターンすると(図8Aの170)、DLLはリターン時の時刻をメモリに保存し、戻り値をメモリに保存し、リターン時にポインタパラメータが指すメモリ内容を、別メモリに保存する(図8Aの171)。その後、DLLは保存したログ情報をファイルに書き込み(図8Aの172、図8BのステップS805)、あたかもCOMサーバのMethod AAが通常通りに終了したかのように、EXEにリターンする(図8Aの173)。
【0024】
図9は、本発明の第1の実施形態にかかるソフトウェア評価システムの内部構成をあらわす図である。通常は実行形式のEXE(176)が、COMサーバ1(179)やCOMサーバ2(180)内のメソッドを呼び出すが、ここではAPIトレーサと呼ばれるログ取得コードを埋め込み(177)、処理ログを生成している(178)。APIトレーサは、COMサーバ1(179)やCOMサーバ2の関数定義を記述したファイル(174)と、どのCOMサーバのどのインターフェースのどのメソッドのvirtual address tableを書き換えてログを取得するかの設定シナリオ(トレースシナリオ175)を元に動作する。
【0025】
<関数定義ファイル>
図10は、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムに対して、それぞれの関数及びメソッドのパラメータの形式や、戻り値の形式を指示する、関数定義ファイルの例を示す図である。
【0026】
同図において示された、パッキングオプション(PackingOption)のバイト数が、本発明の特徴となる定義部分である。
【0027】
図11は、図10に示した関数定義ファイルを用いて、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムで取得した、ログの一例である。それぞれの呼び出しに対して、関数/メソッドが呼び出された時刻、及びその際のパラメータ/戻り値が、ログとして生成される。
【0028】
図12の説明に入る前に、従来広く用いられている、構造体のパッキングオプションに関して説明する。
【0029】
構造体のパッキングオプションとは、構造体の実体をメモリに配置する際に、どのようなアライメントでメモリに配置するかに関しての取り決めであり、モジュール間で構造体を受け渡しする際に用いられるものである。
【0030】
通常のCPUでは、構造体のメンバはCPUの速度を落とさずに内容をレジスタに読み込むことができるようなメモリ配置に置かれている。例えば、データバス幅が64bitのCPUでは、以下のようなメモリ境界にメンバを配置することで、CPUの速度を落とさずにメモリ内容をレジスタに読み込むことができる。
1 byte data ->0x00000000, 0x00000001, 0x00000002,,,
2 bytes data ->0x00000000, 0x00000002, 0x00000004,,,(least 1 bit is zero)
4 bytes data ->0x00000000, 0x00000004, 0x00000008,,,(least 2 bits are zero)
8 bytes data ->0x00000000, 0x00000008, 0x00000010,,,(least 3 bits are zero)
これは、通常のCPUがメモリアドレスを計算する際に、データサイズで割り切れるメモリアドレスからデータを読み込む方が、そうでないメモリアドレスからデータを読み込むよりも速いという特性に依存している。
【0031】
ただし、このようにデータを配置すると、メモリ内に使用されていない空間が大量に残ることになるため、速度に関しては最適化することができても、使用メモリ量に対しては悪影響を及ぼす。
【0032】
その悪影響を回避するために、通常コンパイラには、構造体パッキングオプションというオプションが用意されている。例えば、8バイトのデータ計算は遅くても構わないため使用メモリ量の低減を優先したいが、4バイト以下のデータに関してはメモリ量よりも速度を優先したいという場合、構造体のパッキングオプションを4としてプログラム(この実施形態においてはEXEとDLLの両方)をコンパイルすることで、次のようなメモリ境界に構造体の各メンバを配置することができる。
1 byte data ->0x00000000, 0x00000001, 0x00000002,,,
2 bytes data ->0x00000000, 0x00000002, 0x00000004,,,(least 1 bit is zero)
4 bytes data ->0x00000000, 0x00000004, 0x00000008,,,(least 2 bits are zero)
8 bytes data ->0x00000000, 0x00000004, 0x00000008,,,(least 2 bits are zero)
この場合は、4バイト以下のデータのみ、データサイズで割り切れるメモリアドレスに配置される。
【0033】
1バイト以下のデータのみ、データサイズで割り切れるメモリアドレスに配置したい場合は、構造体のパッキングオプションを1としてプログラムをコンパイルすることで、次のようなメモリ境界に構造体の各メンバを配置することができる。
1 byte data ->0x00000000, 0x00000001, 0x00000002,,,
2 bytes data ->0x00000000, 0x00000002, 0x00000004,,,(least 1 bit is zero)
4 bytes data ->0x00000000, 0x00000002, 0x00000004,,,(least 1 bit is zero)
8 bytes data ->0x00000000, 0x00000002, 0x00000004,,,(least 1 bit is zero)
2バイト以下のデータのみ、データサイズで割り切れるメモリアドレスに配置したい場合は、構造体のパッキングオプションを2としてプログラムをコンパイルすることで、次のようなメモリ境界に構造体の各メンバを配置することができる。
1 byte data ->0x00000000, 0x00000001, 0x00000002,,,
2 bytes data ->0x00000000, 0x00000001, 0x00000002,,,
4 bytes data ->0x00000000, 0x00000001, 0x00000002,,,
8 bytes data ->0x00000000, 0x00000001, 0x00000002,,,
図12は、以上に説明した構造体のパッキングオプションに関するより具体的な例である。構造体のメンバが1バイトのデータと8バイトのデータの2つである場合、構造体のパッキングオプションに応じて、EXEとDLLの間でパラメータ乃至戻り値として受け渡しされる構造体が、この図のようにメモリに配置される。
【0034】
図13は、構造体のパッキングオプションに関する別の例である。構造体のメンバが1バイトのデータと4バイトのデータの2つである場合、構造体のパッキングオプションに応じて、EXEとDLLの間でパラメータ乃至戻り値として受け渡しされる構造体が、この図のようにメモリに配置される。
【0035】
図14は、構造体のパッキングオプションに関する別の例である。構造体のメンバが1バイトのデータと2バイトのデータの2つである場合、構造体のパッキングオプションに応じて、EXEとDLLの間でパラメータ乃至戻り値として受け渡しされる構造体が、この図のようにメモリに配置される。
【0036】
これらの例はあくまでも構造体のパッキングオプションを説明するための例であり、本発明の効果は構造体パッキングオプションの種類を問わず有効である。本発明は、トレースする関数/メソッドのパラメータ乃至戻り値に構造体が入っている場合に、予め関数定義ファイルで指定された構造体パッキングオプションに応じて、自動的に構造体の内容を展開するところに特徴がある。
【0037】
図15は、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおける、処理の流れを示す図である。
【0038】
設定された関数/メソッドが呼び出されることによって、処理が開始されると(ステップS1)、関数定義ファイルから構造体のパッキングオプションを読み込み(ステップS2)、DLL名/関数名/呼び出し時の時刻をHDDに保存する(ステップS3)。
【0039】
次に、パラメータが構造体として定義されているかどうかを、図10に示した関数定義ファイルに基づいて判断し(ステップS4)、構造体として定義されていない場合は、その呼び出しに対してのパラメータをHDDに保存する(ステップS5)。構造体として定義されている場合は、ステップS2において読み込まれた構造体のパッキングオプションに基づいて構造体の内容をメモリから展開し(ステップS6)、それぞれのメンバをHDDに保存する(ステップS7)。
【0040】
関数内部の処理が終了すると(ステップS8)、DLL名/関数名/終了時の時刻をHDDに保存する(ステップS9)。次に、パラメータ及び戻り値が構造体として定義されているかどうかを、図10に示した関数定義ファイルに基づいて判断し(ステップS10)、構造体として定義されていない場合は、その呼び出しに対してのパラメータ及び戻り値をHDDに保存する(ステップS11)。構造体として定義されている場合は、ステップS2において読み込まれた構造体のパッキングオプションに基づいて構造体の内容をメモリから展開し(ステップS12)、その呼び出しに対してのパラメータ及び戻り値をHDDに保存する(ステップS13)。
【0041】
この処理は、評価対象となるプログラムが終了するまで(ステップS14)続行される。
【0042】
以上の説明から明らかなように、本実施形態にかかるログ取得方法によれば、複数にモジュール分けされたソフトウエアの処理ログの取得において、モジュール自体に変更を加えることなく、モジュール内に用意された関数/メソッドの呼び出しをログとして記録することが可能となり、処理ログ取得のための作業負荷を低減することが可能となる。また、生成されるログは、時間順のログとして取得することができ、ログの解析が容易となるため、ソフトウェアの障害の原因の解析のための工数を削減することが可能となる。さらに、関数定義において、パッキングオプションを用いることで、ログ取得時の使用メモリ量を低減することが可能となる。
【0043】
【第2の実施形態】
上記第1の実施形態では、パッキングオプションを用いることで、ログ取得時の使用メモリ量を低減する場合について述べたが、メモリにバッファリングするログデータの数を制限することで、ログ取得時の使用メモリ量を一定値以下に制限することも可能である。
【0044】
図16は、本発明の第2の実施形態にかかるログ取得方法を実現するソフトウェア評価システムに対して、それぞれの関数及びメソッドのパラメータの形式や、戻り値の形式を指示する、関数定義ファイルの例である。DLL名及び関数/メソッド名を記述し、その関数/メソッドに対する、パラメータ及び戻り値の型が示されている。本実施形態にかかるログ取得方法を実現するソフトウェア評価システムは、この関数定義ファイルによって指示された内容をもとに、それぞれの関数/メソッドがどのようなパラメータ/戻り値を有しているかを判断し、その内容をログとして取得する。
【0045】
図17は、図16に示した関数定義ファイルを用いて、本実施形態にかかるログ取得方法を実現するソフトウェア評価システムで取得した、ログの一例である。それぞれの呼び出しに対して、関数/メソッドが呼び出された時刻、及びその際のパラメータ/戻り値が、ログとして生成される。
【0046】
図18は、図17に示したログをメモリ保存する際の、メモリ構成をあらわす図である。それぞれの関数呼び出しに対して、あるメモリオフセットに対してデータ及びIndexが保存される。
【0047】
図19は、本実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおける、処理の流れを示す図である。
【0048】
設定された関数/メソッドが呼び出されることによって、処理が開始されると(ステップS21)、Indexのカウント用に指定されたレジスタ乃至メモリエリアをゼロにクリアし(ステップS22)、メモリにバッファリングするIndex数の設定を読み込む(ステップS23)。次に、Indexを図18で示されたIndexエリアに保存し(ステップS24)、DLL名/関数名/呼び出し時の時刻をメモリに保存し(ステップS25)、その呼び出しに対してのパラメータをメモリに保存して(ステップS26)、関数/メソッドを呼び出す(ステップS27)。
【0049】
関数内部の処理が終了すると、DLL名/関数名/終了時の時刻をメモリに保存し(ステップS28)、その呼び出しに対してのパラメータ及び戻り値をメモリに保存する(ステップS29)。次に、ステップS23によって読み込まれた設定と現在のIndexとを比較し(ステップS30)、Indexよりも設定の方が大きいか、あるいは同じである場合には、ログデータをHDDに移動せずに、単にIndexをインクリメントして(ステップS31)、ステップS24の処理に戻る。設定よりもIndexの方が大きい場合、メモリに保持されたデータをHDDに移動し、メモリの内容をゼロクリアする(ステップS32)。
【0050】
この処理は、評価対象となるプログラムが終了するまで(ステップS33)続行される。
【0051】
【第3の実施形態】
上記第2の実施形態においては、ログ取得時の使用メモリ量を一定値以下に制限すべく、Index数をカウントすることとしたが、ログデータのサイズにより制限することも可能である。
【0052】
図20は、本発明の第3の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの、別な一例をあらわす処理の流れを示す図である。
【0053】
設定された関数/メソッドが呼び出されることによって、処理が開始されると(ステップS41)、Indexのカウント用に指定されたレジスタ乃至メモリエリアをゼロにクリアし(ステップS42)、メモリにバッファリングするログサイズの設定を読み込む(ステップS43)。次に、Indexを図18で示されたIndexエリアに保存し(ステップS44)、DLL名/関数名/呼び出し時の時刻をメモリに保存し(ステップS45)、その呼び出しに対してのパラメータをメモリに保存して(ステップS46)、関数/メソッドを呼び出す(ステップS47)。関数内部の処理が終了すると、DLL名/関数名/終了時の時刻をメモリに保存し(ステップS48)、その呼び出しに対してのパラメータ及び戻り値をメモリに保存する(ステップS49)。
【0054】
次に、ステップS43によって読み込まれた設定と、現在のIndexまでにメモリに保存されたデータのサイズを比較し(ステップS50)、メモリに保存されたデータのサイズよりも設定されたサイズの方が大きいか、あるいは同じである場合には、ログデータをHDDに移動せずに、単にIndexをインクリメントして(ステップS51)、ステップS44の処理に戻る。設定されたサイズよりも、メモリに保存されたデータのサイズの方が大きい場合、メモリに保持されたデータを一つ前のIndexまでの分だけHDDに移動し、一つ前のIndexまでの分のメモリの内容をゼロクリアする(ステップS52)。一つ前までのデータをメモリからHDDに移動することで、メモリ使用量が指定サイズを超えない状態を保持することができる。
【0055】
この処理は、評価対象となるプログラムが終了するまで(ステップS53)続行される。
【0056】
【第4の実施形態】
図21は、上記第2および第3の実施形態で示された機能を設定するための、ユーザーインターフェイスの例を示す図である。ログのメモリバッファリングを行う設定として、レコード数による指定すなわち第2の実施形態のIndexによる指定と、ログデータのサイズによる指定すなわち第3の実施形態の指定が可能である。
【0057】
【第5の実施形態】
上記各実施形態においては、ログ取得時の使用メモリ量を低減する場合について述べたが、HDDに保存するログファイルのデータ量を低減させることもできる。
【0058】
図22は、本発明の第5の実施形態にかかるログ取得方法を実現するソフトウェア評価システムに対して、それぞれの関数及びメソッドのパラメータの形式や、戻り値の形式を指示する、関数定義ファイルの例を示す図である。DLL名及び関数/メソッド名を記述し、その関数/メソッドに対する、パラメータ及び戻り値の型が示されている。本実施形態にかかるログ取得方法を実現するソフトウェア評価システムは、この関数定義ファイルによって指示された内容を元に、それぞれの関数/メソッドがどのようなパラメータ/戻り値を有しているかを判断し、その内容をログとして取得する。
【0059】
図22において示された、A.DLL内の関数FuncABに対する関数定義は、本実施形態を最もよくあらわすものである。引数には、データの格納先として示されるポインタpBufと、そのデータのサイズとして示されるdwBufSizeが定義されており、pBufとdwBufSizeとの相関、すなわちpBufに格納されたデータのサイズがdwBufSizeによって指示されているという相関が定義されている。
【0060】
図23は、図22に示した関数定義ファイルを用いて、本実施形態にかかるログ取得方法を実現するソフトウェア評価システムで取得した、ログの一例である。それぞれの呼び出しに対して、関数/メソッドが呼び出された時刻、及びその際のパラメータ/戻り値が、ログとして生成される。
【0061】
図23において示された、A.DLL内の関数FuncABに対する呼び出しのログは、図22の関数定義ファイルと共に、本実施形態の特徴を最もよく表すものである。図22に示した関数定義に基づいて、FuncABに対する呼び出しの際には、引数としてのpBufの値だけでなく、その値が指し示すアドレス上にある、dwBufSize分すなわち24byte分のデータが、通常のログとは別のバイナリログとして保存され、そのバイナリログファイル内に保存された、該当するFuncABの呼び出しのID、すなわちDataIDが、追加情報としてログに保存される。
【0062】
図24は、図23に示したログと共に保存された、バイナリログファイルの内容をあらわす例である。タグとしてDataIDが保存され、そのDataID毎にバイナリデータが保存されている。
【0063】
図22〜図24に示された関数定義ファイル、ログ、バイナリログに示された実施形態は、指示するデータが入力データか出力データか、あるいは戻り値かに依存せずに有効である。例えば、関数からの出力パラメータとしてデータアドレスが戻され、更に関数からの戻り値としてデータサイズが出力された場合にも、同様にデータ本体のログを取得することが可能である。
【0064】
図25は、本実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおける、処理の流れを示す図である。
【0065】
設定された関数/メソッドが呼び出されることによって、処理が開始されると(ステップS61)、DLL名/関数名/呼び出し時の時刻をHDDに保存し(ステップS62)、その呼び出しに対してのパラメータをHDDに保存する(ステップS63)。
【0066】
次に、パラメータがメモリアドレスとして定義されているかどうかを、図22に示した関数定義ファイルに基づいて判断し(ステップS64)、定義されている場合は、サイズをあらわす引数からデータサイズを取得し(ステップS65)、そのサイズ分のデータをメモリから読み込んで(ステップS66)、DataIDをつけてデータをHDDのバイナリログファイルに保存する(ステップS67)。パラメータがメモリアドレスとして定義されていない場合、ステップS65からステップS67の処理は行われない。
【0067】
関数内部の処理が終了すると(ステップS68)、DLL名/関数名/終了時の時刻をHDDに保存し(ステップS69)、その呼び出しに対してのパラメータ及び戻り値をHDDに保存する(ステップS70)。
【0068】
次に、パラメータがメモリアドレスとして定義されているかどうかを、図22に示した関数定義ファイルに基づいて判断し(ステップS71)、定義されている場合は、サイズをあらわす引数からデータサイズを取得し(ステップS72)、そのサイズ分のデータをメモリから読み込んで(ステップS73)、DataIDをつけてデータをHDDのバイナリログファイルに保存する(ステップS74)。パラメータがメモリアドレスとして定義されていない場合、ステップS72からS74の処理は行われない。
【0069】
この処理は、評価対象となるプログラムが終了するまで(ステップS75)続行される。
【0070】
以上の説明から明らかなように、関数定義ファイルにおいてパラメータがメモリアドレスとして定義され、かつ当該メモリアドレスに該当するバイナリデータをログファイルとして保存する場合において、関数定義ファイルにおいて定義されたサイズ分のバイナリデータのみをログファイルとして保存することにより、HDDに保存するログファイルのデータ量を削減することが可能となる。
【0071】
【第6の実施形態】
上記第5の実施形態では、バイナリパラメータ(パラメータがメモリアドレスとして定義され、そのメモリアドレス上に格納されたバイナリデータ)の保存にあたり、サイズ引数より取得したデータサイズ分のデータを保存することとしたが、指定サイズ以上のデータは保存しないようにすることも可能である。
【0072】
図26及び図27は、本発明の第6の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの、別な一例の処理の流れを示す図である。
【0073】
設定された関数/メソッドが呼び出されることによって、処理が開始されると(ステップS81)、DLL名/関数名/呼び出し時の時刻をHDDに保存し(ステップS82)、その呼び出しに対してのパラメータをHDDに保存する(ステップS83)。
【0074】
次に、パラメータがメモリアドレスとして定義されているかどうかを、図22に示した関数定義ファイルに基づいて判断し(ステップS84)、定義されている場合は、サイズをあらわす引数からデータサイズを取得する(ステップS85)。次に、バイナリデータ取得の上限設定があるかどうかを判断し(ステップS86)、上限設定が行われていない場合は、サイズをあらわす引数に示された全体サイズ分のデータをメモリから読み込んで(ステップS87)、DataIDをつけてデータをHDDのバイナリログファイルに保存する(ステップS88)。上限設定が行われている場合は、設定された上限サイズ分のデータをメモリから読み込んで(ステップS89)、DataIDをつけてデータをHDDのバイナリログファイルに保存する(ステップS90)。パラメータがメモリアドレスとして定義されていない場合、ステップS85からS90の処理は行われない。
【0075】
関数内部の処理が終了すると(ステップS91)、DLL名/関数名/呼び出し時の時刻をHDDに保存し(ステップS92)、その呼び出しに対してのパラメータをHDDに保存する(ステップS93)。
【0076】
次に、パラメータがメモリアドレスとして定義されているかどうかを、図22に示した関数定義ファイルに基づいて判断し(ステップS94)、定義されている場合は、サイズをあらわす引数からデータサイズを取得する(ステップS95)。次に、バイナリデータ取得の上限設定があるかどうかを判断し(ステップS96)、上限設定が行われていない場合は、サイズをあらわす引数に示された全体サイズ分のデータをメモリから読み込んで(ステップS97)、DataIDをつけてデータをHDDのバイナリログファイルに保存する(ステップS98)。上限設定が行われている場合は、設定された上限サイズ分のデータをメモリから読み込んで(ステップS99)、DataIDをつけてデータをHDDのバイナリログファイルに保存する(ステップS100)。パラメータがメモリアドレスとして定義されていない場合、ステップS95からS100の処理は行われない。
【0077】
この処理は、評価対象となるプログラムが終了するまで(ステップS101)続行される。
【0078】
【第7の実施形態】
図28は、第5のおよび第6の実施形態で示された機能を設定するための、ユーザーインターフェイスの例を示す図である。ログに保存する対象として、入力パラメータ、出力パラメータと共に、バイナリパラメータを保存するかどうかの設定が存在し、バイナリパラメータを保存するという設定が行われた場合、第5の実施形態に示した処理が行われる。また、バイナリパラメータを保存するという設定が行なわれ、尚且つ指定サイズ以上のデータは保存しないという設定が行なわれていて、サイズが指定されている場合、第6の実施形態に示した処理が行われる。
【0079】
【第8の実施形態】
図29は、図22に示された基本ログ内に記述されたDataIDと、図23に示されたバイナリログの該DataIDにおけるデータとを関連させるユーザーインターフェイスを示す図である。かかるユーザーインターフェースにより、DataIDにおけるデータを容易に参照することが可能となる。通常ログ表示において、そのパラメータがメモリアドレスをあらわすパラメータであることが明示され、その部分をユーザがマウスクリックなどによって選択することによって、該DataIDに対応するデータが表示される。
【0080】
【他の実施形態】
なお、本発明は、複数の機器(例えばホストコンピュータ,インタフェイス機器、リーダ、プリンタなど)から構成されるシステムに適用しても、一つの機器からなる装置(例えば、複写機、ファクシミリ装置など)に適用してもよい。
【0081】
また、本発明の目的は、前述した実施形態の機能を実現するソフトウェアのプログラムコードを記録した記憶媒体を、システムあるいは装置に供給し、そのシステムあるいは装置のコンピュータ(またはCPUやMPU)が記憶媒体に格納されたプログラムコードを読出し実行することによっても、達成されることは言うまでもない。
【0082】
この場合、記憶媒体から読出されたプログラムコード自体が前述した実施形態の機能を実現することになり、そのプログラムコードを記憶した記憶媒体は本発明を構成することになる。
【0083】
プログラムコードを供給するための記憶媒体としては、例えば、フロッピ(登録商標)ディスク、ハードディスク、光ディスク、光磁気ディスク、CD−ROM、CD−R、磁気テープ、不揮発性のメモリカード、ROMなどを用いることができる。
【0084】
また、コンピュータが読出したプログラムコードを実行することにより、前述した実施形態の機能が実現されるだけでなく、そのプログラムコードの指示に基づき、コンピュータ上で稼働しているOS(オペレーティングシステム)などが実際の処理の一部または全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。
【0085】
さらに、記憶媒体から読出されたプログラムコードが、コンピュータに挿入された機能拡張ボードやコンピュータに接続された機能拡張ユニットに備わるメモリに書込まれた後、そのプログラムコードの指示に基づき、その機能拡張ボードや機能拡張ユニットに備わるCPUなどが実際の処理の一部または全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。
【0086】
【発明の効果】
以上説明したように本発明によれば、複数にモジュール分けされたソフトウェアの処理ログを容易に取得でき、かつ、ソフトウェアの障害の原因の解析のための工数を削減することが可能となる。
【図面の簡単な説明】
【図1】本発明の第1の実施形態にかかるログ取得方法を実現するコンピュータ(ソフトウェア評価システム)の構成をあらわす図である。
【図2】本発明の第1の実施形態にかかるログ取得方法を説明するためにあらわした、関数ロード時の通常のメモリ構成をあらわす図である。
【図3】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのIAT Patch使用時のメモリ構成をあらわす図である。
【図4A】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのIAT Patchを使用時の状態を示す図である。
【図4B】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのログ取得処理の流れを示す図である。
【図5】本発明の第1の実施形態にかかるソフトウェア評価システムのIAT Patchを使用時の内部構成をあらわす図である。
【図6】本発明の第1の実施形態にかかるログ取得方法を説明するためにあらわした、COMサーバのインターフェースのインスタンス作成時の通常のメモリ構成をあらわす図である。
【図7】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのVTable Patch使用時のメモリ構成をあらわす図である。
【図8A】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのVTable Patchを使用時の状態を示す図である。
【図8B】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムのログ取得処理の流れを示す図である。
【図9】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの、内部構成をあらわす図である。
【図10】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムに対して、それぞれの関数及びメソッドのパラメータの形式や、戻り値の形式を指示する、関数定義ファイルの例を示す図である。
【図11】図10に示した関数定義ファイルを用いて、本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムで取得した、ログの一例を示す図である。
【図12】構造体のパッキングオプションに関する具体的な例を示す図である。
【図13】構造体のパッキングオプションに関する別の例を示す図である。
【図14】構造体のパッキングオプションに関する別の例を示す図である。
【図15】本発明の第1の実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおける、処理の流れを示す図である。
【図16】本発明の第2の実施形態にかかるログ取得方法を実現するソフトウェア評価システムに対して、それぞれの関数及びメソッドのパラメータの形式や、戻り値の形式を指示する、関数定義ファイルの例を示す図である。
【図17】図16に示した関数定義ファイルを用いて、本発明の第2の実施形態にかかるログ取得方法を実現するソフトウェア評価システムで取得した、ログの一例を示す図である。
【図18】図17に示したログをメモリ保存する際の、メモリ構成をあらわす図である。
【図19】本発明の第2の実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおける、処理の流れを示す図である。
【図20】本発明の第3の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの、別な一例をあらわす処理の流れを示す図である。
【図21】本発明の第2および第3の実施形態で示された機能を設定するための、ユーザーインターフェイスの例を示す図である。
【図22】本発明の第5の実施形態にかかるログ取得方法を実現するソフトウェア評価システムに対して、それぞれの関数及びメソッドのパラメータの形式や、戻り値の形式を指示する、関数定義ファイルの例を示す図である。
【図23】図22に示した関数定義ファイルを用いて、本発明の第5の実施形態にかかるログ取得方法を実現するソフトウェア評価システムで取得した、ログの一例を示す図である。
【図24】図23に示したログと共に保存された、バイナリログファイルの内容をあらわす図である。
【図25】本発明の第5の実施形態にかかるログ取得方法を実現するソフトウェア評価システムにおける、処理の流れを示す図である。
【図26】本発明の第6の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの、別な一例の処理の流れを示す図である。
【図27】本発明の第6の実施形態にかかるログ取得方法を実現するソフトウェア評価システムの、別な一例の処理の流れを示す図である。
【図28】本発明の第5のおよび第6の実施形態で示された機能を設定するための、ユーザーインターフェイスの例を示す図である。
【図29】図22に示された基本ログ内に記述されたDataIDと、図23に示されたバイナリログの該DataIDにおけるデータとを関連させるユーザーインターフェイスを示す図である。
【符号の説明】
1:CPU
2:チップセット
3:RAM
4:ハードディスクコントローラ
5:ディスプレイコントローラ
6:ハードディスクドライブ
7:CD−ROMドライブ
8:ディスプレイ
11:CPUとチップセットを繋ぐ信号線
12:チップセットとRAMを繋ぐ信号線
13:チップセットと各種周辺機器とを繋ぐ周辺機器バス
14:ハードディスクコントローラとハードディスクドライブを繋ぐ信号線
15:ハードディスクコントローラとCD−ROMドライブを繋ぐ信号線
16:ディスプレイコントローラとディスプレイを繋ぐ信号線
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a technique for acquiring a processing log of software divided into a plurality of modules.
[0002]
[Prior art]
In the past, for software failures with low recall, the cause of the failure has been identified by taking a software processing log and analyzing the processing log, and countermeasures have been taken.
[0003]
[Problems to be solved by the invention]
However, the acquisition of the conventional processing log has the following problems.
(1) In order to continue to acquire logs even in the user's operating environment, the software module itself has to be modified and a processing log acquisition routine has to be added, resulting in a heavy workload for acquiring the processing logs.
(2) Since processing log acquisition is performed for each module, the generated log is for each module, and it is difficult to acquire the entire software processing as a log in time order. For this reason, the prospect as the whole processing log was bad, and it took man-hours to analyze the log and discover the cause of the failure.
[0004]
The present invention has been made in view of the above problems, and can easily acquire a software processing log divided into a plurality of modules, and can reduce the number of steps for analyzing the cause of a software failure. An object of the present invention is to provide a simple log acquisition method, a program for realizing the method by a computer, and a storage medium storing the program.
[0005]
[Means for Solving the Problems]
In order to achieve the above object, a log acquisition method according to the present invention has the following configuration. That is,
A dynamic link library storing functions, an import function address table storing addresses of the functions, and a target program that calls and executes the functions in the dynamic link library; The Program storage means for storing; A storage medium for storing the program; A log memory for temporarily storing a log; a disk device; and an execution means for executing a program, wherein the execution means Storage media A log acquisition method for acquiring a log during execution of the target program in an information processing apparatus comprising a rewriting means implemented by executing a program stored in the memory and a calling means,
The rewriting means loads a log acquisition function corresponding to each function in the dynamic link library into the dynamic link library and stores it in the import function address table before executing the target program. Rewriting the address of each function to the address of the corresponding function for log acquisition;
The call means is configured to acquire the log based on the address of the corresponding function for log acquisition after rewriting on the import function address table for the function to be called that the target program is to call. Starting a log acquisition means realized by calling a function and causing the execution means to execute;
The log acquisition means determining whether a parameter is defined as a structure in the function definition in the target program; and
If the parameter is defined as a structure, the log acquisition means, based on a packing option that defines the memory arrangement of the structure in the function definition, arranges the contents of the structure in the log memory, Recording the contents of the structure arranged in the memory as a log in the disk device;
The log acquisition unit calls the function to be called corresponding to the log acquisition function called by the calling unit, causes the execution unit to execute the call target function, and receives an execution result When,
A step of secondly determining whether or not a parameter or a return value is defined as a structure in the function definition in the target program;
If the parameter or the return value is defined as a structure, the arrangement unit arranges the contents of the structure in the log memory based on a packing option that defines the memory arrangement of the structure in the function definition. And recording the contents of the structure arranged in the memory as a log in the disk device;
The log acquisition means includes a step of passing the execution result to the target program.
[0006]
DETAILED DESCRIPTION OF THE INVENTION
[First Embodiment]
In this embodiment, an import function address stored in a memory or a virtual function address table (Virtual Address Table), which is a mechanism when a function existing in another module is called from one module, is used. By hooking function calls between modules and recording them in the log, it is possible to acquire the entire software process as a log in time order without modifying the software module itself. . This will be specifically described below.
[0007]
<System configuration>
FIG. 1 is a diagram showing the configuration of a computer (software evaluation system) that implements a log acquisition method according to each embodiment of the present invention. In order to simplify the explanation, in this embodiment, it is assumed that the software evaluation system is built inside one PC, but the feature of the log acquisition method of the present invention is built inside one PC. It is effective regardless of whether it is constructed as a network system on a plurality of PCs.
[0008]
A computer on which this software evaluation system is mounted includes a CPU 1, a chip set 2, a RAM 3, a hard disk controller 4, a display controller 5, a hard disk drive 6, a CD-ROM drive 7, and a display 8. Further, a signal line 11 connecting the CPU and the chip set, a signal line 12 connecting the chip set 2 and the RAM 3, a peripheral device bus 13 connecting the chip set 2 and various peripheral devices, and a signal connecting the hard disk controller 4 and the hard disk drive 6. Line 14, signal line 15 connecting hard disk controller 4 and CD-ROM drive 7, and signal line 16 connecting display controller 5 and display 8 are mounted.
[0009]
<Acquire processing log for function processing>
In order to describe the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention, first, referring to FIG. 2, how the software divided into a plurality of modules is loaded into the memory in a normal state. Explain how.
[0010]
Usually, the software divided into a plurality of modules is divided into an executable file EXE (23) that performs overall control and a dynamic link library DLL (27) that exists as a module and plays a complementary role of EXE. Is loaded with both EXE and DLL. EXE consists of a code segment (28), a data segment (29), and an import function address table (22). Furthermore, the import function address table is divided by the DLL to which the function belongs (21, 24), and the address at which each function is loaded is written for each DLL (30-35). The entity of the DLL function is loaded separately for each DLL (25, 26), and each function is loaded as a part of the corresponding DLL (36-41). This figure shows an example in which one EXE uses functions in two dynamic link libraries of A.DLL and B.DLL, and the functions actually used are Func AA, Func AB, and Func. AC, Func BA, Func BB, and Func BC.
[0011]
When the code in the EXE code segment calls the function Func AA, the Func AA address (30) written in the import function address table is first read. Here, the address of the Func AA code (36) actually read as part of A.DLL is written, and by calling that address, the EXE code calls Func AA of A.DLL. be able to.
[0012]
FIG. 3 is a diagram showing a memory configuration of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention. FIG. 2 is different from FIG. 2 in terms of IAT Patch (Import Address) for the log acquisition code. It is different in that the function call is redirected using a technique called “Table Patch”.
[0013]
When log acquisition is started, C.DLL (58), which is a DLL for IAT Patch, is loaded into the memory. C.DLL is the address of the function written in the import function address table (52), and the address of the log acquisition code in C.DLL is Func CAA, Func CAB, Func CAC, Func CBA, Func CBB, Func CBC (61-66). Func CAA, Func CAB, Func CAC, Func CBA, Func CBB, and Func CBC code (73-78) in C. DLL are logged and loaded into memory to receive the original function call The corresponding functions Func AA, Func AB, Func AC, Func BA, Func BB, and Func BC (67 to 72) are called.
[0014]
4A is a diagram showing the processing of the IAT Patch in FIG. 3, and FIG. 4B is a flowchart showing the flow of the log acquisition processing. In order to simplify the explanation, this figure shows an example of how the log acquisition code by IAT Patch operates when EXE calls Fun AA in A.DLL.
[0015]
When EXE (91 in FIG. 4A) calls Func AA (94 in FIG. 4A), the log acquisition code in C.DLL saves the DLL name / function name in memory (step S402 in FIG. 4B), and the call time Is stored in the memory, the parameter at the time of calling is stored in the memory, and the memory content pointed to by the pointer parameter at the time of calling is stored in another memory (95 in FIG. 4A, step S403 in FIG. 4B). After that, C.DLL calls Func AA in A.DLL (93 in FIG. 4A), which was supposed to be called (96 in FIG. 4A, step S404 in FIG. 4B). When the A.DLL Func AA process (97 in FIG. 4A) ends and control returns to C.DLL (98 in FIG. 4A), C.DLL stores the return time in memory and stores the return value in memory. The memory contents pointed to by the pointer parameter at the time of return are stored in another memory (99 in FIG. 4A). Thereafter, C.DLL writes the saved log information to the file (100 in FIG. 4A, step S405 in FIG. 4B), and returns to EXE as if A.DLL Func AA ended normally ( 101).
[0016]
FIG. 5 is a diagram showing the internal configuration of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention. Normally, the executable EXE (113) calls a function in the DLL-1 (116) or DLL-2 (117). Here, a log acquisition code called an API tracer is embedded (114) to generate a processing log. (115). The API tracer is based on a file (111) describing function definitions of DLL-1 and DLL-2, and a setting scenario (trace scenario 112) of rewriting the import function table of which function of which DLL and acquiring the log. To work.
[0017]
<Acquire process log for method process>
Next, in the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention, when an instance of an interface in which the execution file EXE (118) is exported by a COM (Component Object Model) server is created, In order to explain how the data is loaded into the memory, first, how it is loaded into the memory in a normal state will be described with reference to FIG.
[0018]
Normally, when an instance of an interface is created, the requested interface (121, 122) and its method (: a program describing a procedure executed by an object in object-oriented programming, 130 to 135) in the COM server are displayed. They are both loaded into memory. Here, a virtual address table (virtual address table) is created for each created interface (118, 120), and passed to the EXE that made the creation request. In this virtual address table, addresses where each method is created are written (124 to 129). EXE uses these information to make a call to each interface. In this figure, one EXE creates instances of two interfaces, Interface A and Interface B, and shows an example of using the methods inside that interface. , Method AA, Method AB, Method AC, Method BA, Method BB, Method BC.
[0019]
When the EXE code calls the function Method AA, the address (124) of the Method AA written in the virtual address table is first read. Here, the address of the Method AA code (130) created as part of Interface A of the COM server is actually written, and by calling this address, the code of EXE executes Method AA of Interface A. Can be called.
[0020]
FIG. 7 is a diagram showing a memory configuration of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention. FIG. 6 is different from FIG. 6 in terms of VTable Patch (virtual address) for the log acquisition code. This method is different in that the method call is redirected using a method called “table Patch”.
[0021]
When log acquisition is started, a DLL (143) for VTable Patch is loaded in the memory. This DLL uses the address of the method written in the virtual address table (136, 138) as the method A'A, Method A'B, Method A'C, Method B'A, Method B, which is the log acquisition code in the DLL. Rewrite to the address of 'B, Method B'C (145-150). Method A'A, Method A'B, Method A'C, Method B'A, Method B'B, Method B'C code (157-162) in the DLL records the log and the original method Method AA, Method AB, Method AC, Method BA, Method BB, MethodBC (157 to 162), which are the corresponding methods loaded in the memory to receive the call, are called.
[0022]
8A is a diagram showing the processing of the VTable Patch in FIG. 7, and FIG. 8B is a flowchart showing the flow of the log acquisition processing. In order to simplify the explanation, this figure shows an example of how the log acquisition code by VTable Patch operates when EXE calls MethodAA of Interface A in the COM server.
[0023]
When EXE (163 in FIG. 8A) calls Method AA (166 in FIG. 8A), the log acquisition code in the DLL stores the module name / interface name / method name in memory (step S802 in FIG. 8B) and calls The time is saved in the memory, the parameter at the time of calling is saved in the memory, and the memory content pointed to by the pointer parameter at the time of calling is saved in another memory (167 in FIG. 8A, step S803 in FIG. 8B). Thereafter, the DLL calls Method AA in the COM server (165 in FIG. 8A), which was supposed to be called (168 in FIG. 8A, step S804 in FIG. 8B)). When the Method AA process (169 in FIG. 8A) of the COM server ends and control returns to the DLL (170 in FIG. 8A), the DLL stores the return time in the memory, stores the return value in the memory, and returns. The memory content pointed to by the pointer parameter is saved in another memory (171 in FIG. 8A). Thereafter, the DLL writes the saved log information to the file (172 in FIG. 8A, step S805 in FIG. 8B), and returns to EXE as if Method AA of the COM server was terminated normally (in FIG. 8A). 173).
[0024]
FIG. 9 is a diagram showing the internal configuration of the software evaluation system according to the first embodiment of the present invention. Normally, the execution format EXE (176) calls a method in the COM server 1 (179) or the COM server 2 (180). Here, a log acquisition code called an API tracer is embedded (177) to generate a processing log. (178). The API tracer sets a file (174) in which the function definitions of the COM server 1 (179) and the COM server 2 are described, and a virtual address table for which method of which interface of which COM server to acquire a log. Operates based on (trace scenario 175).
[0025]
<Function definition file>
FIG. 10 is a diagram of a function definition file for instructing the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention, the format of each function and method parameter, and the format of the return value. It is a figure which shows an example.
[0026]
The number of bytes of the packing option (PackingOption) shown in the figure is a defining part that characterizes the present invention.
[0027]
FIG. 11 shows an example of a log acquired by the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention using the function definition file shown in FIG. For each call, the time when the function / method is called and the parameters / return values at that time are generated as a log.
[0028]
Prior to the description of FIG. 12, a structure packing option widely used in the past will be described.
[0029]
The structure packing option is an agreement on the alignment of the structure entity in the memory when it is placed in the memory, and is used when passing the structure between modules. is there.
[0030]
In a normal CPU, the members of the structure are placed in a memory arrangement that allows the contents to be read into a register without slowing down the CPU. For example, in a CPU having a data bus width of 64 bits, memory contents can be read into a register without reducing the CPU speed by arranging members on the following memory boundaries.
1 byte data-> 0x00000000, 0x00000001, 0x00000002 ,,,
2 bytes data-> 0x00000000, 0x00000002, 0x00000004 ,,, (least 1 bit is zero)
4 bytes data-> 0x00000000, 0x00000004, 0x00000008 ,,, (least 2 bits are zero)
8 bytes data-> 0x00000000, 0x00000008, 0x00000010 ,,, (least 3 bits are zero)
This depends on the characteristic that when a normal CPU calculates a memory address, it is faster to read data from a memory address that is divisible by the data size than to read data from a memory address that is not.
[0031]
However, if data is arranged in this way, a large amount of unused space remains in the memory, so even if the speed can be optimized, the amount of used memory is adversely affected.
[0032]
In order to avoid this adverse effect, an ordinary compiler has an option called a structure packing option. For example, if you want to give priority to reducing the amount of memory used because 8 bytes of data calculation may be slow, if you want to prioritize speed over the amount of memory for data of 4 bytes or less, set the structure packing option to 4. By compiling the program (both EXE and DLL in this embodiment), each member of the structure can be arranged at the following memory boundary.
1 byte data-> 0x00000000, 0x00000001, 0x00000002 ,,,
2 bytes data-> 0x00000000, 0x00000002, 0x00000004 ,,, (least 1 bit is zero)
4 bytes data-> 0x00000000, 0x00000004, 0x00000008 ,,, (least 2 bits are zero)
8 bytes data-> 0x00000000, 0x00000004, 0x00000008 ,,, (least 2 bits are zero)
In this case, only data of 4 bytes or less is arranged at a memory address divisible by the data size.
[0033]
If you want to place only data of 1 byte or less at a memory address that is divisible by the data size, compile the program with the structure packing option set to 1, and place each member of the structure on the following memory boundary: Can do.
1 byte data-> 0x00000000, 0x00000001, 0x00000002 ,,,
2 bytes data-> 0x00000000, 0x00000002, 0x00000004 ,,, (least 1 bit is zero)
4 bytes data-> 0x00000000, 0x00000002, 0x00000004 ,,, (least 1 bit is zero)
8 bytes data-> 0x00000000, 0x00000002, 0x00000004 ,,, (least 1 bit is zero)
If you want to place only data of 2 bytes or less at memory addresses that are divisible by the data size, compile the program with the structure packing option set to 2, and place each member of the structure on the following memory boundary: Can do.
1 byte data-> 0x00000000, 0x00000001, 0x00000002 ,,,
2 bytes data-> 0x00000000, 0x00000001, 0x00000002 ,,,
4 bytes data-> 0x00000000, 0x00000001, 0x00000002 ,,,
8 bytes data-> 0x00000000, 0x00000001, 0x00000002 ,,,
FIG. 12 is a more specific example regarding the structure packing option described above. When there are two structure members, 1-byte data and 8-byte data, the structure passed as a parameter or return value between EXE and DLL according to the structure packing option is shown in this figure. As shown in FIG.
[0034]
FIG. 13 is another example of a structure packing option. When there are two structure members, 1-byte data and 4-byte data, the structure passed as a parameter or return value between EXE and DLL according to the packing option of the structure is shown in this figure. As shown in FIG.
[0035]
FIG. 14 is another example of a structure packing option. When there are two structure members, 1-byte data and 2-byte data, the structure passed as a parameter or return value between EXE and DLL according to the structure packing option is shown in this figure. As shown in FIG.
[0036]
These examples are merely examples for explaining the structure packing option, and the effect of the present invention is effective regardless of the type of structure packing option. The present invention automatically expands the contents of a structure according to a structure packing option specified in advance in a function definition file when a structure is included in parameters or return values of the function / method to be traced. There is a feature.
[0037]
FIG. 15 is a diagram showing the flow of processing in the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention.
[0038]
When processing is started by calling the set function / method (step S1), the structure packing option is read from the function definition file (step S2), and the DLL name / function name / calling time is set. Saving in the HDD (step S3).
[0039]
Next, it is determined whether the parameter is defined as a structure based on the function definition file shown in FIG. 10 (step S4). If the parameter is not defined as a structure, the parameter for the call is determined. Is stored in the HDD (step S5). If it is defined as a structure, the contents of the structure are expanded from the memory based on the packing option of the structure read in step S2 (step S6), and each member is stored in the HDD (step S7). .
[0040]
When the processing inside the function ends (step S8), the DLL name / function name / end time is stored in the HDD (step S9). Next, it is determined whether or not the parameter and return value are defined as a structure based on the function definition file shown in FIG. 10 (step S10). All parameters and return values are stored in the HDD (step S11). If it is defined as a structure, the contents of the structure are expanded from the memory based on the packing option of the structure read in step S2 (step S12), and parameters and return values for the call are stored in the HDD. (Step S13).
[0041]
This process is continued until the program to be evaluated ends (step S14).
[0042]
As is clear from the above description, according to the log acquisition method according to the present embodiment, the acquisition of the processing log of the software divided into a plurality of modules is prepared in the module without changing the module itself. The function / method calls can be recorded as a log, and the work load for acquiring the processing log can be reduced. In addition, the generated log can be acquired as a chronological log and the log can be easily analyzed. Therefore, the number of steps for analyzing the cause of the software failure can be reduced. Furthermore, by using the packing option in the function definition, it is possible to reduce the amount of memory used at the time of log acquisition.
[0043]
[Second Embodiment]
In the first embodiment, the case where the amount of memory used at the time of log acquisition is reduced by using the packing option has been described. However, by limiting the number of log data buffered in the memory, the log at the time of log acquisition can be reduced. It is also possible to limit the amount of memory used to a certain value or less.
[0044]
FIG. 16 is a diagram of a function definition file for instructing the software evaluation system for realizing the log acquisition method according to the second embodiment of the present invention, the format of each function and method parameter, and the format of the return value. It is an example. The DLL name and the function / method name are described, and the parameter and return type for the function / method are shown. The software evaluation system that implements the log acquisition method according to the present embodiment determines what parameters / return values each function / method has based on the contents instructed by the function definition file. Then, the contents are acquired as a log.
[0045]
FIG. 17 is an example of a log acquired by the software evaluation system that implements the log acquisition method according to the present embodiment using the function definition file shown in FIG. For each call, the time when the function / method is called and the parameters / return values at that time are generated as a log.
[0046]
FIG. 18 is a diagram showing a memory configuration when the log shown in FIG. 17 is stored in the memory. For each function call, the data and index are stored for a certain memory offset.
[0047]
FIG. 19 is a diagram showing a flow of processing in the software evaluation system that implements the log acquisition method according to the present embodiment.
[0048]
When processing is started by calling the set function / method (step S21), the register or memory area designated for the index count is cleared to zero (step S22) and buffered in the memory. The setting of the number of indexes is read (step S23). Next, the Index is stored in the Index area shown in FIG. 18 (step S24), the DLL name / function name / call time is stored in the memory (step S25), and the parameters for the call are stored in the memory. (Step S26), and a function / method is called (step S27).
[0049]
When the processing inside the function ends, the DLL name / function name / end time is stored in the memory (step S28), and the parameters and return values for the call are stored in the memory (step S29). Next, the setting read in step S23 is compared with the current index (step S30). If the setting is greater than or the same as the index, the log data is not moved to the HDD. The index is simply incremented (step S31), and the process returns to step S24. If the index is larger than the setting, the data held in the memory is moved to the HDD, and the contents of the memory are cleared to zero (step S32).
[0050]
This process is continued until the program to be evaluated ends (step S33).
[0051]
[Third Embodiment]
In the second embodiment, the number of indexes is counted in order to limit the amount of memory used at the time of log acquisition to a certain value or less. However, the number of indexes can also be limited by the size of log data.
[0052]
FIG. 20 is a diagram showing a flow of processing representing another example of the software evaluation system for realizing the log acquisition method according to the third embodiment of the present invention.
[0053]
When processing is started by calling the set function / method (step S41), the register or memory area designated for the index count is cleared to zero (step S42) and buffered in the memory. The log size setting is read (step S43). Next, the Index is stored in the Index area shown in FIG. 18 (Step S44), the DLL name / function name / call time is stored in the memory (Step S45), and the parameters for the call are stored in the memory. (Step S46) and call a function / method (step S47). When the processing inside the function ends, the DLL name / function name / end time is stored in the memory (step S48), and the parameters and return value for the call are stored in the memory (step S49).
[0054]
Next, the setting read in step S43 is compared with the size of data stored in the memory up to the current index (step S50), and the set size is larger than the size of the data stored in the memory. If it is larger or the same, the index is simply incremented without moving the log data to the HDD (step S51), and the process returns to step S44. If the size of the data stored in the memory is larger than the set size, the data stored in the memory is moved to the HDD by the amount up to the previous index, and the data up to the previous index is stored. The contents of the memory are cleared to zero (step S52). By moving the previous data from the memory to the HDD, it is possible to maintain a state where the memory usage does not exceed the specified size.
[0055]
This process is continued until the program to be evaluated ends (step S53).
[0056]
[Fourth Embodiment]
FIG. 21 is a diagram showing an example of a user interface for setting the functions shown in the second and third embodiments. As settings for performing log memory buffering, designation by the number of records, that is, designation by the index of the second embodiment, designation by log data size, that is, designation by the third embodiment is possible.
[0057]
[Fifth Embodiment]
In each of the above-described embodiments, the case where the amount of memory used at the time of log acquisition is reduced has been described. However, the amount of data in the log file stored in the HDD can also be reduced.
[0058]
FIG. 22 shows a function definition file for instructing the software evaluation system that implements the log acquisition method according to the fifth embodiment of the present invention, the format of each function and method parameter, and the format of the return value. It is a figure which shows an example. The DLL name and the function / method name are described, and the parameter and return type for the function / method are shown. The software evaluation system that implements the log acquisition method according to the present embodiment determines what parameters / return values each function / method has based on the contents instructed by the function definition file. , Get the contents as a log.
[0059]
As shown in FIG. The function definition for the function FuncAB in the DLL best represents this embodiment. In the argument, a pointer pBuf shown as a data storage destination and dwBufSize shown as the size of the data are defined. The correlation between pBuf and dwBufSize, that is, the size of data stored in pBuf is indicated by dwBufSize. Correlation is defined.
[0060]
FIG. 23 is an example of a log acquired by the software evaluation system that implements the log acquisition method according to the present embodiment using the function definition file shown in FIG. For each call, the time when the function / method is called and the parameters / return values at that time are generated as a log.
[0061]
As shown in FIG. The call log for the function FuncAB in the DLL, together with the function definition file of FIG. 22, best represents the features of this embodiment. Based on the function definition shown in FIG. 22, when calling to FuncAB, not only the value of pBuf as an argument but also dwBufSize, that is, 24 bytes of data on the address indicated by the value, The ID of the corresponding FuncAB call stored in the binary log file, that is, the Data ID, is stored in the log as additional information.
[0062]
FIG. 24 is an example showing the contents of the binary log file saved together with the log shown in FIG. DataID is stored as a tag, and binary data is stored for each DataID.
[0063]
The embodiments shown in the function definition file, log, and binary log shown in FIGS. 22 to 24 are effective regardless of whether the data to be indicated is input data, output data, or a return value. For example, even when a data address is returned as an output parameter from a function and a data size is output as a return value from the function, a log of the data body can be obtained in the same manner.
[0064]
FIG. 25 is a diagram showing the flow of processing in the software evaluation system that implements the log acquisition method according to the present embodiment.
[0065]
When processing is started by calling the set function / method (step S61), the DLL name / function name / calling time is stored in the HDD (step S62), and parameters for the calling are stored. Is stored in the HDD (step S63).
[0066]
Next, it is determined whether or not the parameter is defined as a memory address based on the function definition file shown in FIG. 22 (step S64). If it is defined, the data size is obtained from the argument indicating the size. (Step S65), the data corresponding to the size is read from the memory (Step S66), and the data is added to the data and stored in the binary log file of the HDD (Step S67). If the parameter is not defined as a memory address, the processing from step S65 to step S67 is not performed.
[0067]
When the processing inside the function ends (step S68), the DLL name / function name / end time is stored in the HDD (step S69), and the parameters and return value for the call are stored in the HDD (step S70). ).
[0068]
Next, it is determined whether or not the parameter is defined as a memory address based on the function definition file shown in FIG. 22 (step S71). If the parameter is defined, the data size is obtained from the argument indicating the size. (Step S72), the data corresponding to the size is read from the memory (Step S73), and the data is added to the data and saved in the binary log file of the HDD (Step S74). If the parameter is not defined as a memory address, the processing of steps S72 to S74 is not performed.
[0069]
This process is continued until the program to be evaluated ends (step S75).
[0070]
As is clear from the above description, when a parameter is defined as a memory address in the function definition file and binary data corresponding to the memory address is saved as a log file, binary of the size defined in the function definition file is stored. By storing only data as a log file, it is possible to reduce the amount of data in the log file stored in the HDD.
[0071]
[Sixth Embodiment]
In the fifth embodiment, when storing binary parameters (binary data in which parameters are defined as memory addresses and stored on the memory addresses), data corresponding to the data size acquired from the size argument is stored. However, it is possible not to store data larger than the specified size.
[0072]
FIG. 26 and FIG. 27 are diagrams showing another example of the processing flow of the software evaluation system that implements the log acquisition method according to the sixth embodiment of the present invention.
[0073]
When processing is started by calling the set function / method (step S81), the DLL name / function name / call time is stored in the HDD (step S82), and parameters for the call are stored. Is stored in the HDD (step S83).
[0074]
Next, it is determined whether or not the parameter is defined as a memory address based on the function definition file shown in FIG. 22 (step S84). If it is defined, the data size is acquired from the argument indicating the size. (Step S85). Next, it is determined whether or not there is an upper limit setting for binary data acquisition (step S86). If the upper limit setting is not performed, data for the entire size indicated in the argument representing the size is read from the memory ( In step S87), the data is stored in the binary log file of the HDD with DataID (step S88). If the upper limit has been set, data for the set upper limit size is read from the memory (step S89), and the data is stored in the binary log file of the HDD with DataID (step S90). If the parameter is not defined as a memory address, the processing from step S85 to S90 is not performed.
[0075]
When the processing inside the function ends (step S91), the DLL name / function name / call time is stored in the HDD (step S92), and the parameters for the call are stored in the HDD (step S93).
[0076]
Next, it is determined whether or not the parameter is defined as a memory address based on the function definition file shown in FIG. 22 (step S94). If it is defined, the data size is acquired from the argument indicating the size. (Step S95). Next, it is determined whether there is an upper limit setting for binary data acquisition (step S96). If no upper limit setting has been made, data for the entire size indicated in the argument representing the size is read from the memory ( In step S97), DataID is added and the data is stored in the binary log file of the HDD (step S98). If the upper limit has been set, data for the set upper limit size is read from the memory (step S99), and the data is stored in the binary log file of the HDD with DataID (step S100). If the parameter is not defined as a memory address, the processing from step S95 to S100 is not performed.
[0077]
This process is continued until the program to be evaluated ends (step S101).
[0078]
[Seventh embodiment]
FIG. 28 is a diagram showing an example of a user interface for setting the functions shown in the fifth and sixth embodiments. As a target to be saved in the log, there is a setting for whether to save a binary parameter together with an input parameter and an output parameter, and when the setting for saving a binary parameter is performed, the processing shown in the fifth embodiment is performed. Done. Further, when the setting for saving the binary parameter is made and the setting for not saving the data larger than the designated size is made and the size is designated, the processing shown in the sixth embodiment is performed. Is called.
[0079]
[Eighth embodiment]
FIG. 29 is a diagram showing a user interface that associates the DataID described in the basic log shown in FIG. 22 with the data in the DataID of the binary log shown in FIG. With such a user interface, it is possible to easily refer to data in DataID. In the normal log display, it is clearly indicated that the parameter is a parameter representing a memory address, and when the user selects the portion by mouse click or the like, data corresponding to the DataID is displayed.
[0080]
[Other Embodiments]
Note that the present invention can be applied to a system including a plurality of devices (for example, a host computer, an interface device, a reader, and a printer), and a device (for example, a copying machine and a facsimile device) including a single device. You may apply to.
[0081]
Another object of the present invention is to supply a storage medium storing software program codes for implementing the functions of the above-described embodiments to a system or apparatus, and the computer (or CPU or MPU) of the system or apparatus stores the storage medium. Needless to say, this can also be achieved by reading and executing the program code stored in the.
[0082]
In this case, the program code itself read from the storage medium realizes the functions of the above-described embodiment, and the storage medium storing the program code constitutes the present invention.
[0083]
As a storage medium for supplying the program code, for example, a floppy (registered trademark) disk, hard disk, optical disk, magneto-optical disk, CD-ROM, CD-R, magnetic tape, nonvolatile memory card, ROM, or the like is used. be able to.
[0084]
Further, by executing the program code read by the computer, not only the functions of the above-described embodiments are realized, but also an OS (operating system) operating on the computer based on the instruction of the program code. It goes without saying that a case where the function of the above-described embodiment is realized by performing part or all of the actual processing and the processing is included.
[0085]
Further, after the program code read from the storage medium is written in a memory provided in a function expansion board inserted into the computer or a function expansion unit connected to the computer, the function expansion is performed based on the instruction of the program code. It goes without saying that the CPU or the like provided in the board or the function expansion unit performs part or all of the actual processing, and the functions of the above-described embodiments are realized by the processing.
[0086]
【The invention's effect】
As described above, according to the present invention, it is possible to easily obtain a processing log of software divided into a plurality of modules, and to reduce the man-hours for analyzing the cause of software failure.
[Brief description of the drawings]
FIG. 1 is a diagram showing a configuration of a computer (software evaluation system) that implements a log acquisition method according to a first embodiment of the present invention.
FIG. 2 is a diagram showing a normal memory configuration at the time of loading a function, for explaining a log acquisition method according to the first embodiment of the present invention;
FIG. 3 is a diagram showing a memory configuration when using the IAT Patch of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 4A is a diagram showing a state when using the IAT Patch of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 4B is a diagram showing a flow of log acquisition processing of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 5 is a diagram showing an internal configuration when using the IAT Patch of the software evaluation system according to the first embodiment of the present invention.
FIG. 6 is a diagram showing a normal memory configuration at the time of creating an instance of a COM server interface, for explaining a log acquisition method according to the first embodiment of the present invention;
FIG. 7 is a diagram showing a memory configuration when using the VTable Patch of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 8A is a diagram showing a state when using the VTable Patch of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 8B is a diagram showing a flow of log acquisition processing of the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 9 is a diagram showing an internal configuration of a software evaluation system that implements a log acquisition method according to the first embodiment of the present invention;
FIG. 10 is a diagram of a function definition file for instructing the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention, the format of each function and method parameter, and the format of a return value; It is a figure which shows an example.
FIG. 11 is a diagram showing an example of a log acquired by the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention using the function definition file shown in FIG.
FIG. 12 is a diagram illustrating a specific example regarding a packing option of a structure.
FIG. 13 is a diagram illustrating another example regarding a structure packing option;
FIG. 14 is a diagram illustrating another example regarding a structure packing option;
FIG. 15 is a diagram showing a flow of processing in the software evaluation system that implements the log acquisition method according to the first embodiment of the present invention;
FIG. 16 is a function definition file for instructing the software evaluation system that implements the log acquisition method according to the second embodiment of the present invention, the format of each function and method parameter, and the format of a return value; It is a figure which shows an example.
FIG. 17 is a diagram showing an example of a log acquired by a software evaluation system that implements a log acquisition method according to the second embodiment of the present invention using the function definition file shown in FIG. 16;
18 is a diagram showing a memory configuration when the log shown in FIG. 17 is stored in the memory.
FIG. 19 is a diagram showing a flow of processing in a software evaluation system that implements a log acquisition method according to the second embodiment of the present invention;
FIG. 20 is a diagram showing a flow of processing representing another example of a software evaluation system that implements a log acquisition method according to the third embodiment of the present invention;
FIG. 21 is a diagram showing an example of a user interface for setting the functions shown in the second and third embodiments of the present invention.
FIG. 22 is a function definition file for instructing the software evaluation system that implements the log acquisition method according to the fifth embodiment of the present invention, the format of each function and method parameter, and the format of a return value; It is a figure which shows an example.
FIG. 23 is a diagram showing an example of a log acquired by a software evaluation system that implements a log acquisition method according to the fifth embodiment of the present invention using the function definition file shown in FIG. 22;
FIG. 24 is a diagram showing the contents of a binary log file saved together with the log shown in FIG.
FIG. 25 is a diagram showing a flow of processing in a software evaluation system for realizing a log acquisition method according to a fifth embodiment of the present invention.
FIG. 26 is a diagram showing another example of the process flow of the software evaluation system that implements the log acquisition method according to the sixth embodiment of the present invention;
FIG. 27 is a diagram showing another example of the process flow of the software evaluation system that implements the log acquisition method according to the sixth embodiment of the present invention;
FIG. 28 is a diagram showing an example of a user interface for setting the functions shown in the fifth and sixth embodiments of the present invention.
29 is a diagram showing a user interface for associating DataID described in the basic log shown in FIG. 22 with data in the DataID of the binary log shown in FIG.
[Explanation of symbols]
1: CPU
2: Chipset
3: RAM
4: Hard disk controller
5: Display controller
6: Hard disk drive
7: CD-ROM drive
8: Display
11: Signal line connecting CPU and chipset
12: Signal line connecting chipset and RAM
13: Peripheral device bus connecting chipset and various peripheral devices
14: Signal line connecting hard disk controller and hard disk drive
15: Signal line connecting hard disk controller and CD-ROM drive
16: Signal line connecting display controller and display

Claims (10)

関数を記憶したダイナミックリンクライブラリと、該関数のアドレスを記憶したインポート関数アドレステーブルと、該ダイナミックリンクライブラリ内の関数を呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記ダイナミックリンクライブラリ内の各関数に対応するログ取得のための関数を当該ダイナミックリンクライブラリ内にロードし、前記インポート関数アドレステーブル上に記憶された各関数のアドレスを、対応する前記ログ取得のための関数のアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象の関数に対する前記インポート関数アドレステーブル上の書き換え後の前記対応するログ取得のための関数のアドレスに基づいて、前記ログ取得のための関数を呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータが構造体として定義されているか否かを判断する工程と、
前記ログ取得手段が、前記パラメータが構造体として定義されている場合、前記関数定義において該構造体のメモリ配置を規定したパッキングオプションに基づいて、該構造体の内容を前記ログメモリに配置し、該メモリに配置された構造体の内容を前記ディスク装置にログとして記録する工程と、
前記ログ取得手段が、前記呼び出し手段により呼び出された前記ログ取得のための関数に対応する前記呼び出し対象の関数を呼び出して、該呼び出し対象の関数を前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータまたは戻り値が構造体として定義されているか否かを第2の判断する工程と、
前記配置手段が、前記パラメータまたは戻り値が構造体として定義されている場合、前記関数定義において該構造体のメモリ配置を規定したパッキングオプションに基づいて、該構造体の内容を前記ログメモリに配置し、該メモリに配置された構造体の内容を前記ディスク装置にログとして記録する工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
A dynamic link library that stores functions, an import function address table that stores addresses of the functions, a program storage unit that stores a target program that calls and executes functions in the dynamic link library, and a memory that stores programs a medium, and the log memory for temporarily storing the log has a disk device, and execution means for executing a program, rewriting the execution unit is realized by executing a program stored in the storage medium A log acquisition method for acquiring a log during execution of the target program in an information processing apparatus comprising:
The rewriting means loads a log acquisition function corresponding to each function in the dynamic link library into the dynamic link library and stores it in the import function address table before executing the target program. Rewriting the address of each function to the address of the corresponding function for log acquisition;
The call means is configured to acquire the log based on the address of the corresponding function for log acquisition after rewriting on the import function address table for the function to be called that the target program is to call. Starting a log acquisition means realized by calling a function and causing the execution means to execute;
The log acquisition means determining whether a parameter is defined as a structure in the function definition in the target program; and
If the parameter is defined as a structure, the log acquisition means, based on a packing option that defines the memory arrangement of the structure in the function definition, arranges the contents of the structure in the log memory, Recording the contents of the structure arranged in the memory as a log in the disk device;
The log acquisition unit calls the function to be called corresponding to the log acquisition function called by the calling unit, causes the execution unit to execute the call target function, and receives an execution result When,
A step of secondly determining whether or not a parameter or a return value is defined as a structure in the function definition in the target program;
If the parameter or the return value is defined as a structure, the arrangement unit arranges the contents of the structure in the log memory based on a packing option that defines the memory arrangement of the structure in the function definition. And recording the contents of the structure arranged in the memory as a log in the disk device;
The log acquisition unit includes a step of passing the execution result to the target program.
関数を記憶したダイナミックリンクライブラリと、該関数のアドレスを記憶したインポート関数アドレステーブルと、該ダイナミックリンクライブラリ内の関数を呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記ダイナミックリンクライブラリ内の各関数に対応するログ取得のための関数を当該ダイナミックリンクライブラリ内にロードし、前記インポート関数アドレステーブル上に記憶された各関数のアドレスを、対応する前記ログ取得のための関数のアドレスに書き換える工程と、
前記呼び出し手段が、前記呼び出し手段が呼び出そうとする呼び出し対象の関数に対する前記インポート関数アドレステーブル上の書き換え後の前記対応するログ取得のための関数のアドレスに基づいて、前記ログ取得のための関数を呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納し、前記呼び出し手段により呼び出された前記ログ取得のための関数に対応する前記呼び出し対象の関数を呼び出して、該呼び出し対象の関数を前記実行手段に実行させる工程と、
前記ログ取得手段が、前記呼び出し対象の関数の実行結果を受け取って該実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記呼び出し対象の関数の呼び出し回数を予め設定された回数と比較して、設定された回数以下であれば、当該呼び出し回数をインクリメントする工程と、
前記ログ取得手段が、前記呼び出し回数が前記設定された回数より大きければ、前記ログメモリに格納されたログを前記ディスク装置に移動させ、保存させる工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
A dynamic link library that stores functions, an import function address table that stores addresses of the functions, a program storage unit that stores a target program that calls and executes functions in the dynamic link library, and a memory that stores programs a medium, and the log memory for temporarily storing the log has a disk device, and execution means for executing a program, rewriting the execution unit is realized by executing a program stored in the storage medium A log acquisition method for acquiring a log during execution of the target program in an information processing apparatus comprising:
The rewriting means loads a log acquisition function corresponding to each function in the dynamic link library into the dynamic link library and stores it in the import function address table before executing the target program. Rewriting the address of each function to the address of the corresponding function for log acquisition;
The call unit is configured to acquire the log based on an address of the corresponding log acquisition function after rewriting on the import function address table for the function to be called that the call unit is to call. Starting a log acquisition means realized by calling a function and causing the execution means to execute;
The log acquisition unit stores a log related to the call by the calling unit in the log memory, calls the function to be called corresponding to the function for log acquisition called by the calling unit, and executes the call Causing the execution means to execute a target function;
The log acquisition means receiving an execution result of the function to be called and storing a log related to the execution result in the log memory;
The log acquisition unit compares the number of calls of the function to be called with a preset number of times, and if the number is less than the set number of times, incrementing the number of calls;
The log acquisition means, if the number of calls is larger than the set number of times, moving the log stored in the log memory to the disk device, and storing the log;
The log acquisition unit includes a step of passing the execution result to the target program.
関数を記憶したダイナミックリンクライブラリと、該関数のアドレスを記憶したインポート関数アドレステーブルと、該ダイナミックリンクライブラリ内の関数を呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記ダイナミックリンクライブラリ内の各関数に対応するログ取得のための関数を当該ダイナミックリンクライブラリ内にロードし、前記インポート関数アドレステーブル上に記憶された各関数のアドレスを、対応する前記ログ取得のための関数のアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象の関数に対する前記インポート関数アドレステーブル上の書き換え後の前記対応するログ取得のための関数のアドレスに基づいて、前記ログ取得のための関数を呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納し、前記呼び出し手段により呼び出された前記ログ取得のための関数に対応する前記呼び出し対象の関数を呼び出して、該呼び出し対象の関数を前記実行手段に実行させる工程と、
前記ログ取得手段が、前記呼び出し対象の関数の実行結果を受け取って該実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記ログメモリに格納されたログのサイズを予め設定されたサイズと比較して、設定されたサイズより大きければ、前記ログメモリに格納されたログを前記ディスク装置に移動させ、保存させる工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
A dynamic link library that stores functions, an import function address table that stores addresses of the functions, a program storage unit that stores a target program that calls and executes functions in the dynamic link library, and a memory that stores programs a medium, and the log memory for temporarily storing the log has a disk device, and execution means for executing a program, rewriting the execution unit is realized by executing a program stored in the storage medium A log acquisition method for acquiring a log during execution of the target program in an information processing apparatus comprising:
The rewriting means loads a log acquisition function corresponding to each function in the dynamic link library into the dynamic link library and stores it in the import function address table before executing the target program. Rewriting the address of each function to the address of the corresponding function for log acquisition;
The call means is configured to acquire the log based on the address of the corresponding function for log acquisition after rewriting on the import function address table for the function to be called that the target program is to call. Starting a log acquisition means realized by calling a function and causing the execution means to execute;
The log acquisition unit stores a log related to the call by the calling unit in the log memory, calls the function to be called corresponding to the function for log acquisition called by the calling unit, and executes the call Causing the execution means to execute a target function;
The log acquisition means receiving an execution result of the function to be called and storing a log related to the execution result in the log memory;
The log acquisition means compares the size of the log stored in the log memory with a preset size, and moves the log stored in the log memory to the disk device if the size is larger than the set size. A process of storing,
The log acquisition unit includes a step of passing the execution result to the target program.
関数を記憶したダイナミックリンクライブラリと、該関数のアドレスを記憶したインポート関数アドレステーブルと、前記ダイナミックリンクライブラリ内の関数を呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記ダイナミックリンクライブラリ内の各関数に対応するログ取得のための関数を当該ダイナミックリンクライブラリ内にロードし、前記インポート関数アドレステーブル上に記憶された各関数のアドレスを、対応する前記ログ取得のための関数のアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象の関数に対する前記インポート関数アドレステーブル上の書き換え後の前記対応するログ取得のための関数のアドレスに基づいて、前記ログ取得のための関数を呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータがメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムの関数定義において定義された、該パラメータのサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記呼び出し手段により呼び出された前記ログ取得のための関数に対応する前記呼び出し対象の関数を呼び出して、該呼び出し対象の関数を前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータまたは戻り値がメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムの関数定義において定義された、該パラメータまたは戻り値のサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記ログ取得手段が、前記関数の実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
A dynamic link library that stores functions, an import function address table that stores addresses of the functions, a program storage unit that stores a target program that calls and executes functions in the dynamic link library, and a memory that stores programs A medium, a log memory for temporarily storing a log, and an execution means for executing a program, the rewriting means realized by executing the program stored in the storage medium by the execution means, and a call A log acquisition method for acquiring a log during execution of the target program, in an information processing apparatus comprising:
The rewriting means loads a log acquisition function corresponding to each function in the dynamic link library into the dynamic link library and stores it in the import function address table before executing the target program. Rewriting the address of each function to the address of the corresponding function for log acquisition;
The call means is configured to acquire the log based on the address of the corresponding function for log acquisition after rewriting on the import function address table for the function to be called that the target program is to call. Starting a log acquisition means realized by calling a function and causing the execution means to execute;
The log acquisition means storing a log related to a call by the calling means in the log memory;
The log acquisition means identifies whether a parameter is defined as a memory address in the function definition in the target program, and when defined as a memory address, is defined in the function definition of the program, Reading the size of the parameter;
Storing binary data on the memory address in the log memory as a log of the read size;
Calling the function to be called corresponding to the function for log acquisition called by the calling means, causing the execution means to execute the function to be called, and receiving an execution result;
The log acquisition means storing a log related to the execution result in the log memory;
The log acquisition unit identifies whether a parameter or a return value is defined as a memory address in the function definition in the target program, and if defined as a memory address, defines in the function definition of the program Reading the size of the parameter or return value,
Storing binary data on the memory address in the log memory as a log of the read size;
The log acquisition unit includes a step of passing the execution result of the function to the target program.
関数を記憶したダイナミックリンクライブラリと、該関数のアドレスを記憶したインポート関数アドレステーブルと、該ダイナミックリンクライブラリ内の関数を呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記ダイナミックリンクライブラリ内の各関数に対応するログ取得のための関数を当該ダイナミックリンクライブラリ内にロードし、前記インポート関数アドレステーブル上に記憶された各関数のアドレスを、対応する前記ログ取得のための関数のアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象の関数に対する前記インポート関数アドレステーブル上の書き換え後の前記対応するログ取得のための関数のアドレスに基づいて、前記ログ取得のための関数を呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータがメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムの関数定義において定義された、該パラメータのサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記読み込まれたサイズと予め設定されたサイズとを比較し、小さい方のサイズ分のバイナリデータを前記ログメモリから前記ディスク装置に移動させ、保存させる工程と、
前記呼び出し手段により呼び出された前記ログ取得のための関数に対応する前記呼び出し対象の関数を呼び出して、該呼び出し対象の関数を前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおける関数定義において、パラメータまたは戻り値がメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムの関数定義において定義された、該パラメータまたは戻り値のサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記読み込まれたサイズと予め設定されたサイズとを比較し、小さい方のサイズ分のバイナリデータを前記ログメモリから前記ディスク装置に移動させ、保存させる工程と、
前記ログ取得手段が、前記関数の実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
A dynamic link library that stores functions, an import function address table that stores addresses of the functions, a program storage unit that stores a target program that calls and executes functions in the dynamic link library, and a memory that stores programs a medium, and the log memory for temporarily storing the log has a disk device, and execution means for executing a program, rewriting the execution unit is realized by executing a program stored in the storage medium A log acquisition method for acquiring a log during execution of the target program in an information processing apparatus comprising:
The rewriting means loads a log acquisition function corresponding to each function in the dynamic link library into the dynamic link library and stores it in the import function address table before executing the target program. Rewriting the address of each function to the address of the corresponding function for log acquisition;
The call means is configured to acquire the log based on the address of the corresponding function for log acquisition after rewriting on the import function address table for the function to be called that the target program is to call. Starting a log acquisition means realized by calling a function and causing the execution means to execute;
The log acquisition means storing a log related to a call by the calling means in the log memory;
The log acquisition means identifies whether a parameter is defined as a memory address in the function definition in the target program, and when defined as a memory address, is defined in the function definition of the program, Reading the size of the parameter;
Storing binary data on the memory address in the log memory as a log of the read size;
Comparing the read size with a preset size, moving binary data for a smaller size from the log memory to the disk device, and storing it;
Calling the function to be called corresponding to the function for log acquisition called by the calling means, causing the execution means to execute the function to be called, and receiving an execution result;
The log acquisition means storing a log related to the execution result in the log memory;
The log acquisition unit identifies whether a parameter or a return value is defined as a memory address in the function definition in the target program, and if defined as a memory address, defines in the function definition of the program Reading the size of the parameter or return value,
Storing binary data on the memory address in the log memory as a log of the read size;
Comparing the read size with a preset size, moving binary data for a smaller size from the log memory to the disk device, and storing it;
The log acquisition unit includes a step of passing the execution result of the function to the target program.
メソッドを記憶したインターフェースと、該メソッドのアドレスを記憶した仮想アドレステーブルと、該インターフェース内のメソッドを呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記インターフェース内の各メソッドに対応するログ取得のためのメソッドをインターフェース内にロードし、前記仮想アドレステーブル上に記憶されたメソッドのアドレスを、対応する前記ログ取得のためのメソッドのアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象のメソッドに対する前記仮想アドレステーブル上の書き換え後の前記対応するログ取得のためのメソッドのアドレスに基づいて、前記ログ取得のためのメソッドを呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記対象プログラムにおけるメソッド定義において、パラメータが構造体として定義されているか否かを判断する工程と、
前記ログ取得手段が、前記パラメータが構造体として定義されている場合、前記メソッド定義において該構造体のメモリ配置を規定したパッキングオプションに基づいて、該構造体の内容を前記ログメモリに配置し、該ログメモリに配置された構造体の内容を前記ディスク装置にログとして記録する工程と、
前記ログ取得手段が、前記呼び出し手段により呼び出された前記ログ取得のためのメソッドに対応する前記呼び出し対象のメソッドを呼び出して、該呼び出し対象のメソッドを前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記対象プログラムにおけるメソッド定義において、パラメータまたは戻り値が構造体として定義されているか否かを第2の判断する工程と、
前記配置手段が、前記パラメータまたは戻り値が構造体として定義されている場合、前記メソッド定義において該構造体のメモリ配置を規定したパッキングオプションに基づいて、該構造体の内容を前記ログメモリに配置し、該ログメモリに配置された構造体の内容を前記ディスク装置にログとして記録する工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
An interface that stores methods, the virtual address table storing an address of the method, a program storage means for storing a target program to be executed by calling a method in the interface, and a storage medium for storing the program, the log Rewriting means, log means for temporarily storing, disk device, and executing means for executing a program, the execution means being realized by executing a program stored in the storage medium , and a calling means A log acquisition method for acquiring a log during execution of the target program,
Before executing the target program, the rewriting means loads a method for log acquisition corresponding to each method in the interface into the interface, and corresponds the method address stored in the virtual address table. Rewriting the address of the method for acquiring the log,
The method for acquiring the log based on the address of the corresponding method for acquiring the log after the rewriting on the virtual address table for the method to be called that the target program is to call by the target program Starting log acquisition means realized by calling and causing the execution means to execute,
The log acquisition means determining whether or not a parameter is defined as a structure in the method definition in the target program; and
When the parameter is defined as a structure, the log acquisition means arranges the contents of the structure in the log memory based on a packing option that defines the memory arrangement of the structure in the method definition, Recording the contents of the structure arranged in the log memory as a log in the disk device;
The log acquisition unit calls the method to be called corresponding to the method for log acquisition called by the calling unit, causes the execution unit to execute the method to be called, and receives an execution result When,
A step of secondly determining whether or not a parameter or a return value is defined as a structure in the method definition in the target program;
In the case where the parameter or return value is defined as a structure, the arrangement means arranges the contents of the structure in the log memory based on a packing option that defines the memory arrangement of the structure in the method definition. And recording the contents of the structure arranged in the log memory as a log in the disk device;
The log acquisition unit includes a step of passing the execution result to the target program.
メソッドを記憶したインターフェースと、該メソッドのアドレスを記憶した仮想アドレステーブルと、該インターフェース内のメソッドを呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記インターフェース内の各メソッドに対応するログ取得のためのメソッドをインターフェース内にロードし、前記仮想アドレステーブル上に記憶されたメソッドのアドレスを、対応する前記ログ取得のためのメソッドのアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象のメソッドに対する前記仮想アドレステーブル上の書き換え後の前記対応するログ取得のためのメソッドのアドレスに基づいて、前記ログ取得のためのメソッドを呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納し、前記呼び出し手段により呼び出された前記ログ取得のためのメソッドに対応する前記呼び出し対象のメソッドを呼び出して、該呼び出し対象のメソッドを前記実行手段に実行させる工程と、
前記ログ取得手段が、前記呼び出し対象のメソッドの実行結果を受け取って該実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記呼び出し対象のメソッドの呼び出し回数を予め設定された回数と比較して、設定された回数以下であれば、当該呼び出し回数をインクリメントする工程と、
前記ログ取得手段が、前記呼び出し回数が前記設定された回数より大きければ、前記ログメモリに格納されたログを前記ディスク装置に移動させ、保存させる工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
An interface that stores methods, the virtual address table storing an address of the method, a program storage means for storing a target program to be executed by calling a method in the interface, and a storage medium for storing the program, the log Rewriting means, log means for temporarily storing, disk device, and executing means for executing a program, the execution means being realized by executing a program stored in the storage medium , and a calling means A log acquisition method for acquiring a log during execution of the target program,
Before executing the target program, the rewriting means loads a method for log acquisition corresponding to each method in the interface into the interface, and corresponds the method address stored in the virtual address table. Rewriting the address of the method for acquiring the log,
The method for acquiring the log based on the address of the corresponding method for acquiring the log after the rewriting on the virtual address table for the method to be called that the target program is to call by the target program Starting log acquisition means realized by calling and causing the execution means to execute,
The log acquisition unit stores a log related to the call by the calling unit in the log memory, calls the method to be called corresponding to the method for log acquisition called by the calling unit, and executes the call Causing the execution means to execute a target method;
The log acquisition means receiving an execution result of the method to be called and storing a log related to the execution result in the log memory;
The log acquisition unit compares the number of calls of the method to be called with a preset number of times, and if the number is less than or equal to the set number of times, increments the number of calls.
The log acquisition means, if the number of calls is larger than the set number of times, moving the log stored in the log memory to the disk device, and storing the log;
The log acquisition unit includes a step of passing the execution result to the target program.
メソッドを記憶したインターフェースと、該メソッドのアドレスを記憶した仮想アドレステーブルと、該インターフェース内のメソッドを呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記インターフェース内の各メソッドに対応するログ取得のためのメソッドをインターフェース内にロードし、前記仮想アドレステーブル上に記憶されたメソッドのアドレスを、対応する前記ログ取得のためのメソッドのアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象のメソッドに対する前記仮想アドレステーブル上の書き換え後の前記対応するログ取得のためのアドレスに基づいて、前記ログ取得のためのメソッドを呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納し、前記呼び出し手段により呼び出された前記ログ取得のためのメソッドに対応する前記呼び出し対象のメソッドを呼び出して、該呼び出し対象のメソッドを前記実行手段に実行させる工程と、
前記ログ取得手段が、前記呼び出し対象のメソッドの実行結果を受け取って該実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記ログメモリに格納されたログのサイズを予め設定されたサイズと比較して、設定されたサイズより大きければ、前記ログメモリに格納されたログを前記ディスク装置に移動させ、保存させる工程と、
前記ログ取得手段が、前記実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
An interface that stores methods, the virtual address table storing an address of the method, a program storage means for storing a target program to be executed by calling a method in the interface, and a storage medium for storing the program, the log Rewriting means, log means for temporarily storing, disk device, and executing means for executing a program, the execution means being realized by executing a program stored in the storage medium , and a calling means A log acquisition method for acquiring a log during execution of the target program,
Said rewriting means, before execution of the target program, the address of the method that was loaded into the interface methods, stored on the virtual address table for the log acquisition for each method in the interface, the corresponding Rewriting the address of the method for acquiring the log,
The calling means calls the method for log acquisition based on the corresponding log acquisition address after rewriting on the virtual address table for the method to be called that the target program is to call. Starting the log acquisition means realized by causing the execution means to execute,
The log acquisition unit stores a log related to the call by the calling unit in the log memory, calls the method to be called corresponding to the method for log acquisition called by the calling unit, and executes the call Causing the execution means to execute a target method;
The log acquisition means receiving an execution result of the method to be called and storing a log related to the execution result in the log memory;
The log acquisition means compares the size of the log stored in the log memory with a preset size, and moves the log stored in the log memory to the disk device if the size is larger than the set size. A process of storing,
The log acquisition unit includes a step of passing the execution result to the target program.
メソッドを記憶したインターフェースと、該メソッドのアドレスを記憶した仮想アドレステーブルと、インターフェース内のメソッドを呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記インターフェース内の各メソッドに対応するログ取得のためのメソッドをインターフェース内にロードし、前記仮想アドレステーブル上に記憶されたメソッドのアドレスを、対応する前記ログ取得のためのメソッドのアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象のメソッドに対する前記仮想アドレステーブル上の書き換え後の前記対応するログ取得のためのメソッドのアドレスに基づいて、前記ログ取得のためのメソッドを呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおけるメソッド定義において、パラメータがメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムのメソッド定義において定義された、該パラメータのサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記呼び出し手段により呼び出された前記ログ取得のためのメソッドに対応する前記呼び出し対象のメソッドを呼び出して、該呼び出し対象のメソッドを前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおけるメソッド定義において、パラメータまたは戻り値がメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムのメソッド定義において定義された、該パラメータまたは戻り値のサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記ログ取得手段が、前記メソッドの実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
An interface that stores methods, the virtual address table storing an address of the method, a program storage means for storing a target program to be executed by calling a method in the interface, and a storage medium for storing the program, the log A log memory for temporary storage; and an execution means for executing a program, the execution means including a rewriting means realized by executing a program stored in the storage medium , and a calling means In the information processing apparatus, a log acquisition method for acquiring a log during execution of the target program,
Before executing the target program, the rewriting means loads a method for log acquisition corresponding to each method in the interface into the interface, and corresponds the method address stored in the virtual address table. Rewriting the address of the method for acquiring the log,
The method for acquiring the log based on the address of the corresponding method for acquiring the log after the rewriting on the virtual address table for the method to be called that the target program is to call by the target program Starting log acquisition means realized by calling and causing the execution means to execute,
The log acquisition means storing a log related to a call by the calling means in the log memory;
The log acquisition means identifies whether or not a parameter is defined as a memory address in the method definition in the target program, and when defined as a memory address, is defined in the method definition of the program, Reading the size of the parameter;
Storing binary data on the memory address in the log memory as a log of the read size;
Calling the method to be called corresponding to the method for log acquisition called by the calling unit, causing the execution unit to execute the method to be called, and receiving an execution result;
The log acquisition means storing a log related to the execution result in the log memory;
The log acquisition unit identifies whether a parameter or a return value is defined as a memory address in a method definition in the target program. If the parameter is defined as a memory address, it is defined in the method definition of the program. Reading the size of the parameter or return value,
Storing binary data on the memory address in the log memory as a log of the read size;
The log acquisition unit includes a step of passing the execution result of the method to the target program.
メソッドを記憶したインターフェースと、該メソッドのアドレスを記憶した仮想アドレステーブルと、該インターフェース内のメソッドを呼び出して実行する対象プログラムと記憶するプログラム記憶手段と、プログラムを記憶する記憶媒体と、ログを一時格納するためのログメモリと、ディスク装置と、プログラムを実行する実行手段とを有し、前記実行手段が前記記憶媒体に記憶されたプログラムを実行することにより実現される書き換え手段と、呼び出し手段とを備えた情報処理装置において、前記対象プログラムの実行中のログを取得するログ取得方法であって、
前記書き換え手段が、前記対象プログラムの実行前に、前記インターフェース内の各メソッドに対応するログ取得のためのメソッドをインターフェース内にロードし、前記仮想アドレステーブル上に記憶されたメソッドのアドレスを、対応する前記ログ取得のためのメソッドのアドレスに書き換える工程と、
前記呼び出し手段が、前記対象プログラムが呼び出そうとする呼び出し対象のメソッドに対する前記仮想アドレステーブル上の書き換え後の前記対応するログ取得のためのメソッドのアドレスに基づいて、前記ログ取得のためのメソッドを呼び出して前記実行手段に実行させることで実現されるログ取得手段を起動する工程と、
前記ログ取得手段が、前記呼び出し手段による呼び出しに関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおけるメソッド定義において、パラメータがメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムのメソッド定義において定義された、該パラメータのサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記読み込まれたサイズと予め設定されたサイズとを比較し、小さい方のサイズ分のバイナリデータを前記ログメモリから前記ディスク装置に移動させ、保存させる工程と、
前記呼び出し手段により呼び出された前記ログ取得のためのメソッドに対応する前記呼び出し対象のメソッドを呼び出して、該呼び出し対象のメソッドを前記実行手段に実行させ、実行結果を受け取る工程と、
前記ログ取得手段が、前記実行結果に関わるログを前記ログメモリに格納する工程と、
前記ログ取得手段が、前記対象プログラムにおけるメソッド定義において、パラメータまたは戻り値がメモリアドレスとして定義されているか否かを識別し、メモリアドレスとして定義されている場合には、前記プログラムのメソッド定義において定義された、該パラメータまたは戻り値のサイズを読み込む工程と、
前記メモリアドレス上のバイナリデータを前記読み込まれたサイズ分ログとして前記ログメモリに格納する工程と、
前記読み込まれたサイズと予め設定されたサイズとを比較し、小さい方のサイズ分のバイナリデータを前記ログメモリから前記ディスク装置に移動させ、保存させる工程と、
前記ログ取得手段が、前記メソッドの実行結果を前記対象プログラムに渡す工程と
を備えることを特徴とするログ取得方法。
An interface that stores methods, the virtual address table storing an address of the method, a program storage means for storing a target program to be executed by calling a method in the interface, and a storage medium for storing the program, the log Rewriting means, log means for temporarily storing, disk device, and executing means for executing a program, the execution means being realized by executing a program stored in the storage medium , and a calling means A log acquisition method for acquiring a log during execution of the target program,
Before executing the target program, the rewriting means loads a method for log acquisition corresponding to each method in the interface into the interface, and corresponds the method address stored in the virtual address table. Rewriting the address of the method for acquiring the log,
The method for acquiring the log based on the address of the corresponding method for acquiring the log after the rewriting on the virtual address table for the method to be called that the target program is to call by the target program Starting log acquisition means realized by calling and causing the execution means to execute,
The log acquisition means storing a log related to a call by the calling means in the log memory;
The log acquisition means identifies whether or not a parameter is defined as a memory address in the method definition in the target program, and when defined as a memory address, is defined in the method definition of the program, Reading the size of the parameter;
Storing binary data on the memory address in the log memory as a log of the read size;
Comparing the read size with a preset size, moving binary data for a smaller size from the log memory to the disk device, and storing it;
Calling the method to be called corresponding to the method for log acquisition called by the calling unit, causing the execution unit to execute the method to be called, and receiving an execution result;
The log acquisition means storing a log related to the execution result in the log memory;
The log acquisition unit identifies whether a parameter or a return value is defined as a memory address in a method definition in the target program. If the parameter is defined as a memory address, it is defined in the method definition of the program. Reading the size of the parameter or return value,
Storing binary data on the memory address in the log memory as a log of the read size;
Comparing the read size with a preset size, moving binary data for a smaller size from the log memory to the disk device, and storing it;
The log acquisition unit includes a step of passing the execution result of the method to the target program.
JP2002191130A 2002-06-28 2002-06-28 Log acquisition method Expired - Fee Related JP4125056B2 (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
JP2002191130A JP4125056B2 (en) 2002-06-28 2002-06-28 Log acquisition method
US10/465,280 US7188279B2 (en) 2002-06-28 2003-06-20 Method, program, and storage medium for acquiring logs
EP03254034A EP1376365A3 (en) 2002-06-28 2003-06-25 Method for acquiring logs for program debugging
CN03149336.XA CN1276355C (en) 2002-06-28 2003-06-27 Run journal obtaining method, program and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002191130A JP4125056B2 (en) 2002-06-28 2002-06-28 Log acquisition method

Publications (2)

Publication Number Publication Date
JP2004038314A JP2004038314A (en) 2004-02-05
JP4125056B2 true JP4125056B2 (en) 2008-07-23

Family

ID=31700844

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002191130A Expired - Fee Related JP4125056B2 (en) 2002-06-28 2002-06-28 Log acquisition method

Country Status (1)

Country Link
JP (1) JP4125056B2 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1779245B1 (en) * 2004-07-20 2018-06-13 Microsoft Technology Licensing, LLC Method and system for minimizing loss in a computer application
JP4681868B2 (en) * 2004-12-16 2011-05-11 キヤノン株式会社 Information processing apparatus and control method therefor, computer program, and storage medium
JP4681923B2 (en) * 2005-04-01 2011-05-11 キヤノン株式会社 Information processing apparatus and control method therefor, computer program, and storage medium
JP4849941B2 (en) * 2006-04-12 2012-01-11 株式会社エヌ・ティ・ティ・ドコモ Software behavior modeling device
JP2009070230A (en) * 2007-09-14 2009-04-02 Ricoh Co Ltd Operation history information recording device, control method for operation history information recording device, control program and recording medium

Also Published As

Publication number Publication date
JP2004038314A (en) 2004-02-05

Similar Documents

Publication Publication Date Title
US5870607A (en) Method and apparatus for selective replay of computer programs
US7743228B2 (en) Information processing apparatus and method for obtaining software processing log
US7406684B2 (en) Compiler, dynamic compiler, and replay compiler
US8887141B2 (en) Automatically modifying a native code module accessed from virtual machine bytecode to determine execution information
US7478282B2 (en) Log acquisition method and its control program and storage medium
US20060064576A1 (en) Boot systems and methods
JPH11110194A (en) Connection method to external library function and recording medium in which the connection method is recorded and programmed
US7188279B2 (en) Method, program, and storage medium for acquiring logs
CN112041824A (en) Selective tracing of computer process execution
US7086034B2 (en) Method, program, and storage medium for acquiring logs
WO2022227409A1 (en) Embedded terminal remote software updating method
WO2024169933A1 (en) Program exception vector space optimization system and method, device, and medium
JP4280749B2 (en) Log acquisition method, program, and storage medium
US7426660B2 (en) Method, program, and storage medium for acquiring logs
JP4125056B2 (en) Log acquisition method
JP4125055B2 (en) Log acquisition method
JP4125053B2 (en) Log acquisition method
JP4125054B2 (en) Log acquisition method
US8191050B2 (en) Information processor, control method therefor, computer program and storage medium
JP4503203B2 (en) Method and apparatus for creating test program for evaluating information processing apparatus, and program describing processing for the same
US7305660B2 (en) Method to generate a formatted trace for an embedded device
US7617087B2 (en) Memory management method for dynamic conversion type emulator
JP2006031248A (en) Software evaluation system for generating log by hooking function call
JP2001134464A (en) Method and device for processing information
JP2003228492A (en) Computer simulation program, verification method for model of processor, and computer simulation method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050615

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20071001

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20071130

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20071225

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080225

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20080414

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080507

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110516

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120516

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120516

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130516

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140516

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees