JPH0689171A - Program check method - Google Patents

Program check method

Info

Publication number
JPH0689171A
JPH0689171A JP4067812A JP6781292A JPH0689171A JP H0689171 A JPH0689171 A JP H0689171A JP 4067812 A JP4067812 A JP 4067812A JP 6781292 A JP6781292 A JP 6781292A JP H0689171 A JPH0689171 A JP H0689171A
Authority
JP
Japan
Prior art keywords
program
subroutine
routine
argument
external variable
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.)
Withdrawn
Application number
JP4067812A
Other languages
Japanese (ja)
Inventor
Hideyuki Okabe
秀之 岡部
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 IC Microcomputer Systems Co Ltd
Original Assignee
NEC IC Microcomputer Systems Co Ltd
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 IC Microcomputer Systems Co Ltd filed Critical NEC IC Microcomputer Systems Co Ltd
Priority to JP4067812A priority Critical patent/JPH0689171A/en
Publication of JPH0689171A publication Critical patent/JPH0689171A/en
Withdrawn legal-status Critical Current

Links

Landscapes

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

Abstract

PURPOSE:To easily and surely check a program at the time of substituting the program of the same function with another language or transferring it to a machine of a different machine type. CONSTITUTION:This method consists of an argument, external variable name, and type acquiring means 1, a means 2 which generates an argument and external variable information output routine and builds it in a conversion source program A, a means 3 which generates an argument and external variable information dump routine and builds it in the conversion source program A, an execution means 4 of a program B which builds in these two routines, an execution means 5 of a program C which builds in arguments, initial values of external variables, and the dump routine obtained by the execution means 4, and a means 6 which compares a dump result E obtained by the execution means 4 and a dump result F obtained by the execution means 5 with each other.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明はプログラムの検査方法に
関し、特に同一機能のプログラムを他の言語に置き換え
る場合、または、異機種マシンに移しかえる場合のプロ
グラムの検査方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a program inspection method, and more particularly to a program inspection method for replacing a program having the same function with another language or transferring the program to a machine of a different model.

【0002】[0002]

【従来の技術】従来のこの種のデバッグ方法の一例を図
を用いて説明する。図8は従来の検査方法の一例を示す
構成図であり、変換元のプログラム(A),変換元のプ
ログラム(A)中のサブルーチン2(A−2),サブル
ーチン2(A−2)を参照しているサブルーチン1(A
−1)と、変換後のプログラム(B),変換後のプログ
ラム(B)中のサブルーチン2a(B−2),サブルー
チン2a,(B−2)を参照しているサブルーチン1a
(B−1)と、引き数名称解析手段(1),外部変数名
称解析手段(2),引き数の型解析手段(3),外部変
数の型解析手段(4),引き数値解析手段(5),外部
変数値解析手段(6)と、引き数と外部変数の情報を組
み込む手段(7)、引き数と外部変数の値のダンプルー
チンを組み込む手段(8)と、引き数と外部変数の値の
ダンプルーチンを組み込んだ変換元プログラムの実行手
段1(9)と、引き数と外部変数の初期値、および、引
き数と外部変数の値のダンプルーチンを組み込んだ変換
後プログラムの実行手段2(10)、および変換元プロ
グラムの引き数と外部変数のダンプ結果1(C)と変換
後プログラムの引き数と外部変数のダンプ結果2(D)
の比較手段(11)から構成される。
2. Description of the Related Art An example of a conventional debugging method of this type will be described with reference to the drawings. FIG. 8 is a block diagram showing an example of a conventional inspection method. See the conversion source program (A), the subroutine 2 (A-2) and the subroutine 2 (A-2) in the conversion source program (A). Subroutine 1 (A
-1), the converted program (B), the subroutine 2a (B-2) in the converted program (B), the subroutine 1a referring to the subroutines 2a, (B-2)
(B-1), argument name analysis means (1), external variable name analysis means (2), argument type analysis means (3), external variable type analysis means (4), argument numerical analysis means ( 5), external variable value analysis means (6), means (7) for incorporating information on arguments and external variables, means (8) for incorporating a dump routine for arguments and values of external variables, and arguments and external variables Means (1) for executing the conversion source program incorporating the dump routine for the value of [1], and executing means for the post-conversion program incorporating the dump routine for the arguments and the initial values of external variables and the values of the arguments and external variables 2 (10), the argument of the conversion source program and the dump result 1 (C) of the external variable, the argument of the post-conversion program and the dump result 2 (D) of the external variable
Comparing means (11).

【0003】まず、変換元のプログラム(A)中のサブ
ルーチン1(A−1)がサブルーチン2(A−2)に渡
す引き数の名称と型および値の解析を行う(1,3およ
び5)。
First, the subroutine 1 (A-1) in the conversion source program (A) analyzes the names, types and values of the arguments passed to the subroutine 2 (A-2) (1, 3 and 5). .

【0004】次に変換元のプログラム(A)中のサブル
ーチン1(A−1)がサブルーチン2(A−2)を参照
する時点での外部変数の名称と型および値の解析を行う
(2,4および6)。
Next, the name, type and value of the external variable are analyzed when the subroutine 1 (A-1) in the conversion source program (A) refers to the subroutine 2 (A-2) (2. 4 and 6).

【0005】次に、前記解析により得られた引き数の情
報と外部変数の情報を変換後のプログラム(B)中のサ
ブルーチン2a(B−2)に初期値として組み込む
(7)。
Next, the argument information and the external variable information obtained by the analysis are incorporated as initial values in the subroutine 2a (B-2) in the converted program (B) (7).

【0006】次に、変換元のプログラム(A)中のサブ
ルーチン1(A−1)がサブルーチン2(A−2)を参
照した後の引き数と外部変数の値をダンプするルーチン
を作成し、サブルーチン(A−1)に組み込む。
Next, a routine for dumping the argument and the value of the external variable after the subroutine 1 (A-1) in the conversion source program (A) refers to the subroutine 2 (A-2) is created, It is incorporated into the subroutine (A-1).

【0007】同様に、変換後のプログラム(B)の中の
サブルーチン1a(B−1)がサブルーチン2a(B−
2)を参照した後の引き数と外部変数の値をダンプする
ルーチンを作成し、サブルーチン1a(B−1)に組み
込む。
Similarly, the subroutine 1a (B-1) in the converted program (B) is replaced by the subroutine 2a (B-
A routine for dumping the argument and the value of the external variable after referring to 2) is created and incorporated into the subroutine 1a (B-1).

【0008】次に、前記引き数と外部変数の値のダンプ
ルーチンを組み込んだ変換元のプログラムの実行を行う
(9)。
Next, the conversion source program incorporating the dump routine of the argument and the value of the external variable is executed (9).

【0009】次に、前記引き数と外部変数の初期値、お
よび、引き数と外部変数の値のダンプルーチンを組み込
んだ変換後プログラムの実行を行う(10)。
Next, a post-conversion program incorporating a dump routine of the arguments and the initial values of the external variables and the arguments and the values of the external variables is executed (10).

【0010】次に、前記実行により得られた変換元プロ
グラムの引き数と外部変数のダンプ結果(C)と変換後
プログラムの引き数と外部変数のダンプ結果(D)を比
較する(11)ことにより検査を行っていた。
Next, the argument of the conversion source program and the dump result (C) of the external variable obtained by the execution, and the argument of the post-conversion program and the dump result (D) of the external variable are compared (11). Had been inspected by.

【0011】[0011]

【発明が解決しようとする課題】上述した従来のプログ
ラムの検査方法においては、変換元プログラム中のサブ
ルーチンに引き渡される引き数の情報の解析と外部変数
の情報の解析を必要とし、前記解析で得られた引き数と
外部変数の情報を変換後プログラムに初期値として組み
込む必要が生じるため、解析時および組み込み時に誤り
の生ずることがあるという欠点があった。
In the conventional method for checking a program described above, it is necessary to analyze the information of the argument passed to the subroutine in the conversion source program and the information of the external variable, and the information obtained by the above analysis is required. Since it is necessary to incorporate the information of the obtained arguments and external variables into the converted program as initial values, there is a drawback that errors may occur during analysis and incorporation.

【0012】また、サブルーチン実行後の引き数の外部
変数をダンプするルーチンを作成し、変換元のプログラ
ムおよび変換後のプログラムに組み込む手間の、前記サ
ブルーチン実行後の引き数と外部変数の値のダンプルー
チンを組み込んだ変換元プログラムを実行する手間と、
前記引き数と外部変数の初期値およびサブルーチン実行
後の引き数と外部変数の値のダンプルーチンを組み込ん
だ変換後プログラムを実行する手間と、各々の実行によ
り得られるダンプ結果を比較する手間が生じ、人手の介
入することにより誤りの生じ易いという欠点があった。
Further, a routine for dumping the external variables of the arguments after the execution of the subroutine is created, and the time and effort of incorporating them in the program of the conversion source and the program after the conversion of the arguments and the values of the external variables after the subroutine is executed are dumped. The trouble of executing the conversion source program incorporating the routine,
There is a trouble of executing a post-conversion program incorporating a dump routine of the argument and the initial value of the external variable and the argument and the value of the external variable after the execution of the subroutine, and a trouble of comparing the dump result obtained by each execution. However, there is a drawback that errors are likely to occur due to human intervention.

【0013】[0013]

【課題を解決するための手段】本発明のプログラムの検
査方法は、プログラムの検査で同一機能のプログラムを
他の言語に置き換える場合、または異機種マシンに移し
かえる場合のプログラム検査方法において、引き数およ
び外部変数の名称と型を取得する手段と、引き数および
外部変数の情報を引き渡す手段と、引き数および外部変
数の情報をダンプするルーチンを組み込む手段と、前記
引き数および外部変数の情報を引き渡す手段と、前記引
き数および外部変数の情報をダンプするルーチンを組み
込む手段により引き数および外部変数の情報の引渡しル
ーチンと引き数および外部変数の情報をダンプするルー
チンが組み込まれたサブルーチンを実行する手段と、前
記実行する手段により得られた引き数と外部変数のダン
プ結果と前記実行手段により得られた初期値およびダン
プルーチンの組み込まれたサブルーチンを実行して得ら
れる引き数と外部変数のダンプ結果とを比較する手段と
を有して構成されるている。
The program checking method according to the present invention uses an argument in a program checking method for replacing a program having the same function with another language in checking the program or transferring the program to a different machine type. And a means for acquiring the name and type of the external variable, a means for passing the information of the argument and the external variable, a means for incorporating a routine for dumping the information of the argument and the external variable, and a means for collecting the information of the argument and the external variable. Executes a subroutine in which a means for delivering information on the argument and the external variable and a routine for delivering information on the argument and the external variable and a routine for dumping the information on the argument and the external variable are incorporated. Means, dump results of arguments and external variables obtained by the executing means, and the execution And configured with a means for comparing the dump result arguments and external variables obtained by executing a subroutine built of initial and dump routine obtained by stage.

【0014】[0014]

【実施例】以下本発明の実施例につき図面を参照して説
明する。図1は本発明の第1の実施例を説明するための
フロー図で、同一機能のプログラムを他の言語に置き換
える場合であり、引き数および外部変数の名称と型取得
手段(1)、引き数と外部変数の情報を出力するルーチ
ンを作成し、変換元プログラム(A)に組み込む手段
(2)、引き数と外部変数の情報をダンプするルーチン
を作成し、変換元プログラム(A)に組み込む手段
(3)、前記2つのルーチンを組み込んだプログラム
(B)の実行手段1(4)、実行手段1(4)により得
られる変換後のプログラム(D)に引き数と外部変数の
初期値とダンプルーチンの組み込まれたプログラム
(C)の実行手段2(5)、実行手段1(4)により得
られる引き数と外部変換のダンプ結果1(E)と実行手
段2(5)により得られる引き数と外部変換数のダンプ
結果2(F)を比較する手段(6)、変換元のプログラ
ム(A)中のサブルーチン2(A−2)、サブルーチン
2を参照しているサブルーチン1(A−1)、変換元の
プログラム(A)に引き数と外部変数の初期値およびサ
ブルーチン2参照後の引き数と外部変数の値のダンプル
ーチンを組み込むための組み込みサブルーチン1a
(B)、変換後のプログラム(D)中のサブルーチン2
b(D−2)、サブルーチン2bを参照しているサブル
ーチン1c(D−1)から構成される。
Embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a flow chart for explaining a first embodiment of the present invention, which is a case where a program having the same function is replaced with another language. Names of arguments and external variables and type acquisition means (1), arguments A means (2) for creating a routine for outputting the information of the number and the external variable and incorporating it in the conversion source program (A), and a routine for dumping the information of the argument and the external variable and incorporating it in the conversion source program (A). Means (3), execution means 1 (4) of the program (B) incorporating the above two routines, converted program (D) obtained by the execution means 1 (4), with arguments and initial values of external variables Arguments obtained by the execution means 2 (5) and execution means 1 (4) of the program (C) incorporating the dump routine, dump result 1 (E) of external conversion, and arguments obtained by the execution means 2 (5). Number and external Means (6) for comparing the dumped results 2 (F) of the conversion numbers, subroutine 2 (A-2) in the conversion source program (A), subroutine 1 (A-1) referring to the subroutine 2, conversion Built-in subroutine 1a for incorporating a dump routine of arguments and initial values of external variables and arguments and external variables after reference to subroutine 2 into the original program (A)
(B), Subroutine 2 in program (D) after conversion
b (D-2) and subroutine 1c (D-1) referencing subroutine 2b.

【0015】図2は図1の引き数および外部変換の名称
と型取得手段1のフロー図であり、シンボル情報の取得
(101)、引き数かどうかの判定(102)、引き数
テーブルへの型と名称の登録(104)、外部変数かど
うかの判定(103)、外部変数テーブルへの型と名称
の登録(105)から構成される。変換元のプログラム
(A)中のサブルーチン(A−1)をコンパイルした結
果得られるオブジェクトモジュールからシンボルの情報
を取得し、シンボルが引き数である場合シンボル名と型
を引き数テーブルに登録する。シンボルが外部変数であ
る場合、シンボル名と型を外部変数テーブルに登録す
る。
FIG. 2 is a flow chart of the argument and external conversion names and type acquisition means 1 of FIG. 1. Symbol information acquisition (101), argument determination (102), and argument table conversion. It consists of registration of type and name (104), determination of whether it is an external variable (103), and registration of type and name in the external variable table (105). The symbol information is obtained from the object module obtained as a result of compiling the subroutine (A-1) in the conversion source program (A), and if the symbol is an argument, the symbol name and type are registered in the argument table. If the symbol is an external variable, register the symbol name and type in the external variable table.

【0016】図3は図1の引き数・外部変数情報出力ル
ーチン組み込む手段2のフロー図であり、引き数テーブ
ルの情報を変換後のプログラム言語に変換する手段(2
01)、変換後のプログラムに引き数の初期値を出力す
るルーチンを、組み込みサブルーチン1a(B)に組み
込む手段(202)、外部変数テーブルの情報を変換後
のプログラム言語に変換する手段(203)、変換後の
プログラムに外部変数の初期値を出力するルーチンを、
組み込みサブルーチン1a(B)に組み込む手段(20
4)、変換後のプログラムにサブルーチン2(A−2)
実行後の引き数の値をダンプするルーチンを、組み込み
サブルーチン1a(B)に組み込む手段(205)、変
換後のプログラムにサブルーチン2(A−2)実行後の
外部変数の値をダンプするルーチンを、組み込みサブル
ーチン1a(B)に組み込む手段(206)から構成さ
れる。
FIG. 3 is a flow chart of the means 2 for incorporating the argument / external variable information output routine of FIG. 1, and means (2) for converting the information in the argument table into the converted programming language.
01), means for incorporating a routine for outputting the initial value of the argument into the converted program into the incorporated subroutine 1a (B) (202), means for converting the information of the external variable table into the converted programming language (203) , A routine that outputs the initial value of the external variable to the converted program,
A means (20) for incorporating into the incorporation subroutine 1a (B)
4) Subroutine 2 (A-2) in the converted program
A means (205) for incorporating a routine for dumping the value of the argument after execution into the incorporation subroutine 1a (B), and a routine for dumping the value of the external variable after execution of the subroutine 2 (A-2) to the converted program. , Built-in subroutine 1a (B), and a means (206) for incorporating.

【0017】引き数テーブル中の引き数の型を変換後の
プログラムに対応した型に変換し、変換後のプログラム
に引き数の初期値を出力するルーチンを作成する。
A routine for converting the type of the argument in the argument table into a type corresponding to the converted program and outputting the initial value of the argument to the converted program is created.

【0018】次に作成した引き数の初期値出力ルーチン
を組み込みサブルーチン1a(B)に組み込む。
Next, the created initial value output routine of the argument is incorporated into the incorporated subroutine 1a (B).

【0019】同様に外部変数テーブル中の外部変数の型
を、変換後のプログラムに対応した型に変換し、変換後
のプログラムに外部変数の初期値を出力するルーチンを
作成する。
Similarly, a routine for converting the type of the external variable in the external variable table into a type corresponding to the converted program and outputting the initial value of the external variable to the converted program is created.

【0020】次に作成した外部変数の初期値出力ルーチ
ンを組み込みサブルーチン1a(B)に組み込む。次に
変換後のプログラムにサブルーチン2(A−2)実行後
の引き数の値を変換後のプログラム言語で出力するダン
プルーチンを作成し、組み込みサブルーチン1a(B)
に組み込む。
Then, the created initial value output routine of the external variable is incorporated into the incorporated subroutine 1a (B). Next, a dump routine for outputting the argument value after execution of the subroutine 2 (A-2) in the converted program language to the converted program is created, and the built-in subroutine 1a (B) is created.
Built in.

【0021】同様に変換後のプログラムにサブルーチン
2(A−2)実行後の外部変数の値を変換後のプログラ
ム言語で出力するダンプルーチンを作成し、組み込みサ
ブルーチン1a(B)に組み込む。
Similarly, a dump routine for outputting the values of the external variables after the execution of the subroutine 2 (A-2) in the converted program in the converted programming language is created and incorporated into the incorporating subroutine 1a (B).

【0022】図4は図1の変換元プログラムの引き数・
外部変数情報ダンプルーチン組み込む手段3の詳細フロ
ー図であり、サブルーチン2(A−2)実行後の引き数
の値をダンプするルーチンを組み込む手段(301)、
サブルーチン2(A−2)実行後の外部変数の値をダン
プするルーチンを組み込む手段(302)から構成され
る。
FIG. 4 shows the arguments of the conversion source program of FIG.
It is a detailed flow chart of the external variable information dump routine incorporating means 3, which is a means (301) for incorporating a routine for dumping the value of the argument after execution of the subroutine 2 (A-2),
It comprises means (302) for incorporating a routine for dumping the value of the external variable after the execution of the subroutine 2 (A-2).

【0023】サブルーチン1(A−1)がサブルーチン
2(A−2)を実行した後の引き数の値をダンプするル
ーチンを作成し、組み込みサブルーチン1a(B)中で
サブルーチン2(A−2)を参照した後ろに前記ダンプ
ルーチンを組み込む。次にサブルーチン1(A−1)が
サブルーチン2(A−2)を実行した後の外部変数の値
をダンプするルーチンを作成し、組み込みサブルーチン
1a(B)中でサブルーチン2(A−2)を参照した後
ろに前記ダンプルーチンを組み込む。
Subroutine 1 (A-1) creates a routine for dumping the value of the argument after executing subroutine 2 (A-2), and subroutine 2 (A-2) in built-in subroutine 1a (B) is created. The dump routine is incorporated after the reference. Next, a routine for dumping the value of the external variable after the subroutine 1 (A-1) has executed the subroutine 2 (A-2) is created, and the subroutine 2 (A-2) is executed in the built-in subroutine 1a (B). The dump routine is incorporated after the reference.

【0024】図5は図1のサブルーチン1a(B)のフ
ロー図であり、元サブルーチンと同内容の検査サブルー
チン参照前のプログラム(B−101)、検査サブルー
チンの参照(B−104)、上述の手段により込み混ま
れた引き数の初期値出力ルーチン(B−102)、外部
変数の初期値出力ルーチン(B−103)、引き数およ
び外部変数値のダンプルーチン(B−105)、プログ
ラム中止ルーチン(B−106)より構成される。
FIG. 5 is a flow chart of the subroutine 1a (B) in FIG. 1. The program (B-101) before reference to the inspection subroutine having the same contents as the original subroutine, the inspection subroutine reference (B-104), and the above-mentioned Initial value output routine (B-102) of arguments mixed by means, external variable initial value output routine (B-103), argument and external variable value dump routine (B-105), program abort routine (B-106).

【0025】実行手段1(4)により、組み込みサブル
ーチン1a(B)とサブルーチン2(A−2)を実行す
ることで、今回組み込みを行った引き数の初期値出力ル
ーチン(B102)、外部変数の初期値出力ルーチン
(B−103)により図1中の初期値およびダンプルー
チンの組み込まれたサブルーチン(C)が作成される。
By executing the built-in subroutine 1a (B) and the subroutine 2 (A-2) by the execution means 1 (4), the initial value output routine (B102) of the argument which was built this time and the external variable By the initial value output routine (B-103), a subroutine (C) incorporating the initial value and dump routine in FIG. 1 is created.

【0026】また、今回組み込みを行った引き数および
外部変数値のダンプルーチン(B−105)により図1
中のダンプ結果2(F)が得られる。前記組み込みルー
チンが実行された後プログラムを中止するよう、プログ
ラム中止ルーチン(B−106)を設定する。
In addition, the argument and the external variable value dump routine (B-105) incorporated this time are used in FIG.
The inside dump result 2 (F) is obtained. A program stop routine (B-106) is set to stop the program after the built-in routine is executed.

【0027】図6は図1の実行手段1(4)により作成
された初期値およびダンプルーチンの組み込まれたサブ
ルーチン(C)のフロー図であり、引き数の初期値(C
−101)、外部変数の初期値(C−102)、検査サ
ブルーチンの参照(C−103)、引き数および外部変
数のダンプルーチン(C−104)、プログラムの中止
ルーチン(C−105)より構成され、全構成要素は、
上述の手段により作成されるものである。
FIG. 6 is a flow chart of the initial value created by the execution means 1 (4) in FIG. 1 and the subroutine (C) incorporating the dump routine.
-101), initial value of external variable (C-102), reference of inspection subroutine (C-103), dump routine of argument and external variable (C-104), program abort routine (C-105) And all components are
It is created by the means described above.

【0028】前述の初期値およびダンプルーチンの組み
込まれたサブルーチン(C)と、変換後のサブルーチン
2b(D−2)を実行手段2(5)により実行すること
により得られるダンプ結果2(F)と、前記実行手段1
(4)により得られるダンプ結果1(E)をダンプ結果
比較手段(6)により比較することにより、同一機能の
プログラムを他の言語に置き換える場合の検査が可能と
なる。
The dump result 2 (F) obtained by executing the subroutine (C) incorporating the above-mentioned initial value and dump routine and the converted subroutine 2b (D-2) by the executing means 2 (5). And the execution means 1
By comparing the dump result 1 (E) obtained by (4) with the dump result comparing means (6), it becomes possible to perform an inspection when replacing a program having the same function with another language.

【0029】図7は本発明の第2の実施例を説明するた
めの引く数・外部変数情報出力ルーチンを組み込む手段
2のフロー図で、同一機能のプログラムを異機種マシン
に移しかえる場合であり、移しかえ後のプログラムに引
き数の初期値を出力するルーチンを、組み込みサブルー
チン1a(B)に組み込む手段(211)、移しかえ後
のプログラムに外部変数の初期値を出力するルーチン
を、組み込みサブルーチン1a(B)に組み込む手段
(212)、移しかえ後のプログラムにサブルーチン2
(A−2)実行後の引き数の値をダンプするルーチン
を、組み込みサブルーチン1a(B)に組み込む手段
(213)、移しかえ後のプログラムにサブルーチン2
(A−2)実行後の外部変数の値をダンプするルーチン
を、組み込みサブルーチン1a(B)に組み込む手段
(214)から構成される。
FIG. 7 is a flow chart of a means 2 for incorporating a draw number / external variable information output routine for explaining the second embodiment of the present invention, in which a program having the same function is transferred to a machine of a different model. , Means for incorporating a routine for outputting the initial value of the argument into the transferred program into the incorporated subroutine 1a (B), and a routine for outputting the initial value of the external variable to the transferred program, the incorporated subroutine Means (212) to be incorporated in 1a (B), Subroutine 2 in the transferred program
(A-2) A means (213) for incorporating a routine for dumping the argument values after execution into the incorporated subroutine 1a (B), and the subroutine 2 for the transferred program.
(A-2) A means (214) for incorporating a routine for dumping the value of the external variable after execution into the incorporation subroutine 1a (B).

【0030】移しかえ後のプログラムに引き数の初期値
を出力するルーチンを作成し、作成した引き数の初期値
出力ルーチンを組み込みサブルーチン1a(B)に組み
込む。同様に、移しかえ後のプログラムに外部変数の初
期値を出力するルーチンを作成し、作成した外部変数の
初期値出力ルーチンを組み込みサブルーチン1a(B)
に組み込む。次に移しかえ後のプログラムにサブルーチ
ン2(A−2)実行後の引き数の値を出力するダンプル
ーチンを作成し、組み込みサブルーチン1a(B)に組
み込む。同様に移しかえ後のプログラムにサブルーチン
2(A−2)実行後の外部変数の値を出力するダンプル
ーチンを作成し、組み込むサブルーチン1a(B)に組
み込む。
A routine for outputting the initial value of the argument to the transferred program is created, and the created initial value output routine of the argument is installed in the built-in subroutine 1a (B). Similarly, a routine for outputting the initial value of the external variable is created in the transferred program, and the created initial value output routine for the external variable is incorporated into the subroutine 1a (B).
Built in. Next, a dump routine that outputs the value of the argument after execution of the subroutine 2 (A-2) is created in the transferred program and incorporated into the incorporation subroutine 1a (B). Similarly, a dump routine for outputting the value of the external variable after execution of the subroutine 2 (A-2) is created in the transferred program and incorporated in the incorporated subroutine 1a (B).

【0031】その他の流れは全て第1の実施例と同様で
ある。以上のことから同一機能のプログワムを異機種マ
シンに移しかえた場合の検査が可能となる。
The other flow is the same as that of the first embodiment. From the above, it is possible to inspect when a program with the same function is moved to a different machine type.

【0032】[0032]

【発明の効果】以上説明したように本発明のプログラム
の検査方法によれば、変換元プログラムのサブルーチン
に引き渡される引き数と外部変数の情報を自動的に取得
し、変換後プログラムに初期値として組み込むことがで
きるため、正確な情報が迅速に受渡しできることと、変
換元プログラムを実行した後の引き数と外部変数の値
と、変換後プログラムを実行した後の引き数と外部変数
の値を比較するまでバッチ形式で行うため、人手の介入
する部分を少なくすることができ、誤りが生じ難くなる
という効果がある。
As described above, according to the program inspection method of the present invention, the information of the argument and the external variable passed to the subroutine of the conversion source program is automatically acquired and used as the initial value in the converted program. Since it can be incorporated, accurate information can be passed quickly, and the argument and external variable value after executing the conversion source program and the argument and external variable value after executing the converted program are compared. Since the process is carried out in a batch format until the above, there is an effect that it is possible to reduce a manual intervention portion and an error is less likely to occur.

【0033】また、引き数および外部変数の情報の解析
を必要としないため、複数人が任意のサブルーチンを検
査することが可能となる効果がある。
Further, since it is not necessary to analyze the information of the argument and the external variable, there is an effect that a plurality of persons can inspect an arbitrary subroutine.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明の第1の実施例を説明するためのフロー
図である。
FIG. 1 is a flow chart for explaining a first embodiment of the present invention.

【図2】図1の引き数および外部変数の名称と型取得手
段のフロー図である。
FIG. 2 is a flowchart of names and type acquisition means of arguments and external variables in FIG.

【図3】図1の引き数・外部変数情報出力ルーチン組み
込む手段2のフロー図である。
FIG. 3 is a flow chart of means 2 for incorporating an argument / external variable information output routine of FIG.

【図4】図1の変換元プログラムの引き数・外部変数情
報ダンプルーチン組み込む手段3のフロー図である。
FIG. 4 is a flow chart of means 3 for incorporating an argument / external variable information dump routine of the conversion source program of FIG.

【図5】図1のサブルーチンのフロー図である。5 is a flowchart of the subroutine of FIG.

【図6】図1の初期値およびダンプルーチンの組み込ま
れたサブルーチンのフロー図である。
FIG. 6 is a flow chart of a subroutine incorporating the initial value and dump routine of FIG.

【図7】本発明の第2の実施例を説明するための引き数
・外部変数情報出力ルーチンを組み込む手段のフロー図
である。
FIG. 7 is a flowchart of means for incorporating an argument / external variable information output routine for explaining the second embodiment of the present invention.

【図8】従来のプログラムの検査方法の一例を説明する
ためのフロー図である。
FIG. 8 is a flowchart for explaining an example of a conventional program inspection method.

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

1 引き数および外部変数名称と型取得手段 2 引き数・外部変数情報出力ルーチン組み込み手段 3 引き数・外部変数情報ダンプルーチン組み込み手
段 4 実行手段1 5 実行手段2 6 ダンプ結果比較手段 A 変換元のプログラム A−1 サブルーチン1 A−3 サブルーチン2 B 組み込みサブルーチン1a C 初期値およびダンプルーチンの組み込まれたサブ
ルーチン D 変換後のプログラム D−1 サブルーチン1b D−3 サブルーチン2b E ダンプ結果1 F ダンプ結果2
1 argument and external variable name and type acquisition means 2 argument / external variable information output routine incorporation means 3 argument / external variable information dump routine incorporation means 4 execution means 1 5 execution means 2 6 dump result comparison means A conversion source Program A-1 Subroutine 1 A-3 Subroutine 2 B Built-in subroutine 1a C Subroutine with built-in initial value and dump routine D Program after conversion D-1 Subroutine 1b D-3 Subroutine 2b E Dump result 1 F Dump result 2

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 プログラムの検査で同一機能のプログラ
ムを他の言語に置き換える場合、または異機種マシンに
移しかえる場合のプログラム検査方法において、引き数
および外部変数の名称と型を取得する手段と、引き数お
よび外部変数の情報を引き渡す手段と、引き数および外
部変数の情報をダンプするルーチンを組み込む手段と、
前記引き数および外部変数の情報を引き渡す手段と、前
記引き数および外部変数の情報をダンプするルーチンを
組み込む手段により引き数および外部変数の情報の引渡
しルーチンと引き数および外部変数の情報をダンプする
ルーチンが組み込まれたサブルーチンを実行する手段
と、前記実行する手段により得られた引き数と外部変数
のダンプ結果と前記実行手段により得られた初期値およ
びダンプルーチンの組み込まれたサブルーチンを実行し
て得られる引き数と外部変数のダンプ結果とを比較する
手段とを有することを特徴とするプログラムの検査方
法。
1. A means for acquiring the names and types of arguments and external variables in a program checking method for replacing a program having the same function with another language in checking a program or transferring to another machine. Means for passing information of arguments and external variables, means for incorporating a routine for dumping information of arguments and external variables,
A means for passing the information of the argument and the external variable, and a means for incorporating the routine for dumping the information of the argument and the external variable, and a routine for passing the information of the argument and the external variable and the information of the argument and the external variable are dumped. A means for executing a subroutine in which the routine is incorporated, a result of dumping the arguments and external variables obtained by the means for executing, an initial value obtained by the executing means, and a subroutine in which the dump routine is incorporated, A method for inspecting a program, comprising: means for comparing the obtained argument with a dump result of an external variable.
JP4067812A 1992-03-26 1992-03-26 Program check method Withdrawn JPH0689171A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP4067812A JPH0689171A (en) 1992-03-26 1992-03-26 Program check method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP4067812A JPH0689171A (en) 1992-03-26 1992-03-26 Program check method

Publications (1)

Publication Number Publication Date
JPH0689171A true JPH0689171A (en) 1994-03-29

Family

ID=13355737

Family Applications (1)

Application Number Title Priority Date Filing Date
JP4067812A Withdrawn JPH0689171A (en) 1992-03-26 1992-03-26 Program check method

Country Status (1)

Country Link
JP (1) JPH0689171A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009245066A (en) * 2008-03-31 2009-10-22 Nomura Research Institute Ltd Software migration system and method
WO2017038104A1 (en) * 2015-09-03 2017-03-09 株式会社Preferred Networks Installation device and installation method
JP2019109687A (en) * 2017-12-18 2019-07-04 東芝産業機器システム株式会社 Programming language conversion support device, programming language conversion support method and program
US11521070B2 (en) 2015-10-29 2022-12-06 Preferred Networks, Inc. Information processing device and information processing method

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009245066A (en) * 2008-03-31 2009-10-22 Nomura Research Institute Ltd Software migration system and method
WO2017038104A1 (en) * 2015-09-03 2017-03-09 株式会社Preferred Networks Installation device and installation method
US11521070B2 (en) 2015-10-29 2022-12-06 Preferred Networks, Inc. Information processing device and information processing method
US11915146B2 (en) 2015-10-29 2024-02-27 Preferred Networks, Inc. Information processing device and information processing method
US12026620B2 (en) 2015-10-29 2024-07-02 Preferred Networks, Inc. Information processing device and information processing method
US12079729B2 (en) 2015-10-29 2024-09-03 Preferred Networks, Inc. Information processing device and information processing method
JP2019109687A (en) * 2017-12-18 2019-07-04 東芝産業機器システム株式会社 Programming language conversion support device, programming language conversion support method and program

Similar Documents

Publication Publication Date Title
CN103235759B (en) Method for generating test case and device
US20090055804A1 (en) Method and device for automatically evaluating the quality of a software source code
CN112444731A (en) Chip testing method and device, processor chip and server
Harrold Architecture-based regression testing of evolving systems
JPH0689171A (en) Program check method
CN112363729B (en) Monitoring method and device for mixed compiling of multiple compilers for static analysis
Lakehal et al. Lustructu: A tool for the automatic coverage assessment of lustre programs
JPH0210443A (en) Reset case selecting system
JPH0736734A (en) Method for checking argument value
US6385740B1 (en) Method to dynamically change microprocessor test software to reflect different silicon revision levels
Nguyen et al. Testability analysis of data-flow software
US20040230883A1 (en) Method, system, apparatus and program for programming defect data for evaluation of reticle inspection apparatus
JPH06195216A (en) Automatic generation device for verification program
CN114325294B (en) Test method and device
JPH05143393A (en) Device for forming test program
JPH01177165A (en) Definition-quotation relation checking system for array
JP3587644B2 (en) Method of creating test program for semiconductor device
JP2815178B2 (en) Compiler unit
JPH08272623A (en) Device and method for program analysis
JPH0782074B2 (en) Logic verification device
Lin et al. Promoting the software design for testability towards a partial test oracle
JPH0363838A (en) Software program inspection system
JPH01261737A (en) Automatic control system for inspection of language processor
JPH04236636A (en) Check method for interactive system
Alves et al. A Framework for System-level Co-verification using the BST Infrastructure

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 19990608