JPH0690732B2 - Microprocessor - Google Patents

Microprocessor

Info

Publication number
JPH0690732B2
JPH0690732B2 JP62282568A JP28256887A JPH0690732B2 JP H0690732 B2 JPH0690732 B2 JP H0690732B2 JP 62282568 A JP62282568 A JP 62282568A JP 28256887 A JP28256887 A JP 28256887A JP H0690732 B2 JPH0690732 B2 JP H0690732B2
Authority
JP
Japan
Prior art keywords
microprocessor
cache memory
mode
information
buffer 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.)
Expired - Lifetime
Application number
JP62282568A
Other languages
Japanese (ja)
Other versions
JPH01124049A (en
Inventor
亮 大塚
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP62282568A priority Critical patent/JPH0690732B2/en
Publication of JPH01124049A publication Critical patent/JPH01124049A/en
Publication of JPH0690732B2 publication Critical patent/JPH0690732B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)
  • Microcomputers (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Description

【発明の詳細な説明】 [産業上の利用分野] この発明はマイクロプロセッサに関し、特に、キャッシ
ュメモリを内蔵したマイクロプロセッサに関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a microprocessor, and more particularly to a microprocessor including a cache memory.

[従来の技術] 第5図は従来の内蔵キャッシュメモリを有するマイクロ
プロセッサのブロック図であり、“MC68020 32bit Micr
oprocessor User's Mannual"の第1頁および第2頁に掲
載されたものである。第5図において、マイクロプロセ
ッサ21は、シーケンサ22,制御ユニット23,実行ユニット
24,命令フェッチデコードユニット25,バス制御ユニット
26および内蔵キャッシュメモリ27により構成され、アド
レスバス28,データバス29および制御バス30よりマイク
ロプロセッサ外部と情報の授受を行なう。
[Prior Art] FIG. 5 is a block diagram of a conventional microprocessor having a built-in cache memory.
It is published on pages 1 and 2 of "Oprocessor User's Manual." In FIG. 5, the microprocessor 21 includes a sequencer 22, a control unit 23, and an execution unit.
24, instruction fetch decode unit 25, bus control unit
26 and a built-in cache memory 27, information is exchanged with the outside of the microprocessor through an address bus 28, a data bus 29 and a control bus 30.

第6図は、“VLSI DESIGN"誌,1984,November 26頁に掲
載された内蔵キャッシュメモリの動作を表わすブロック
図であり、第4図はそのフロー図である。
FIG. 6 is a block diagram showing the operation of the built-in cache memory published in "VLSI DESIGN" magazine, 1984, November, page 26, and FIG. 4 is a flow chart thereof.

次に、第4図ないし第6図を参照して、従来のマイクロ
プロセッサの動作について説明する。第5図の内蔵キャ
ッシュメモリ27は、命令コードとその拡張部を格納する
セットアソシアティブメモリであり、プログラムとデー
タとを区別し、データはキャッシングしない。第6図に
示すように、内蔵キャッシュメモリ27はアドレスタグ32
とデータキャッシュ34の2つのフィールドからなる。ア
ドレスタグ32は各エントリごとにアドレスの上位側ビッ
トを保持し、データキャッシュ34はアドレスタグ32で示
される記憶場所からの固定語長のデータを保持してい
る。アドレスデコーダ37でデコードされたプログラムカ
ウンタ33の下位側ビットはアドレスタグ32の1エントリ
とそれに対応するデータキャッシュ34のエントリを示
す。指示されたアドレスタグ32のエントリの内容がプロ
グラムカウンタ33の上位側ビットと一致した場合つまり
ヒットした場合には、命令コードは内蔵キャッシュメモ
リ27より命令フェッチデコードユニット25に転送され、
実行ユニット24で実行される。もし、一致しなかった場
合には、バス制御ユニット26によってマイクロプロセッ
サ21外部からの命令フェッチが実行され、命令フェッチ
デコードユニット25と内蔵キャッシュメモリ27のデータ
キャッシュ34に命令コードが格納される。つまり、第4
図に示すように、次にアクセスするアドレスをプログラ
ムカウンタ33にセットすることで、内蔵キャッシュメモ
リ27の任意のエントリをアクセスすることができ、キャ
ッシュアクセスがヒットしなかった場合には、外部への
命令フェッチに応答してアドレスをアドレスタグに入力
することができるとともに、内蔵キャッシュメモリ27の
データキャッシュ34に命令コードをセットすることがで
きる。一方、キャッシュアクセスがヒットした場合に
は、データキャッシュ34の内容がデータバス29に出力さ
れるため、読出しも可能である。データの読出しは、マ
イクロプロセッサチップ外部とアクセスするための外部
データバス(図示せず)およびアドレスバスにより行な
われる。
Next, the operation of the conventional microprocessor will be described with reference to FIGS. The built-in cache memory 27 in FIG. 5 is a set associative memory that stores an instruction code and its extension, distinguishes between a program and data, and does not cache data. As shown in FIG. 6, the internal cache memory 27 has an address tag 32.
And the data cache 34. The address tag 32 holds the upper bits of the address for each entry, and the data cache 34 holds the fixed word length data from the storage location indicated by the address tag 32. The lower bits of the program counter 33 decoded by the address decoder 37 indicate one entry of the address tag 32 and the corresponding entry of the data cache 34. When the content of the entry of the designated address tag 32 matches the upper bits of the program counter 33, that is, when a hit occurs, the instruction code is transferred from the internal cache memory 27 to the instruction fetch decode unit 25,
It is executed by the execution unit 24. If they do not match, the bus control unit 26 executes the instruction fetch from the outside of the microprocessor 21, and the instruction code is stored in the instruction fetch decode unit 25 and the data cache 34 of the internal cache memory 27. That is, the fourth
As shown in the figure, by setting the address to be accessed next to the program counter 33, it is possible to access any entry of the internal cache memory 27, and if no cache access hits, An address can be input to an address tag in response to an instruction fetch, and an instruction code can be set in the data cache 34 of the internal cache memory 27. On the other hand, when the cache access is hit, the contents of the data cache 34 are output to the data bus 29, and thus the data can be read. Data is read by an external data bus (not shown) and an address bus for accessing the outside of the microprocessor chip.

[発明が解決しようとする問題点] 従来のマイクロプロセッサは、以上のように構成されて
おり、キャッシュメモリを本来の使用方法のみで使用
し、それ以上の機能を持たせたものはなかった。
[Problems to be Solved by the Invention] The conventional microprocessor is configured as described above, and the cache memory is used only in its original usage, and none has been provided with a further function.

それゆえに、この発明は上述のような問題点を解消する
ためになされたもので、キャッシュメモリを備えたマイ
クロプロセッサにおいて、本来のキャッシュメモリの機
能に加え、デバッグモード時にはマイクロプロセッサの
内部状態を退避させるのにも使用できるキャッシュメモ
リを備えたマイクロプロセッサを得ることを目的とす
る。
Therefore, the present invention has been made to solve the above problems, and in a microprocessor equipped with a cache memory, in addition to the original function of the cache memory, the internal state of the microprocessor is saved in the debug mode. The purpose is to obtain a microprocessor with a cache memory that can also be used to

[問題点を解決するための手段] この発明に係るマイクロプロセッサは、モード指定手段
によって予め定めるモードが指定されているとき、マイ
クロプロセッサの内部状態に関する情報を退避させる場
合には、制御手段によって当該情報を内蔵の高速バッフ
ァメモリに格納するように制御するとともに、高速バッ
ファメモリに格納されているマイクロプロセッサの内部
状態に関する情報を参照することができるようにしたも
のである。
[Means for Solving Problems] In the microprocessor according to the present invention, when the mode specifying means specifies a predetermined mode, when the information about the internal state of the microprocessor is saved, the control means The information is controlled to be stored in the built-in high-speed buffer memory, and the information about the internal state of the microprocessor stored in the high-speed buffer memory can be referred to.

[作用] この発明における高速バッファメモリは、予め定めるモ
ードが指定されているとき、マイクロプロセッサの内部
状態に関する情報を退避格納することができるととも
に、必要に応じて参照することができる。
[Operation] In the high-speed buffer memory according to the present invention, when a predetermined mode is designated, information on the internal state of the microprocessor can be saved and stored, and can be referred to when necessary.

[発明の実施例] 以下、この発明の一実施例を図について説明する。[Embodiment of the Invention] An embodiment of the present invention will be described below with reference to the drawings.

第1図はこの発明の一実施例のマイクロプロセッサの構
成を示す図である。第1図において、マイクロプロセッ
サ1は、シーケンサ2,制御ユニット3,実行ユニット4,命
令フェッチデコードユニット5,バス制御ユニット6およ
び内蔵キャッシュメモリ7により構成され、アドレスバ
ス8,データバス9および制御バス10によりマイクロプロ
セッサ外部と情報の授受を行ない、デバッグモード指定
信号線11でマイクロプロセッサ1の動作モードを切換え
る。なお、この実施例では、デバッグモードにおいて、
内蔵キャッシュメモリ7はアドレスバス8およびデータ
バス9によりマイクロプロセッサ外部からアクセスする
ことができる。
FIG. 1 is a diagram showing the configuration of a microprocessor according to an embodiment of the present invention. In FIG. 1, a microprocessor 1 comprises a sequencer 2, a control unit 3, an execution unit 4, an instruction fetch decode unit 5, a bus control unit 6 and a built-in cache memory 7, and an address bus 8, a data bus 9 and a control bus. Information is exchanged with the outside of the microprocessor by 10 and the operation mode of the microprocessor 1 is switched by the debug mode designation signal line 11. In this embodiment, in debug mode,
The built-in cache memory 7 can be accessed from outside the microprocessor by the address bus 8 and the data bus 9.

第2図は第1図に示すマイクロプロセッサ1の内蔵キャ
ッシュメモリ7の動作を表わすプロック図であり、第3
図はそのフロー図である。
FIG. 2 is a block diagram showing the operation of the internal cache memory 7 of the microprocessor 1 shown in FIG.
The figure is the flow chart.

次に、第1図ないし第3図を参照して、この発明の一実
施例の動作について説明する。通常動作モードでは、内
蔵キャッシュメモリ7は従来例と同じく命令コードおよ
びその拡張部を格納するセットアソシアティブメモリで
あり、プログラムとデータとを区別し、データはキャッ
シングしない。通常モードでは、第4図に示す従来例と
同様の動作を行なうので説明を省略する。
Next, the operation of the embodiment of the present invention will be described with reference to FIGS. In the normal operation mode, the built-in cache memory 7 is a set associative memory that stores an instruction code and its extension as in the conventional example, distinguishes between a program and data, and does not cache data. In the normal mode, the same operation as the conventional example shown in FIG.

マイクロプロセッサ1がデバッグモード指定信号線11に
よって、システムデバッグモードで動作しているとき、
内蔵キャッシュメモリ7は本来のキャッシュメモリとし
ての動作は行なわない。マイクロプロセッサ1の制御ユ
ニット3は外部から割込が入力されたり、例外が発生し
たりすると、マイクロプロセッサ1の内部状態に関する
情報を内蔵キャッシュメモリ7の予め決められたデータ
キャッシュ14のエントリに格納して、例外処理を開始す
る。ここで、マイクロプロセッサ1の内部状態に関する
情報とは、ステータス情報,プログラムカウンタのカウ
ント値,レジスタの値などである。
When the microprocessor 1 is operating in the system debug mode by the debug mode designation signal line 11,
The built-in cache memory 7 does not operate as an original cache memory. When an interrupt is input from the outside or an exception occurs, the control unit 3 of the microprocessor 1 stores information about the internal state of the microprocessor 1 in a predetermined data cache 14 entry of the internal cache memory 7. And start exception handling. Here, the information regarding the internal state of the microprocessor 1 is status information, the count value of the program counter, the value of the register, and the like.

制御ユニット3は内蔵キャッシュメモリ7に格納された
内部状態に関する情報を、例外処理ルーチンにおいて特
殊命令により図示されていない汎用レジスタへ転送した
り、マイクロプロセッサ1の外部からの指令によってマ
イクロプロセッサ1を停止させて、内蔵キャッシュメモ
リ7を外部からアクセスできるようにする。つまり、外
部からアドレスバス8によりキャッシュメモリ7のいず
れかのエントリが指定されると、データキャッシュ14の
指定内容はデータバス9を介して読出されて、参照され
る。
The control unit 3 transfers the information about the internal state stored in the built-in cache memory 7 to a general-purpose register (not shown) by a special instruction in the exception handling routine, or stops the microprocessor 1 by a command from the outside of the microprocessor 1. Then, the built-in cache memory 7 can be accessed from the outside. That is, when any entry of the cache memory 7 is designated by the address bus 8 from the outside, the designated content of the data cache 14 is read out through the data bus 9 and referred to.

なお、上述の実施例では、内蔵キャッシュメモリがセッ
トアソシアティブ命令キャッシュメモリであるものにつ
いて、デバッグモード動作を行なうものを示したが、内
蔵キャッシュメモリはフルアソシアティブ方式でも、ダ
イレクトマッピング方式であってもよい。また、命令コ
ードをキャッシングするものに限らず、データもキャッ
シングするキャッシュメモリにおいても上述と同様の効
果を奏する。
In the above-described embodiment, the one in which the built-in cache memory is the set associative instruction cache memory performs the debug mode operation, but the built-in cache memory may be the full associative system or the direct mapping system. . Further, not only the instruction code is cached but also a cache memory that caches data also has the same effect as described above.

[発明の効果] 以上のように、この発明によれば、予め定めるモードが
指定されているとき、マイクロプロセッサの内部情報を
示す情報をマイクロプロセッサ内に設けられた高速バッ
ファメモリに退避するようにしたので、外部メモリをア
クセスする必要がなく、高速に情報を退避することがで
きる。また、当該情報を必要とするときマイクロプロセ
ッサまたは外部の装置によって参照することができる。
As described above, according to the present invention, when the predetermined mode is designated, the information indicating the internal information of the microprocessor is saved in the high-speed buffer memory provided in the microprocessor. Therefore, it is not necessary to access the external memory, and the information can be saved at high speed. Further, the information can be referred to by a microprocessor or an external device when the information is needed.

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

第1図はこの発明の一実施例のマイクロプロセッサの構
成を示すブロック図である。第2図は第1図に示すマイ
クロプロセッサの内蔵キャッシュメモリの動作を表わす
ブロック図である。第3図はこの発明の一実施例の動作
を説明するためのフロー図である。第4図は従来のマイ
クロプロセッサおよびこの発明の一実施例の動作を説明
するためのフロー図である。第5図は従来のマイクロプ
ロセッサの構成を示すブロック図である。第6図は第5
図に示す従来のマイクロプロセッサに内蔵されたキャッ
シュメモリの動作を表わすブロック図である。 図において、1はマイクロプロセッサ、2はシーケン
サ、3は制御ユニット、4は実行ユニット、5は命令フ
ェッチデコードユニット、6はバス制御ユニット、7は
内蔵キャッシュメモリ、8はアドレスバス、9はデータ
バス、10は制御バス、11はデバッグモード指定信号線、
12はアドレスタグ、13はプログラムカウンタ、14はデー
タキャッシュ、17はアドレスデコーダを示す。
FIG. 1 is a block diagram showing the configuration of a microprocessor according to an embodiment of the present invention. FIG. 2 is a block diagram showing the operation of the internal cache memory of the microprocessor shown in FIG. FIG. 3 is a flow chart for explaining the operation of the embodiment of the present invention. FIG. 4 is a flow chart for explaining the operation of the conventional microprocessor and one embodiment of the present invention. FIG. 5 is a block diagram showing the configuration of a conventional microprocessor. FIG. 6 is the fifth
It is a block diagram showing operation | movement of the cache memory incorporated in the conventional microprocessor shown in the figure. In the figure, 1 is a microprocessor, 2 is a sequencer, 3 is a control unit, 4 is an execution unit, 5 is an instruction fetch decode unit, 6 is a bus control unit, 7 is a built-in cache memory, 8 is an address bus, and 9 is a data bus. , 10 is a control bus, 11 is a debug mode designation signal line,
12 is an address tag, 13 is a program counter, 14 is a data cache, and 17 is an address decoder.

Claims (5)

【特許請求の範囲】[Claims] 【請求項1】高速バッファメモリを内蔵したマイクロプ
ロセッサにおいて、 予め定めるモードを指定するモード指定手段と、前記モ
ード指定手段によって前記予め定めるモードが指定され
ているとき、前記マイクロプロセッサの内部状態に関す
る情報を退避させる場合には、当該情報を前記高速バッ
ファメモリに格納するように制御するとともに、前記高
速バッファメモリに格納された前記マイクロプロセッサ
の内部状態に関する情報を参照できるように制御する制
御手段とを備えた、マイクロプロセッサ。
1. A microprocessor with a built-in high-speed buffer memory, wherein a mode designating means for designating a predetermined mode and information about an internal state of the microprocessor when the predetermined mode is designated by the mode designating means. In order to save the information, control means for controlling the information to be stored in the high-speed buffer memory, and controlling so as to refer to the information on the internal state of the microprocessor stored in the high-speed buffer memory. Equipped with a microprocessor.
【請求項2】前記高速バッファメモリがキャッシュメモ
リである、特許請求の範囲第1項記載のマイクロプロセ
ッサ。
2. The microprocessor according to claim 1, wherein the high speed buffer memory is a cache memory.
【請求項3】前記予め定めるモードがデバッグモードで
ある、特許請求の範囲第1項または第2項記載のマイク
ロプロセッサ。
3. The microprocessor according to claim 1 or 2, wherein the predetermined mode is a debug mode.
【請求項4】前記高速バッファメモリは、前記モード指
定手段によって前記予め定めるモードが指定されている
とき、予め定める命令が与えられたことに応じて、アク
セスできるようにした、特許請求の範囲第1項記載のマ
イクロプロセッサ。
4. The high-speed buffer memory can be accessed when a predetermined command is given when the predetermined mode is specified by the mode specifying means. The microprocessor according to item 1.
【請求項5】前記高速バッファメモリは、複数のエント
リを含み、前記モード指定手段によって前記予め定める
モードが指定されているとき、外部から前記複数のエン
トリのいずれかが指定されたことに応じて、当該指定さ
れたエントリがアクセスできるようにした、特許請求の
範囲第1項記載のマイクロプロセッサ。
5. The high speed buffer memory includes a plurality of entries, and when any one of the plurality of entries is designated from the outside when the predetermined mode is designated by the mode designating means. The microprocessor according to claim 1, wherein the specified entry is accessible.
JP62282568A 1987-11-09 1987-11-09 Microprocessor Expired - Lifetime JPH0690732B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP62282568A JPH0690732B2 (en) 1987-11-09 1987-11-09 Microprocessor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62282568A JPH0690732B2 (en) 1987-11-09 1987-11-09 Microprocessor

Publications (2)

Publication Number Publication Date
JPH01124049A JPH01124049A (en) 1989-05-16
JPH0690732B2 true JPH0690732B2 (en) 1994-11-14

Family

ID=17654179

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62282568A Expired - Lifetime JPH0690732B2 (en) 1987-11-09 1987-11-09 Microprocessor

Country Status (1)

Country Link
JP (1) JPH0690732B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007306143A (en) * 2006-05-09 2007-11-22 Ricoh Co Ltd Image processing apparatus

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH03175537A (en) * 1989-12-04 1991-07-30 Nec Corp Error controller for debugging microprocessor
JPH03185530A (en) * 1989-12-14 1991-08-13 Mitsubishi Electric Corp Data processor
JP2696578B2 (en) * 1989-12-16 1998-01-14 三菱電機株式会社 Data processing device
JP2643790B2 (en) * 1993-09-01 1997-08-20 日本電気株式会社 emulator

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007306143A (en) * 2006-05-09 2007-11-22 Ricoh Co Ltd Image processing apparatus

Also Published As

Publication number Publication date
JPH01124049A (en) 1989-05-16

Similar Documents

Publication Publication Date Title
US5247639A (en) Microprocessor having cache bypass signal terminal
US4937738A (en) Data processing system which selectively bypasses a cache memory in fetching information based upon bit information of an instruction
US4648034A (en) Busy signal interface between master and slave processors in a computer system
US20080270707A1 (en) Data processor
KR100309615B1 (en) High Speed Programmable Logic Controllers (PLC)
JPH0997230A (en) Method and system for data transfer
JPH04242848A (en) System for controlling cache memory by running mode
EP0525666B1 (en) Information processing apparatus incorporating branch target instruction buffer
JPH0748190B2 (en) Microprocessor with cache memory
JPH0690732B2 (en) Microprocessor
US4737908A (en) Buffer memory control system
EP0101718B1 (en) Computer with automatic mapping of memory contents into machine registers
KR100317976B1 (en) Device for Performing Interrupt Service Routine in the system having cache memory
JP3217348B2 (en) Information processing system
JPH0628258A (en) Microprocessor
JPH0795288B2 (en) Microcomputer
JP3378270B2 (en) Multiprocessor system
JPH0630074B2 (en) Processor
JPS6252334B2 (en)
JP2923273B2 (en) Data processing system
JPH06149677A (en) Cache memory system
JPH04205535A (en) Copy on write system
JPH07129469A (en) Cache memory and microprocessor having the same
JPH08147216A (en) Data processor
JPH0776943B2 (en) Method for testing system memory of data processing system having cache memory and data processing system having cache memory