JPH03257548A - Measurement system for instruction executing frequency of program - Google Patents
Measurement system for instruction executing frequency of programInfo
- Publication number
- JPH03257548A JPH03257548A JP2057010A JP5701090A JPH03257548A JP H03257548 A JPH03257548 A JP H03257548A JP 2057010 A JP2057010 A JP 2057010A JP 5701090 A JP5701090 A JP 5701090A JP H03257548 A JPH03257548 A JP H03257548A
- Authority
- JP
- Japan
- Prior art keywords
- instruction
- branch
- address
- module
- 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.)
- Ceased
Links
Landscapes
- Debugging And Monitoring (AREA)
Abstract
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は、情報処理システムに於けるプログラムの性能
測定方式に関し、特にプログラムの命令実行数を測定す
る方式に間する。DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a method for measuring the performance of a program in an information processing system, and particularly to a method for measuring the number of executed instructions of a program.
従来、プログラムの性能の基準となるプログラムの命令
実行数は、机上でプログラムの実行過程を予測しながら
計算するか、ハードウェアモニタにより測定する方法が
取られていた。Conventionally, the number of executed instructions of a program, which serves as a standard for program performance, has been calculated on a desk while predicting the program execution process, or measured using a hardware monitor.
上記のように、机上でプログラムの実行過程を予測しな
がら計算する場合には、プログラムの内容を良く理解し
ていlければなム′うす、また、ブロクラムの内容を良
く理解した担当者であっても相当の時間を必要とした。As mentioned above, when calculating while predicting the execution process of a program on a desk, it is necessary to have a good understanding of the contents of the program, and the person in charge must have a good understanding of the contents of the block diagram. However, it required a considerable amount of time.
他の、ハードウェアモニタにより測定する方法では、測
定の準備か面倒なため、ソフトウェア担当者は一般に使
用していないのか現状である。Other methods, such as measuring using a hardware monitor, require troublesome preparation for measurement, so software engineers generally do not use them at present.
本発明のプログラムの命令実行数測定方式の構成は、プ
ログラムを構成する全モジュールの先頭部に当該モジュ
ールの先頭を示し、且つ、そのモジュール名を含むモジ
ュール先頭識別機構を有し、前記全モジュールの先頭ア
ドレスと終了アドレスとモジュール名とを求めるため前
記モジュール先頭識別機構をサーチするモジュールサー
チ手段と、該モジュールサーチ手段によって得られた前
記全モジュールの先頭アドレスと終了アドレスとモジュ
ール名とを記憶するモジュール範囲情報記憶手段と、分
岐命令の実行により分岐後最初の命令が実行される前に
当該分岐命令を含むプログラムの走行の優先レベルと分
岐命令自身のアドレスである分岐前アドレスと分岐命令
の分岐先アドレスである分岐後アドレスとを保持して内
部割込みを発生させ、且つ、該内部側込みが一個以上の
前記優先レベル毎に発生できるような分岐命令割込み手
段と、該分岐命令割込み手段の起動および停止を行なう
ための分岐命令割込みモード設定および解除手段と、前
記優先レベルに対応させて前記分岐後アドレスを記憶す
る分岐後アドレス記憶手段と、分岐命令割込み時に前記
分岐割込み手段から通知される前記分岐前アドレスと前
記分岐後アドレス記憶手段により当該分岐命令割込みの
一度前の分岐命令割込み時に記憶されていて当該分岐命
令割込み時の前記優先レベルに対応する前記分岐後アド
レスとで示される範囲に存在する命令を探索し、命令種
別、且つ、アドレス指定形式別に命令の個数を解析する
命令解析手段と、該命令解析手段による解析結果を命令
種別、且つ、アドレス指定形式別に、且つ、当該探索対
象となった命令を含むモジュール毎に対応させて累積し
て記憶するアドレス指定形式別命令数記憶手段と、命令
種別、且つ、アドレス指定形式別に命令の実行時間を示
すアドレス指定形式別命令実行時間対応情報を有し、前
記アドレス指定形式g’l #i令数記憶手段による累
積記憶結果と前記アドレス指定形式別命令実行時間対応
情報とを基に前記モジュール毎の実行時間を算出すると
ともに、編集出力する測定結果編集出力手段とを含むこ
とを特徴とする。The configuration of the method for measuring the number of executed instructions of a program according to the present invention includes a module head identification mechanism that indicates the head of the module at the head of all the modules constituting the program, and includes the module name. A module search means for searching the module start identification mechanism to obtain a start address, an end address, and a module name, and a module for storing the start address, end address, and module name of all the modules obtained by the module search means. A range information storage means, a priority level for running the program including the branch instruction, a pre-branch address which is the address of the branch instruction itself, and the branch destination of the branch instruction before the first instruction after the branch is executed by executing the branch instruction. A branch instruction interrupt means that holds a post-branch address as an address and generates an internal interrupt, and is capable of generating one or more internal side interrupts for each of the priority levels, and a branch instruction interrupt means for activating and branch instruction interrupt mode setting and cancellation means for performing a stop; post-branch address storage means for storing the post-branch address in correspondence with the priority level; Exists in the range indicated by the previous address and the post-branch address that was stored by the post-branch address storage unit at the time of a branch instruction interrupt immediately before the branch instruction interrupt and corresponds to the priority level at the time of the branch instruction interrupt. An instruction analysis means for searching for instructions and analyzing the number of instructions by instruction type and addressing format; a storage means for storing the number of instructions by addressing format in a cumulative manner corresponding to each module containing the instructions; and instruction execution time correspondence information by addressing format indicating instruction execution time for each instruction type and addressing format. and calculates the execution time for each module based on the accumulated storage result by the addressing format g'l #i instruction number storage means and the instruction execution time correspondence information by addressing format, and edits and outputs the measurement. and a result editing output means.
次に、本発明について図面を参照して説明する。 Next, the present invention will be explained with reference to the drawings.
第1図は、本発明のプログラムの命令実行数測定方式の
一実施例のブロック図である。FIG. 1 is a block diagram of an embodiment of a method for measuring the number of executed instructions of a program according to the present invention.
本実施例のプログラムの命令実行数測定方式は、入力操
作が行なわれる入力装置1と、入力情報解析部20と制
御部21とモジュールサーチ部22と命令語解析部23
と測定結果編集出力部24とを含むプログラム命令実行
数測定装置2と、分岐命令の実行により分岐後最初の命
令が実行される前に優先レベルと分岐前アドレスと分岐
後アドレスとを保持して内部割込みを発生させる分岐命
令割込機構30を含む中央処理装置3と5モジユール4
1 42.・・・、4nから成る測定対象プログラムを
記憶する主記憶装置4と、優先レベル毎に対応する分岐
後アドレス51,52.・・・、5nを次の分岐命令割
込み時まで記憶しておく分岐後アドレス記憶部5と、命
令種別、且つ、アドレス指定形式別の命令実行回数をモ
ジュール毎に対応させて記憶するアドレス指定形式別実
行数記憶部6と、モジュール毎の測定結果リストが出力
される出力装置7と、命令種別、且つ、アドレス指定形
式別の命令実行時間を示すアドレス指定形式命令実行時
間対応表8とから構成されている。The method of measuring the number of executed instructions of a program in this embodiment consists of an input device 1 on which an input operation is performed, an input information analysis section 20, a control section 21, a module search section 22, and a command word analysis section 23.
A program instruction execution number measuring device 2 including a measurement result editing output unit 24, and a program instruction execution number measuring device 2 that holds a priority level, a pre-branch address, and a post-branch address before the first instruction after a branch is executed by executing a branch instruction. Central processing units 3 and 5 modules 4 including a branch instruction interrupt mechanism 30 that generates internal interrupts
1 42. . . , 4n, and post-branch addresses 51, 52 . . . corresponding to each priority level. ..., 5n until the next branch instruction interrupt, and an addressing format that stores the number of instruction executions for each instruction type and addressing format in correspondence with each module. Consists of a separate execution number storage unit 6, an output device 7 that outputs a list of measurement results for each module, and an addressing format instruction execution time correspondence table 8 that shows instruction execution times for each instruction type and addressing format. has been done.
主記憶装置4には、モジュール41,42゜・・・、4
nとから構成する測定対象プログラムが存在し、それぞ
れのモジュールの先頭アドレスはSl、S2.・・・、
Sn番地で表わされ、同じく、終了アドレスはEO,E
l、・・・Enとして表わされている。そしてモジュー
ルの先頭アドレスS1・・・、Sn番地からは、それぞ
れモジュールの先頭であることを示し、且つ、それぞれ
に対応するモジュール名(aaaaa、bbbbb、・
−、nnnnn>を罰むモジj−1し先頭識別語41
M、42M、・−,4nMを持つ。The main storage device 4 includes modules 41, 42°..., 4
There is a measurement target program consisting of modules Sl, S2, . ...,
Similarly, the ending address is EO, E.
It is expressed as l,...En. The module start addresses S1..., Sn indicate the start of the module, and the corresponding module names (aaaaa, bbbbb, .
-, nnnnn> is punishable by modj-1 and the first identifier word 41
M, 42M, -, 4nM.
アドレス指定形式別命令実行数記憶部6の内容は、測定
対象プログラムを構成するモジュールのモジュール名(
aaaaa、bbbbb、・−、nnnnn)と先頭ア
ドレス(Sl、S2.・・・、Sn)と終了アドレス(
El、E2.・・・、En)とを示すモジュール範囲情
報61M、62M、 ・ 、6nM (それぞれ、モジ
ュール41,42.・・・、4nに対応)と、モジュー
ル範囲情報61M、62M、−・、6nMで示されるモ
ジュール毎に対応し、且つ、命令の区別を示す命令種別
600とアドレス指定形式の区別を示すアドレス指定形
式別11601に対応し命令の実行回数を記憶するアド
レス指定形式別命令実行回数記憶情報61.62.・・
・6n(それぞれモジュール41,42.・・、4nに
対応)とを含む。The contents of the instruction execution number storage unit 6 by addressing format are the module names (
aaaaa, bbbbb, ..., nnnnn), the start address (Sl, S2..., Sn), and the end address (
El, E2. ..., En) and module range information 61M, 62M, . . . , 6nM (corresponding to modules 41, 42. Instruction execution count storage information 61 by addressing format stores the number of instruction executions corresponding to each module in which the instruction is executed, and corresponds to instruction type 600 indicating instruction distinction and addressing format 11601 indicating distinction between addressing formats. .62.・・・
- 6n (corresponding to modules 41, 42, . . . , 4n, respectively).
また、アドレス指定形式別命令実行時間対応表8は、命
令の区別を示す命令種別列80.に令種別列80の命令
毎に対応しアドレス指定形式AS1、AS2.・・・、
ASn毎に実行時間を示すアドレス指定形式別命令実行
時間st、82.・・・、8nとを含む。The instruction execution time correspondence table 8 by addressing format also includes an instruction type column 80. Addressing formats AS1, AS2, . ...,
Instruction execution time st by addressing format indicating execution time for each ASn, 82. ..., 8n.
次に、このように構成された本実施例のプログラムの命
令実行数測定方式の動作について説明する。Next, the operation of the method for measuring the number of executed instructions of a program according to the present embodiment configured as described above will be explained.
まず、モジュール41.42.・・・、4nから成る測
定対象プログラムの優先レベルを1と仮定した場合、優
先レベル番号1と測定対象プログラムの範囲(511番
上En番地)とが入力装置1から入力される。First, modules 41.42. . . , 4n, the priority level number 1 and the range of the measurement target program (511 top En address) are input from the input device 1.
入力情報解析部20は、この入力された優先レベル番地
1と測定対象プロゲラの範囲とを制御部21に通知する
。この通知を受けた制御部21は、優先レベル番号1を
分岐命令割込みモードにして、分岐命令割込機構30を
起動すると共に、優先レベル番号1に対応すると分岐後
アドレス記憶部5内の分岐後アドレス(分岐後アドレス
51)をゼロで切開化する。The input information analysis section 20 notifies the control section 21 of the input priority level address 1 and the range of the measurement target progera. Upon receiving this notification, the control unit 21 sets the priority level number 1 to the branch instruction interrupt mode, activates the branch instruction interrupt mechanism 30, and also stores the branch address in the post-branch address storage unit 5 as corresponding to the priority level number 1. The address (post-branch address 51) is incised with zero.
また、測定対象プログラムの範囲はモジュールサーチ部
22に通知され、この通知によってモジュールサーチ部
22は、81番地からEn番地の範囲にあるモジュール
をサーチし、モジュール名(aaaaa、bbbbb、
・、 nnnnn)と先頭アドレス(SL。Further, the range of the program to be measured is notified to the module search unit 22, and based on this notification, the module search unit 22 searches for modules within the range of addresses 81 to En, and searches for modules with module names (aaaaa, bbbbb, etc.).
., nnnnn) and the start address (SL.
S2.・・・Sn)と終了アドレス(El、E2.・・
・En)とをアドレス指定形式別命令実行数記憶部6内
のモジュール範囲情報61M、62M ・・6nMに
保持するとともに、モジュール範囲情報61M、62M
、・・・、6nMのそれぞれに対応するアドレス指定形
式別命令実行回数記憶情報61゜62、・・・6nをゼ
ロで初期化する。S2. ...Sn) and end address (El, E2...
・En) is held in the module range information 61M, 62M, 6nM in the instruction execution number storage unit 6 by addressing format, and the module range information 61M, 62M
, . . . , 6nM, instruction execution count storage information 61, 62, .
この後、主記憶装置4内での測定対象プログラムか起動
されて分岐命令が実行されると、中央処理袋W3の分岐
命令割込機構30は分岐先のアドレスで分岐命令割込み
を発生させ、プログラム命令実行数測定装置2の制御部
21を動作させる。Thereafter, when the program to be measured in the main storage device 4 is started and a branch instruction is executed, the branch instruction interrupt mechanism 30 of the central processing bag W3 generates a branch instruction interrupt at the branch destination address, and the program The control unit 21 of the instruction execution count measuring device 2 is operated.
制御部21は、分岐命令割込機構30によって優先レベ
ル番号1と測定対象プログラム内の分岐命令自身のアド
レスである分岐前アドレスとこの分岐命令による分岐先
である分岐後アドレスとが通知されると1分岐後アドレ
ス記憶部5内の優先レベル番号1に対応する分岐後アド
レス51の内容が示すアドレスから、この分岐命令割込
み時通知された分岐前アドレスまでの範囲内にある命令
を解析するよう命令語解析部23に指示すると共に、同
じく、この分岐命令割込み時通知された分岐後アドレス
は、優先レベル番号1に対する次の分岐命令割込み時ま
で分岐後アドレス51に記憶しておく。When the control unit 21 is notified by the branch instruction interrupt mechanism 30 of the priority level number 1, the pre-branch address that is the address of the branch instruction itself in the program to be measured, and the post-branch address that is the branch destination of this branch instruction, 1 An instruction to analyze instructions within the range from the address indicated by the contents of the post-branch address 51 corresponding to priority level number 1 in the post-branch address storage unit 5 to the pre-branch address notified at the time of this branch instruction interrupt. In addition to instructing the word analysis unit 23, the post-branch address notified at the time of this branch instruction interrupt is also stored in the post-branch address 51 until the next branch instruction interrupt for priority level number 1.
この後、命令語解析部23は、制御部21によって指示
された範囲内の命令を解析し、この解析結果(命令種別
、且つ、アドレス指定形式別の数)をアドレス指定形式
別命令実行回数記憶情報(解析された範囲がSL番地か
ら21番地内であれば、アドレス指定形式別命令実行回
数記憶情報61)内の命令種別列600とアドレス指示
形式別欄601に対応させて加算する。Thereafter, the instruction word analysis unit 23 analyzes the instructions within the range instructed by the control unit 21, and stores the analysis results (instruction type and number for each addressing format) as the number of instruction executions for each addressing format. The instruction type column 600 in the information (if the analyzed range is within the 21st address from the SL address, the instruction execution count storage information 61 by addressing format) is added in correspondence with the instruction type column 600 and the addressing format column 601.
尚、制御部21は、分岐後アドレス51がゼロてm期(
ヒされている最初の分岐命令割込み時に(ま、←岐命令
割込機[30から通知された分岐後アトしスを分岐後ア
ドレス51に記憶するたけて・、命令語解析部23に対
して命令の解析指示をしない。Note that the control unit 21 controls the m-period (
At the time of the first branch instruction interrupt that is being Does not give instructions for analyzing instructions.
以上の動作を行なった後、制御部21は測定対象プログ
ラム41での分岐後アドレスからの実行再開を分岐命令
割込機構30に指示し、次の分岐命令割込み待ちとなる
。After performing the above operations, the control unit 21 instructs the branch instruction interrupt mechanism 30 to resume execution from the post-branch address in the measurement target program 41, and waits for the next branch instruction interrupt.
ここで、第2図は、プログラム命令実行数測定装置2の
命令語解析部23か解析する範囲を、モジュール41の
アドレスPOからアドレスP4までのルーチンを例にと
って、具体的に説明するための関連図である。Here, FIG. 2 shows a relationship for specifically explaining the range to be analyzed by the instruction word analysis unit 23 of the program instruction execution count measuring device 2, taking the routine from address PO to address P4 of the module 41 as an example. It is a diagram.
モジュール41に於いて、アドレスPO1PiP2.P
3.P4は分岐命令の分岐先アドレスであり、アドレス
Bl、B2.B3.B4は分岐命令自身のアドレスであ
る。In module 41, address PO1PiP2. P
3. P4 is the branch destination address of the branch instruction, and addresses B1, B2 . B3. B4 is the address of the branch instruction itself.
まず、モジュール41のアドレスPOに分岐する分岐命
令(図示していない〉が実行されると、分岐命令割込機
構30によって分岐命令割込みが発生し、プログラム命
令実行数測定装置2(の制御部21)か動作する。プロ
グラム命令実行数測定装置2(の制御部21)は、分岐
命令割込機構30から通知されるアドレスPOを分岐後
アドレス51に記憶する(ここでは、アドレスPOに分
岐する前の範囲に対する動作手順の説明を省略する)。First, when a branch instruction (not shown) that branches to address PO of the module 41 is executed, a branch instruction interrupt is generated by the branch instruction interrupt mechanism 30, and the control unit 21 of the program instruction execution count measuring device 2 (not shown) is executed. ), the program instruction execution count measuring device 2 (control unit 21) stores the address PO notified from the branch instruction interrupt mechanism 30 in the post-branch address 51 (here, (The explanation of the operating procedure for the range of is omitted).
次に、モジュール41のアドレスB1での分岐命令が実
行され、分岐先であるアドレスP1で分岐命令割込みが
発生し、プログラム命令実行数測定装置2(の命令語解
析部23〉は、分岐命令割込機構30から通知されるア
ドレスB1とこのとき分岐後アドレス51が記憶してい
るアドレスPOとの範囲(アドレスPOからアドレスB
lまで)にある命令を解析して、その解析結果(命令種
別、且つ、アドレス指定形式別の数)を、アドレス指定
形式別命令実行回数記憶情報61内の命令種別列600
とアドレス指定形式別欄601に対応させて加算する。Next, the branch instruction at address B1 of the module 41 is executed, a branch instruction interrupt occurs at address P1, which is the branch destination, and the program instruction execution number measuring device 2 (instruction word analysis unit 23) The range between the address B1 notified from the loading mechanism 30 and the address PO stored in the post-branch address 51 at this time (from address PO to address B
1), and the analysis result (instruction type and number by addressing format) is stored in the instruction type column 600 in the instruction execution count storage information 61 by addressing format.
and are added in correspondence with the address specification format column 601.
二の凌、プログラム命令実行数測定装置2(の制御部2
1)は、アドレスB1と共に通知されたアl〜レスP1
を分岐後アドレス51に記憶する。Ninoryo, the control unit 2 of the program instruction execution count measuring device 2
1) is address P1 notified along with address B1.
is stored in the post-branch address 51.
同様に、アドレスB2.B3.B4の分岐命令の実行に
よってそれぞれアドレスP2 P3P4で分岐命令割
込みが発生し、このとき、プログラム命令実行数測定装
置2(の命令語解析部23)によって解析されるのは、
それぞれアドレスP1からアドレスB2まての範囲と、
アドレスP2からアドレスB3までの範囲と、アドレス
P3からアドレスB4までの範囲である。Similarly, address B2. B3. Execution of the branch instruction B4 generates branch instruction interrupts at addresses P2, P3, and P4, respectively, and at this time, the program instruction execution count measuring device 2 (instruction word analysis unit 23) analyzes the following:
a range from address P1 to address B2, and
These are the range from address P2 to address B3, and the range from address P3 to address B4.
尚、分岐命令割込み時に、分岐命令割込機構30から通
知されるのは、分岐命令自身のアドレス(Bl、B2.
B3.B4)と分岐命令の分岐先アドレス(PO,PL
、B2.B3.B4)の他に、測定対象プログラム41
の優先レベル番号〈図示していない〉もあり、この優先
レベル番号によって分岐後アドレス51が選択可能とな
る。Note that when a branch instruction interrupts, what is notified from the branch instruction interrupt mechanism 30 is the address of the branch instruction itself (Bl, B2 .
B3. B4) and the branch destination address of the branch instruction (PO, PL
,B2. B3. In addition to B4), measurement target program 41
There is also a priority level number (not shown), and the post-branch address 51 can be selected based on this priority level number.
また、分岐後アドレス記憶部5内の分岐後アドレスは、
優先レベルに対応させて記憶できるため、以上述べた優
先レベル1で走行する測定対象プログラム単独の測定だ
けでなく、複数の優先レベルを同時に測定することか可
能である。Further, the post-branch address in the post-branch address storage unit 5 is
Since the programs can be stored in correspondence with priority levels, it is possible not only to measure only the program to be measured running at priority level 1 as described above, but also to simultaneously measure a plurality of priority levels.
最後に測定が終了し、優先レベル番号1の分岐命令割込
みモード解除指令が入力装W1から入力される。Finally, the measurement is completed, and a branch instruction interrupt mode cancellation command with priority level number 1 is input from the input device W1.
入力情報解析部20は、この入力された優先レベル番号
1に対する分岐命令割込みモード解除指令を制御部21
に通知する。この通知を受けた制御部21は、優先レベ
ル番号1の分岐命令割込みモードを解除して、分岐命令
割込機構30を停止すると共に、優先レベル番号1に対
する測定結果を編集出力するように測定結果w4集出力
部24に指示する。この指示を受けた測定結果編集出力
部24は、アドレス指定形式別命令実行数記憶部6とア
ドレス指定形式別命令実行時間対応表8とともに、モジ
ュール毎の実行時間を算出しくアドレス指定形式別命令
実行回数記憶部61,62.・・・6n内の実行回数と
アドレス指定形式別命令実行時間対応表8内の実行時間
とを命令種別、且つ、アトしス指定形式別に対応させて
乗算し1乗算結果はモジュール毎に合計する〉、この算
出結果を出力装置7に出力する。The input information analysis unit 20 transmits the branch instruction interrupt mode release command for this input priority level number 1 to the control unit 21.
to notify. Upon receiving this notification, the control unit 21 cancels the branch instruction interrupt mode of priority level number 1, stops the branch instruction interrupt mechanism 30, and edits and outputs the measurement results for priority level number 1. Instruct the w4 collection output unit 24. Upon receiving this instruction, the measurement result editing output unit 24 calculates the execution time for each module using the address specification format instruction execution number storage unit 6 and the address specification format instruction execution time correspondence table 8. Number of times storage units 61, 62. ...Multiply the number of executions in 6n and the execution times in the instruction execution time correspondence table 8 by address specification format in correspondence with the instruction type and address specification format, and add up the multiplication results for each module. >, this calculation result is output to the output device 7.
更に、アドレス指定形式別命令実行時間対応表8で示さ
れる命令の実行時間は、同じ命令であっても計算機の種
類によって異なるため、命令の種類毎に、且つ、計算機
の種類毎に命令の実行時間を対応させるように楕或し、
計算機の種類毎にプログラム毎の実行時間を測定するこ
とが可能となる。Furthermore, the instruction execution time shown in the instruction execution time correspondence table 8 by addressing format differs depending on the type of computer even for the same instruction. Oval to match the time,
It becomes possible to measure the execution time of each program for each type of computer.
以上説明したように本発明は、分岐命令割込みを利用し
てプログラムの命令実行数を測定するため、プログラム
の内容を全く知らなくとも測定することができ、測定の
ための手続きも簡単であり、さらに測定のための時間も
机上で計算する場合に比較して大幅に減少する。As explained above, the present invention uses branch instruction interrupts to measure the number of instructions executed in a program, so it can be measured without knowing the contents of the program at all, and the measurement procedure is simple. Furthermore, the time required for measurement is significantly reduced compared to when calculating on a desk.
また、編集出力されるリストには、モジュール毎に実行
時間と命令種別、且つ、アドレス指定形式別の命令実行
回数が出力されるため、プログラム 〈特に、制御プロ
グラム)の性能を改善する場合には、大変参考になる。In addition, the edited list outputs the execution time and instruction type for each module, as well as the number of instruction executions for each addressing format, so when improving the performance of a program (especially a control program), , very helpful.
第1図は本発明の一実施例を示すブロック図、第2図は
プログラム命令実行数測定装置2の命令語解析部23が
解析する範囲を具体的に説明するための関連図である。
l・・・入力装置、2・・・プログラム命令実行数測定
装置、3・・・中央処理装置、4・・・主記憶装置、5
・・分岐後アドレス記憶部、6・・・アドレス指定形式
別命令実行数記憶部、7・・・出力装置、8・・・アド
レス指定形式別命令実行時間対応表。FIG. 1 is a block diagram showing an embodiment of the present invention, and FIG. 2 is a related diagram for specifically explaining the range analyzed by the instruction word analysis unit 23 of the program instruction execution count measuring device 2. In FIG. l...Input device, 2...Program instruction execution number measuring device, 3...Central processing unit, 4...Main storage device, 5
... Post-branch address storage unit, 6... Instruction execution number storage unit by addressing format, 7... Output device, 8... Instruction execution time correspondence table by addressing format.
Claims (1)
ュールの先頭を示し、且つ、そのモジュール名を含むモ
ジュール先頭識別機構を有し、前記全モジュールの先頭
アドレスと終了アドレスとモジュール名とを求めるため
前記モジュール先頭識別機構をサーチするモジュールサ
ーチ手段と、該モジュールサーチ手段によって得られた
前記全モジュールの先頭アドレスと終了アドレスとモジ
ュール名とを記憶するモジュール範囲情報記憶手段と、
分岐命令の実行により分岐後最初の命令が実行される前
に当該分岐命令を含むプログラムの走行の優先レベルと
分岐命令自身のアドレスである分岐前アドレスと分岐命
令の分岐先アドレスである分岐後アドレスとを保持して
内部割込みを発生させ、且つ、該内部割込みが一個以上
の前記優先レベル毎に発生できるような分岐命令割込み
手段と、該分岐命令割込み手段の起動および停止を行な
うための分岐命令割込みモード設定および解除手段と、
前記優先レベルに対応させて前記分岐後アドレスを記憶
する分岐後アドレス記憶手段と、分岐命令割込み時に前
記分岐割込み手段から通知される前記分岐前アドレスと
前記分岐後アドレス記憶手段により当該分岐命令割込み
の一度前の分岐命令割込み時に記憶されていて当該分岐
命令割込み時の前記優先レベルに対応する前記分岐後ア
ドレスとで示される範囲に存在する命令を探索し、命令
種別、且つ、アドレス指定形式別に命令の個数を解析す
る命令解析手段と、該命令解析手段による解析結果を命
令種別、且つ、アドレス指定形式別に、且つ、当該探索
対象となった命令を含むモジュール毎に対応させて累積
して記憶するアドレス指定形式別命令数記憶手段と、命
令種別、且つ、アドレス指定形式別に命令の実行時間を
示すアドレス指定形式別命令実行時間対応情報を有し、
前記アドレス指定形式別命令数記憶手段による累積記憶
結果と前記アドレス指定形式別命令実行時間対応情報と
を基に前記モジュール毎の実行時間を算出するとともに
、編集出力する測定結果編集出力手段とを含むことを特
徴とするプログラムの命令実行数測定方式。The module has a module start identification mechanism that indicates the start of the module at the top of all the modules that make up the program and includes the module name, and the module module search means for searching for a head identification mechanism; module range information storage means for storing the head addresses, end addresses, and module names of all the modules obtained by the module search means;
Before the first instruction after a branch is executed by executing a branch instruction, the priority level of the program including the branch instruction, the pre-branch address which is the address of the branch instruction itself, and the post-branch address which is the branch destination address of the branch instruction. a branch instruction interrupt means for holding and generating an internal interrupt, and the internal interrupt can be generated for each of the one or more priority levels, and a branch instruction for starting and stopping the branch instruction interrupt means. Interrupt mode setting and cancellation means;
The post-branch address storage means stores the post-branch address in correspondence with the priority level, and the pre-branch address and post-branch address storage means are used to store the post-branch address and the post-branch address that are notified from the branch interrupt means when the branch instruction interrupt occurs. Search for instructions that are stored at the time of a previous branch instruction interrupt and exist in the range indicated by the post-branch address that corresponds to the priority level at the time of the branch instruction interrupt, and search for instructions by instruction type and addressing format. an instruction analysis means for analyzing the number of instructions, and the results of analysis by the instruction analysis means are accumulated and stored in association with each instruction type, each address specification format, and each module containing the instruction to be searched. a storage means for storing the number of instructions by addressing format, and instruction execution time correspondence information by addressing format indicating instruction execution time for each instruction type and addressing format;
and measurement result editing/outputting means for calculating the execution time for each module based on the cumulative storage result of the instruction number storing means for each addressing format and the instruction execution time correspondence information for each addressing format, and editing and outputting the execution time for each module. A method for measuring the number of executed instructions of a program.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2057010A JPH03257548A (en) | 1990-03-07 | 1990-03-07 | Measurement system for instruction executing frequency of program |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2057010A JPH03257548A (en) | 1990-03-07 | 1990-03-07 | Measurement system for instruction executing frequency of program |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH03257548A true JPH03257548A (en) | 1991-11-18 |
Family
ID=13043476
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2057010A Ceased JPH03257548A (en) | 1990-03-07 | 1990-03-07 | Measurement system for instruction executing frequency of program |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH03257548A (en) |
-
1990
- 1990-03-07 JP JP2057010A patent/JPH03257548A/en not_active Ceased
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JPH09101880A (en) | Program analyzer | |
| JPH0795293B2 (en) | Information processing equipment | |
| JP2009211588A (en) | Analysis information sampling device of database access delay, analysis information sampling method, and program | |
| JPS63300335A (en) | Measurement system for number of times of instruction execution of program | |
| JPH07152578A (en) | Maximum stack usage detection method | |
| JP2003316611A (en) | Program performance analysis method, its execution device, and its processing program | |
| JP2526713B2 (en) | Primitive program analyzer | |
| JPH0468446A (en) | Debugging supporting device | |
| JP2977951B2 (en) | Arithmetic unit | |
| JP2004133827A (en) | core analyzer | |
| JP2787927B2 (en) | Automatic SFC language generation apparatus and method | |
| JPH01130234A (en) | Fault search method | |
| JPH0497445A (en) | Diagnostic system for information processor | |
| JP2727996B2 (en) | Program execution monitoring method and program execution monitoring system | |
| JPH08153026A (en) | Method of measuring data for program performance evaluation and measuring apparatus therefor | |
| JP2000330823A (en) | Program debugging device and debugging method | |
| JPH01166228A (en) | Automatic detection debug system for unpassed check point | |
| JPS63268040A (en) | Program debugging method | |
| JP2006202102A (en) | Simulation device | |
| JPH03103935A (en) | Numerical calculation processing verifying device dependent upon computer | |
| JPH01298436A (en) | Automatic measuring system for program automatic preparing ratio data | |
| JPH0997182A (en) | Program converter and debug device | |
| JPH05282177A (en) | Test coverage measurement method | |
| JPH02115951A (en) | Maintenance and debug system for high level language program | |
| JPH05233370A (en) | Check system for covering degree of machine language instruction table reference test |