JP3199603B2 - Code size reduction microprocessor - Google Patents
Code size reduction microprocessorInfo
- Publication number
- JP3199603B2 JP3199603B2 JP13328195A JP13328195A JP3199603B2 JP 3199603 B2 JP3199603 B2 JP 3199603B2 JP 13328195 A JP13328195 A JP 13328195A JP 13328195 A JP13328195 A JP 13328195A JP 3199603 B2 JP3199603 B2 JP 3199603B2
- Authority
- JP
- Japan
- Prior art keywords
- code
- register
- word
- instruction
- decoding
- 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
Links
Landscapes
- Advance Control (AREA)
- Executing Machine-Instructions (AREA)
Description
【0001】[0001]
【産業上の利用分野】本発明は、プログラムに従ってデ
ータ処理を実行するマイクロプロセッサに関し、特にプ
ログラムのコードサイズの縮小化を支援するマイクロプ
ロセッサに関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a microprocessor which executes data processing according to a program, and more particularly to a microprocessor which supports a reduction in the code size of a program.
【0002】[0002]
【従来の技術】近年、マイクロプロセッサを用いた製品
は、ますます高機能化が求められ、それに伴ってプログ
ラムは大規模化してきている。ところが、マイクロプロ
セッサ組み込み型の製品においては、プログラムをRO
M化して実装する必要があるため、そのコードサイズの
増大は実装すべきROMの容量や個数の増大をもたら
し、低価格な製品の開発を阻害する。従って、このよう
な製品の開発においては、コードサイズを可能な限り圧
縮することが望まれる。2. Description of the Related Art In recent years, products using microprocessors have been required to have higher and more advanced functions, and programs have become larger in scale. However, in products with a built-in microprocessor, the program is
Since it is necessary to implement M, the increase in the code size causes an increase in the capacity and the number of ROMs to be implemented, which hinders the development of low-cost products. Therefore, in the development of such products, it is desirable to reduce the code size as much as possible.
【0003】コードサイズを圧縮するための従来の技術
として、マイクロプロセッサが実行する個々の命令の語
長を縮小する方法がある(例えば、NEC社製V800
シリーズ、日立社製SH7000シリーズ)。これらの
マイクロプロセッサは、一度に扱うデータ長、即ちデー
タバスや内部の演算器、レジスタのビット幅(以下、
「演算幅」という。)よりも小さい語長からなる命令の
セットを備えている。具体的には、演算幅が32ビット
であるにも拘らず16ビットからなる命令を備えてい
る。As a conventional technique for compressing the code size, there is a method of reducing the word length of each instruction executed by a microprocessor (for example, NEC V800).
Series, SH7000 series manufactured by Hitachi, Ltd.). These microprocessors have a data length handled at a time, that is, a data bus, an internal arithmetic unit, and a bit width of a register (hereinafter, referred to as a bit width).
It is called "calculation width". ) Has a set of instructions with word lengths smaller than. More specifically, it has an instruction consisting of 16 bits despite the fact that the operation width is 32 bits.
【0004】このような技術によって、必ずしも32ビ
ットも必要としない命令を16ビットで構成したり、使
用頻度の高い命令を16ビットで構成することが可能と
なり、命令を構成する無駄なビットが排除され、同一内
容のプログラムであっても全体のコードサイズは効率よ
く圧縮される。[0004] Such a technique makes it possible to configure an instruction that does not necessarily require 32 bits with 16 bits, or to configure a frequently used instruction with 16 bits, thereby eliminating useless bits constituting the instruction. As a result, even if the programs have the same contents, the entire code size is efficiently compressed.
【0005】[0005]
【発明が解決しようとする課題】しかしながら、上記の
ような従来の技術には次のような問題点があった。即
ち、演算幅よりも小さい語長からなる命令を備えていて
も、それらの語長は、マイクロプロセッサが有する命令
解読器のビット幅と同じかその整数倍である。例えば、
命令解読器のビット幅が8ビットであれば、命令の語長
は、8、16、24、32、、、のいずれかである。そ
のために、命令の語長を縮小化しても、8ビットよりも
小さい単位では縮小化することができず、例えば、8ビ
ットも必要としない数値を指定する場合であっても8ビ
ットを用いて指定せざる得ないために、依然としてコー
ドサイズの点において無駄が存在した。However, the above-mentioned prior art has the following problems. That is, even if an instruction having a word length smaller than the operation width is provided, the word length is the same as or an integer multiple of the bit width of the instruction decoder included in the microprocessor. For example,
If the bit width of the instruction decoder is 8 bits, the word length of the instruction is any of 8, 16, 24, 32,. For this reason, even if the word length of the instruction is reduced, it cannot be reduced in units smaller than 8 bits. For example, even when a numerical value that does not require 8 bits is specified, using 8 bits There was still a waste in code size because it had to be specified.
【0006】図10は、従来のマイクロプロセッサにお
ける命令のビット構成を説明するための図である。
今、”レジスタd0に格納された値に即値4を加算す
る”という命令”add #4,d0”を考える。この
命令の語長は、オペコード”add#n,d0”を特定
する8ビットと、即値#nを指定する8ビット、即ち合
計16ビットである。ここでは、8ビットを用いて即
値”4”を指定しているが、例えば、−8から+7の範
囲の整数を指定するのであれば4ビットあれば足りる。
即ち、従来のマイクロプロセッサによれば、合計12ビ
ットあれば特定できる命令であっても、16ビットで構
成していたために、依然としてコードサイズの点におけ
る無駄があった。FIG. 10 is a diagram for explaining a bit configuration of an instruction in a conventional microprocessor.
Now, consider an instruction "add # 4, d0" of "add immediate value 4 to the value stored in register d0". The word length of this instruction is 8 bits for specifying the operation code "add # n, d0" and 8 bits for specifying the immediate value #n, that is, a total of 16 bits. Here, the immediate value “4” is specified using 8 bits, but for example, if an integer in the range of −8 to +7 is specified, 4 bits are sufficient.
That is, according to the conventional microprocessor, even if an instruction can be specified with a total of 12 bits, the instruction is constituted by 16 bits, so that there is still a waste in code size.
【0007】そこで、本発明はかかる問題点に鑑みてな
されたものであり、マイクロプロセッサが有する命令解
読器のビット幅の整数倍に制限されることなく、効率よ
く語長が縮小化された命令セットを有するマイクロプロ
セッサを提供し、これによって、同一内容であってもコ
ードサイズが圧縮されたプログラムの作成を可能とする
ことを目的としている。Accordingly, the present invention has been made in view of such a problem, and is not limited to an integral multiple of the bit width of an instruction decoder included in a microprocessor, and an instruction whose word length is efficiently reduced. It is an object of the present invention to provide a microprocessor having a set, thereby enabling creation of a program having the same content and a reduced code size.
【0008】[0008]
【課題を解決するための手段】上記目的を達成するため
に請求項1記載のマイクロプロセッサは、コード化され
た命令を逐一に解読する解読器と、前記解読器による解
読結果に基づいてデータ処理を実行する実行手段とを備
えるマイクロプロセッサであって、前記命令の語長w
は、前記解読器が一度に解読するコードの語長をaと
し、aよりも小さい語長をbとした場合に、w=a+n
b (但し、nは0及び1を含む正の整数とする) で
表され、前記実行手段は、少なくとも語長がaである命
令と語長が(a+b)である命令を実行することを特徴
とする。According to another aspect of the present invention, there is provided a microprocessor for decoding a coded instruction one by one, and a data processor based on a result of the decoding by the decoder. And an execution means for executing the instruction.
If the word length of the code that the decoder decodes at a time is a and the word length smaller than a is b, w = a + n
b (where, n is a positive integer including 0 and 1) is represented by the execution means, characterized by executing the instructions is an instruction and word length at least word length is a is (a + b) And
【0009】請求項2記載のマイクロプロセッサは、請
求項1記載のマイクロプロセッサにおいて、前記bは、
前記aを1ワードとした場合に、ハーフワードであるこ
とを特徴とする。請求項3のマイクロプロセッサは、請
求項2記載のマイクロプロセッサにおいてさらに、先読
みした命令を保持する命令バッファと、前記解読器で解
読する1ワードのコードをハーフワードずつ分割して保
持する上位側解読レジスタと下位側解読レジスタと、前
記解読器による解読結果に基づいて、次に新たに前記解
読レジスタに転送すべきコードの語長がハーフワードで
あるか1ワードであるかを判断する第1の判断手段と、
前記第1の判断手段においてハーフワードと判断された
場合、前記下位側解読レジスタに格納されたコードを前
記上位側解読レジスタに転送するともに、前記命令バッ
ファに格納された次に転送すべきハーフワードのコード
を前記下位側解読レジスタに転送する選択手段とを備え
ることを特徴とする。請求項4記載のマイクロプロセッ
サは、請求項2記載のマイクロプロセッサにおいてさら
に、先読みした命令を保持する命令バッファと、前記命
令バッファにおける命令のハーフワード単位での格納状
態を記憶する記憶手段と、前記解読器による解読結果に
基づいて、次に解読すべきコードの語長がハーフワード
であるか1ワードであるかを判断する第1の判断手段
と、判断された語長と前記格納状態とに基づいて、前記
命令バッファに格納されたコードを前記解読器に取り込
むよう前記命令バッファを制御すると共に前記格納状態
を更新する制御手段とを備えることを特徴とする。The microprocessor according to claim 2 is the microprocessor according to claim 1, wherein b is:
When a is one word, it is a half word. The microprocessor according to claim 3 is a contractor.
The microprocessor of claim 2, further comprising:
An instruction buffer that holds the read instruction and the
One word code to be read is divided into half words and stored.
The upper and lower decryption registers
Then, based on the result of decoding by the decoder,
The word length of the code to be transferred to the read register is halfword.
First determining means for determining whether there is a word or one word;
Half word is judged by the first judgment means
If the code stored in the lower decoding register is
Transfer to the upper decoding register and the instruction
Code of the next halfword to be transferred
To the lower decoding register.
It is characterized by that. The microprocessor according to claim 4 , further comprising: an instruction buffer for holding a prefetched instruction; a storage unit for storing a storage state of the instruction in a halfword unit in the instruction buffer; First determining means for determining whether the word length of the code to be decoded next is half word or one word based on the result of decoding by the decoder; Control means for controlling the instruction buffer so as to take in the code stored in the instruction buffer into the decoder and updating the storage state.
【0010】請求項5記載のマイクロプロセッサは、請
求項2記載のマイクロプロセッサにおいてさらに、先読
みした命令を保持する命令バッファと、前記命令バッフ
ァにおける命令のハーフワード単位での格納状態を記憶
する記憶手段と、前記解読器で解読する1ワードのコー
ドをハーフワードずつ分割して保持する上位側解読レジ
スタと下位側解読レジスタと、前記格納状態に基づい
て、前記命令バッファに格納されたコードを前記解読レ
ジスタに取り込むよう前記命令バッファを制御すると共
に前記格納状態を更新する制御手段と、前記解読器によ
る解読結果に基づいて、次に新たに前記解読レジスタに
転送すべきコードの語長がハーフワードであるか1ワー
ドであるかを判断する第1の判断手段と、前記第1の判
断手段においてハーフワードと判断された場合、前記下
位側解読レジスタに格納されたコードを前記上位側解読
レジスタに転送するともに、前記命令バッファに格納さ
れた次に転送すべきハーフワードのコードを前記下位側
解読レジスタに転送する選択手段とを備えることを特徴
とする。請求項6記載のマイクロプロセッサは、請求項
5記載のマイクロプロセッサにおいて、前記命令バッフ
ァは、最新にフェッチした1ワードのコードを保持する
第1レジスタと、その直前にフェッチした1ワードのコ
ードを保持する第2レジスタとからなり、前記第1のレ
ジスタは、1ワードのコードをハーフワードずつ分割し
て保持する上位側第1レジスタと下位側第1レジスタと
からなり、前記第2のレジスタは、1ワードのコードを
ハーフワードずつ分割して保持する上位側第2レジスタ
と下位側第2レジスタとからなり、前記選択手段は、少
なくとも前記上位側第2レジスタと前記下位側第2レジ
スタと前記下位側解読レジスタとから選択した1つのレ
ジスタに保持されているコードを前記上位側解読レジス
タに転送する上位側選択手段と、少なくとも前記下位側
第1レジスタと前記上位側第2レジスタと前記下位側第
2レジスタとから選択した1つのレジスタに保持されて
いるコードを前記下位側解読レジスタに転送する下位側
選択手段とからなり、前記記憶手段は、前記上位側第2
レジスタ及び前記下位側第2レジスタのいずれにもコー
ドが保持されていない第1の状態と、前記上位側第2レ
ジスタにはコードが保持されているが前記下位側第2レ
ジスタにはコードが保持されていない第2の状態と、前
記上位側第2レジスタ及び前記下位側第2レジスタにコ
ードが保持されている第3の状態のいずれかの格納状態
を記憶することを特徴とする。[0010] The microprocessor according to claim 5 is a contractor.
The microprocessor of claim 2, further comprising:
An instruction buffer for holding the read instruction and the instruction buffer
Stores the storage state of instructions in halfword units
Storage means for decoding, and a one-word code to be decoded by the decoder.
Upper-side decryption register that divides and stores the word in halfwords
And the lower-side decryption register, based on the storage state.
And decodes the code stored in the instruction buffer
Controlling the instruction buffer so that it takes in the register
Control means for updating the storage state to the
Next, based on the decryption result,
Whether the word length of the code to be transferred is halfword or one word
First judging means for judging whether or not the first
If the disconnection means determines that the word is a halfword,
Decoding the code stored in the high-order decoding register
The data is transferred to the register and stored in the instruction buffer.
The half-word code to be transferred next
Selecting means for transferring to the decoding register.
And The microprocessor according to claim 6 has the following features.
In 5 microprocessor described before Symbol instruction buffer, a second register Toka Rannahli holding a first register for holding the code of one word fetched to date, the code of one word fetched immediately before, the first One register is composed of an upper first register and a lower first register that hold a code of one word divided by half word, and the second register divides a code of one word by half word. And a lower register. The selecting means includes at least one register selected from the upper second register, the lower second register, and the lower decoding register. Upper-side selecting means for transferring the code held in the lower-side decoding register to at least the lower-side first register; Lower-side selection means for transferring a code held in one register selected from the upper-side second register and the lower-side second register to the lower-side decryption register; Second
A first state in which neither a register nor the lower second register holds a code, and a code is stored in the upper second register but a code is stored in the lower second register. A second state that is not stored and a storage state of one of a third state in which a code is held in the upper second register and the lower second register are stored.
【0011】請求項7記載のマイクロプロセッサは、請
求項6記載のマイクロプロセッサにおいて、前記制御手
段は、前記記憶手段に記憶されている状態が第2の状態
であり、かつ前記第1の判断手段により次に解読すべき
コードの語長が1ワードであると判断された場合には、
前記上位側選択手段が前記上位側第2レジスタに保持さ
れているコードを前記上位側解読レジスタに転送し、前
記下位側選択手段が前記下位側第1レジスタに保持され
ているコードを前記下位側解読レジスタに転送するよう
前記選択手段を制御することを特徴とする。According to a seventh aspect of the present invention, in the microprocessor according to the sixth aspect , the control means is configured such that a state stored in the storage means is a second state, and the first determination means Determines that the code length to be decoded next is one word,
The upper-side selecting means transfers the code held in the upper-side second register to the upper-side decoding register, and the lower-side selecting means transfers the code held in the lower-side first register to the lower-side first register. The selection means is controlled to transfer the data to a decoding register.
【0012】請求項8記載のマイクロプロセッサは、請
求項6記載のマイクロプロセッサにおいて、前記制御手
段は、前記記憶手段に記憶されている状態が第3の状態
であり、かつ前記第1の判断手段により次に解読すべき
コードの語長がハーフワードであると判断された場合に
は、前記上位側選択手段が前記下位側解読レジスタに保
持されているコードを前記上位側解読レジスタに転送
し、前記下位側選択手段が前記下位側第2レジスタに保
持されているコードを前記下位側解読レジスタに転送す
るよう前記選択手段を制御すると共に、前記記憶手段に
記憶する状態を第2の状態に更新することを特徴とす
る。According to an eighth aspect of the present invention, in the microprocessor according to the sixth aspect , the control means is configured so that the state stored in the storage means is a third state and the first determination means If it is determined that the word length of the code to be decoded next is a halfword, the upper-side selecting means transfers the code held in the lower-side decoding register to the upper-side decoding register, The lower-side selector controls the selector to transfer the code held in the lower-side second register to the lower-side decryption register, and updates a state stored in the storage to a second state. It is characterized by doing.
【0013】請求項9記載のマイクロプロセッサは、請
求項6記載のマイクロプロセッサにおいて、前記制御手
段は、前記記憶手段に記憶されている状態が第2の状態
であり、かつ前記第1の判断手段により次に解読すべき
コードの語長がハーフワードであると判断された場合に
は、前記上位側選択手段が前記下位側解読レジスタに保
持されているコードを前記上位側解読レジスタに転送
し、前記下位側選択手段が前記上位側第2レジスタに保
持されているコードを前記下位側解読レジスタに転送す
るよう前記選択手段を制御すると共に、前記記憶手段に
記憶する状態を第3の状態に更新することを特徴とす
る。According to a ninth aspect of the present invention, in the microprocessor according to the sixth aspect, the control means is configured so that a state stored in the storage means is a second state and the first determination means If it is determined that the word length of the code to be decoded next is a halfword, the upper-side selecting means transfers the code held in the lower-side decoding register to the upper-side decoding register, The lower-order selector controls the selector to transfer the code held in the upper-side second register to the lower-side decryption register, and updates a state stored in the storage to a third state. It is characterized by doing.
【0014】請求項10記載のマイクロプロセッサは、
請求項4記載のマイクロプロセッサにおいてさらに、前
記記憶手段に記憶された格納状態と前記解読器での解読
結果とに基づいて、前記解読器によって解読された命令
がハーフワードで終了するメモリ上の位置に置かれてい
たサブルーチン分岐命令であるかどうかを判断する第2
の判断手段を備え、前記実行手段は、前記命令がハーフ
ワードで終了するメモリ上の位置に置かれていたサブル
ーチン分岐命令であると判断された場合には、その位置
に該当するメモリ番地にハーフワードのコードに相当す
る番地を加算したメモリ番地をサブルーチンからの戻り
番地とみなしてサブルーチンへの分岐処理を実行するこ
とを特徴とする。請求項11記載のマイクロプロセッサ
は、先読みした命令を保持する命令バッファと、コード
化された命令を1ワードずつ解読する解読器と、前記解
読器で解読する1ワードのコードをハーフワードずつ分
割して保持する上位側解読レジスタと下位側解読レジス
タと、前記解読器による解読結果に基づいて、次に新た
に前記解読レジスタに転送すべきコードの語長がハーフ
ワードであるか1ワードであるかを判断する第1の判断
手段と、前記第1の判断手段においてハーフワードと判
断された場合、前記下位側解読レジスタに格納されたコ
ードを前記上位側解読レジスタに転送するともに、前記
命令バッファに格納された次に転送すべきハーフワード
のコードを前記下位側解読レジスタに転送する選択手段
とを備えることを特徴とする。 [0014] The microprocessor according to claim 10 is:
5. The microprocessor according to claim 4 , further comprising: a position on a memory where an instruction decoded by the decoder ends in a halfword based on a storage state stored in the storage means and a result of decoding by the decoder. To determine if it is a subroutine branch instruction placed in
When it is determined that the instruction is a subroutine branch instruction located at a memory location ending with a halfword, the execution unit stores a half address at a memory address corresponding to the location. The memory address obtained by adding the address corresponding to the word code is regarded as the return address from the subroutine, and branch processing to the subroutine is executed. The microprocessor according to claim 11.
Is the instruction buffer that holds the prefetched instruction, and the code
A decryptor for decrypting the converted instructions word by word,
One word code that is decoded by a reader is divided into half words
Upper and lower decoding registers that are divided and held
Based on the decryption result by the decryptor
The word length of the code to be transferred to the decoding register is half
First judgment to determine whether it is a word or one word
Means and a half word in the first determination means.
In the case of a disconnection, the code stored in the lower
Code to the upper decoding register, and
Halfword to be transferred next stored in the instruction buffer
Selecting means for transferring the code of
And characterized in that:
【0015】[0015]
【作用】上記のように構成された請求項1及び2記載の
マイクロプロセッサによれば、解読器が解読する対象と
なる命令の語長は、解読器が一度に解読するコードの語
長aの整数倍に限定されない。従って、語長aよりも小
さい語長bを単位として、命令の語長を拡張して定義す
ることができる。According to the microprocessor of the first and second aspects of the present invention, the word length of the instruction to be decoded by the decoder is equal to the word length a of the code to be decoded by the decoder at one time. It is not limited to an integral multiple. Therefore, the word length of an instruction can be extended and defined in units of a word length b smaller than the word length a.
【0016】請求項3記載のマイクロプロセッサによれ
ば、請求項2記載のマイクロプロセッサにおいて、b=
a/2の関係となる。従って、命令の語長wは、a,
1.5a,2a,2.5a,3a,・・・のいずれかと
なる。即ち、命令の語長は、解読器が一度に解読するコ
ードの語長aの半分の語長を単位として最小語長aに付
加された値となる。これは、語長aを単位として拡張さ
れた命令の場合に比較し、コードを指定する際の情報量
は、語長aの上半分か下半分かを特定するためのビット
数、即ち、1ビット分の増加で済む。According to the microprocessor of the third aspect, in the microprocessor of the second aspect , b =
a / 2. Therefore, the word length w of the instruction is a,
1.5a, 2a, 2.5a, 3a,... That is, the word length of the instruction is a value added to the minimum word length a in units of half the word length a of the code decoded by the decoder at a time. This is compared with the instruction extended in units of the word length a, and the amount of information when specifying the code is the number of bits for specifying the upper half or the lower half of the word length a, that is, 1 Only an increase in bits is required.
【0017】請求項3、4及び11記載のマイクロプロ
セッサによれば、先読みされた命令は命令バッファに保
持され、命令バッファにおける命令のハーフワード単位
での格納状態が記記憶され更新される。さらに、次に解
読すべきコードの語長がハーフワードであるか1ワード
であるかが判断される。これによって、次に命令バッフ
ァから取り込んで解読すべきコードの位置と語長が判明
する。According to the microprocessor of the third , fourth and eleventh aspects, the prefetched instruction is held in the instruction buffer, and the storage state of the instruction in the instruction buffer in half word units is recorded and updated. Further, it is determined whether the word length of the code to be decoded next is half word or one word. As a result, the position and word length of the code to be fetched next from the instruction buffer and to be decoded are determined.
【0018】請求項5及び6記載のマイクロプロセッサ
によれば、フェッチされた1ワードのコードは、ハーフ
ワード単位で分割して命令バッファに保持されると共
に、それらの中から選択されたコードは、ハーフワード
単位で独立して解読レジスタに転送される。また、記憶
手段には、解読レジスタに転送される直前の命令バッフ
ァでのコードの格納状態が記憶されている。これによっ
て、命令バッファに保持された必要なコードは、ハーフ
ワード単位で解読レジスタに転送されて解読される。According to the microprocessor of the fifth and sixth aspects, the fetched one-word code is divided in half word units and held in the instruction buffer, and the code selected from them is: The data is independently transferred to the decoding register in halfword units. The storage means stores the code storage state in the instruction buffer immediately before being transferred to the decoding register. As a result, the necessary codes held in the instruction buffer are transferred to the decoding register in half word units and decoded.
【0019】請求項7記載のマイクロプロセッサによれ
ば、第1レジスタと第2レジスタに跨って保持された1
ワード長のコードが解読レジスタに転送されて実行され
る。請求項8記載のマイクロプロセッサによれば、下位
側第2レジスタに保持されたハーフワードのコードだけ
が解読レジスタに転送され、既に解読されたハーフワー
ドのコードと共に解読され実行される。According to the microprocessor of claim 7, held over the first register and the second register 1
The word length code is transferred to the decoding register and executed. According to the microprocessor of claim 8, only the lower side halfword code held in the second register is transferred to the decode register and already decoded with the code of the decrypted halfword executed.
【0020】請求項9記載のマイクロプロセッサによれ
ば、上位側第2レジスタに保持されたハーフワードのコ
ードだけが解読レジスタに転送され、既に解読されたハ
ーフワードのコードと共に解読され実行される。請求項
10記載のマイクロプロセッサによれば、解読器によっ
て解読された命令がハーフワードで終了するメモリ上の
位置に置かれていたサブルーチン分岐命令であるかどう
かが判断され、該命令であると判断された場合には、そ
の位置に該当するメモリ番地にハーフワードのコードに
相当する番地を加算したメモリ番地をサブルーチンから
の戻り番地とみなしてサブルーチンへの分岐処理が実行
される。According to the microprocessor of the ninth aspect, only the half-word code held in the upper second register is transferred to the decoding register, and is decoded and executed together with the already decoded half-word code. Claim
According to the microprocessor described in 10, it is determined whether or not the instruction decoded by the decoder is a subroutine branch instruction placed at a memory position ending with a half word, and is determined to be the instruction. In this case, the branching process to the subroutine is executed by regarding the memory address obtained by adding the address corresponding to the half-word code to the memory address corresponding to the position as the return address from the subroutine.
【0021】[0021]
【実施例】以下、本発明の実施例について図面を用いて
詳細に説明する。 (マイクロプロセッサの構成)図1は、本発明の第1実
施例に係るマイクロプロセッサの構成を示すブロック図
である。本マイクロプロセッサは、大きく分けてデータ
パスブロック200及び命令解読ブロック100からな
り、16ビットの外部アドレスバス212と8ビットの
外部データバス213を有する。尚、実行の対象となる
命令が置かれている外部メモリは、図示されていない
が、これらのバスを通じて本マイクロプロセッサと接続
されている。Embodiments of the present invention will be described below in detail with reference to the drawings. (Configuration of Microprocessor) FIG. 1 is a block diagram showing a configuration of a microprocessor according to the first embodiment of the present invention. This microprocessor is roughly composed of a data path block 200 and an instruction decoding block 100, and has a 16-bit external address bus 212 and an 8-bit external data bus 213. An external memory in which instructions to be executed are stored is connected to the microprocessor through these buses, though not shown.
【0022】データパスブロック200は、データの転
送や演算を行うブロックであり、セレクタ(SEL)2
01、レジスタ群202、内部Aバス203、内部Bバ
ス204、解読用カウンタ(DECPC)205、プリ
フェッチカウンタ(PFC)206、インクリメンタ
(INC)207、演算器(ALU)208、アドレス
バッファ(ADB)209、ストアデータバッファ(S
TB)210及びロードデータバッファ(LDB)21
1からなり、それらの機能は通常のマイクロプロセッサ
と異なるところはない。The data path block 200 is a block for performing data transfer and calculation, and is a selector (SEL) 2.
01, register group 202, internal A bus 203, internal B bus 204, decoding counter (DECPC) 205, prefetch counter (PFC) 206, incrementer (INC) 207, arithmetic unit (ALU) 208, address buffer (ADB) 209, store data buffer (S
TB) 210 and load data buffer (LDB) 21
1 and their functions are not different from ordinary microprocessors.
【0023】尚、スタックポインタ(SP)202a、
解読用カウンタ(DECPC)205、プリフェッチカ
ウンタ(PFC)206、インクリメンタ(INC)2
07及びアドレスバッファ(ADB)209は、アドレ
ス情報を保持する構成部であり、16ビット幅である。
一方、汎用レジスタ(REG)202b、ストアデータ
バッファ(STB)210及びロードデータバッファ
(LDB)211は、データ情報を保持する構成部であ
り、8ビット幅である。データパスブロック200と命
令解読ブロック100とは、内部Bバス204によって
接続されている。The stack pointer (SP) 202a,
Decryption counter (DECPC) 205, prefetch counter (PFC) 206, incrementer (INC) 2
07 and an address buffer (ADB) 209 are components for holding address information, and have a 16-bit width.
On the other hand, the general-purpose register (REG) 202b, the store data buffer (STB) 210, and the load data buffer (LDB) 211 are components that hold data information, and have an 8-bit width. The data path block 200 and the instruction decoding block 100 are connected by an internal B bus 204.
【0024】図2は、命令解読ブロック100の詳細な
構成を示すブロック図である。命令解読ブロック100
は、外部メモリからフェッチした命令を解読するブロッ
クであり、命令フェッチバッファ(IFB)101、命
令バッファ(IB)102、命令セレクタ(SI)10
3、命令レジスタ(IR)104、解読部105、実行
部108、制御部109及び記憶部110から構成され
る。FIG. 2 is a block diagram showing a detailed configuration of the instruction decoding block 100. Instruction decoding block 100
Is a block for decoding an instruction fetched from an external memory, and includes an instruction fetch buffer (IFB) 101, an instruction buffer (IB) 102, and an instruction selector (SI) 10.
3. Consists of an instruction register (IR) 104, a decoding unit 105, an execution unit 108, a control unit 109, and a storage unit 110.
【0025】IFB101は、外部メモリから外部デー
タバスを通じてフェッチした1ワードのコードを格納す
るレジスタである。ここで、ワードとは、命令を解読す
る際の単位をいい、本マイクロプロセッサにおいては8
ビット、即ち1バイトである。従って、本実施例では、
16ビットのアドレスバスによって特定される外部メモ
リの一つの番地には1ワード、即ち1バイト分のコード
が置かれている。The IFB 101 is a register for storing a one-word code fetched from an external memory through an external data bus. Here, the word refers to a unit for decoding an instruction, and is 8 words in the present microprocessor.
Bits, one byte. Therefore, in this embodiment,
At one address of the external memory specified by the 16-bit address bus, a code of one word, that is, one byte is placed.
【0026】また、命令とは、本マイクロプロセッサに
対する論理的なひとまとまりの指示をいい、例えば、”
add #4,d0”等が該当する。一方、コードと
は、命令が符号化されたビット並びの全体又は部分をい
い、例えば、命令”add #4,d0”に対応するビ
ット並び”0c2(hex)”や、その部分である”0
c”等が該当する。An instruction refers to a logical group of instructions to the microprocessor, for example, "
add # 4, d0 "etc. On the other hand, the code refers to the whole or a part of the bit sequence in which the instruction is coded, for example, the bit sequence" 0c2 () corresponding to the instruction "add # 4, d0". hex) ”and its part“ 0 ”
c "and the like.
【0027】IFB101は、フェッチしたコードの上
位4ビット(以下、4ビットの単位を「ニブル」とい
う。)を格納する上位側命令フェッチバッファ(IFB
H)101aと下位の1ニブルを格納する下位側命令フ
ェッチバッファ(IFBL)101bからなる。尚、デ
ータパスブロック200のプリフェッチカウンタ(PF
C)206には、このIFB101にフェッチされてい
るコードが置かれていた外部メモリの番地が保持され
る。The IFB 101 stores an upper instruction fetch buffer (IFB) for storing upper 4 bits of a fetched code (hereinafter, a unit of 4 bits is referred to as “nibble”).
H) comprises a lower instruction fetch buffer (IFBL) 101b for storing one lower nibble 101a. The prefetch counter (PF) of the data path block 200
C) 206 holds the address of the external memory where the code fetched in the IFB 101 is located.
【0028】IB102は、IFB101から出力され
たコードを格納するレジスタであり、IFB101と同
様に上位側命令バッファ(IBH)102aと下位側命
令バッファ(IBL)102bからなる。尚、IFB1
01とIB102に保持されたコードは、後述する実行
部108からの指示に従って図示されていないセレクタ
を介して内部Bバス204に出力されデータパスブロッ
ク200に転送される。The IB 102 is a register for storing the code output from the IFB 101 and, like the IFB 101, comprises an upper instruction buffer (IBH) 102a and a lower instruction buffer (IBL) 102b. In addition, IFB1
01 and the code held in the IB 102 are output to the internal B bus 204 via a selector (not shown) and transferred to the data path block 200 in accordance with an instruction from the execution unit 108 described later.
【0029】IR104は、解読する対象となる1バイ
トのコードを格納するレジスタであり、上位1ニブルの
コードを格納する上位側命令レジスタ(IRH)104
aと下位1ニブルのコードを格納する下位側命令レジス
タ(IRL)104bからなる。尚、データパスブロッ
ク200の解読用カウンタ(DECPC)205には、
このIR104にフェッチされているコードが置かれて
いた外部メモリの番地が保持される。An IR 104 is a register for storing a one-byte code to be decoded, and is an upper instruction register (IRH) 104 for storing a code for the upper one nibble.
a and a lower instruction register (IRL) 104b for storing the code of the lower 1 nibble. The decoding counter (DECPC) 205 of the data path block 200 includes
The address of the external memory where the code fetched in the IR 104 is stored.
【0030】上記のIFB101、IB102及びIR
104によって、3段の命令パイプラインが形成され、
先読みされた2バイトのコードと解読されている1バイ
トのコードを併せた合計3バイトのコードがこの命令パ
イプラインに格納される。SI103は、後述する制御
部109からの指示に従って、IBH102a、IBL
102b及びIRL104bから選択した1つのレジス
タに格納されている1ニブルのコードをIRH104a
に転送する上位側命令セレクタ(SIH)103aと、
IFBL101b、IBH102a及びIBL102b
から選択した1つのレジスタに格納されている1ニブル
のコードをIRL104bに転送する下位側命令セレク
タ(SIL)103bとからなり、これらは独立して動
作する。The above IFB101, IB102 and IR
104 form a three-stage instruction pipeline;
A total of three bytes of code, including the two-byte code read ahead and the one-byte code decoded, are stored in this instruction pipeline. The SI 103 receives the IBH 102a, IBL
102b and one nibble code stored in one register selected from IRL 104b
An upper instruction selector (SIH) 103a for transferring to
IFBL101b, IBH102a and IBL102b
And a lower instruction selector (SIL) 103b for transferring the code of one nibble stored in one register selected from the IRL 104b to the IRL 104b, and these operate independently.
【0031】記憶部110は、IB102に格納されて
いるコードの格納状態を数値に対応させて記憶してい
る。具体的には、図3に示される3つの状態のいずれか
の状態を記憶している。ステートS0はIBH102a
とIBL102bにはコードが格納されていない状態を
示し、ステートS1はIBH102aにはコードが格納
されているがIBL102bにはコードが格納されてい
ない状態を示し、ステートS2はIBH102aとIB
L102bにコードが格納されている状態を示す。The storage unit 110 stores the storage states of the codes stored in the IB 102 in association with the numerical values. Specifically, one of the three states shown in FIG. 3 is stored. State S0 is IBH102a
And IBL 102b indicate a state in which no code is stored, state S1 indicates a state in which a code is stored in the IBH 102a but no code is stored in the IBL 102b, and state S2 indicates a state in which the IBH 102a and the IB
This shows a state where a code is stored in L102b.
【0032】解読部105は、記憶部110に記憶され
ている状態を参照すると共に、IR104に格納されて
いる1バイトのコードを解読し、その結果を実行部10
8及び制御部109に通知する。解読部105は、コー
ドを複号する一般的な機能を有する他に、特定の判断を
行うためのコードサイズ判断部107及びワードアライ
ン判断部106を有する。The decoding unit 105 refers to the state stored in the storage unit 110, decodes the one-byte code stored in the IR 104, and outputs the result to the execution unit 10.
8 and the control unit 109 are notified. The decoding unit 105 has a code size judging unit 107 and a word alignment judging unit 106 for making a specific judgment, in addition to having a general function of decoding a code.
【0033】コードサイズ判断部107は、次に解読す
べきコードの語長が1ニブルであるか1バイトであるか
を判断し、その結果を制御部109に通知する。制御部
109は、コードサイズ判断部107からの通知と記憶
部110に記憶されている状態に基づいて、SI103
を制御すると共に記憶部110に記憶させる状態を更新
する。The code size determining unit 107 determines whether the word length of the code to be decoded next is 1 nibble or 1 byte, and notifies the control unit 109 of the result. The control unit 109 controls the SI 103 based on the notification from the code size determination unit 107 and the state stored in the storage unit 110.
And the state stored in the storage unit 110 is updated.
【0034】ワードアライン判断部106は、解読した
命令が外部メモリ上のハーフバイト境界に置かれていた
サブルーチン分岐命令であるかどうかを判断し、その結
果を実行部108に通知する。ここで、ハーフバイト境
界とは、バイト境界に対する用語であり、外部メモリ上
の1つの番地に対応する記憶領域、即ち1バイトの記憶
領域の中央の位置、即ち上位ニブルと下位ニブルとの境
界をいう。一方、バイト境界とは、外部メモリ上の1つ
の番地に対応する1バイトの記憶領域とその隣の番地に
対応する1バイトの記憶領域との境界をいう。The word alignment judging section 106 judges whether or not the decoded instruction is a subroutine branch instruction placed on a half-byte boundary in the external memory, and notifies the execution section 108 of the result. Here, the half-byte boundary is a term for a byte boundary, and indicates a storage area corresponding to one address on an external memory, that is, a central position of a 1-byte storage area, that is, a boundary between an upper nibble and a lower nibble. Say. On the other hand, a byte boundary refers to a boundary between a 1-byte storage area corresponding to one address on the external memory and a 1-byte storage area corresponding to an address next to the storage area.
【0035】実行部108は、解読部105での解読結
果に従って、命令解読ブロック100やデータパスブロ
ック200の各構成部を制御し、データ転送や演算を行
う。尚、実行部108から出力される制御信号は各構成
部に送られるが、その接続は図1及び図2には示されて
いない。また、実行部108を含む全ての構成部は、図
示されていないクロック信号に同期して動作し、クロッ
クサイクルを単位として動作内容が変化する。 (命令フォーマット)次に、以上のように構成されたマ
イクロプロセッサの命令フォーマットについて説明す
る。図4は、その命令フォーマットを説明するためのビ
ットの構成図である。本マイクロプロセッサが解読して
実行できる全ての命令は、フォーマット1(図4
(a))又はフォーマット2(図4(b))のいずれか
に分類される。The execution unit 108 controls each component of the instruction decoding block 100 and the data path block 200 according to the decoding result of the decoding unit 105, and performs data transfer and calculation. The control signal output from the execution unit 108 is sent to each component, but the connection is not shown in FIGS. 1 and 2. All components including the execution unit 108 operate in synchronization with a clock signal (not shown), and the operation changes in units of a clock cycle. (Instruction Format) Next, the instruction format of the microprocessor configured as described above will be described. FIG. 4 is a configuration diagram of bits for explaining the instruction format. All instructions that can be decoded and executed by the microprocessor are in Format 1 (FIG. 4).
(A)) or format 2 (FIG. 4 (b)).
【0036】フォーマット1に分類される命令は、1バ
イト長の基本命令語に1ニブル単位で拡張語が付加され
る可変長の構成となる。全ての命令は、基本命令語とそ
れに続く拡張語から構成されるが、拡張語を有しない場
合もある。ここで、基本命令語とは、命令の種類を特定
するオペレーションコードであり、解読部105が解読
する対象となるものをいう。拡張語とは、基本命令語に
よる演算等の操作の対象となるデータ(ディスプレース
メントや即値等)をいい、解読部105が解読する対象
とはならない。The instructions classified into the format 1 have a variable length configuration in which an extension word is added in units of 1 nibble to a basic instruction word of 1 byte length. All instructions consist of a basic instruction word followed by an expansion word, but may have no expansion word. Here, the basic command word is an operation code that specifies the type of command, and is a target to be decoded by the decoding unit 105. The extension word refers to data (displacement, immediate value, or the like) to be subjected to an operation such as an operation by a basic instruction word, and is not to be decoded by the decoding unit 105.
【0037】例えば、”即値2をレジスタd0に格納さ
れた値に加算する”という命令”add #2,d0”
は、基本命令語”0c(hex)”と拡張語”2”から
なる”0c2(hex)”というコードで表現される。
基本命令語”0c”は、”続く1ニブルの拡張語の値を
レジスタd0の値に加算する”という演算操作を意味す
る。この例のように、本マイクロプロセッサによれば、
1ニブルで表現できる数値とレジスタの値との演算を指
示する命令であれば、合計3ニブル、即ち、12ビット
あれば足りる。ところが、1バイトを命令の拡張単位と
する従来のマイクロプロセッサであれば、上述と同一内
容の命令であっても、拡張語を”02”(hex)”と
せざるを得ないために、合計16ビットが必要とされ
る。For example, the instruction "add # 2, d0" to "add immediate 2 to the value stored in register d0"
Is expressed by a code “0c2 (hex)” including a basic instruction word “0c (hex)” and an expansion word “2”.
The basic instruction word “0c” means an arithmetic operation of “adding the value of the extended word of the next one nibble to the value of the register d0”. According to the present microprocessor, as in this example,
In the case of an instruction instructing an operation of a numerical value that can be represented by one nibble and a register value, a total of three nibbles, that is, 12 bits is sufficient. However, in the case of a conventional microprocessor in which one byte is an extension unit of an instruction, even if the instruction has the same content as described above, the extension word is forced to be "02" (hex) ". A bit is needed.
【0038】従って、フォーマット1に示される命令で
あれば、無駄な情報が排除されるので、同一内容の指示
をする命令であってもより少ないビット数で構成でき
る。一方、フォーマット2に分類される命令は、3ニブ
ル長の基本命令語に1ニブル単位で拡張語が付加される
可変長の構成となる。例えば、”即値ff(hex)と
レジスタd0に格納された値との排他的論理和をとる”
という命令”XOR#ff,d0”は、基本命令語”2
08(hex)”と拡張語”ff(hex)”からな
り、”208ff(hex)”というコードで表現され
る。基本命令語”208”は、”続く1バイトの拡張語
の値とレジスタd0の値との排他的論理和をとる”とい
う演算操作を意味する。この命令の場合には、基本命令
語の3ニブルが解読部105によって解読される。Therefore, in the case of the instruction shown in the format 1, useless information is eliminated, so that even an instruction instructing the same contents can be configured with a smaller number of bits. On the other hand, instructions classified into format 2 have a variable length configuration in which an extension word is added in units of 1 nibble to a basic instruction word of 3 nibbles length. For example, "the exclusive OR of the immediate value ff (hex) and the value stored in the register d0 is taken."
The instruction “XOR # ff, d0” is a basic instruction word “2
08 (hex) "and an extension word" ff (hex) ", and is expressed by a code" 208ff (hex). "The basic instruction word" 208 "is" the value of the following 1-byte extension word and the register d0. In the case of this instruction, the three nibbles of the basic instruction word are decrypted by the decryption unit 105.
【0039】尚、フォーマット2の基本命令語は、第1
ニブルのコードを”2”又は”3”に定義している。即
ち、基本命令語のコードが”2xx(hex)”又は”
3xx(hex)”となるよう定義している。これは、
第1ニブルの値のみによって、その命令が2種類の命令
フォーマットのいずれであるかを区別するためである。The format 2 basic instruction word is the first
The nibble code is defined as "2" or "3". That is, the code of the basic instruction word is “2xx (hex)” or “2xx (hex)”.
3xx (hex) ".
This is for discriminating which of the two types of instruction format the instruction is based on only the value of the first nibble.
【0040】以上の説明から明らかなように、本マイク
ロプロセッサの命令セットは、8、12、16、20、
24、、、というように、最小が8ビット長であり、こ
れに4ビット単位で拡張された語長になっている。即
ち、各命令の語長は、命令解読器のビット幅(8ビッ
ト)よりも小さいビット数(4ビット)を単位として拡
張された値に定義されている。従って、これらの命令セ
ットを用いることによって、命令解読器のビット幅(8
ビット)の単位で拡張された命令を用いる場合に比べ、
同一内容のプログラムであっても、無駄なコードを排除
することができるので、全体のコードサイズを圧縮する
ことができる。 (マイクロプロセッサの動作)次に、以上のように定義
された命令セットを備える本マイクロプロセッサの動作
について説明する。As is clear from the above description, the instruction set of this microprocessor is 8, 12, 16, 20,
The minimum is an 8-bit length, such as 24,..., And the word length is extended in 4-bit units. That is, the word length of each instruction is defined as a value extended in units of bits (4 bits) smaller than the bit width (8 bits) of the instruction decoder. Therefore, by using these instruction sets, the bit width of the instruction decoder (8
Bit), compared to using the extended instruction
Even for programs having the same contents, useless codes can be eliminated, so that the entire code size can be compressed. (Operation of Microprocessor) Next, the operation of the microprocessor having the instruction set defined as described above will be described.
【0041】尚、本マイクロプロセッサは、命令の語長
が、解読部105の入力の語長(8ビット)よりも小さ
い語長(4ビット)の単位で拡張されている点に特徴が
あるあるので、この点に起因する特徴的な動作について
説明し、8ビット単位で拡張された命令セットを備える
従来のマイクロプロセッサと異ならない動作についての
説明は省略する。データパスブロック200における動
作は、従来のマイクロプロセッサの場合と同様であるの
でその説明は省略し、命令解読ブロック100の動作を
中心に説明する。 (解読例1)先ず、命令が外部メモリのバイト境界に置
かれている場合における命令解読ブロック100の動作
について説明する。The present microprocessor is characterized in that the word length of an instruction is extended in units of a word length (4 bits) smaller than the word length (8 bits) of the input of the decoding unit 105. Therefore, a characteristic operation resulting from this point will be described, and a description of an operation that is not different from a conventional microprocessor having an instruction set extended in 8-bit units will be omitted. The operation of the data path block 200 is the same as that of the conventional microprocessor, so that the description thereof will be omitted, and the operation of the instruction decoding block 100 will be mainly described. (Decryption Example 1) First, the operation of the instruction decoding block 100 when the instruction is located at a byte boundary of the external memory will be described.
【0042】図5は、5ニブル長の命令が本マイクロプ
ロセッサによって解読されて実行される場合の動作を説
明するための図である。図5(a)は、その命令のフォ
ーマットを示す図であり、3ニブルの基本命令語と2ニ
ブルの拡張語からなる。ここでは説明の便宜上、命令を
構成するコードをニブル単位で、A,B,C,D,Eと
表している。図5(b)は、この命令が外部メモリに置
かれている場合の各コードの配置を示す図である。尚、
基本命令語と拡張語では、外部メモリに置かれていると
きの各コードの配置順序が異なる。FIG. 5 is a diagram for explaining the operation when an instruction having a length of 5 nibbles is decoded and executed by the microprocessor. FIG. 5A shows the format of the instruction, which is composed of a basic instruction word of 3 nibbles and an extended word of 2 nibbles. Here, for convenience of explanation, codes constituting instructions are represented as A, B, C, D, and E in nibble units. FIG. 5B is a diagram showing the arrangement of each code when this instruction is stored in an external memory. still,
The basic instruction word and the expansion word differ in the arrangement order of each code when they are stored in the external memory.
【0043】図5(c)は、この命令が命令解読ブロッ
ク100に読み込まれた場合の、各クロックサイクルに
おける命令パイプライン、即ちIFB101、IB10
2、IR104に格納される各1バイト分のコードと記
憶部110に記憶される状態を示す表である。尚、図5
(c)の表に書かれている記号”−”は、この命令の実
行とは無関係であることを示している。FIG. 5C shows an instruction pipeline in each clock cycle, that is, IFB 101 and IB 10 when this instruction is read into the instruction decoding block 100.
2 is a table showing 1-byte codes stored in the IR 104 and states stored in the storage unit 110. FIG.
The symbol "-" written in the table (c) indicates that it is not related to the execution of this instruction.
【0044】クロックサイクル1において、命令の最初
の1バイトのコード”BA”がIFB101にフェッチ
される。続いて、クロックサイクル2において、続く1
バイトのコード”EC”がIFB101にフェッチされ
ると共にIFB101に格納されていたコード”BA”
はIB102に転送される。尚、コードのフェッチや命
令パイプラインにおける転送は、クロックサイクルごと
に送られてくる実行部108からの指示に従って行われ
る。クロックサイクル2においては、この命令の直前の
命令の解読が終了しているので、状態はS2になってい
る。In clock cycle 1, the first one-byte code "BA" of the instruction is fetched into IFB101. Subsequently, in clock cycle 2, the following 1
The byte code “EC” is fetched into the IFB 101 and the code “BA” stored in the IFB 101
Is transferred to the IB 102. Note that code fetch and transfer in the instruction pipeline are performed in accordance with an instruction from the execution unit 108 sent every clock cycle. In clock cycle 2, since the decoding of the instruction immediately before this instruction has been completed, the state is S2.
【0045】クロックサイクル3が開始されると、先
ず、制御部109は、記憶部110に記憶されている状
態がS2であることを知ると共に、コードサイズ判断部
107から”次に解読すべきコードの語長は1バイトで
ある”旨の通知を受ける。その結果、制御部109は、
IB102に格納されている1バイト分のコードをIR
104に転送するようSI103に選択信号を出力する
と共に、状態S2を記憶部110に書き込む。その選択
信号に基づいて、SIH103aは、IBL102bに
格納されていたコード”A”をIRH104aに転送
し、SIL103bは、IBH102aに格納されてい
たコード”B”をIRL104bに転送する。When the clock cycle 3 is started, first, the control unit 109 knows that the state stored in the storage unit 110 is S2, and the code size determination unit 107 determines "the code to be decoded next". Is 1 byte long. " As a result, the control unit 109
1-byte code stored in IB102 is converted to IR
A selection signal is output to the SI 103 so as to be transferred to the S 104, and the state S 2 is written to the storage unit 110. Based on the selection signal, the SIH 103a transfers the code “A” stored in the IBL 102b to the IRH 104a, and the SIL 103b transfers the code “B” stored in the IBH 102a to the IRL 104b.
【0046】その結果、IR104に転送されたコー
ド”AB”は、解読部105によって解読される。コー
ドサイズ判断部107は、この命令の第1ニブルのコー
ド”A”を解読することによって、この命令はフォーマ
ット2、即ち基本命令語は3ニブル長であることを知
り、”次に解読すべきコードの語長は、残る基本命令語
の語長、即ち1ニブルである”と判断する。As a result, the code “AB” transferred to the IR 104 is decoded by the decoding unit 105. The code size determination unit 107, by decoding the code “A” of the first nibble of this instruction, knows that this instruction is in format 2, that is, the basic instruction word is 3 nibbles long, and The word length of the code is determined to be the word length of the remaining basic instruction word, that is, one nibble.
【0047】クロックサイクル4においては、制御部1
09は、記憶部110に記憶されている状態がS2であ
ることを知ると共に、コードサイズ判断部107から”
次に解読すべきコードの語長は1ニブルである”旨の通
知を受ける。その結果、制御部109は、IBL102
bに格納されているコードをIRL104bに転送する
ようSI103に選択信号を出力すると共に、状態S1
を記憶部110に書き込む。その選択信号に基づいて、
SIH103aは、IRL104bに格納されていたコ
ード”B”をIRH104aに転送し、SIL103b
は、IBL102bに格納されていたコード”C”をI
RL104bに転送する。In clock cycle 4, control unit 1
09 determines that the state stored in the storage unit 110 is S2, and the code size determination unit 107
The control unit 109 receives the notification that the word length of the code to be decoded next is 1 nibble.
b, and outputs a selection signal to the SI 103 to transfer the code stored in the IRL 104b to the IRL 104b.
Is written into the storage unit 110. Based on the selection signal,
The SIH 103a transfers the code “B” stored in the IRL 104b to the IRH 104a, and
Replaces the code “C” stored in the IBL 102b with the I
Transfer to RL 104b.
【0048】その結果、IR104に転送されたコー
ド”BC”は、解読部105によって解読される。実行
部108は、解読部105での解読結果に基づいて、I
FB101及びIB102に格納されている拡張語”D
E”を内部Bバス204を介してデータパスブロック2
00に転送し、必要なデータ処理を行うことによってこ
の5ニブル長の命令の実行を終了する。As a result, the code “BC” transferred to the IR 104 is decoded by the decoding unit 105. The execution unit 108 executes I based on the result of decryption by the decryption unit 105
The expansion word "D" stored in the FB101 and the IB102
E ″ to the data path block 2 via the internal B bus 204
00 and perform the necessary data processing to terminate the execution of the 5-nibble length instruction.
【0049】ここで、基本命令語の第1ニブル”A”
は、この命令が3ニブル長であるという情報だけを有
し、続く命令”BC”が、この命令の実質的な内容(例
えば、”レジスタの値と即値を加算する”等)を有する
ように定義されている。従って、実行部108は、コー
ド”BC”の解読結果に基づいて実行する際には、既に
行ったコード”AB”の解読結果を必要としない。Here, the first nibble "A" of the basic instruction word is used.
Has only information that this instruction is three nibbles long, and the following instruction "BC" has the substantial content of this instruction (eg, "add register value to immediate value"). Is defined. Therefore, when executing based on the result of decoding the code “BC”, the execution unit 108 does not need the result of decoding the code “AB” already performed.
【0050】以上のようにして、3ニブル長の基本命令
語は、その語長が解読部105の入力語長の1.5倍で
あるにも拘らず、解読部105によって正しく解読され
実行される。 (解読例2)次に、命令が外部メモリのハーフバイト境
界に置かれている場合における命令解読ブロック100
の動作について説明する。As described above, the basic instruction word having a length of 3 nibbles is correctly decoded and executed by the decoding unit 105 even though the word length is 1.5 times the input word length of the decoding unit 105. You. (Decoding Example 2) Next, the instruction decoding block 100 in the case where the instruction is located at a half byte boundary of the external memory.
Will be described.
【0051】この命令のフォーマットは、図5(a)に
示された解読例1におけるフォーマットと同一とする。
図6(a)は、この命令が外部メモリに置かれている場
合の配置を、ニブル単位で示す図である。命令は、バイ
トの境界ではなく、ハーフバイト境界に置かれている点
が、図5(b)に示された解読例1の場合と異なる。以
下、解読例1と異なる点を中心に説明する。The format of this instruction is the same as the format in the first decryption example shown in FIG.
FIG. 6A is a diagram showing an arrangement in a case where the instruction is stored in the external memory in units of nibbles. The instruction is different from the case of the decoding example 1 shown in FIG. 5B in that the instruction is not placed on a byte boundary but on a half-byte boundary. Hereinafter, points different from the decoding example 1 will be mainly described.
【0052】図6(b)は、命令パイプラインの流れを
示す表であり、解読例1における図5(c)に対応す
る。クロックサイクル1において、第1ニブルのコー
ド”A”がIFB101にフェッチされ、続くクロック
サイクル2において、1バイトのコード”BC”がIF
B101にフェッチされる。このクロックサイクル2に
おいては、この命令の直前の命令の最終ニブルがハーフ
バイト境界に置かれていたので、状態はS1になってい
る。FIG. 6B is a table showing the flow of the instruction pipeline, and corresponds to FIG. 5C in the first decoding example. In the clock cycle 1, the code “A” of the first nibble is fetched into the IFB 101, and in the following clock cycle 2, the 1-byte code “BC” is
Fetched to B101. In clock cycle 2, the state is S1 because the last nibble of the instruction immediately before this instruction was located on a half-byte boundary.
【0053】クロックサイクル3が開始されると、先
ず、制御部109は、記憶部110に記憶されている状
態がS1であることを知ると共に、コードサイズ判断部
107から”次に解読すべきコードの語長は1バイトで
ある”旨の通知を受ける。その結果、制御部109は、
IFB101とIB102とに跨って格納されている1
バイトのコードをIR104に転送するようSI103
に選択信号を出力すると共に、状態S1を記憶部110
に書き込む。その選択信号に基づいて、SIH103a
は、IBH102aに格納されていたコード”A”をI
RH104aに転送し、SIL103bは、IFBL1
01bに格納されていたコード”B”をIRL104b
に転送する。When the clock cycle 3 is started, first, the control unit 109 knows that the state stored in the storage unit 110 is S1, and the control unit 109 determines from the code size determination unit 107 that "the code to be decoded next" is "1". Is 1 byte long. " As a result, the control unit 109
1 stored across IFB 101 and IB 102
SI 103 to transfer the byte code to IR 104
And outputs the state signal S1 to the storage unit 110.
Write to. Based on the selection signal, SIH103a
Replaces the code “A” stored in the IBH 102a with the I
The transfer to the RH 104a, the SIL 103b
01b stored in the IRL 104b
Transfer to
【0054】その結果、IR104に転送されたコー
ド”AB”は、解読部105によって解読される。コー
ドサイズ判断部107は、この命令の第1ニブルのコー
ド”A”を解読することによって、この命令はフォーマ
ット2、即ち基本命令語は3ニブル長であることを知
り、”次に解読すべきコードの語長は、残る基本命令語
の語長、即ち1ニブルである”と判断する。As a result, the code “AB” transferred to the IR 104 is decoded by the decoding unit 105. The code size determination unit 107, by decoding the code “A” of the first nibble of this instruction, knows that this instruction is in format 2, that is, the basic instruction word is 3 nibbles long, and The word length of the code is determined to be the word length of the remaining basic instruction word, that is, one nibble.
【0055】クロックサイクル4においては、制御部1
09は、記憶部110に記憶されている状態がS1であ
ることを知ると共に、コードサイズ判断部107から”
次に解読すべきコードの語長は1ニブルである”旨の通
知を受ける。その結果、制御部109は、IBH102
aに格納されているコードをIRL104bに転送する
ようSI103に選択信号を出力すると共に、状態S2
を記憶部110に書き込む。その選択信号に基づいて、
SIH103aは、IRL104bに格納されていたコ
ード”B”をIRH104aに転送し、SIL103b
は、IBH102aに格納されていたコード”C”をI
RL104bに転送する。In clock cycle 4, control unit 1
09 knows that the state stored in the storage unit 110 is S1, and the code size determination unit 107
The control unit 109 receives the notification that the word length of the code to be decoded next is 1 nibble.
a, and outputs a selection signal to the SI 103 to transfer the code stored in the IRL 104b to the IRL 104b.
Is written into the storage unit 110. Based on the selection signal,
The SIH 103a transfers the code “B” stored in the IRL 104b to the IRH 104a, and
Converts the code “C” stored in the IBH 102a into an I
Transfer to RL 104b.
【0056】その結果、IR104に転送されたコー
ド”BC”は、解読部105によって解読される。実行
部108は、解読部105での解読結果に基づいて、I
B102に格納されている拡張語”DE”を内部Bバス
204を介してデータパスブロック200に転送し、必
要なデータ処理を行うことによってこの5ニブル長の命
令の実行を終了する。As a result, the code “BC” transferred to the IR 104 is decoded by the decoding unit 105. The execution unit 108 executes I based on the result of decryption by the decryption unit 105
The extended word "DE" stored in B102 is transferred to the data path block 200 via the internal B bus 204, and the necessary data processing is performed to terminate the execution of the 5-nibble length instruction.
【0057】以上のようにして、外部メモリのハーフバ
イト境界に置かれている命令であっても、本マイクロプ
ロセッサによって正しく解読され実行される。 (分岐例1)次に、ハーフバイト境界から始まるプログ
ラムに分岐するための、分岐命令のフォーマット及び本
プロセッサの動作について説明する。As described above, even the instruction located at the half-byte boundary of the external memory is correctly decoded and executed by the microprocessor. (Branch Example 1) Next, the format of a branch instruction and the operation of the present processor for branching to a program starting from a half-byte boundary will be described.
【0058】図7は、無条件分岐命令jmpのフォーマ
ットを示す。この命令は、8ビットの基本命令語と16
ビットの拡張語を併せた6ニブル長のコードからなる。
ところで、本マイクロプロセッサにおいては、命令が外
部メモリのハーフバイト境界から始まる位置に置かれる
場合があるので、分岐先のメモリ番地を特定するために
は16ビットでは足りない。即ち、16ビットで特定さ
れるメモリ番地であっても、その番地の上位ニブル又は
下位ニブルのいずれに置かれた命令に分岐すべきかを指
定する必要がある。そのために、無条件分岐命令である
ことを特定するための8ビットの基本命令語に、分岐先
番地を特定するための17ビット以上の拡張語を併せた
語長、即ち7ニブル長の命令とすることもできる。FIG. 7 shows the format of the unconditional branch instruction jmp. This instruction consists of an 8-bit basic instruction word and 16
It consists of a 6 nibble length code combined with bit extension words.
By the way, in the present microprocessor, since an instruction may be placed at a position starting from a half-byte boundary of an external memory, 16 bits are not enough to specify a memory address of a branch destination. That is, even for a memory address specified by 16 bits, it is necessary to specify whether to branch to an instruction located in the upper nibble or the lower nibble of the address. Therefore, an 8-bit basic instruction word for specifying an unconditional branch instruction and a word length obtained by adding an expansion word of 17 bits or more for specifying a branch destination address, that is, an instruction having a length of 7 nibbles, You can also.
【0059】しかし、7ニブル長のコードを用いてjm
p命令を定義したのでは、このコードの中に実質的に使
用されない3ビット分の無駄なコードが含まれることに
なり、コードサイズの縮小化が阻害される。そこで、図
7に示されるように、jmp命令の基本命令語の最下位
ビットを、分岐先の命令が外部メモリ上のハーフバイト
境界に置かれているか否かを示すための情報として定義
している。即ち、基本命令語の最下位1ビットと拡張語
の2バイトを併せた合計17ビットによって、分岐先の
メモリ番地が特定されるようjmp命令のコードを定義
している。これによって、無条件分岐命令jmpは、7
ニブル長ではなく6ニブル長のコードに圧縮して定義さ
れるので、無駄なコードの発生が回避される。However, using a 7 nibble length code, jm
When the p instruction is defined, this code includes a wasteful code of 3 bits that is not substantially used, which hinders a reduction in code size. Therefore, as shown in FIG. 7, the least significant bit of the basic instruction word of the jmp instruction is defined as information for indicating whether or not the branch destination instruction is located at a half-byte boundary on the external memory. I have. That is, the code of the jmp instruction is defined so that the memory address of the branch destination is specified by a total of 17 bits including the least significant bit of the basic instruction word and the two bytes of the expansion word. Thereby, the unconditional branch instruction jmp becomes 7
Since the code is defined by being compressed to a code having a length of 6 nibbles instead of the nibble length, generation of useless codes is avoided.
【0060】次に、このjmp命令が実行された場合
の、本マイクロプロセッサの動作を説明する。今、この
3バイト長のjmp命令が外部メモリからフェッチされ
て、IFB101、IB102及びIR104に保持さ
れているとする。解読部105は、IR104に格納さ
れている基本命令語の最下位ビットの情報だけを制御部
109に送る。制御部109は、送られてきた情報が”
1”である場合には状態S1を記憶部110に書き込
み、”0”である場合には状態S2を書き込む。Next, the operation of the present microprocessor when the jmp instruction is executed will be described. Now, it is assumed that the 3-byte length jmp instruction is fetched from the external memory and held in the IFB 101, IB 102, and IR 104. The decoding unit 105 sends only the information of the least significant bit of the basic instruction stored in the IR 104 to the control unit 109. The control unit 109 determines that the transmitted information is "
If it is "1", the state S1 is written to the storage unit 110, and if it is "0", the state S2 is written.
【0061】同時に、解読部105は、IR104に格
納されている基本命令語の上位7ビット分のコードを解
読することによって、この命令が無条件分岐命令である
ことを実行部108に通知する。この通知を受けた実行
部108は、IFB101及びIB102に格納されて
いる16ビット分の分岐先番地をデータパスブロック2
00に転送し、さらに外部アドレスバス212に出力さ
せる。その結果、外部アドレスバス212によって指定
されたメモリ番地から始まる外部メモリ上の命令が、1
バイト単位で命令解読ブロック100に取り込まれてい
く。At the same time, the decoding unit 105 notifies the execution unit 108 that this instruction is an unconditional branch instruction by decoding the upper 7 bits of the code of the basic instruction word stored in the IR 104. Upon receiving this notification, the execution unit 108 sets the 16-bit branch destination address stored in the IFB 101 and the IB 102 to the data path block 2.
00 and output to the external address bus 212. As a result, the instruction on the external memory starting from the memory address designated by the external address bus 212 is 1
The instruction is read into the instruction decoding block 100 in byte units.
【0062】分岐先の先頭の1バイト分のコードがIB
102に転送されると、制御部109は、次のクロック
サイクルにおいて解読すべきコードを決定するために、
記憶部110に記憶されている状態に従ってSI103
を制御する。具体的には、記憶部110に状態S2が記
憶されていた場合には、制御部109は、IB102に
保持されている1バイト分のコードをIR104に転送
するようSI103を制御する。この制御は、上述の解
読例1のクロックサイクル3での制御と同様であり、外
部メモリ上に置かれていたバイト境界から始まる命令を
解読することに相当する。即ち、この場合は、バイト境
界への分岐処理に該当する。The code for the first byte of the branch destination is IB
Once transferred to 102, the control unit 109 determines the code to be decoded in the next clock cycle by:
SI 103 according to the state stored in storage unit 110
Control. Specifically, when the state S2 is stored in the storage unit 110, the control unit 109 controls the SI 103 to transfer the one-byte code held in the IB 102 to the IR 104. This control is similar to the control in clock cycle 3 of the above-described decoding example 1, and corresponds to decoding an instruction starting from a byte boundary placed on the external memory. That is, this case corresponds to the branch processing to the byte boundary.
【0063】一方、記憶部110に状態S1が記憶され
ていた場合には、制御部109は、IFB101とIB
102とに跨る1バイト分のコードをIR104に転送
するようSI103を制御する。この制御は、上述の解
読例2のクロックサイクル3での制御と同様であり、外
部メモリ上に置かれていたハーフバイト境界から始まる
命令を解読することに相当する。即ち、この場合は、ハ
ーフバイト境界への分岐処理に該当する。On the other hand, when the state S1 has been stored in the storage unit 110, the control unit 109
The SI 103 is controlled so as to transfer a one-byte code extending to the IR 102 to the IR 104. This control is the same as the control in clock cycle 3 in the above-described decoding example 2, and corresponds to decoding an instruction starting from a half-byte boundary placed on the external memory. That is, this case corresponds to the branch processing to the half-byte boundary.
【0064】以上の動作によって、3バイト長の無条件
分岐命令jmpによる、バイト境界又はハーフバイト境
界への分岐処理が終了する。 (分岐例2)次に、分岐後に戻るべきメモリ番地がハー
フバイト境界である場合における、サブルーチン分岐命
令(以下、「jsr命令」という。)を実行した本プロ
セッサの動作について説明する。With the above operation, the branch processing to the byte boundary or the half-byte boundary by the 3-byte unconditional branch instruction jmp is completed. (Branch Example 2) Next, the operation of the present processor that has executed a subroutine branch instruction (hereinafter, referred to as "jsr instruction") when the memory address to be returned after the branch is a half-byte boundary will be described.
【0065】ここで、jsr命令とは、指定されたメモ
リ番地への分岐処理に先立ち、この命令が置かれている
メモリ番地の次の番地を戻り番地としてスタックポイン
タ(SP)202aが示す記憶領域(以下、単に「スタ
ック」という。)に退避しておく処理を伴うような分岐
命令をいう。この命令は、サブルーチンの終了を指示す
るリターン命令と対で用いられる。リターン命令が実行
されると、スタックに退避していた戻り番地を読み出
し、その番地に戻る処理が行われる。Here, the jsr instruction is a storage area indicated by the stack pointer (SP) 202a with the return address next to the memory address where this instruction is located, prior to the branch processing to the specified memory address. (Hereinafter, simply referred to as a “stack”). This instruction is used in combination with a return instruction instructing the end of the subroutine. When the return instruction is executed, a process of reading the return address saved on the stack and returning to the address is performed.
【0066】ところで、外部メモリ上のハーフバイト境
界に戻る場合を考慮すると、分岐例1で説明したよう
に、戻り番地を指定するには17ビットが必要とされ
る。従って、スタックに退避する戻り番地のコードは、
2バイトでは足りず3バイトが必要とされる。即ち、j
sr命令やリターン命令を実行するたびに、スタックに
対して3回ずつアクセスする必要が生じる。By the way, considering the return to the half-byte boundary on the external memory, 17 bits are required to specify the return address as described in the first branch example. Therefore, the return address code saved on the stack is
Two bytes are not enough and three bytes are needed. That is, j
Each time an sr instruction or a return instruction is executed, it is necessary to access the stack three times.
【0067】しかしながら、同一内容のプログラムであ
っても、スタックへのアクセスの頻度が多くなると、そ
の処理に要する時間だけマイクロプロセッサによるスル
ープットが低下する。特に、C言語で作成されたプログ
ラムにおいては、一般にスタックを使用する頻度が多い
ため、そのスループットは、スタックへのアクセス回数
の影響を強く受ける。However, even if the programs have the same contents, if the frequency of accessing the stack increases, the throughput of the microprocessor decreases by the time required for the processing. In particular, in a program written in the C language, the stack is generally used frequently, and the throughput is strongly affected by the number of times the stack is accessed.
【0068】そこで、本マイクロプロセッサでは、戻り
番地がハーフバイト境界となる場合であっても、スタッ
クへの退避が2バイトで済むように工夫している。以下
に、その内容について説明する。jsr命令のフォーマ
ットは、図7に示された無条件分岐命令と同一である。
即ち、この命令は、1バイトの基本命令語に2バイトの
拡張語を付加した合計3バイトからなり、分岐先番地
は、基本命令語の最下位ビットと拡張語の16ビットを
併せた合計17ビットにより特定される。従って、分岐
先が外部メモリのバイト境界であってもハーフバイト境
界であっても分岐例1の場合と同様に実行される。Therefore, in the present microprocessor, even if the return address is on a half-byte boundary, it is devised that saving to the stack requires only 2 bytes. The details will be described below. The format of the jsr instruction is the same as the unconditional branch instruction shown in FIG.
That is, this instruction is composed of a total of 3 bytes obtained by adding a 2-byte extension word to a 1-byte basic instruction word, and the branch destination address is a total of 17 bytes including the least significant bit of the basic instruction word and 16 bits of the extension word. Specified by bit. Therefore, whether the branch destination is a byte boundary or a half-byte boundary of the external memory is executed in the same manner as in the case of the first branch example.
【0069】次に、jsr命令が実行された場合におけ
る、本マイクロプロセッサの動作について図8に示され
たフローチャートを用いて説明する。この命令の基本命
令語がIR104に格納されると、ワードアライン判断
部106は、この命令がjsr命令であることを認識す
ると同時に、記憶部110に記憶されている状態を参照
することにより、この命令が外部メモリ上のバイト境界
に置かれていたかハーフバイト境界に置かれていたかを
判断し、その結果を実行部108に通知する(ステップ
S81)。Next, the operation of the microprocessor when the jsr instruction is executed will be described with reference to the flowchart shown in FIG. When the basic instruction word of this instruction is stored in the IR 104, the word alignment judging unit 106 recognizes that this instruction is a jsr instruction and, at the same time, refers to the state stored in the storage unit 110, It is determined whether the instruction is located on a byte boundary or a half-byte boundary on the external memory, and the result is notified to the execution unit 108 (step S81).
【0070】この命令が外部メモリ上のバイト境界に置
かれていた旨の通知を受けた実行部108は、この命令
自体の語長は上述の定義通り6ニブルであると認識し
(ステップS82)、この命令の直後に置かれている命
令のメモリ番地、即ち、16ビットで表わされるバイト
境界を示すメモリ番地をスタックに退避する(ステップ
S84)。図9(a)は、外部メモリ上のバイト境界に
置かれているjsr命令と、戻り番地の関係を示す図で
ある。The execution unit 108, which has been notified that this instruction is located at a byte boundary on the external memory, recognizes that the word length of this instruction itself is 6 nibbles as defined above (step S82). The memory address of the instruction placed immediately after this instruction, that is, the memory address indicating a byte boundary represented by 16 bits, is saved on the stack (step S84). FIG. 9A is a diagram showing a relationship between a jsr instruction located at a byte boundary on an external memory and a return address.
【0071】一方、この命令が外部メモリ上のハーフバ
イト境界に置かれていた旨の通知を受けた実行部108
は、この命令自体の語長は6ニブルではなく7ニブルで
あるとみなし(ステップS83)、この7ニブル長の命
令の直後に置かれている命令のメモリ番地、即ち、16
ビットで表わされるバイト境界を示すメモリ番地をスタ
ックに退避する(ステップS84)。具体的には、実行
部108は、この命令が置かれていたメモリ番地を解読
用カウンタ(DECPC)205から読み出して演算器
(ALU)208に送り、この命令自体が7ニブル長で
あるとした場合の戻り番地を算出し、スタックに書き込
むよう各構成部を制御する。図9(b)は、外部メモリ
上のハーフバイト境界に置かれているjsr命令と、戻
り番地の関係を示す図である。On the other hand, when the execution unit 108 is notified that this instruction has been placed on a half-byte boundary in the external memory,
Assumes that the word length of this instruction itself is 7 nibbles instead of 6 nibbles (step S83), and the memory address of the instruction placed immediately after this 7 nibble length instruction, that is, 16
The memory address indicating the byte boundary represented by the bit is saved on the stack (step S84). Specifically, the execution unit 108 reads the memory address where the instruction is located from the decryption counter (DECPC) 205 and sends it to the arithmetic unit (ALU) 208, and determines that the instruction itself has a length of 7 nibbles. A return address in the case is calculated, and each component is controlled to write the return address to the stack. FIG. 9B is a diagram showing the relationship between the jsr instruction located at the half-byte boundary on the external memory and the return address.
【0072】戻り番地をスタックに退避した後の動作は
分岐例1での動作と同様であり、実行部108は、この
命令の下位17ビットで特定されるサブルーチンの先頭
番地に分岐するための処理を行う(ステップS85)。
以上のようにして、このjsr命令が外部メモリ上のバ
イト境界又はハーフバイト境界のいずれの位置に配置さ
れている場合であっても、スタックに退避する戻り番地
は、2バイトで済む。The operation after saving the return address on the stack is the same as the operation in the first example of branching, and the execution unit 108 performs processing for branching to the head address of the subroutine specified by the lower 17 bits of this instruction. Is performed (step S85).
As described above, even if the jsr instruction is located on a byte boundary or a half-byte boundary on the external memory, the return address saved on the stack is only 2 bytes.
【0073】尚、サブルーチンの処理を終えて、リター
ン命令を実行した場合には、実行部108は、スタック
に退避されていた2バイトの戻り番地を読み出してアド
レスバッファ(ADB)209に格納し、その番地から
始まる命令を実行するよう各構成部を制御する。ところ
で、以上のようにjsr命令が実行される前提として、
jsr命令とその次の命令が、上述の動作と整合して外
部メモリ上に配置されている必要がある。即ち、jsr
命令を外部メモリ上のハーフバイト境界に配置した場合
には、その次の命令は、そのjsr命令が6ニブル長で
はなく7ニブル長の命令であるとみなして、外部メモリ
上に配置しておく必要があるのは言うまでもない。その
処理は、一般にリンカーと呼ばれるメモリ番地割付プロ
グラムによって実現されるものであり、本マイクロプロ
セッサの動作とは直接には関係しないので、その説明は
省略する。When the return instruction is executed after the processing of the subroutine, the execution unit 108 reads the 2-byte return address saved on the stack and stores it in the address buffer (ADB) 209. Each component is controlled to execute the instruction starting from that address. By the way, assuming that the jsr instruction is executed as described above,
The jsr instruction and the next instruction need to be arranged on the external memory consistent with the above operation. That is, jsr
When an instruction is arranged at a half-byte boundary on the external memory, the next instruction is arranged on the external memory, assuming that the jsr instruction is not a 6 nibble length instruction but a 7 nibble length instruction. Needless to say, it is necessary. This processing is realized by a memory address allocation program generally called a linker, and is not directly related to the operation of the present microprocessor.
【0074】以上の説明から明らかなように、本マイク
ロプロセッサにおいては、jsr命令が実行された場合
には、その命令が置かれているメモリ番地の境界に拘ら
ず、常に2バイトの戻り番地を退避するだけで済む。従
って、3バイトの戻り番地を退避する場合に比べ、プロ
グラムの処理時間が短縮される。以上、本発明に係るマ
イクロプロセッサについて、実施例に基づいて説明した
が、本発明はこれら実施例に限られないことは勿論であ
る。即ち、 (1)本実施例では、命令を解読する際の単位、即ち、
1ワードが8ビットであったが、このビット数に限定さ
れるものではない。例えば、1ワードが12ビットであ
ってもよい。その場合には、命令解読ブロック100及
びデータパスブロック200において、8ビットで構成
されている全ての構成部のビット幅を12ビットし、さ
らに、外部メモリに配置するコードを12ビット単位と
すればよい。 (2)本実施例では、IB102におけるコードの格納
状態が記憶部110に記憶されたが、IB102に限定
されるものではない。例えば、IFB101とIB10
2におけるコードの格納状態が記憶されてもよい。これ
によって、IB102だけでなく、IFB101でのコ
ードの有無による柔軟な制御が可能になる。 (3)本実施例における命令パイプラインは、IFB1
01、IB102及びSI103からなる3段である
が、この段数に限定されるものではない。As is apparent from the above description, in the present microprocessor, when the jsr instruction is executed, the return address of 2 bytes is always set regardless of the boundary of the memory address where the instruction is located. Just evacuate. Therefore, the processing time of the program is reduced as compared with the case where the return address of 3 bytes is saved. As described above, the microprocessor according to the present invention has been described based on the embodiments. However, it goes without saying that the present invention is not limited to these embodiments. That is, (1) In the present embodiment, the unit for decoding the instruction, that is,
Although one word has eight bits, the number of bits is not limited. For example, one word may be 12 bits. In that case, in the instruction decoding block 100 and the data path block 200, the bit width of all the constituent parts composed of 8 bits is set to 12 bits, and the code arranged in the external memory is set to 12 bits. Good. (2) In the present embodiment, the storage state of the code in the IB 102 is stored in the storage unit 110, but the present invention is not limited to the IB 102. For example, IFB101 and IB10
2 may be stored. This enables flexible control based on the presence or absence of a code in the IFB 101 as well as the IB 102. (3) The instruction pipeline in this embodiment is IFB1
01, the IB 102 and the SI 103, but the number of stages is not limited.
【0075】[0075]
【発明の効果】以上の説明から明らかなように、請求項
1及び2記載のマイクロプロセッサによれば、命令の語
長は、1ワード、即ち解読器が一度に解読するコードの
語長の整数倍に限定されない。従って、命令を構成する
コードの中に、使用されない無駄なビットが含まれる割
合を低減することができる。As is apparent from the above description, according to the microprocessors of the first and second aspects, the word length of the instruction is one word, that is, an integer of the word length of the code that the decoder decodes at one time. It is not limited to double. Therefore, it is possible to reduce the ratio of useless bits that are not used in the code constituting the instruction.
【0076】これによって、同一内容のプログラムであ
っても、コードサイズが縮小されたプログラムの作成が
可能になるという効果がある。請求項3記載のマイクロ
プロセッサによれば、命令の語長は、ハーフワードを単
位として拡張された値となる。従って、ハーフワードを
単位としてきめ細かく命令を定義したり、データを指定
したりできる。As a result, even if the programs have the same contents, it is possible to create a program with a reduced code size. According to the microprocessor of the third aspect , the word length of the instruction is a value extended in units of half words. Therefore, it is possible to finely define an instruction or specify data in units of a half word.
【0077】請求項4記載のマイクロプロセッサによれ
ば、次に解読すべきコードが命令バッファにどのように
配置されているかを、ハーフワード単位で判断すること
ができる。請求項5記載のマイクロプロセッサによれ
ば、命令バッファに保持されたコードを、ハーフワード
単位で独立して解読レジスタに転送し、解読することが
できる。According to the microprocessor of the fourth aspect, it is possible to determine, in half word units, how the code to be decoded next is arranged in the instruction buffer. According to the microprocessor of the fifth aspect, the code held in the instruction buffer can be independently transferred to the decoding register in half word units and decoded.
【0078】請求項6記載のマイクロプロセッサによれ
ば、外部メモリ上の2つの番地に跨って置かれた1ワー
ド長のコードであっても正しく解読され実行される。請
求項7記載のマイクロプロセッサによれば、外部メモリ
上の下位の位置に置かれたハーフワード長のコードであ
っても正しく解読され実行される。請求項8記載のマイ
クロプロセッサによれば、外部メモリ上の上位の位置に
置かれたハーフワード長のコードであっても正しく解読
され実行される。[0078] According to the microprocessor of claim 6, also correctly decrypted run a 1 word length code placed over two addresses on the external memory. According to the microprocessor of the seventh aspect , even a half-word length code placed at a lower position on the external memory can be correctly decoded and executed. According to the microprocessor of the eighth aspect , even a half-word length code placed at a higher position on the external memory can be correctly decoded and executed.
【0079】請求項9記載のマイクロプロセッサによれ
ば、外部メモリ上のハーフワード境界に置かれたサブル
ーチン分岐命令を実行する場合であっても、その命令が
ワード境界に置かれていた場合と同じビット数からなる
戻り番地を退避するだけで済む。従って、スタックへの
アクセス頻度が減少すると共に、スタックの無駄な消費
を回避できる。According to the microprocessor of the ninth aspect , even when a subroutine branch instruction placed on a halfword boundary on an external memory is executed, it is the same as when the instruction is placed on a word boundary. It is only necessary to save the return address consisting of the number of bits. Therefore, the frequency of access to the stack is reduced, and wasteful consumption of the stack can be avoided.
【0080】これによって、同一内容のプログラムを実
行した場合であっても、そのスループットを向上させる
ことができるという効果がある。As a result, even when programs having the same contents are executed, there is an effect that the throughput can be improved.
【図1】本発明の実施例に係るマイクロプロセッサの構
成を示すブロック図である。FIG. 1 is a block diagram illustrating a configuration of a microprocessor according to an embodiment of the present invention.
【図2】同実施例に係るマイクロプロセッサの命令解読
ブロック100の詳細な構成を示すブロック図である。FIG. 2 is a block diagram showing a detailed configuration of an instruction decoding block 100 of the microprocessor according to the embodiment.
【図3】同実施例に係るマイクロプロセッサのIB10
2におけるコードの格納状態を示す図である。FIG. 3 is an IB10 of the microprocessor according to the embodiment.
FIG. 4 is a diagram illustrating a storage state of codes in FIG.
【図4】同実施例に係るマイクロプロセッサが実行する
命令の2種類のフォーマットを示す図である。FIG. 4 is a diagram showing two types of formats of instructions executed by the microprocessor according to the embodiment.
【図5】図5(a)は、同実施例における5ニブル長の
命令のフォーマットを示す図である。図5(b)は、図
5(a)に示された命令が外部メモリ上のバイト境界に
置かれている場合の各コードの配置を示す図である。図
5(c)は、図5(a)に示された命令が命令解読ブロ
ック100に読み込まれた場合の、各クロックサイクル
における命令パイプラインの流れを示す図である。FIG. 5A is a diagram showing a format of a 5-nibble-length instruction in the embodiment. FIG. 5B is a diagram showing an arrangement of each code when the instruction shown in FIG. 5A is located at a byte boundary on the external memory. FIG. 5C is a diagram showing the flow of the instruction pipeline in each clock cycle when the instruction shown in FIG. 5A is read into the instruction decoding block 100.
【図6】図6(a)は、図5(a)に示された命令が外
部メモリ上のハーフバイト境界に置かれている場合の各
コードの配置を示す図である。図6(b)は、図5
(a)に示された命令が命令解読ブロック100に読み
込まれた場合の、各クロックサイクルにおける命令パイ
プラインの流れを示す図である。FIG. 6A is a diagram showing an arrangement of each code when the instruction shown in FIG. 5A is located at a half-byte boundary on an external memory. FIG. 6B shows FIG.
FIG. 3 is a diagram showing a flow of an instruction pipeline in each clock cycle when the instruction shown in FIG.
【図7】同実施例における無条件分岐命令jmpのフォ
ーマットを示す図である。FIG. 7 is a diagram showing a format of an unconditional branch instruction jmp in the embodiment.
【図8】同実施例において、jsr命令が実行された場
合における、本マイクロプロセッサの動作を示すフロー
チャートである。FIG. 8 is a flowchart showing the operation of the microprocessor when a jsr instruction is executed in the embodiment.
【図9】図9(a)は、同実施例において、外部メモリ
上のバイト境界に置かれているjsr命令と戻り番地の
関係を示す図である。図9(b)は、同実施例におい
て、外部メモリ上のハーフバイト境界に置かれているj
sr命令と、戻り番地の関係を示す図である。FIG. 9A is a diagram showing a relationship between a jsr instruction located at a byte boundary on an external memory and a return address in the embodiment. FIG. 9 (b) shows the j that is located at the half-byte boundary on the external memory in the embodiment.
FIG. 4 is a diagram illustrating a relationship between an sr instruction and a return address.
【図10】従来のマイクロプロセッサにおける命令のビ
ット構成を示す図である。FIG. 10 is a diagram showing a bit configuration of an instruction in a conventional microprocessor.
101a IFBH 101b IFBL 102a IBH 102b IBL 103a SIH 103b SIL 104a IRH 104b IRL 105 解読部 106 ワードアライン判断部 107 コードサイズ判断部 108 実行部 109 制御部 110 記憶部 101a IFBH 101b IFBL 102a IBH 102b IBL 103a SIH 103b SIL 104a IRH 104b IRL 105 Decryption unit 106 Word alignment determination unit 107 Code size determination unit 108 Execution unit 109 Control unit 110 Storage unit
───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 平3−97031(JP,A) 特開 昭54−122043(JP,A) 特開 平4−101230(JP,A) 特開 平3−33931(JP,A) 特開 昭61−33545(JP,A) 特開 昭63−244233(JP,A) (58)調査した分野(Int.Cl.7,DB名) G06F 9/30 - 9/355 G06F 9/40 - 9/42 ──────────────────────────────────────────────────続 き Continuation of the front page (56) References JP-A-3-97031 (JP, A) JP-A-54-124343 (JP, A) JP-A-4-101230 (JP, A) JP-A-3-103 33931 (JP, A) JP-A-61-33545 (JP, A) JP-A-63-244233 (JP, A) (58) Fields investigated (Int. Cl. 7 , DB name) G06F 9 / 30-9 / 355 G06F 9/40-9/42
Claims (11)
読器と、前記解読器による解読結果に基づいてデータ処
理を実行する実行手段とを備えるマイクロプロセッサで
あって、 前記命令の語長wは、前記解読器が一度に解読するコー
ドの最小語長をaとし、aよりも小さい語長をbとした
場合に、 w=a+nb (但し、nは0及び1を含む正の整数と
する) で表され、 前記実行手段は、少なくとも語長がaである命令と語長
が(a+b)である命令を実行することを特徴とするマ
イクロプロセッサ。1. A microprocessor comprising: a decoder for decoding coded instructions one by one; and execution means for executing data processing based on a result of decoding by the decoder. Where a is the minimum word length of the code that the decoder decodes at a time and b is a word length smaller than a, where w is a + nb (where n is a positive integer including 0 and 1 ) ) is represented by the execution unit, microprocessor and executes instructions and word length at least word length is a is an instruction is (a + b).
に、ハーフワードであることを特徴とする請求項1記載
のマイクロプロセッサ。2. The microprocessor according to claim 1, wherein said b is a half word when said a is one word.
ずつ分割して保持する上位側解読レジスタと下位側解読
レジスタと、 前記解読器による解読結果に基づいて、次に新たに前記
解読レジスタに転送すべきコードの語長がハーフワード
であるか1ワードであるかを判断する第1の判断手段
と、 前記第1の判断手段においてハーフワードと判断された
場合、前記下位側解読レジスタに格納されたコードを前
記上位側解読レジスタに転送するともに、前記命令バッ
ファに格納された次に転送すべきハーフワードのコード
を前記下位側解読レジスタに転送する選択手段とを備え
ることを特徴とする請求項2記載のマイクロプロセッ
サ。 3. The microprocessor further comprises : an instruction buffer for holding a pre-read instruction; an upper-side decoding register and a lower-side decoding register for holding a one-word code to be decoded by the decoder in half-word units. First determining means for determining whether a word length of a code to be newly transferred to the decoding register is half word or 1 word based on a decoding result by the decoding device; When the determination means determines that the code is a half word, the code stored in the lower decoding register is transferred to the upper decoding register, and the code of the next half word to be transferred stored in the instruction buffer is transferred. 3. The microprocessor according to claim 2, further comprising selection means for transferring the data to the lower decoding register.
格納状態を記憶する記憶手段と、 前記解読器による解読結果に基づいて、次に解読すべき
コードの語長がハーフワードであるか1ワードであるか
を判断する第1の判断手段と、 判断された語長と前記格納状態とに基づいて、前記命令
バッファに格納されたコードを前記解読器に取り込むよ
う前記命令バッファを制御すると共に前記格納状態を更
新する制御手段とを備えることを特徴とする請求項2記
載のマイクロプロセッサ。4. The microprocessor according to claim 1, further comprising : an instruction buffer configured to store a pre-read instruction; a storage unit configured to store a storage state of the instruction in the instruction buffer in a unit of half word; First determining means for determining whether the word length of a code to be decoded next is half word or one word; and storing the code in the instruction buffer based on the determined word length and the storage state. 3. The microprocessor according to claim 2, further comprising: control means for controlling the instruction buffer so as to take in the decoded code into the decoder and updating the storage state.
格納状態を記憶する記憶手段と、 前記解読器で解読する1ワードのコードをハーフワード
ずつ分割して保持する上位側解読レジスタと下位側解読
レジスタと、 前記格納状態に基づいて、前記命令バッファに格納され
たコードを前記解読レジスタに取り込むよう前記命令バ
ッファを制御すると共に前記格納状態を更新する制御手
段と、 前記解読器による解読結果に基づいて、次に新たに前記
解読レジスタに転送すべきコードの語長がハーフワード
であるか1ワードであるかを判断する第1の判断手段
と、 前記第1の判断手段においてハーフワードと判断された
場合、前記下位側解読レジスタに格納されたコードを前
記上位側解読レジスタに転送するともに、前記命令バッ
ファに格納された次に転送すべきハーフワードのコード
を前記下位側解読レジスタに転送する選択手段とを備え
ることを特徴とする請求項2記載のマイクロプロセッ
サ。5. The microprocessor further comprises : an instruction buffer for holding prefetched instructions; storage means for storing a storage state of instructions in the instruction buffer in halfword units; An upper-side decoding register and a lower-side decoding register that divide and hold a code by half words, and, based on the storage state, control the instruction buffer so as to take in the code stored in the instruction buffer into the decoding register. Control means for updating the storage state; and determining whether the word length of a code to be newly transferred to the decoding register is half word or one word based on a decoding result by the decoding unit. And a lower-order decryption register when the first determination means determines that the word is a halfword. Selecting means for transferring the stored code to the upper decoding register and transferring the halfword code to be transferred next stored in the instruction buffer to the lower decoding register. The microprocessor according to claim 2.
た1ワードのコードを保持する第1レジスタと、その直
前にフェッチした1ワードのコードを保持する第2レジ
スタとからなり、 前記第1のレジスタは、1ワードのコードをハーフワー
ドずつ分割して保持する上位側第1レジスタと下位側第
1レジスタとからなり、 前記第2のレジスタは、1ワードのコードをハーフワー
ドずつ分割して保持する上位側第2レジスタと下位側第
2レジスタとからなり、 前記選択手段は、少なくとも前記上位側第2レジスタと
前記下位側第2レジスタと前記下位側解読レジスタとか
ら選択した1つのレジスタに保持されているコードを前
記上位側解読レジスタに転送する上位側選択手段と、少
なくとも前記下位側第1レジスタと前記上位側第2レジ
スタと前記下位側第2レジスタとから選択した1つのレ
ジスタに保持されているコードを前記下位側解読レジス
タに転送する下位側選択手段とからなり、 前記記憶手段は、前記上位側第2レジスタ及び前記下位
側第2レジスタのいずれにもコードが保持されていない
第1の状態と、前記上位側第2レジスタにはコードが保
持されているが前記下位側第2レジスタにはコードが保
持されていない第2の状態と、前記上位側第2レジスタ
及び前記下位側第2レジスタにコードが保持されている
第3の状態のいずれかの格納状態を記憶することを特徴
とする請求項5記載のマイクロプロセッサ。6. The instruction buffer comprises : a first register for holding a code of the most recently fetched one word; and a second register for holding a code of a one word fetched immediately before the first register. Consists of an upper first register and a lower first register that hold a one-word code in half-word units, and the second register holds the one-word code in half-word units. An upper second register and a lower second register; and the selection means is held in at least one register selected from the upper second register, the lower second register, and the lower decoding register. Upper-side selection means for transferring a code to the upper-side decoding register; and at least the lower-side first register and the upper-side second register. And lower-order selecting means for transferring a code held in one register selected from the lower-order second register to the lower-order decoding register. The storage means includes the upper-side second register and the lower-order register. A first state in which no code is held in any of the second side registers, and a first state in which a code is held in the upper second register but no code is held in the lower second register. 6. The microprocessor according to claim 5, wherein a state stored in any one of a second state and a third state in which a code is held in the upper second register and the lower second register is stored. .
れている状態が第2の状態であり、かつ前記第1の判断
手段により次に解読すべきコードの語長が1ワードであ
ると判断された場合には、前記上位側選択手段が前記上
位側第2レジスタに保持されているコードを前記上位側
解読レジスタに転送し、前記下位側選択手段が前記下位
側第1レジスタに保持されているコードを前記下位側解
読レジスタに転送するよう前記選択手段を制御すること
を特徴とする請求項6記載のマイクロプロセッサ。 7. The control means determines that the state stored in the storage means is a second state and the word length of a code to be decoded next by the first determination means is one word. If it is determined, the upper-side selecting means transfers the code held in the upper-side second register to the upper-side decoding register, and the lower-side selecting means holds the code held in the lower-side first register. 7. The microprocessor according to claim 6, wherein said selection means is controlled so as to transfer a code to said lower decoding register.
れている状態が第3の状態であり、かつ前記第1の判断
手段により次に解読すべきコードの語長がハーフワード
であると判断された場合には、前記上位側選択手段が前
記下位側解読レジスタに保持されているコードを前記上
位側解読レジスタに転送し、前記下位側選択手段が前記
下位側第2レジスタに保持されているコードを前記下位
側解読レジスタに転送するよう前記選択手段を制御する
と共に、前記記憶手段に記憶する状態を第2の状態に更
新することを特徴とする請求項6記載のマイクロプロセ
ッサ。 Wherein said control means state stored in said storage means is a third state, and when the word length of the code to be deciphered in the following by the first determination means is a halfword When it is determined, the upper-side selection means transfers the code held in the lower-side decoding register to the upper-side decoding register, and the lower-side selection means is held in the lower-side second register. 7. The microprocessor according to claim 6, wherein the control means controls the selection means so as to transfer the stored code to the lower decoding register, and updates a state stored in the storage means to a second state.
れている状態が第2の状態であり、かつ前記第1の判断
手段により次に解読すべきコードの語長がハーフワード
であると判断された場合には、前記上位側選択手段が前
記下位側解読レジスタに保持されているコードを前記上
位側解読レジスタに転送し、前記下位側選択手段が前記
上位側第2レジスタに保持されているコードを前記下位
側解読レジスタに転送するよう前記選択手段を制御する
と共に、前記記憶手段に記憶する状態を第3の状態に更
新することを特徴とする請求項6記載のマイクロプロセ
ッサ。 9. The control means determines that the state stored in the storage means is a second state and the word length of a code to be decoded next by the first determination means is a half word. If it is determined, the upper-side selection means transfers the code held in the lower-side decoding register to the upper-side decoding register, and the lower-side selection means is held in the upper-side second register. 7. The microprocessor according to claim 6, wherein the control means controls the selection means so as to transfer the stored code to the lower decoding register, and updates a state stored in the storage means to a third state.
読結果とに基づいて、前記解読器によって解読された命
令がハーフワードで終了するメモリ上の位置に置かれて
いたサブルーチン分岐命令であるかどうかを判断する第
2の判断手段を備え、 前記実行手段は、前記命令がハーフワードで終了するメ
モリ上の位置に置かれていたサブルーチン分岐命令であ
ると判断された場合には、その位置に該当するメモリ番
地にハーフワードのコードに相当する番地を加算したメ
モリ番地をサブルーチンからの戻り番地とみなしてサブ
ルーチンへの分岐処理を実行することを特徴とする請求
項4記載のマイクロプロセッサ。 Wherein said processor is further based on the result of decoding by the decoder and stored stored state in the storage means, location in memory where the instruction is decoded by the decoder is terminated halfword Second determining means for determining whether or not the instruction is a subroutine branch instruction which has been placed in the memory. The execution means is a subroutine branch instruction which has been placed in a memory where the instruction ends in a halfword. When it is determined that a memory address obtained by adding an address corresponding to a halfword code to a memory address corresponding to the position is regarded as a return address from the subroutine, branch processing to the subroutine is executed. The microprocessor according to claim 4, wherein
ァと、 コード化された命令を1ワードずつ解読する解読器と、 前記解読器で解読する1ワードのコードをハーフワード
ずつ分割して保持する上位側解読レジスタと下位側解読
レジスタと、 前記解読器による解読結果に基づいて、次に新たに前記
解読レジスタに転送すべきコードの語長がハーフワード
であるか1ワードであるかを判断する第1の判断手段
と、 前記第1の判断手段においてハーフワードと判断された
場合、前記下位側解読レジスタに格納されたコードを前
記上位側解読レジスタに転送するともに、前記命令バッ
ファに格納された次に転送すべきハーフワードのコード
を前記下位側解読レジスタに転送する選択手段とを備え
ることを特徴とするマイクロプロセッサ。 11. An instruction buffer for holding a pre-read instruction, a decoder for decoding a coded instruction one word at a time, and a high-order part for holding a one-word code to be decoded by the decoder in half-word units. A side decoding register, a lower side decoding register, and a second determining unit that determines whether the word length of a code to be newly transferred to the decoding register is a half word or a single word based on a result of decoding by the decoder. When the first determining means determines that the code is a half word, the code stored in the lower decoding register is transferred to the upper decoding register, and the next code stored in the instruction buffer is transferred. Selecting means for transferring a half-word code to be transferred to the lower decoding register.
Priority Applications (10)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP13328195A JP3199603B2 (en) | 1995-05-31 | 1995-05-31 | Code size reduction microprocessor |
US08/643,947 US5966514A (en) | 1995-05-31 | 1996-05-07 | Microprocessor for supporting reduction of program codes in size |
KR1019960015261A KR100436015B1 (en) | 1995-05-31 | 1996-05-09 | A microprocessor that supports the program's code size reduction |
EP01111215A EP1143333B1 (en) | 1995-05-31 | 1996-05-30 | Microprocessor for supporting reduction of program codes in size |
DE69630416T DE69630416T2 (en) | 1995-05-31 | 1996-05-30 | Microprocessor for executing commands with variable lengths |
EP96303914A EP0745932B1 (en) | 1995-05-31 | 1996-05-30 | Microprocessor supporting variable length instruction execution |
DE69632970T DE69632970T2 (en) | 1995-05-31 | 1996-05-30 | Microprocessor with reduced program codes |
CNB021574936A CN1286004C (en) | 1995-05-31 | 1996-05-31 | Microprocessor for supporting program code length reduction |
CN96107762A CN1114153C (en) | 1995-05-31 | 1996-05-31 | Microprocessor for supporting reduction of program codes in size |
US09/226,791 US6253305B1 (en) | 1995-05-31 | 1999-01-07 | Microprocessor for supporting reduction of program codes in size |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP13328195A JP3199603B2 (en) | 1995-05-31 | 1995-05-31 | Code size reduction microprocessor |
Publications (2)
Publication Number | Publication Date |
---|---|
JPH08328850A JPH08328850A (en) | 1996-12-13 |
JP3199603B2 true JP3199603B2 (en) | 2001-08-20 |
Family
ID=15100980
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP13328195A Expired - Lifetime JP3199603B2 (en) | 1995-05-31 | 1995-05-31 | Code size reduction microprocessor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP3199603B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100379837B1 (en) * | 2000-06-30 | 2003-04-11 | 주식회사 에이디칩스 | Extended instruction folding system |
-
1995
- 1995-05-31 JP JP13328195A patent/JP3199603B2/en not_active Expired - Lifetime
Also Published As
Publication number | Publication date |
---|---|
JPH08328850A (en) | 1996-12-13 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US6405302B1 (en) | Microcomputer | |
KR100327777B1 (en) | Data processing device using multiple instruction sets | |
US5809306A (en) | Variable address length compiler and processor improved in address management | |
JP2816248B2 (en) | Data processor | |
JP3203401B2 (en) | Data processing device | |
US5966514A (en) | Microprocessor for supporting reduction of program codes in size | |
US6631459B1 (en) | Extended instruction word folding apparatus | |
JPH07120278B2 (en) | Data processing device | |
JP2003044273A (en) | Data processor and data processing method | |
US20070101101A1 (en) | Microprocessor | |
JP3030297B2 (en) | Computer system | |
US20020116599A1 (en) | Data processing apparatus | |
US6209080B1 (en) | Constant reconstruction processor that supports reductions in code size and processing time | |
JPH08212075A (en) | Information processor | |
JP3199603B2 (en) | Code size reduction microprocessor | |
JP3504355B2 (en) | Processor | |
JPH0769806B2 (en) | Data processing device | |
JP3901670B2 (en) | Data processing device | |
JP3030298B2 (en) | Computer system | |
US5463747A (en) | Microprogram data processor processing operand address calculation and instruction execution with common hardware | |
JP3472504B2 (en) | Command decoding method, command decoding device and data processing device | |
JP2004005738A5 (en) | ||
JP3199604B2 (en) | Processor | |
US20060101248A1 (en) | Method and programmable unit for bit field shifting | |
JPH117388A (en) | Processor |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20080615 Year of fee payment: 7 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090615 Year of fee payment: 8 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100615 Year of fee payment: 9 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100615 Year of fee payment: 9 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110615 Year of fee payment: 10 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20120615 Year of fee payment: 11 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20120615 Year of fee payment: 11 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130615 Year of fee payment: 12 |
|
EXPY | Cancellation because of completion of term |