JPH04263338A - Automatic check system for data value of debugger - Google Patents

Automatic check system for data value of debugger

Info

Publication number
JPH04263338A
JPH04263338A JP3044033A JP4403391A JPH04263338A JP H04263338 A JPH04263338 A JP H04263338A JP 3044033 A JP3044033 A JP 3044033A JP 4403391 A JP4403391 A JP 4403391A JP H04263338 A JPH04263338 A JP H04263338A
Authority
JP
Japan
Prior art keywords
data
data value
source program
program
check
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP3044033A
Other languages
Japanese (ja)
Inventor
Masanori Saito
齊▲藤▼ 正則
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.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP3044033A priority Critical patent/JPH04263338A/en
Publication of JPH04263338A publication Critical patent/JPH04263338A/en
Pending legal-status Critical Current

Links

Landscapes

  • Stored Programmes (AREA)
  • Debugging And Monitoring (AREA)
  • Devices For Executing Special Programs (AREA)

Abstract

PURPOSE:To shorten the debug processing time by checking automatically the data value during the debug processing process. CONSTITUTION:A source program analyzing means 1 analyzes a source program 5 where a declaration sentence including a comment for check of the data value and produces a table specification data base 7 and an object program 5. An automatic table check test means 3 loads and executes a load module 6 where some programs 5 are linked together and checks automatically the propriety of the data value contained in the module 6 by reference to the base 7.

Description

【発明の詳細な説明】[Detailed description of the invention]

【0001】0001

【産業上の利用分野】本発明は、プログラムのテストを
支援する対話形式のデバッガに関し、特にデバッグ対象
のプログラムに係るデータの値の正当性を自動的にチェ
ックするデバッガにおけるデータの値の自動チェック方
式に関する。
[Field of Industrial Application] The present invention relates to an interactive debugger that supports program testing, and in particular, automatic checking of data values in a debugger that automatically checks the validity of data values related to a program to be debugged. Regarding the method.

【0002】0002

【従来の技術】従来、プログラムのテストを支援する対
話形式のデバッガでは、デバッグ対象のプログラムに係
るデータの値は表示されるのみであり、その正当性のチ
ェックは利用者に委ねられていた。
2. Description of the Related Art Conventionally, interactive debuggers that support program testing only display data values related to the program to be debugged, leaving the user to check their validity.

【0003】0003

【発明が解決しようとする課題】上述した従来のデバッ
ガでは、データの値は表示されるのみであり、データの
値の正当性をチェックするための利用者による作業が必
要になるので、デバッグ処理、ひいてはプログラムのテ
ストに要する時間が長くなるという欠点がある。
[Problems to be Solved by the Invention] In the conventional debugger described above, the data value is only displayed, and the user must perform work to check the validity of the data value, so the debugging process This has the disadvantage that it increases the time required to test the program.

【0004】本発明の目的は、上述の点に鑑み、デバッ
グ処理の過程で自動的にデータの値の正当性をチェック
し、デバッグ処理に要する時間を短くできるデバッガに
おけるデータの値の自動チェック方式を提供することに
ある。
In view of the above points, an object of the present invention is to provide an automatic check method for data values in a debugger that can automatically check the validity of data values in the process of debugging and shorten the time required for debugging. Our goal is to provide the following.

【0005】[0005]

【課題を解決するための手段】本発明のデバッガにおけ
るデータの値の自動チェック方式は、データの値のチェ
ックのためのコメントを有する宣言文が記述されたソー
スプログラムを解析しテーブル仕様データベースおよび
オブジェクトプログラムを作成するソースプログラム解
析手段と、このソースプログラム解析手段により作成さ
れたオブジェクトプログラムがリンクされたロードモジ
ュールをロードし実行して前記ソースプログラム解析手
段により作成されたテーブル仕様データベースを参照し
てそのロードモジュール中のデータの値の正当性を自動
的にチェックするテーブル自動チェックテスト手段とを
有する。
[Means for Solving the Problems] The automatic data value checking method in the debugger of the present invention analyzes a source program in which a declaration statement with comments for checking data values is written, and analyzes a table specification database and objects. A source program analysis means for creating a program, and a load module to which the object program created by the source program analysis means is linked is loaded and executed, and the table specification database created by the source program analysis means is referred to and the object program created by the source program analysis means is linked. and table automatic check test means for automatically checking the validity of data values in the load module.

【0006】[0006]

【作用】本発明のデバッガにおけるデータの値の自動チ
ェック方式では、ソースプログラム解析手段がデータの
値のチェックのためのコメントを有する宣言文が記述さ
れたソースプログラムを解析しテーブル仕様データベー
スおよびオブジェクトプログラムを作成し、テーブル自
動チェックテスト手段がソースプログラム解析手段によ
り作成されたオブジェクトプログラムがリンクされたロ
ードモジュールをロードし実行してソースプログラム解
析手段により作成されたテーブル仕様データベースを参
照してそのロードモジュール中のデータの値の正当性を
自動的にチェックする。
[Operation] In the automatic data value checking method in the debugger of the present invention, the source program analysis means analyzes a source program in which a declaration statement with comments for checking data values is written, and generates a table specification database and an object program. The table automatic check test means loads and executes the load module to which the object program created by the source program analysis means is linked, and refers to the table specification database created by the source program analysis means to check the load module. Automatically check the validity of the data values inside.

【0007】[0007]

【実施例】次に、本発明について図面を参照して詳細に
説明する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS Next, the present invention will be explained in detail with reference to the drawings.

【0008】図1は、本発明のデバッガにおけるデータ
の値の自動チェック方式の一実施例の構成を示すブロッ
ク図である。本実施例のデバッガにおけるデータの値の
自動チェック方式は、ソースプログラム解析手段1と、
オブジェクトプログラム結合手段2(リンケージエディ
タ)と、テーブル自動チェックテスト手段3と、ソース
プログラム4と、オブジェクトプログラム5と、ロード
モジュール6と、テーブル仕様データベース7とを含ん
で構成されている。図中の実線の矢線は制御の流れを示
し、破線の矢線はデータの流れを示す。
FIG. 1 is a block diagram showing the structure of an embodiment of an automatic data value checking method in a debugger of the present invention. The automatic data value checking method in the debugger of this embodiment includes a source program analysis means 1,
The program includes an object program linking means 2 (linkage editor), an automatic table check test means 3, a source program 4, an object program 5, a load module 6, and a table specification database 7. The solid arrows in the figure indicate the flow of control, and the dashed arrows indicate the flow of data.

【0009】図2は、ソースプログラム解析手段1の処
理を示す流れ図である。この処理は、ソースコード読込
みステップ21と、ソースプログラム終了判定ステップ
22と、宣言文判定ステップ23と、仕様データレコー
ド作成ステップ24と、オブジェクトコード作成ステッ
プ25とからなる。
FIG. 2 is a flowchart showing the processing of the source program analysis means 1. This process consists of a source code reading step 21, a source program end determination step 22, a declaration statement determination step 23, a specification data record creation step 24, and an object code creation step 25.

【0010】図3は、テーブル仕様データベース7内の
仕様データレコードの構成を示す図である。仕様データ
レコードは、データ名31と、データ値個数32と、N
(正整数)個のデータ値33とからなる。
FIG. 3 is a diagram showing the structure of specification data records in the table specification database 7. As shown in FIG. The specification data record has a data name 31, a data value number 32, and N
(positive integer) data values 33.

【0011】図4は、テーブル自動チェックテスト手段
3の処理を示す流れ図である。この処理は、コマンド取
得ステップ41と、終了判定ステップ42と、データチ
ェック判定ステップ43と、ロードモジュール実行等ス
テップ44と、データ値チェックステップ45とからな
る。
FIG. 4 is a flowchart showing the processing of the table automatic check test means 3. This process includes a command acquisition step 41, an end determination step 42, a data check determination step 43, a load module execution etc. step 44, and a data value check step 45.

【0012】次に、このように構成された本実施例のデ
バッガにおけるデータの値の自動チェック方式の動作に
ついて説明する。
Next, the operation of the automatic data value checking method in the debugger of this embodiment configured as described above will be explained.

【0013】ソースプログラム解析手段1は、以下に示
すような処理を行う。
The source program analysis means 1 performs the following processing.

【0014】まず、ソースプログラム4からソースコー
ドを読み込んで(ステップ21)、ソースプログラム4
の終了判定(読み込むべきソースコードがソースプログ
ラム4にまだ残っているか否か、すなわちステップ21
でソースコードを読み込むことができたか否かの判定)
を行う(ステップ22)。
First, the source code is read from the source program 4 (step 21).
end determination (whether or not the source code to be read still remains in the source program 4, that is, step 21)
(Determining whether the source code could be loaded with
(Step 22).

【0015】この判定でソースプログラム4が終了でな
い場合(ステップ21でソースコードを読み込むことが
できた場合)には、そのソースコードが宣言文であるか
否かを判定する(ステップ23)。
If it is determined that the source program 4 is not finished (if the source code could be read in step 21), it is determined whether the source code is a declaration statement (step 23).

【0016】この判定でそのソースコードが宣言文であ
る場合には、その宣言文中のコメント(その宣言文で宣
言されたデータに関するデータの値のチェックのための
コメント)を解析し、そのコメントに対応する仕様デー
タレコードをテーブル仕様データベース7内に作成する
。すなわち、そのコメント中の当該データの仕様(当該
データが取りうる可能性のあるいくつかのデータの値)
を解析し、当該データのデータ名31,取りうるデータ
の値の個数を示すデータ値個数32および各データの値
を示すN個のデータ値34を仕様データレコードに設定
する(ステップ24)。なお、チェックの不要なデータ
についてはコメントは存在しないので、対応する仕様デ
ータレコードを作成することもない。
[0016] If the source code is a declaration statement in this judgment, the comment in the declaration statement (comment for checking the value of data related to the data declared in the declaration statement) is analyzed, and the comment is A corresponding specification data record is created in the table specification database 7. In other words, the specifications of the data in the comment (some data values that the data may take)
is analyzed, and the data name 31 of the data, the number of data values 32 indicating the number of possible data values, and N data values 34 indicating the value of each data are set in the specification data record (step 24). Note that since no comments exist for data that does not require checking, there is no need to create a corresponding specification data record.

【0017】ステップ23の判定でそのソースコードが
宣言文でない場合(実行文である場合)には、その実行
文に対応するオブジェクトコードをオブジェクトプログ
ラム5内に作成する(ステップ25)。
If it is determined in step 23 that the source code is not a declaration statement (if it is an executable statement), an object code corresponding to the executable statement is created in the object program 5 (step 25).

【0018】ステップ24または25の処理を終了する
と、ステップ21に戻り、次のソースコードをソースプ
ログラム4から読み込んで上述の処理を繰り返す。
When the process of step 24 or 25 is completed, the process returns to step 21, reads the next source code from the source program 4, and repeats the above process.

【0019】ステップ22の判定でソースプログラム4
が終了である場合(読み込むべきソースコードがソース
プログラム4にもう残っていない場合)には、処理を終
了する。
Source program 4 is determined in step 22.
If it is the end (if no source code to be read remains in the source program 4), the process ends.

【0020】オブジェクトプログラム結合手段2は、以
上のようなソースプログラム解析手段1による処理で作
成されたオブジェクトプログラム5のいくつかをリンク
してロードモジュール6を作成する。
The object program combining means 2 creates a load module 6 by linking some of the object programs 5 created through the processing by the source program analysis means 1 as described above.

【0021】ロードモジュール6に対するデバッグ処理
の過程で、テーブル自動チェックテスト手段3は、以下
に示すような処理を行う(テーブル自動チェックテスト
手段3は利用者との対話形式で処理を行う)。
In the process of debugging the load module 6, the table automatic check test means 3 performs the following processing (the table automatic check test means 3 performs the process in an interactive manner with the user).

【0022】まず、対話形式で利用者から指定されたコ
マンドを取得し(ステップ41)、そのコマンドを解析
し、そのコマンドが終了を指示しているか否かの判定(
終了判定)を行う(ステップ42)。
First, a command specified by the user in an interactive format is obtained (step 41), the command is analyzed, and it is determined whether the command instructs termination (step 41).
end determination) is performed (step 42).

【0023】この判定でそのコマンドが終了を指示して
いる場合には、処理を終了する。
[0023] In this judgment, if the command instructs termination, the process is terminated.

【0024】ステップ42の判定でそのコマンドが終了
を指示してない場合には、そのコマンドがデータチェッ
クを指示しているか否かの判定(データチェック判定)
を行う(ステップ43)。
If it is determined in step 42 that the command does not instruct termination, it is determined whether the command instructs data check (data check determination).
(Step 43).

【0025】この判定でそのコマンドがデータチェック
を指示している場合には、テーブル仕様データベース7
を参照し、その指示に係るデータ値チェックを行う(ス
テップ45)。すなわち、テーブル仕様データベース7
内の該当する仕様データレコード(その指示で指定され
たデータ名をデータ名31に有する仕様データレコード
)中のデータ値33を取得し、取得したいくつかのデー
タ値33の中に実行中のロードモジュール6におけるそ
のデータの値と一致するものがあるか否かをチェックし
(一致するものがあればそのデータの値の正当性が確認
されたことになる)、そのチェック結果を利用者に通知
する。
[0025] In this judgment, if the command instructs data check, the table specification database 7
, and performs a data value check related to the instruction (step 45). That is, table specification database 7
Obtain the data value 33 in the corresponding specification data record (the specification data record whose data name 31 has the data name specified in the instruction), and load the data value 33 that is being executed into some of the obtained data values 33. Check whether there is a match with the data value in module 6 (if there is a match, the validity of the data value has been confirmed), and notify the user of the check result. do.

【0026】ステップ43の判定でそのコマンドがデー
タチェックを指示していない場合には、そのコマンドに
基づいてロードモジュール6の実行等を行い、デバッグ
処理を進める(ステップ44)。
If it is determined in step 43 that the command does not instruct data checking, the load module 6 is executed based on the command, and the debugging process proceeds (step 44).

【0027】ステップ44または45の処理を終了する
と、ステップ41に戻り、次のコマンドを取得して上述
の処理を繰り返す。
When the processing in step 44 or 45 is completed, the process returns to step 41, obtains the next command, and repeats the above-described processing.

【0028】[0028]

【発明の効果】以上説明したように本発明は、デバッグ
処理の過程でデータの値の正当性を自動的にチェックす
ることにより、チェック対象のデータに係るプログラム
のテストに要する時間を短くでき、デバッグ処理を効率
的に行うことができるという効果がある。
[Effects of the Invention] As explained above, the present invention automatically checks the validity of data values in the process of debugging, thereby reducing the time required to test a program related to the data to be checked. This has the effect that debugging processing can be performed efficiently.

【図面の簡単な説明】[Brief explanation of the drawing]

【図1】本発明の一実施例の構成を示すブロック図であ
る。
FIG. 1 is a block diagram showing the configuration of an embodiment of the present invention.

【図2】図1中のソースプログラム解析手段の処理を示
す流れ図である。
FIG. 2 is a flowchart showing the processing of the source program analysis means in FIG. 1;

【図3】図1中のテーブル仕様データベース内の仕様デ
ータレコードの構成を示す図である。
FIG. 3 is a diagram showing the configuration of specification data records in the table specification database in FIG. 1;

【図4】図1中のテーブル自動チェックテスト手段の処
理を示す流れ図である。
FIG. 4 is a flowchart showing the processing of the table automatic check test means in FIG. 1;

【符号の説明】[Explanation of symbols]

1  ソースプログラム解析手段 2  オブジェクトプログラム結合手段3  テーブル
自動チェックテスト手段4  ソースプログラム 5  オブジェクトプログラム 6  ロードモジュール 7  テーブル仕様データベース 31  データ名 32  データ値個数 33  データ値
1 Source program analysis means 2 Object program combination means 3 Table automatic check test means 4 Source program 5 Object program 6 Load module 7 Table specification database 31 Data name 32 Number of data values 33 Data value

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】  データの値のチェックのためのコメン
トを有する宣言文が記述されたソースプログラムを解析
しテーブル仕様データベースおよびオブジェクトプログ
ラムを作成するソースプログラム解析手段と、このソー
スプログラム解析手段により作成されたオブジェクトプ
ログラムがリンクされたロードモジュールをロードし実
行して前記ソースプログラム解析手段により作成された
テーブル仕様データベースを参照してそのロードモジュ
ール中のデータの値の正当性を自動的にチェックするテ
ーブル自動チェックテスト手段とを有することを特徴と
するデバッガにおけるデータの値の自動チェック方式。
Claim 1: Source program analysis means for analyzing a source program in which a declaration statement with comments for checking data values is written, and creating a table specification database and an object program; A table automation system that loads and executes a load module to which an object program has been linked and automatically checks the validity of data values in the load module by referring to the table specification database created by the source program analysis means. 1. A method for automatically checking data values in a debugger, comprising a check test means.
JP3044033A 1991-02-18 1991-02-18 Automatic check system for data value of debugger Pending JPH04263338A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3044033A JPH04263338A (en) 1991-02-18 1991-02-18 Automatic check system for data value of debugger

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3044033A JPH04263338A (en) 1991-02-18 1991-02-18 Automatic check system for data value of debugger

Publications (1)

Publication Number Publication Date
JPH04263338A true JPH04263338A (en) 1992-09-18

Family

ID=12680327

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3044033A Pending JPH04263338A (en) 1991-02-18 1991-02-18 Automatic check system for data value of debugger

Country Status (1)

Country Link
JP (1) JPH04263338A (en)

Similar Documents

Publication Publication Date Title
JPH04263338A (en) Automatic check system for data value of debugger
US20070168978A1 (en) Computer program code debugging method and system
CN112162921B (en) Industrial automation test and control system
JP4055197B2 (en) Device for analyzing procedures included in the program
JPH05334117A (en) Automatic checking system for data value in debugger
JP2870735B2 (en) Automatic check method of data value in debugger
JP2004287869A (en) Program execution monitoring device and method
JPH02275539A (en) Debugging system
JPH0461380B2 (en)
JPH04540A (en) Debugging device
JPH03294934A (en) Debugger for high level program lenguage
JPH01273144A (en) Software development supporting device
JPH01154256A (en) Detecting method for program error position
CN115757168A (en) Vehicle UI automatic test script recording method and device and electronic equipment
JPH0468446A (en) Debugging supporting device
JPH10326188A (en) Resource competition check device, assemble device, link device, instruction pipeline simulation device, resource competition check method, and medium recording resource competition check program
JPS6365542A (en) Debugging system
JPH03189737A (en) Program developing device
JPS63268040A (en) Program debugging system
JPH05204698A (en) Debugger processing system
JPH04205355A (en) Use inspecting device for program variable
JPH01311335A (en) Program comprehensive ratio measuring system
JPH0353334A (en) Output processing system for debug information on language process program
JP2002278792A (en) Method for testing software
Sneed The MicroTest Integrated Test Environment