JPH04256039A - Information processor capable of counting instruction - Google Patents

Information processor capable of counting instruction

Info

Publication number
JPH04256039A
JPH04256039A JP3038169A JP3816991A JPH04256039A JP H04256039 A JPH04256039 A JP H04256039A JP 3038169 A JP3038169 A JP 3038169A JP 3816991 A JP3816991 A JP 3816991A JP H04256039 A JPH04256039 A JP H04256039A
Authority
JP
Japan
Prior art keywords
data
machine language
microprogram
value
address
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
JP3038169A
Other languages
Japanese (ja)
Inventor
Mutsuo Shindo
睦雄 進藤
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 Computertechno Ltd
Original Assignee
NEC Computertechno 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 Computertechno Ltd filed Critical NEC Computertechno Ltd
Priority to JP3038169A priority Critical patent/JPH04256039A/en
Publication of JPH04256039A publication Critical patent/JPH04256039A/en
Pending legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

PURPOSE:To drastically reduce measuring time and to prevent the increase of hardware quantity. CONSTITUTION:A microprogram counter holds the address of a microinstruction in the course of execution. A storage device 8 stores either the operation history of a microprogram or the number of times of the execution for each machine language instruction. A trace memory control address generating means 4 generates a memory address capable of tracing the address of the microinstruction in the course of the execution. A selecting means 6 selects one of data obtained from the trace memory control address generating means 4 and the data obtained from the machine language code of an operation code register 1 as the address to be given to the storage device 8 according to the value of the operation mode of the operation code register 1. The selecting means 7 selects either the data obtained from the microprogram counter 2 or the data obtained from an incremental means 5 as the data to be written in the storage device 8 according to the value of the operation mode of the operation code register 1.

Description

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

【0001】0001

【技術分野】本発明は各機械語命令実行回数の計測手段
を備えた命令カウント可能な情報処理装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an information processing apparatus capable of counting instructions and having means for measuring the number of executions of each machine language instruction.

【0002】0002

【従来技術】情報処理装置の処理速度向上、とくにファ
ームウェアやソフトウェアの処理速度の向上を効率よく
行うための情報として各機械語命令実行回数は非常に有
効な情報である。従来の情報処理装置におけるこの各機
械語命令実行回数の計測には、ファームウェア及びソフ
トウェアによる各計測の2つの方法がある。
2. Description of the Related Art The number of executions of each machine language instruction is very effective information for efficiently improving the processing speed of an information processing device, especially for improving the processing speed of firmware and software. There are two methods for measuring the number of executions of each machine language instruction in a conventional information processing device: one using firmware and one using software.

【0003】まず、ファームウェアによる計測方法を図
3を参照して説明する。図3を参照すると、機械語の処
理が開始されると、オペコードデコード手段11により
各機械語命令コードに対応したマイクロ命令の先頭アド
レスが出力されマイクロプログラムが起動される。各機
械語処理マイクロプログラムの先頭にある、計測用にあ
らかじめ用意されたマイクロ命令が実行される。このマ
イクロ命令では、主記憶装置上に確保された命令カウン
ト用メモリアドレスが作成される(12)。
First, a measurement method using firmware will be explained with reference to FIG. Referring to FIG. 3, when machine language processing is started, the operation code decoding means 11 outputs the start address of the microinstruction corresponding to each machine language instruction code, and the microprogram is activated. Microinstructions prepared in advance for measurement at the beginning of each machine language processing microprogram are executed. For this microinstruction, a memory address for instruction counting secured on the main memory is created (12).

【0004】次に計測用共通サブルーチンへのジャンプ
が実行される(13)。すなわち、計測用共通サブルー
チンでは、共に作成されたメモリアドレスに指定された
場所からデータが読出され(131) 、データがカウ
ントアップされ(132) 、そしてカウントアップさ
れたデータが書込まれる。このようなマイクロ命令が実
行されたあと、もとの機械語処理マイクロルーチンにタ
ーンされる。そして次のサイクルから各機械語処理マイ
クロプログラム(14)が実行され機械語の1回の計測
が終了することになる。
Next, a jump to a common measurement subroutine is executed (13). That is, in the common measurement subroutine, data is read from the location specified by the memory address created together (131), the data is counted up (132), and the counted up data is written. After such a microinstruction is executed, a turn is made to the original machine language processing microroutine. From the next cycle, each machine language processing microprogram (14) is executed, and one measurement of machine language is completed.

【0005】このようなファームウェアによる計測方法
において、ファームウェアの書換えが必要である。この
ため読出専用制御記憶装置のみ備えるシステムでは計測
できず、さらにファームウェアの書換作業が必要となり
、また計測用マイクロ命令が各機械語処理毎に実行され
マイクロ命令の処理ステップが増加されるという数々の
欠点がある。
[0005] In such a measurement method using firmware, it is necessary to rewrite the firmware. For this reason, measurement cannot be performed in a system equipped with only a read-only control storage device, the firmware must be rewritten, and the measurement microinstruction is executed for each machine language process, increasing the number of microinstruction processing steps. There are drawbacks.

【0006】次にハードウェアによる計測方法について
図4を参照して説明する。図4を参照すると、機械語の
処理が開始されると、オペコードレジスタ1に保持され
ているオペコードがアドレスとして命令カウント用記憶
装置に与えられる。この記憶装置3は1マシンサイクル
でデータ読出しが行なわれ、データ書込みが行なわれる
。また、記憶装置3から読出されたデータはインクリメ
ント手段5に与えられる。インクリメント手段5でカウ
ントアップされたデータは記憶装置3にそのまま書込ま
れ機械語の1回の計測が終了する。
Next, a measurement method using hardware will be explained with reference to FIG. Referring to FIG. 4, when machine language processing is started, the opcode held in the opcode register 1 is given as an address to the instruction count storage device. Data is read from and written to the storage device 3 in one machine cycle. Further, the data read from the storage device 3 is given to the incrementing means 5. The data counted up by the incrementing means 5 is written as is into the storage device 3, and one measurement of the machine language is completed.

【0007】このようなハードウェアによる計測方法に
おいて、通常の処理では全く使用しない計測専用の記憶
装置を備えなければならず、ハードウェア量が増大する
という欠点がある。
[0007] Such a measurement method using hardware requires a storage device dedicated to measurement, which is not used at all in normal processing, and has the disadvantage that the amount of hardware increases.

【0008】[0008]

【発明の目的】本発明の目的は、計測時間を大幅に低減
しハードウェア量が増大しないようにした命令カウント
可能な情報処理装置を提供することにある。
OBJECTS OF THE INVENTION An object of the present invention is to provide an information processing device capable of counting instructions, which significantly reduces measurement time and prevents increase in hardware amount.

【0009】[0009]

【発明の構成】本発明によれば、データ処理操作手順を
記憶するマイクロプログラムの実行中該マイクロプログ
ラムを構成するマイクロ命令のアドレスを保護するマイ
クロプログラムカウンタ手段と、1マシンサイクルに読
出し書込みの両動作が可能で前記マイクロプログラムの
動作履歴または機械語命令ごとの実行回数のいずれかを
記憶する記憶手段と、この記憶手段から読出されたデー
タに予め定めた数を加えるインクリメント手段と、実行
中のマイクロ命令アドレスをトレースできるようなメモ
リアドレスを発生するトレースメモリ制御アドレス発生
手段と、データ処理操作コードを示す機械語コードフィ
ールドと前記記憶手段に記憶するデータがマイクロプロ
グラムの動作履歴かまたは機械語命令ごとの実行回数か
という動作モードを示す動作モードフィールドの2つの
フィールドからなる機械語命令を保持するオペコード保
持手段と、前記記憶手段に与えるアドレスとして前記ト
レースメモリ制御アドレス発生手段から得られるデータ
および前記オペコード保持手段の機械語コードフィール
ドから得られるデータのどちらか一方を前記オペコード
保持手段の動作モードフィールドの値により選択する第
1の選択手段と、前記記憶手段に書込むデータとして前
記マイクロプログラムカウンタ手段から得られるデータ
および前記インクリメント手段から得られるデータを前
記オペコード保持手段の動作モードフィールドの値によ
り選択する第2の選択手段とを含むことを特徴とする命
令カウント可能な情報処理装置が得られる。
According to the present invention, microprogram counter means protects the addresses of microinstructions constituting a microprogram during execution of a microprogram that stores data processing operation procedures, and a microprogram counter means that protects the addresses of microinstructions constituting the microprogram during execution of the microprogram stores data processing operation procedures, and a microprogram counter means that protects the addresses of microinstructions constituting the microprogram while the microprogram stores data processing operation procedures. a storage means that is operable and stores either the operation history of the microprogram or the number of times each machine language instruction has been executed; an increment means that adds a predetermined number to the data read from the storage means; A trace memory control address generating means for generating a memory address capable of tracing a microinstruction address, a machine language code field indicating a data processing operation code, and the data stored in the storage means being an operation history of a microprogram or a machine language instruction. an operation code holding means for holding a machine language instruction consisting of two fields, an operation mode field indicating an operation mode such as the number of execution times for each operation; data obtained from the trace memory control address generation means as an address to be given to the storage means; a first selection means for selecting one of the data obtained from the machine language code field of the operation code holding means according to the value of the operation mode field of the operation code holding means; and the microprogram counter means as the data to be written in the storage means. and a second selection means for selecting the data obtained from the incrementing means and the data obtained from the incrementing means according to the value of the operation mode field of the operation code holding means.

【0010】0010

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

【0011】図1を参照すると、本発明の第1の実施例
は、実行中のデータ処理操作コードを示す機械語コード
フィールド131 、およびマイクロプログラムの動作
履歴または機械語命令ごとの実行回数のどちらを記憶す
るかという動作モードを示す動作モードフィールド13
2 からなる機械語を保持するオペコードレジスタ1を
含む。
Referring to FIG. 1, the first embodiment of the present invention includes a machine language code field 131 indicating the data processing operation code being executed, and either the operation history of the microprogram or the number of executions for each machine language instruction. Operation mode field 13 indicating the operation mode for storing
It includes an opcode register 1 that holds a machine code consisting of 2.

【0012】各機械語の実行回数計測時には、このレジ
スタ1の機械語コードフィールド131 の値が記憶装
置8へのアドレスデータとなり、各機械語ごとに1ワー
ドの領域が割当てられる。また、オペコードレジスタ1
の動作モードフィールド132 は1ビットであり、こ
のフィールド132 の値が“H”のとき各機械語命令
の実行回数を計測するモードであることを示し、フィー
ルド132 の値が“L”のときはマイクロプログラム
動作履歴記憶モードであることを示す。
When measuring the number of executions of each machine language, the value of the machine code field 131 of this register 1 becomes address data for the storage device 8, and one word area is allocated for each machine language. Also, opcode register 1
The operation mode field 132 is 1 bit, and when the value of this field 132 is "H", it indicates that the mode is for measuring the number of executions of each machine language instruction, and when the value of the field 132 is "L", it indicates that the mode is for measuring the number of executions of each machine language instruction. Indicates microprogram operation history storage mode.

【0013】マイクロプログラムカウンタ2は、実行中
のマイクロ命令アドレスを保持するレジスタである。
The microprogram counter 2 is a register that holds the address of the microinstruction being executed.

【0014】トレースメモリ制御アドレス発生手段4は
、実行中のマイクロ命令アドレスからNステップ古いマ
イクロ命令アドレスまでを常に記憶させるため、0,1
,2,…,N−1,N,0,1,…,N−1,N,0,
…のような常に巡回する記憶装置8のためのアドレスを
出力する。
The trace memory control address generating means 4 always stores the address of the microinstruction N steps older than the microinstruction address being executed.
,2,...,N-1,N,0,1,...,N-1,N,0,
Outputs the address for the constantly circulating storage device 8, such as...

【0015】インクリメント手段5は与えられたデータ
をプラス1して出力する加算器である。
The incrementing means 5 is an adder that adds 1 to the given data and outputs the result.

【0016】第1の選択手段6は、トレースメモリ制御
アドレス発生手段4の値とオペコードレジスタ1の機械
語コードフィールド131 の値が入力され、オペコー
ドレジスタ1の動作モードフィールド132 の値が“
L”のときはトレースメモリ制御アドレス発生手段4の
値を記憶装置8のアドレスとして選択出力し、動作モー
ドフィールド132 の値が“H”のときは機械語コー
ドフィールド131 の値を記憶装置8のアドレスとし
て選択出力する。
The first selection means 6 receives the value of the trace memory control address generation means 4 and the value of the machine code field 131 of the operation code register 1, and the value of the operation mode field 132 of the operation code register 1 is set to "
When the value of the trace memory control address generation means 4 is "L", the value of the trace memory control address generation means 4 is selected and output as the address of the storage device 8, and when the value of the operation mode field 132 is "H", the value of the machine language code field 131 is outputted as the address of the storage device 8. Selectively output as an address.

【0017】第2の選択手段7はオペコードレジスタ1
の動作をモードフィールド132 の値が“L”のとき
はマイクロプログラムカウンタ2の値を記憶装置8への
書込データとして選択出力し、動作モードフィールド1
32 の値が“H”のときはインクリメント手段5の値
を記憶装置8への書込データとして選択出力する。
The second selection means 7 is an operation code register 1
When the value of the mode field 132 is "L", the value of the micro program counter 2 is selected and output as write data to the storage device 8, and the value of the operation mode field 132 is "L".
When the value of 32 is "H", the value of the increment means 5 is selectively outputted as write data to the storage device 8.

【0018】記憶装置8は、1マシンサイクルで読出し
、書込みの両動作が実行可能であり、マイクロプログラ
ムの動作履歴または各機械語命令の実行回数のいずれか
を記憶する。
The storage device 8 can perform both read and write operations in one machine cycle, and stores either the operation history of the microprogram or the number of executions of each machine language instruction.

【0019】次に本発明の第1の実施例の動作について
図1を参照して詳細に説明する。図1を参照すると、オ
ペコードレジスタ1の動作モードフィールド132 の
値が“L”の場合、第1の選択手段6はトレースメモリ
制御アドレス発生手段4の値を選択し、第2の選択手段
7はマイクロプログラムカウンタ2の値を選択する。
Next, the operation of the first embodiment of the present invention will be explained in detail with reference to FIG. Referring to FIG. 1, when the value of the operation mode field 132 of the operation code register 1 is "L", the first selection means 6 selects the value of the trace memory control address generation means 4, and the second selection means 7 selects the value of the trace memory control address generation means 4. Select the value of micro program counter 2.

【0020】従って、記憶装置8に与えられるアドレス
はトレースメモリ制御アドレス発生手段4によりラウン
ドロビン方式で作成された“O”から“N”の間を順序
よく昇順に巡回する値となる。このアドレスで指定され
る記憶装置8の位置に第2の選択手段7で選択されたマ
イクロプログラムカウンタ2からの値を書込む。この書
込動作によりマイクロプログラムの動作履歴を記憶する
ことができる。
Therefore, the address given to the storage device 8 is a value that is generated by the trace memory control address generation means 4 in a round-robin manner and circulates in ascending order between "O" and "N". The value from the microprogram counter 2 selected by the second selection means 7 is written to the location of the storage device 8 specified by this address. This write operation allows the operation history of the microprogram to be stored.

【0021】オペコードレジスタ1の動作モードフィー
ルド132 の値が“H”のとき第1の選択手段6から
機械語コードフィールド131 の値が選択される。従
って、記憶装置8に与えられるアドレスは各機械語コー
ドごとに異なるものとなり、記憶装置8上に各機械語命
令個々の実行回数値の記憶場所が確保される。
When the value of the operation mode field 132 of the operation code register 1 is "H", the value of the machine code field 131 is selected by the first selection means 6. Therefore, the address given to the storage device 8 is different for each machine language code, and a storage location for the execution count value of each machine language instruction is secured on the storage device 8.

【0022】機械語の1つの実行とともに機械語コード
フィールド131 の値に対応した機械語命令の実行回
数値が記憶装置8から読出される。記憶装置8から読出
された実行回数値はインクリメント手段5で“1”が加
えられたあと、第2の選択手段7に与えられる。動作モ
ードフィールド132 の値が“H”であるため、第2
の選択手段7から記憶装置8に与えられるデータは、イ
ンクリメント手段5から出力された値となる。従って、
記憶装置8から以前に読出された機械語命令の実行回数
値にプラス1された機械語命令の実行回数値が記憶装置
8に書込まれ、一機械語命令に対する計測動作が完了す
る。
When one machine language is executed, the number of executions of the machine language instruction corresponding to the value of the machine language code field 131 is read from the storage device 8. The execution count value read from the storage device 8 is incremented by "1" by the incrementing means 5, and then given to the second selection means 7. Since the value of the operation mode field 132 is “H”, the second
The data given to the storage device 8 from the selection means 7 becomes the value output from the increment means 5. Therefore,
The execution count value of the machine language instruction, which is added by 1 to the execution count value of the machine language instruction previously read from the storage device 8, is written to the storage device 8, and the measurement operation for one machine language instruction is completed.

【0023】次に本発明の第2の実施例について図2を
参照して詳細に説明する。図2を参照すると、本発明の
第2の実施例は、実行中のデータ処理操作コードを示す
機械語コードフィールド131 とマイクロプログラム
の動作履歴または機械語命令ごとの実行回数のうちどち
らを記憶するかという動作モードを示す動作モードフィ
ールド132 とからなる機械語を保持するオペコード
レジスタ1を備えている。
Next, a second embodiment of the present invention will be explained in detail with reference to FIG. Referring to FIG. 2, the second embodiment of the present invention stores a machine language code field 131 indicating the data processing operation code being executed and either the operation history of the microprogram or the number of executions for each machine language instruction. The operation code register 1 is provided to hold machine language consisting of an operation mode field 132 indicating an operation mode.

【0024】各機械語の実行回数計測時にはこのレジス
タ1の機械語コードフィールド131 の値が記憶部8
1へのアドレスとなり各機械語ごとに1ワードの領域が
割当てられる。また、動作モードフィールド132 は
1ビットであり、このフィールド132 の値が“H”
のときは各機械語命令の実行回数を計測するモードであ
ることを示し、フィールド132 の値が“L”のとき
はマイクロプログラム動作履歴記憶モードであることを
示す。
When measuring the number of executions of each machine language, the value of the machine language code field 131 of this register 1 is stored in the storage section 8.
1, and an area of 1 word is allocated for each machine language. Furthermore, the operation mode field 132 is 1 bit, and the value of this field 132 is “H”.
, it indicates that the mode is for counting the number of executions of each machine language instruction, and when the value of field 132 is "L", it indicates that the mode is for storing the microprogram operation history.

【0025】マイクロプログラムカウンタ2は、実行中
のマイクロ命令アドレスを保持するレジスタである。
The microprogram counter 2 is a register that holds the address of the microinstruction being executed.

【0026】トレースメモリ制御アドレス発生手段4は
、実行中のマイクロ命令アドレスからNステップ古いマ
イクロ命令アドレスまでを常に記憶させるため、0,1
,2,…,N−1,N,0,1,…,N−1,N,0,
…のような常に巡回する記憶部81用アドレスを出力す
る。
The trace memory control address generating means 4 always stores the microinstruction address N steps older from the microinstruction address being executed.
,2,...,N-1,N,0,1,...,N-1,N,0,
It outputs an address for the storage unit 81 that is constantly circulated, such as...

【0027】インクリメント手段5は、与えられたデー
タに“1”を加えて出力する加算器である。
The incrementing means 5 is an adder that adds "1" to the supplied data and outputs the result.

【0028】第1の選択手段6は、動作モードフィール
ド132 の値が“L”のとき、トレースメモリ制御ア
ドレス発生手段4の値を記憶部81のアドレスとして選
択出力し、動作モードフィールド132 の値が“H”
のとき機械語コードフィールド231 の値を記憶部8
1のアドレスとして選択出力する。
When the value of the operation mode field 132 is "L", the first selection means 6 selects and outputs the value of the trace memory control address generation means 4 as the address of the storage section 81, and selects and outputs the value of the operation mode field 132. is “H”
When , the value of machine code field 231 is stored in storage unit 8.
Selectively output as address 1.

【0029】第2の選択手段7は、動作モードフィール
ド132 の値が“L”のとき、マイクロプログラムカ
ウンタ2の値を記憶部81の書込みデータとして選択出
力し、動作モードフィールド132 の値が“H”のと
きインクリメント手段5の値を該書込データとして選択
出力する。記憶部81は、マイクロプログラムの動作履
歴または各機械語命令の実行回数のいずれかを記憶する
When the value of the operation mode field 132 is "L", the second selection means 7 selects and outputs the value of the microprogram counter 2 as the write data of the storage section 81, and the value of the operation mode field 132 is "L". At the time of "H", the value of the increment means 5 is selected and outputted as the write data. The storage unit 81 stores either the operation history of the microprogram or the number of executions of each machine language instruction.

【0030】記憶部制御手段9は、記憶部81に対して
マシンサイクルの前半に読出動作とマシンサイクルの後
半に書込動作を行う制御指示を出力するとともに、マシ
ンサイクルが前半から後半に変化するタイミングで記憶
部81から読出されたデータをデータラッチ10に記憶
させるよう制御指示する。
The storage unit control means 9 outputs a control instruction to the storage unit 81 to perform a read operation in the first half of the machine cycle and a write operation in the second half of the machine cycle, and also changes the machine cycle from the first half to the second half. A control instruction is given to cause the data latch 10 to store the data read from the storage section 81 at the appropriate timing.

【0031】データラッチ10は、記憶部81から読出
されたデータを一時記憶しインクリメント手段5に対し
、データを出力する。
The data latch 10 temporarily stores the data read from the storage section 81 and outputs the data to the increment means 5.

【0032】次に、本発明の第2の実施例の動作を図2
を参照して詳述する。図2を参照すると、オペコードレ
ジスタ1の動作モードフィールド132 の値が“L”
の場合、第1の選択手段6はトレースメモリ制御アドレ
ス発生手段4の値を選択し、第2の選択手段7はマイク
ロプログラムカウンタ2の値を選択する。従って、記憶
部81に与えられるアドレスは、トレースメモリ制御ア
ドレス発生手段4によりラウンドロビン方式で作成され
た“0”から“N”の間を順序よく昇順に巡回する値と
なる。
Next, FIG. 2 shows the operation of the second embodiment of the present invention.
Please refer to the following for details. Referring to FIG. 2, the value of the operation mode field 132 of the opcode register 1 is “L”.
In this case, the first selection means 6 selects the value of the trace memory control address generation means 4, and the second selection means 7 selects the value of the microprogram counter 2. Therefore, the address given to the storage unit 81 is a value that cycles in ascending order between "0" and "N" created by the trace memory control address generation means 4 in a round-robin method.

【0033】マイクロプログラムカウンタ2の値は第2
の選択手段7を介して記憶部8に書込まれて、マイクロ
プログラムの動作履歴が記憶される。オペコードレジス
タ1の動作モードフィールド132 の値が“H”であ
ると、第1の選択手段6は、機械語コードフィールド1
31 の値を選択する。従って、記憶部81に与えられ
るアドレスは、各機械語コードごとに異なるものとなり
、記憶部81上に各機械語命令個々の実行回数値の記憶
場所が確保される。
The value of microprogram counter 2 is the second
The operation history of the microprogram is written into the storage section 8 via the selection means 7, and the operation history of the microprogram is stored therein. When the value of the operation mode field 132 of the operation code register 1 is "H", the first selection means 6 selects the machine language code field 132.
Select the value of 31. Therefore, the address given to the storage unit 81 is different for each machine language code, and a storage location for the execution count value of each machine language instruction is secured on the storage unit 81.

【0034】マシンサイクルの開始とともに機械語の一
つの実行が開始される。これと同時に、機械語コードフ
ィールド131 の値に対応した機械語命令の実行回数
値を記憶部制御手段9の指示により記憶部81から読出
す。
[0034] At the start of a machine cycle, execution of one machine language begins. At the same time, the execution count value of the machine language instruction corresponding to the value of the machine language code field 131 is read out from the storage section 81 according to instructions from the storage section control means 9.

【0035】記憶部81から読出された実行回数値はデ
ータラッチ10に与えられる。
The execution count value read from the storage section 81 is given to the data latch 10.

【0036】マシンサイクルの前半から後半に変わるタ
イミングで記憶部制御手段9はデータラッチ10にデー
タ保持を指示し、データラッチ10は与えられたデータ
を保持する。また、このタイミングで記憶部制御手段9
は記憶部81にデータ読出動作を終了し書込動作となる
ように指示を出力する。
At a timing when the machine cycle changes from the first half to the second half, the storage section control means 9 instructs the data latch 10 to hold data, and the data latch 10 holds the applied data. Also, at this timing, the storage unit control means 9
outputs an instruction to the storage unit 81 to end the data read operation and start the write operation.

【0037】マシンサイクルの後半はデータラッチ10
に保持された機械語命令の実行回数値がデータラッチ1
0から読出され、インクリメント手段5に与えられる。 インクリメント手段5に与えられた機械語命令の実行回
数値に“1”が加えられ、第2の選択手段7に与えられ
る。  動作モードフィールド132 の値が“H”で
あるため、第2の選択手段7はインクリメント手段5か
らの値を選択し、記憶部81にデータとして供給する。 従って、記憶部81から以前読出された機械語命令の実
行回数値に“1”を加えられた機械語命令の実行回数値
が記憶部8に書込まれ、一機械語命令に対しての計測動
作が完了する。
In the second half of the machine cycle, data latch 10
The execution count value of the machine language instruction held in data latch 1
It is read from 0 and given to the increment means 5. “1” is added to the execution count value of the machine language instruction given to the increment means 5, and the result is given to the second selection means 7. Since the value of the operation mode field 132 is "H", the second selection means 7 selects the value from the increment means 5 and supplies it to the storage section 81 as data. Therefore, the execution count value of the machine language instruction, which is obtained by adding "1" to the execution count value of the machine language instruction previously read from the storage unit 81, is written to the storage unit 8, and the measurement for one machine language instruction is performed. The operation is complete.

【0038】[0038]

【発明の効果】以上説明したように本発明は、ハードウ
ェアによる機械語命令実行数の計測手段を提供すること
により計測時間を大幅に低減し、かつこの計測手段を、
マイクロプログラムトレース用記憶装置と機械語命令実
行数の計測記憶装置とを共用して実現したことにより、
ハードウェア量が増大しないという効果がある。
As explained above, the present invention significantly reduces the measurement time by providing a means for measuring the number of executed machine language instructions using hardware, and also enables the measuring means to
By sharing the storage device for microprogram tracing and the storage device for measuring the number of executed machine language instructions,
This has the effect that the amount of hardware does not increase.

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

【図1】本発明の第1の実施例を示す図である。FIG. 1 is a diagram showing a first embodiment of the present invention.

【図2】本発明の第2の実施例を示す図である。FIG. 2 is a diagram showing a second embodiment of the invention.

【図3】従来技術のファームウェアによる処理手順を説
明するための図である。
FIG. 3 is a diagram for explaining a processing procedure using firmware in the prior art.

【図4】従来技術のハードウェアによる処理手順を説明
するための図である。
FIG. 4 is a diagram for explaining a processing procedure by hardware in the prior art.

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

1  オペコードレジスタ 2  マイクロプログラムカウンタ 3  記憶装置 4  トレースメモリ制御アドレス発生手段5  イン
クリメント手段 6  第1の選択手段 7  第2の選択手段 8  記憶装置 9  記憶部制御手段 10  データラッチ
1 Operation code register 2 Microprogram counter 3 Storage device 4 Trace memory control address generation means 5 Increment means 6 First selection means 7 Second selection means 8 Storage device 9 Storage section control means 10 Data latch

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】  データ処理操作手順を記憶するマイク
ロプログラムの実行中該マイクロプログラムを構成する
マイクロ命令のアドレスを保護するマイクロプログラム
カウンタ手段と、1マシンサイクルに読出し書込みの両
動作が可能で前記マイクロプログラムの動作履歴または
機械語命令ごとの実行回数のいずれかを記憶する記憶手
段と、この記憶手段から読出されたデータに予め定めた
数を加えるインクリメント手段と、実行中のマイクロ命
令アドレスをトレースできるようなメモリアドレスを発
生するトレースメモリ制御アドレス発生手段と、データ
処理操作コードを示す機械語コードフィールドと前記記
憶手段に記憶するデータがマイクロプログラムの動作履
歴かまたは機械語命令ごとの実行回数かという動作モー
ドを示す動作モードフィールドの2つのフィールドから
なる機械語命令を保持するオペコード保持手段と、前記
記憶手段に与えるアドレスとして前記トレースメモリ制
御アドレス発生手段から得られるデータおよび前記オペ
コード保持手段の機械語コードフィールドから得られる
データのどちらか一方を前記オペコード保持手段の動作
モードフィールドの値により選択する第1の選択手段と
、前記記憶手段に書込むデータとして前記マイクロプロ
グラムカウンタ手段から得られるデータおよび前記イン
クリメント手段から得られるデータを前記オペコード保
持手段の動作モードフィールドの値により選択する第2
の選択手段とを含むことを特徴とする命令カウント可能
な情報処理装置。
1. A microprogram counter that protects the addresses of microinstructions constituting the microprogram during execution of a microprogram that stores data processing operation procedures, and a microprogram counter that is capable of both reading and writing operations in one machine cycle. A storage means for storing either the program operation history or the number of executions for each machine language instruction, an increment means for adding a predetermined number to the data read from the storage means, and an address for tracing the microinstruction being executed. a trace memory control address generation means for generating a memory address, a machine language code field indicating a data processing operation code, and a field indicating whether the data stored in the storage means is the operation history of a microprogram or the number of executions for each machine language instruction. an operation code holding means for holding a machine language instruction consisting of two fields, an operation mode field indicating an operation mode; data obtained from the trace memory control address generation means as an address to be given to the storage means; and a machine language for the operation code holding means. a first selection means for selecting one of the data obtained from the code field according to the value of the operation mode field of the operation code holding means; the data obtained from the microprogram counter means and the first selection means as data to be written in the storage means; a second selector for selecting data obtained from the incrementing means according to the value of the operation mode field of the operation code holding means;
An information processing device capable of counting instructions, comprising: selection means.
【請求項2】  請求項1記載の命令カウント可能な情
報処理装置において、前記記憶手段は、マイクロプログ
ラムの動作履歴または機械語命令ごとの実行回数のいず
れかを記憶する記憶部と、この記憶部からの読出された
データを保持するデータ保持手段と、1マシンサイクル
の前半に前記記憶部をデータ読出動作とする指示を出す
とともに前記データ保持手段に前記記憶部から読出され
たデータを保持させる指示を出しかつ1マシンサイクル
の後半に前記データ保持手段に保持されているデータを
インクリメントし前記第2の選択手段から受取ったデー
タを前記記憶部に書込むよう指示を出す記憶部制御手段
とを含むことを特徴とする命令カウント可能な情報処理
装置。
2. The information processing device capable of counting instructions according to claim 1, wherein the storage means includes a storage section that stores either the operation history of the microprogram or the number of times each machine language instruction is executed, and the storage section. a data holding means for holding data read from the storage unit; and an instruction to cause the storage unit to perform a data read operation in the first half of one machine cycle, and an instruction to cause the data holding unit to hold the data read from the storage unit. storage section control means for incrementing the data held in the data holding means in the latter half of one machine cycle and issuing an instruction to write the data received from the second selection means to the storage section. An information processing device capable of counting instructions.
JP3038169A 1991-02-07 1991-02-07 Information processor capable of counting instruction Pending JPH04256039A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3038169A JPH04256039A (en) 1991-02-07 1991-02-07 Information processor capable of counting instruction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3038169A JPH04256039A (en) 1991-02-07 1991-02-07 Information processor capable of counting instruction

Publications (1)

Publication Number Publication Date
JPH04256039A true JPH04256039A (en) 1992-09-10

Family

ID=12517899

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3038169A Pending JPH04256039A (en) 1991-02-07 1991-02-07 Information processor capable of counting instruction

Country Status (1)

Country Link
JP (1) JPH04256039A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5388233A (en) * 1993-04-30 1995-02-07 Intel Corporation Method and apparatus for counting instruction types using bit masks and a programmable bit map

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5388233A (en) * 1993-04-30 1995-02-07 Intel Corporation Method and apparatus for counting instruction types using bit masks and a programmable bit map

Similar Documents

Publication Publication Date Title
US3979729A (en) Microprogram unit for a data processor
GB2079502A (en) Digital computers
US4124892A (en) Data processing systems
JPH04256039A (en) Information processor capable of counting instruction
JP2758624B2 (en) Speed control method of micro program
JP3055139B2 (en) Micro program control method
JPH0470936A (en) Information processor
JP2819753B2 (en) Pipeline microprocessor
JP3057732B2 (en) Information processing device
US3763475A (en) Stored program computer with plural shift register storage
JPH08328851A (en) Load / store instruction processing device and method
JPH0561660B2 (en)
JPH0128965B2 (en)
JPH0831054B2 (en) History information storage method
JP3153063B2 (en) Micro program controller
JPH05233379A (en) Execution history storage device
JP2689894B2 (en) Micro program control type information processing device
JPS5947649A (en) Data processor
JPH04243436A (en) Execution history storage device
JPS63301338A (en) Memory with control memory
JPS5936853A (en) Operation processor
JPH05224919A (en) Program execution system for microprocessor
JPH05250156A (en) RISC processor
JPH0145650B2 (en)
JPH064345A (en) History information storage system