JPH02165349A - Address tracing circuit - Google Patents

Address tracing circuit

Info

Publication number
JPH02165349A
JPH02165349A JP63321434A JP32143488A JPH02165349A JP H02165349 A JPH02165349 A JP H02165349A JP 63321434 A JP63321434 A JP 63321434A JP 32143488 A JP32143488 A JP 32143488A JP H02165349 A JPH02165349 A JP H02165349A
Authority
JP
Japan
Prior art keywords
address
trace
execution
circuit
memory
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
JP63321434A
Other languages
Japanese (ja)
Inventor
Chikara Suzuki
鈴木 主税
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP63321434A priority Critical patent/JPH02165349A/en
Publication of JPH02165349A publication Critical patent/JPH02165349A/en
Pending legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

PURPOSE:To effectively use an address tracing memory by specifying the range of execution addresses for collecting trace information by a microinstruction and storing only a necessary execution address in an address trace memory. CONSTITUTION:Two address comparators 8, 9 compare address information set up by a microinstruction with an execution address. When an address trace control circuit 10 outputs an address updating signal indicating whether the address of the address trace memory 6 is to be updated or not based upon the compared results of these comparators 8, 9, an address trace memory control circuit 11 controls the address of the memory 6 for storing the execution address based upon the address updating signal. Thus, the address trace memory 6 can be effectively used.

Description

【発明の詳細な説明】 (産業上の利用分野) 本発明は、マイクロ命令の実行アドレスをアドレストレ
ースメモリに格納するアドレストレース回路に関する。
DETAILED DESCRIPTION OF THE INVENTION (Field of Industrial Application) The present invention relates to an address trace circuit that stores an execution address of a microinstruction in an address trace memory.

(従来の技術) マイクロプログラム制御装置には、マイクロプログラム
のデバッグ等を効率よく行う為、マイクロプログラムの
マイクロ命令の実行アドレスをアドレストレースメモリ
に保持しておくアドレストレース回路が設けられている
。このアドレストレース回路は、一般に、実行アドレス
の収集の開始が指示されると実行された全てのマイクロ
命令の実行アドレスをアドレストレースメモリに格納し
、アドレストレースメモリの全てのアドレス領域に実行
アドレス情報を格納した時点で動作を終了している。
(Prior Art) A microprogram control device is provided with an address trace circuit that holds execution addresses of microinstructions of a microprogram in an address trace memory in order to efficiently debug the microprogram. In general, this address trace circuit stores the execution addresses of all executed microinstructions in the address trace memory when it is instructed to start collecting execution addresses, and stores execution address information in all address areas of the address trace memory. The operation ends when it is stored.

(発明が解決しようとする課題) 上述したように、従来のアドレストレース回路は、実行
アドレスの収集の開始が指示されると実行された全ての
実行アドレスをアドレストレースメモリに格納し、アド
レストレースメモリの全アドレス領域にアドレス情報を
格納した時点で実行アドレスの収集を停止するので、必
要とする実行アドレスが格納されずに必要としない実行
アドレスが格納されてしまう場合がある。従って、アド
レストレースメモリが無駄に使用されてしまう場合があ
る。このように従来のアドレストレース回路には解決す
べき課題がある。
(Problems to be Solved by the Invention) As described above, the conventional address trace circuit stores all executed execution addresses in the address trace memory when the start of collection of execution addresses is instructed, and stores the executed addresses in the address trace memory. Since collection of execution addresses is stopped when address information is stored in all address areas of , there are cases where necessary execution addresses are not stored and unnecessary execution addresses are stored. Therefore, the address trace memory may be wasted. As described above, conventional address trace circuits have problems to be solved.

本発明は、このような事情に鑑みてなされたものであり
、その目的は、アドレストレースメモリを有効に使用す
ることができるアドレストレース回路を提供することに
ある。
The present invention has been made in view of the above circumstances, and an object of the present invention is to provide an address trace circuit that can effectively use address trace memory.

(課題を解決するための手段) 本発明のアドレストレース回路は、上記目的を達成する
ために、マイクロ命令の実行アドレスをアドレストレー
スメモリに格納するアドレストレース回路において、 前記マイクロ命令により設定されたアドレス情報と前記
実行アドレスとを比較する第1の比較回路および第2の
比較回路と、 前記第1の比較回路と前記第2の比較回路との比較結果
に基づいて前記アドレストレースメモリのアドレスを更
新するか否かを示すアドレス更新信号を出力するアドレ
ストレース制御回路と、該アドレストレース制御回路に
より出力されたアドレス更新信号に基づいて、前記実行
アドレスを格納する前記アドレストレースメモリのアド
レスを制御するアドレストレースメモリ制御回路とを有
する。
(Means for Solving the Problems) In order to achieve the above object, an address trace circuit of the present invention stores an execution address of a microinstruction in an address trace memory, and includes an address trace circuit that stores an execution address of a microinstruction in an address trace memory. a first comparison circuit and a second comparison circuit that compare information and the execution address; and updating the address of the address trace memory based on a comparison result between the first comparison circuit and the second comparison circuit. an address trace control circuit that outputs an address update signal indicating whether or not to execute the execution address; and an address that controls the address of the address trace memory that stores the execution address based on the address update signal output by the address trace control circuit. and a trace memory control circuit.

(作用) 本発明のアドレストレース回路においては、第1の比較
回路および第2の比較回路が、マイクロ命令により設定
されたアドレス情報と実行アドレスとを比較する。そし
て、アドレストレース制御回路が、第1の比較回路と前
記第2の比較回路との比較結果に基づいてアドレストレ
ースメモリのアドレスを更新するか否かを示すアドレス
更新信号を出力すると、アドレストレースメモリ$制御
回路が、このアドレス更新信号に基づいて、前記実行ア
ドレスを格納するアドレストレースメモリのアドレスを
制御する。
(Operation) In the address trace circuit of the present invention, the first comparison circuit and the second comparison circuit compare address information set by a microinstruction with an execution address. Then, when the address trace control circuit outputs an address update signal indicating whether or not to update the address of the address trace memory based on the comparison result between the first comparison circuit and the second comparison circuit, the address trace control circuit outputs an address update signal indicating whether or not to update the address of the address trace memory. A $ control circuit controls the address of the address trace memory that stores the execution address based on this address update signal.

(実施例) 次に、本発明の実施例について図面を参照して詳細に説
明する。
(Example) Next, an example of the present invention will be described in detail with reference to the drawings.

第1図は本発明の一実施例の構成図である。同図におい
て、1はマイクロ命令を格納するコントロールストレー
ジ、2は通常は一つのマイクロ命令が実行される毎にそ
の値を+1して次に実行すべきマイクロ命令が格納され
ているコントロールストレージ1のアドレス(実行アド
レス)を指定するマイクロアドレスレジスタ、3は無条
件分岐命令および条件分岐命令等のときマイクロアドレ
スレジスタ2の出力したアドレスを変更するマイクロア
ドレス制御回路、4はコントロールストレージ1から読
み出されたマイクロ命令を保持するマイクロ命令レジス
タ、5はマイクロアドレスレジスタ2に保持されている
マイクロ命令をデコードするデコード回路、6は実行ア
ドレスを格納するアドレストレースメモリ、7はマイク
ロアドレス制御回路3により出力された実行アドレスを
ラッチするラッチ回路、8.9はマイクロ命令によりセ
ットされたアドレス情報の値とラッチ回路7の値とを比
較して比較結果を出力するアドレス比較回路、10はア
ドレス比較回路9.10の出力情報に基づいて実行アド
レスをトレースするか否かを示すトレース収集信号を出
力するアドレストレース制御回路、11はこのトレース
アドレスメモリ更新信号を受は取る毎にアドレストレー
スメモリ6のアドレスと書き込み信号とを出力し、その
後アドレスの値を+1するアドレストレースメモリ制御
回路である。
FIG. 1 is a block diagram of an embodiment of the present invention. In the figure, 1 is a control storage that stores microinstructions, and 2 is a control storage 1 in which the next microinstruction to be executed is usually incremented by 1 each time one microinstruction is executed. A microaddress register 3 specifies an address (execution address), a microaddress control circuit 3 changes the address output by the microaddress register 2 in the case of an unconditional branch instruction, a conditional branch instruction, etc., and a microaddress control circuit 4 reads out the address from the control storage 1. 5 is a decode circuit that decodes the microinstructions held in the microaddress register 2, 6 is an address trace memory that stores execution addresses, and 7 is a microinstruction register that is output by the microaddress control circuit 3. 8.9 is an address comparison circuit that compares the value of the address information set by the microinstruction with the value of the latch circuit 7 and outputs a comparison result; 10 is an address comparison circuit 9.9; An address trace control circuit outputs a trace collection signal indicating whether or not to trace an execution address based on the output information of 10, and 11 writes the address of the address trace memory 6 each time it receives this trace address memory update signal. This is an address trace memory control circuit that outputs a signal and then increments the address value by 1.

次に本発明の実施例の動作を第1図を参照して説明する
。ここで、コントロールストレージ1の0.1番地には
、アドレス比較回路8にトレース・情報を収集する下限
のアドレス(下限アドレス)を指定する命令が格納され
、1番地にはトレース情報を収集する上限のアドレス(
上限アドレス)を指定する命令がそれぞれ格納され、2
番地以降に実際に処理するマイクロ命令が格納されてい
るものとする。 外部よりマイクロ制御装置が初期設定
(リセット)されると、マイクロアドレスレジスタ2、
マイクロ命令レジスタ4、ラッチ回路7およびアドレス
トレースメモリ制御回路11は所定の値たとえば「0」
にそれぞれ設定され、マイクロアドレス制御回路3はマ
イクロアドレスレジスタ2の値をそのまま出力するよう
に設定される。
Next, the operation of the embodiment of the present invention will be explained with reference to FIG. Here, at address 0.1 of the control storage 1, an instruction that specifies the lower limit address (lower limit address) for collecting trace information in the address comparison circuit 8 is stored, and at address 1, an upper limit address for collecting trace information is stored. address (
The instructions specifying the upper limit address) are stored, and 2
It is assumed that microinstructions to be actually processed are stored after the address. When the microcontroller is initialized (reset) from the outside, microaddress register 2,
The microinstruction register 4, latch circuit 7 and address trace memory control circuit 11 are set to a predetermined value, for example "0".
, respectively, and the microaddress control circuit 3 is set to output the value of the microaddress register 2 as is.

次にマイクロ命令の実行の開始が指示されると、マイク
ロアドレスレジスタ2のgi’ OJがマイクロアドレ
ス制御回路3を介してコントロールストレージ1に加え
られると、コントロールストレージ1は、0番地に格納
されているマイクロ命令(上述したアドレス比較回路8
に下限アドレスを設定する命令)を出力する。この読み
出されたマイクロ命令はマイクロ命令レジスタ4に保持
され、この保持されたマイクロ命令の一部がデコード回
路5によりデコードされてアドレス比較回路8にアドレ
スを設定する命令と解読されると、トレース収集範囲の
下1@アドレス情報がアドレス比較回路8に送られる。
Next, when the start of execution of a microinstruction is instructed, gi' OJ of the microaddress register 2 is added to the control storage 1 via the microaddress control circuit 3, and the control storage 1 is stored at address 0. microinstruction (address comparison circuit 8 mentioned above)
(instruction to set the lower limit address) is output. This read microinstruction is held in the microinstruction register 4, and when a part of this held microinstruction is decoded by the decoding circuit 5 and interpreted as an instruction to set an address in the address comparison circuit 8, trace The lower 1@address information of the collection range is sent to the address comparison circuit 8.

アドレス比較回路8は、この下限アドレス苗報たとえば
rlooi番地を内部に保持する。このようにして一つ
のマイクロ命令の実行が終了すると、マイクロアドレス
レジスタ2は、その値を+1するので「1」となり1番
地に格納されている上述したマイクロ命令が0番地のマ
イクロ命令を実行したと同様に実行されることになる。
The address comparison circuit 8 internally holds this lower limit address information, for example, the rlooi address. When the execution of one micro-instruction is completed in this way, the micro-address register 2 increments its value by 1, so it becomes "1" and the above-mentioned micro-instruction stored at address 1 executes the micro-instruction at address 0. will be executed in the same way.

この結果アドレス比較回路9にはトレース収集範囲の上
限アドレスたとえばr200jが設定されることになる
As a result, the upper limit address of the trace collection range, for example r200j, is set in the address comparison circuit 9.

アドレス比較回路8,9に設定が終了すると2番地のマ
イクロ命令が上述したと同様に実行される。この時マイ
クロアドレス制御回路3の出力した実行アドレス「2」
はラッチ回路7にも加えられており、ランチ回路7に保
持される。アドレス比較回路8.9は内部に保持してい
るアドレス情報の値とラッチ回路7に保持されている実
行アドレスの値「2」とを比較する。この結果アドレス
比較回路8は内部に保持している下限アドレス情報の値
より小さい旨を、アドレス比較回路9も内部に保持して
いる上限アドレスの値より小さい旨をそれぞれ出力する
。アドレストレース制御回路10はこれらの出力結果に
基づいて今の実行アドレスがトレース収集範囲外と判定
し、l・レース収集番号を出力しない、従ってアドレス
トレースメモリ制御回路11はアドレストレースメモリ
6に書き込み指示を出さないので、この実行アドレスは
アドレストレースメモリ6に書き込まれない。
When the settings in address comparison circuits 8 and 9 are completed, the microinstruction at address 2 is executed in the same manner as described above. At this time, the execution address "2" outputted by the microaddress control circuit 3
is also added to the latch circuit 7 and held in the launch circuit 7. The address comparison circuit 8.9 compares the value of the address information held internally with the value "2" of the execution address held in the latch circuit 7. As a result, the address comparison circuit 8 outputs that the value is smaller than the value of the lower limit address information held internally, and the address comparison circuit 9 also outputs that the value is smaller than the value of the upper limit address held internally. The address trace control circuit 10 determines that the current execution address is outside the trace collection range based on these output results, and does not output the l/race collection number. Therefore, the address trace memory control circuit 11 instructs the address trace memory 6 to write. Therefore, this execution address is not written to the address trace memory 6.

3番地のマイクロ命令も上述したと同様に実行されるの
で、アドレストレースメモリ6に実行アドレスF3」は
書き込まれない。
Since the microinstruction at address 3 is also executed in the same manner as described above, the execution address "F3" is not written to the address trace memory 6.

さて、マイクロ命令が111次に実行されて例えば15
0番地の命令が実行されてラッチ回路7に実行アドレス
r150Jが保持されると、アドレス比較回路8は下限
アドレスより大きい旨をアドレス比較回路9は上限アド
レスよりも小さい旨をそれぞれ出力する。アドレストレ
ース制御回110は、これらの出力結果に基づいてラッ
チ回路7に保持されている実行アドレス’150Jがト
レース収集範囲と判定して、アドレストレースメモリ制
御回路11にトレース収集信号を出す、この指示を受は
取ったアドレストレースメモリ制御回路11は、ラッチ
回路7に保持されている値の書き込み指示をアドレスト
レースメモリ6に出した後、アドレストレースメモリ6
のアドレスを+1(従ってrl、になる)する、書き込
み指示を受は収ったアドレストレースメモリ6は、アド
レストレースメモリ制御回路11がアドレス(今の場合
「0」)にラッチ回路7に保持されている実行アドレス
r150Jを格納する0次に151番地の命令が実行さ
れると上述しなと同様にアドレストレースメモリ6の1
番地に実行アドレスr151Jが格納される。以下、他
のマイクロ命令についても同様に実行される。このよう
にトレース収集範囲(今の場合’100J〜r200」
)までの実行アドレスのマイクロ命令が実行されたとき
だけ、その実行アドレスがアドレストレースメモリ6に
格納される。
Now, the microinstruction is executed 111 times, and for example 15
When the instruction at address 0 is executed and the execution address r150J is held in the latch circuit 7, the address comparison circuit 8 outputs that it is larger than the lower limit address, and the address comparison circuit 9 outputs that it is smaller than the upper limit address. Based on these output results, the address trace control circuit 110 determines that the execution address '150J held in the latch circuit 7 is within the trace collection range, and issues a trace collection signal to the address trace memory control circuit 11. The address trace memory control circuit 11 that received the address trace memory 6 issues an instruction to write the value held in the latch circuit 7 to the address trace memory 6.
The address trace memory 6 that has received the write instruction to increase the address by +1 (therefore becomes rl) is held in the latch circuit 7 by the address trace memory control circuit 11 at the address (in this case "0"). When the instruction at the 0th order address 151, which stores the execution address r150J, is executed, 1 of the address trace memory 6 is executed as described above.
Execution address r151J is stored at address. Thereafter, other microinstructions are executed in the same manner. In this way, trace collection range (currently '100J~r200')
) is stored in the address trace memory 6 only when the microinstruction with the execution address up to ) is executed.

(発明の効果) 以上に説明したように、本発明のアドレストレース回路
は、トレース情報を収集する実行アドレスの範囲をマイ
クロ命令で指定して必要な実行アドレスだけをアドレス
トレースメモリに格納するので、アドレストレースメモ
リを有効に使用することができる。また、アドレストレ
ースメモリを有効に使用することができるので、従来の
アドレストレースメモリよりも少ないメモリ容量とする
ことができる。
(Effects of the Invention) As explained above, the address trace circuit of the present invention specifies the range of execution addresses for which trace information is collected using microinstructions and stores only the necessary execution addresses in the address trace memory. Address trace memory can be used effectively. Furthermore, since the address trace memory can be used effectively, the memory capacity can be smaller than that of the conventional address trace memory.

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

第1図は本発明の実施例の構成図である。 1・・・コントロールストレージ、2・・・マイクロア
ドレスレジスタ、3・・・マイクロアドレス制御回路、
4・・・マイクロ命令レジスタ、5・・・デコード回路
、6・・・アドレストレースメモリ、7・・・ラッチ回
路、8.9・・・アドレス比軸回路、10・・・アドレ
ストレース制御回路、11・・・アドレストレースメモ
リ制御回路。
FIG. 1 is a block diagram of an embodiment of the present invention. 1... Control storage, 2... Micro address register, 3... Micro address control circuit,
4... Micro instruction register, 5... Decode circuit, 6... Address trace memory, 7... Latch circuit, 8.9... Address ratio axis circuit, 10... Address trace control circuit, 11...Address trace memory control circuit.

Claims (1)

【特許請求の範囲】 マイクロ命令の実行アドレスをアドレストレースメモリ
に格納するアドレストレース回路において、 前記マイクロ命令により設定されたアドレス情報と前記
実行アドレスとを比較する第1の比較回路および第2の
比較回路と、 前記第1の比較回路と前記第2の比較回路との比較結果
に基づいて前記アドレストレースメモリのアドレスを更
新するか否かを示すアドレス更新信号を出力するアドレ
ストレース制御回路と、該アドレストレース制御回路に
より出力されたアドレス更新信号に基づいて、前記実行
アドレスを格納する前記アドレストレースメモリのアド
レスを制御するアドレストレースメモリ制御回路とを設
けたことを特徴とするアドレストレース回路。
[Scope of Claims] An address trace circuit that stores an execution address of a microinstruction in an address trace memory, comprising a first comparison circuit and a second comparison circuit that compares address information set by the microinstruction with the execution address. an address trace control circuit that outputs an address update signal indicating whether or not to update the address of the address trace memory based on a comparison result between the first comparison circuit and the second comparison circuit; An address trace memory control circuit that controls an address of the address trace memory that stores the execution address based on an address update signal output by the address trace control circuit.
JP63321434A 1988-12-20 1988-12-20 Address tracing circuit Pending JPH02165349A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP63321434A JPH02165349A (en) 1988-12-20 1988-12-20 Address tracing circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP63321434A JPH02165349A (en) 1988-12-20 1988-12-20 Address tracing circuit

Publications (1)

Publication Number Publication Date
JPH02165349A true JPH02165349A (en) 1990-06-26

Family

ID=18132509

Family Applications (1)

Application Number Title Priority Date Filing Date
JP63321434A Pending JPH02165349A (en) 1988-12-20 1988-12-20 Address tracing circuit

Country Status (1)

Country Link
JP (1) JPH02165349A (en)

Similar Documents

Publication Publication Date Title
JPH02165349A (en) Address tracing circuit
JP2758624B2 (en) Speed control method of micro program
JPH0353320A (en) Program control system
JP2737524B2 (en) Trace circuit
JPS60103450A (en) Microprogram control system
JPS6232500B2 (en)
JPH01258045A (en) In-circuit emulator
JPS60193047A (en) Mode checking system of microprogram
JPH03164945A (en) Data processor
JPH0353321A (en) Information processor
JPS5952348A (en) Microprogram controller
JPS6298443A (en) Data processor
JPS62154036A (en) Address tracing circuit
JPH08202582A (en) Data transferring device for microprocessor
JPH03113659A (en) Cache memory testing method
JPH02103642A (en) History information storing system
JPS63257039A (en) Address tracing device
JPS63163533A (en) Microcomputer
JPH01121950A (en) Microprocessor with trace function
JPH0239812B2 (en)
JPS619733A (en) Test device
JPS6029410B2 (en) Microprogram control method
JPS6191724A (en) Microprogram controller
JPH0228784A (en) One-chip digital signal processing device and debugging device for it
JPS61269744A (en) Debugging system