JPH05120005A - Processor having repeat instruction of preceding instruction - Google Patents

Processor having repeat instruction of preceding instruction

Info

Publication number
JPH05120005A
JPH05120005A JP28023591A JP28023591A JPH05120005A JP H05120005 A JPH05120005 A JP H05120005A JP 28023591 A JP28023591 A JP 28023591A JP 28023591 A JP28023591 A JP 28023591A JP H05120005 A JPH05120005 A JP H05120005A
Authority
JP
Japan
Prior art keywords
instruction
data
output
repeat
decoder
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.)
Withdrawn
Application number
JP28023591A
Other languages
Japanese (ja)
Inventor
Seiji Kawamura
誠司 川村
Yukio Endo
幸雄 遠藤
Norikazu Nakamura
則和 中村
Hiroki Ichimura
宏樹 市村
Tatsuya Nagasawa
達也 長沢
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.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP28023591A priority Critical patent/JPH05120005A/en
Publication of JPH05120005A publication Critical patent/JPH05120005A/en
Withdrawn legal-status Critical Current

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02EREDUCTION OF GREENHOUSE GAS [GHG] EMISSIONS, RELATED TO ENERGY GENERATION, TRANSMISSION OR DISTRIBUTION
    • Y02E50/00Technologies for the production of fuel of non-fossil origin
    • Y02E50/10Biofuels, e.g. bio-diesel
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02EREDUCTION OF GREENHOUSE GAS [GHG] EMISSIONS, RELATED TO ENERGY GENERATION, TRANSMISSION OR DISTRIBUTION
    • Y02E50/00Technologies for the production of fuel of non-fossil origin
    • Y02E50/30Fuel from waste, e.g. synthetic alcohol or diesel

Abstract

PURPOSE:To provide a processor having the repeat instruction of a preceding instruction, which can be executed without inserting a wasteful cycle at the time of operating the operating repeat instruction. CONSTITUTION:A processor having a decoder 700 inputting and decoding instruction data and outputting it, and a storage part 100 inputting and storing the output of the decoder 700 is provided with a control part 180 outputting a control signal for repeatedly outputting prescribed instruction data which is former than n-th data for the prescribed number of times when the decoder 700 decodes that n-th instruction data is the repeat instruction. When the decoder 700 decodes that n-th instruction data is the repeat instruction, the storage part 100 substitutes n-th instruction data with prescribed instruction data which is former than n-th data, and repeatedly outputs prescribed instruction data former as than n-th data for prescribed number of times.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、前命令の繰り返し(リ
ピート)命令をもつプロセッサに関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a processor having a repeat instruction of a previous instruction.

【0002】1命令/クロックサイクルで動作するプロ
セッサにおいて、同一命令を連続して実行する場合、一
般に、その命令を繰り返し回数分記述する代わりに命令
メモリの節約の意味もあり、命令を指定した回数だけ繰
り返すリピート命令をサポートすることが行われる。
In a processor operating in one instruction / clock cycle, when the same instruction is executed continuously, generally, there is a meaning of saving the instruction memory instead of describing the instruction by the number of times of repetition. Supports repeat instructions that only repeat.

【0003】この場合、リピート命令の動作時に無駄な
サイクルを挿入することなく実行出来るプロセッサが要
望されている。
In this case, there is a demand for a processor that can execute a repeat instruction without inserting a wasteful cycle.

【0004】[0004]

【従来の技術】図6は従来例の回路の構成を示すブロッ
ク図である。図7は従来例の動作を説明するための図で
ある。
2. Description of the Related Art FIG. 6 is a block diagram showing the configuration of a conventional circuit. FIG. 7 is a diagram for explaining the operation of the conventional example.

【0005】図6において、1はプログラムカウンタ
(以下PCと称する)3の出力を入力するごとに+1加
算して出力する加算器であり、通常は選択部(以下SE
Lと称する)2で、加算器1の出力(カウント数)を選
択してPC3に加えてPC3で一時記憶した後、このカ
ウント数を命令メモリ4のアドレスを示す信号として出
力する。命令メモリ4で、PC3からのアドレス信号に
よりこのアドレスに記憶されているデータを読み出して
出力する。
In FIG. 6, reference numeral 1 denotes an adder for adding +1 each time the output of a program counter (hereinafter referred to as PC) 3 is input, and outputting the same.
In (2), the output (count number) of the adder 1 is selected and temporarily stored in the PC 3 in addition to the PC 3, and then the count number is output as a signal indicating the address of the instruction memory 4. In the instruction memory 4, the data stored at this address is read and output by the address signal from the PC 3.

【0006】SEL5では、通常は前述した命令メモリ
4から入力したデータを選択して出力してインストラク
ション・レジスタ(以下IRと称する)6に加える。I
R6で、通常は命令メモリ4からSEL5を介して入力
したデータを一時記憶する。そして、デコーダ7で、I
R6に一時記憶したデータを読み出して入力しこのデー
タの内容を解読する。
In the SEL 5, normally, the data input from the above-mentioned instruction memory 4 is selected and output and added to the instruction register (hereinafter referred to as IR) 6. I
At R6, the data normally input from the instruction memory 4 via the SEL 5 is temporarily stored. Then, in the decoder 7, I
The data temporarily stored in R6 is read and input, and the content of this data is decoded.

【0007】IR10では、通常はデコーダ7で解読した
内容(データ)を読み出してSEL9を介して入力して
一時記憶する。そして、このIR10に一時記憶したデー
タを読み出して後段の回路、例えばゲート制御部(図示
しない)等に実行命令として送出する。
In the IR 10, normally, the contents (data) decoded by the decoder 7 are read out, input through the SEL 9 and temporarily stored. Then, the data temporarily stored in the IR 10 is read out and sent as an execution command to a circuit in the subsequent stage, for example, a gate control unit (not shown).

【0008】今、デコーダ7で、図7に示すようにPC
3のカウント数がnに対応するデータ(n)がリピート
命令で、リピートカウンタ(以下RPCと称する、図示
しない)で指示する数、例えば3回(n+1)の命令を
繰り返すことを解読した時、デコーダ7からリピート命
令(REP)を出力して、SEL2、SEL5及びSE
L9に加える。
Now, in the decoder 7, as shown in FIG.
When the data (n) corresponding to the count number of 3 is n is a repeat instruction and the number indicated by a repeat counter (hereinafter referred to as RPC, not shown), for example, decoding of repeating three (n + 1) instructions is decoded, The repeat command (REP) is output from the decoder 7, and SEL2, SEL5 and SE are output.
Add to L9.

【0009】この時PC3ではn+2のクロックサイク
ルであり、SEL2でデコーダ7からリピート命令(R
EP)を入力するとSEL2の入力を(a) 側に切り替え
て、n+2の段階で一旦とめてPC3の出力が先に進ま
ないようにする。即ち、PC3の出力(カウント数)を
SEL2を介してフィードバックして再びPC3に加
え、このフィードバック動作をリピート命令(REP)
が終わるまで(今の場合、例えば3回)繰り返す。これ
を図7(1) に示す。
At this time, the clock cycle is n + 2 in PC3, and the repeat instruction (R
When (EP) is input, the input of SEL2 is switched to the (a) side, and is temporarily stopped at the stage of n + 2 so that the output of PC3 does not proceed. That is, the output (count number) of PC3 is fed back via SEL2 and added to PC3 again, and this feedback operation is repeated by a repeat command (REP).
Repeat until the end (in this case, for example, 3 times). This is shown in FIG. 7 (1).

【0010】SEL5でも同様にSEL5の入力を(a)
側に切り替えて、IR6の出力の(n+1)のデータを
SEL5を介してフィードバックして再びIR6に加
え、(n+1)のデータを(今の場合)3回繰り返し出
力するようにする。これを図7(2) に示す。
Similarly for SEL5, input SEL5 (a)
By switching to the side, the (n + 1) data output from the IR6 is fed back through the SEL5, added to the IR6 again, and the (n + 1) data is output three times (in this case) repeatedly. This is shown in FIG. 7 (2).

【0011】この時IR10では(n)のリピート命令
(REP)を一時記憶しており、この(n)のリピート
命令(REP)を後段の回路(図示しない)に送出して
も実行する内容がないため、SEL9では(b)側に切り
替えて無処理(‘NOP’)8を示す信号をIR10に加え
る。そして、次の3連続するクロックサイクルで(n+
1)のデータを3回繰り返して入力し一時記憶した後、
後段の回路例えばゲート制御部(図示しない)等に送出
してプログラム命令を実行するようにする。(n+1)
のデータが3回連続した後は、通常の命令データに戻り
(n+2)、(n+3)、・・・のデータを入/出力す
る。
At this time, the IR10 temporarily stores the repeat command (REP) of (n), and even if the repeat command (REP) of (n) is sent to the circuit (not shown) in the subsequent stage, the content to be executed remains. Therefore, the SEL 9 is switched to the (b) side and a signal indicating no processing ('NOP') 8 is added to the IR 10. Then, in the next three consecutive clock cycles, (n +
Repeatedly input the data of 1) three times and temporarily store it.
The program command is sent to a circuit in the subsequent stage, for example, a gate control unit (not shown) or the like to execute the program command. (N + 1)
After the data of No. has been repeated three times, the normal command data is returned and the data of (n + 2), (n + 3), ... Are input / output.

【0012】一方、RPC(図示しない)では、デコー
ダ7で(n+1)のデータを解読して出力するごとにカ
ウント数から1を減じ、カウント数が1になった時
(n)のリピート命令(REP)の出力を停止する。こ
のリピート命令(REP)の出力の停止によりSEL
2、5では入力を(a)側から(b)側に切り替え、又、SE
L9では(b) 側から(a) 側に切り替えて、通常のデータ
の転送を行うようにする。これを図7(3) 及び(4)に示
す。
On the other hand, in the RPC (not shown), each time the decoder 7 decodes (n + 1) data and outputs it, the count number is decremented by 1, and when the count number becomes 1, the repeat instruction (n) ( REP) output is stopped. When the output of this repeat command (REP) is stopped, SEL
In 2 and 5, the input is switched from (a) side to (b) side, and SE
At L9, the (b) side is switched to the (a) side so that normal data transfer is performed. This is shown in FIGS. 7 (3) and 7 (4).

【0013】[0013]

【発明が解決しようとする課題】しかしながら上述した
回路においては、デコーダ7でリピート命令を解読した
時には、リピート命令の次の命令を繰り返すため命令実
行時にはリピート命令は無処理(NOP)となり、無駄
な実行サイクルが出来てしまうという問題点があった。
However, in the circuit described above, when the decoder 7 decodes the repeat instruction, the instruction following the repeat instruction is repeated, so that the repeat instruction is not processed (NOP) at the time of executing the instruction, which is wasteful. There was a problem that an execution cycle could be created.

【0014】したがって本発明の目的は、リピート命令
の動作時に無駄なサイクルを挿入することなく実行出来
る前命令のリピート命令をもつプロセッサを提供するこ
とにある。
Therefore, an object of the present invention is to provide a processor having a repeat instruction of a previous instruction which can be executed without inserting a wasteful cycle when the repeat instruction operates.

【0015】[0015]

【課題を解決するための手段】上記問題点は図1に示す
回路の構成によって解決される。即ち図1において、命
令データを入力して解読した後出力するデコーダ700
と、デコーダ700 の出力を入力して記憶する記憶部100
とを有するプロセッサにおいて、180 は、デコーダ700
でn番目の命令データが繰り返しを指示する命令である
ことを解読した時、n番目より前の所定の命令データを
記憶部100 から所定回数だけ繰り返し出力するための制
御信号を出力する制御部である。
The above problems can be solved by the structure of the circuit shown in FIG. That is, in FIG. 1, a decoder 700 that inputs command data, decodes it, and then outputs it
And the storage unit 100 that receives and stores the output of the decoder 700.
In the processor having and 180 is a decoder 700
When it is decoded that the nth instruction data is an instruction to repeat, the control unit that outputs a control signal for repeatedly outputting the predetermined instruction data before the nth from the storage unit 100 a predetermined number of times. is there.

【0016】そして、デコーダ700 でn番目の命令デー
タが繰り返しを指示する命令であることを解読した時、
制御部180 の出力の制御信号により、記憶部100 におい
てn番目の命令データをn番目より前の所定の命令デー
タと置き換えて、n番目より前の所定の命令データを所
定回数だけ繰り返し出力するように構成する。
When the decoder 700 decodes that the n-th instruction data is an instruction to repeat,
The control signal output from the control unit 180 replaces the nth instruction data in the storage unit 100 with the predetermined instruction data before the nth, and repeatedly outputs the predetermined instruction data before the nth a predetermined number of times. To configure.

【0017】[0017]

【作用】図1において、デコーダ700 で、例えばn番目
の命令データが(n−1)番目の命令データを繰り返す
ことを指示する繰り返し命令であることを解読した時、
制御部180 の出力の制御信号により、記憶部100 におい
て、n番目の命令データを(n−1)番目の所定の命令
データと置き換えて、n番目のクロックサイクルで(n
−1)番目の命令データを記憶部100 から読み出して出
力する。
In FIG. 1, when the decoder 700 decodes that the nth instruction data is a repetitive instruction instructing to repeat the (n-1) th instruction data,
The control signal output from the control unit 180 replaces the n-th instruction data with the (n-1) -th predetermined instruction data in the storage unit 100, and (n
The -1) th instruction data is read from the storage unit 100 and output.

【0018】そして、繰り返しの指示回数がm回の時、
残りの(m−1)回前記(n−1)番目の命令データを
記憶部100 から読み出して出力する。この結果、繰り返
し命令の動作時に無駄なサイクルを挿入することなく命
令データを実行することが出来る。
When the number of times of repeat instruction is m,
The remaining (m-1) th instruction data is read from the storage unit 100 and output. As a result, the instruction data can be executed without inserting a wasteful cycle during the operation of the repeated instruction.

【0019】[0019]

【実施例】図2は本発明の実施例の回路の構成を示すブ
ロック図である。図3は実施例のSEL制御回路の構成
を示すブロック図である。
FIG. 2 is a block diagram showing a circuit configuration of an embodiment of the present invention. FIG. 3 is a block diagram showing the configuration of the SEL control circuit of the embodiment.

【0020】図4は実施例の動作を説明するための図
(その1)である。図5は実施例の動作を説明するため
の図(その2)である。全図を通じて同一符号は同一対
象物を示す。
FIG. 4 is a view (No. 1) for explaining the operation of the embodiment. FIG. 5 is a diagram (part 2) for explaining the operation of the embodiment. The same reference numerals denote the same objects throughout the drawings.

【0021】図2において、デコーダ7で繰り返し(リ
ピート)命令以外のデータを解読した時には回路動作が
従来の技術で説明したのと同じであるため、その説明を
省略する。
In FIG. 2, when the decoder 7 decodes data other than the repeat instruction, the circuit operation is the same as that described in the prior art, and therefore the description thereof is omitted.

【0022】次に、デコーダ7でn番目のデータ、即ち
データ(n)がリピート命令であることを解読した時、
デコーダ7からリピート命令(REP)を出力して、図
3に示すSEL制御回路18のSRフリップフロップ回路
(以下SR−FFと称する)16のセット端子(S)に加
える。又、リピート指示回数が例えば3であるとする
と、RPC13にこのリピート回数3を設定する。
Next, when the decoder 7 decodes that the nth data, that is, the data (n) is a repeat instruction,
A repeat command (REP) is output from the decoder 7 and applied to the set terminal (S) of the SR flip-flop circuit (hereinafter referred to as SR-FF) 16 of the SEL control circuit 18 shown in FIG. If the repeat instruction count is 3, for example, this repeat count 3 is set in the RPC 13.

【0023】そして、図3に示す比較部15で、RPC13
の出力と数値‘1’とを比較する。RPC13の出力は
(今の場合)最初‘3’であり両者が等しくないため、
比較部15からは‘0’を出力する。(RPC13の出力が
‘1’になった時両者は等しくなって、比較部15から
‘1' を出力する)。(この出力をCOMPと称する)。こ
の比較部15の出力(COMP)を後述するSEL制御部17に
加えるとともに、前述したSR−FF16のリセット
(R)端子に加える。
Then, in the comparing section 15 shown in FIG.
Compare the output of and the number '1'. Since the output of RPC13 is (in this case) first "3" and they are not equal,
The comparison unit 15 outputs "0". (When the output of the RPC 13 becomes "1", they become equal, and the comparing unit 15 outputs "1"). (This output is called COMP). The output (COMP) of the comparison section 15 is added to the SEL control section 17 which will be described later, and is also added to the reset (R) terminal of the SR-FF 16 described above.

【0024】すると、SR−FF16からは出力(EXREP
と称する)として‘1’を出力する(表1参照)。前述
した比較部15の出力(COMP) とSR−FF16の出力(EX
REP)とをSEL制御部17に加え、SEL制御部17で表2
の〜の(a) 、(b) 又は(a) 〜(c)に示すような論理
演算を行う。SEL制御部17で論理演算して得られた出
力の、、及びをそれぞれ、SEL2、SEL
5、SEL9及びSEL12に加える。
Then, the output (EXREP
(1) is output (see Table 1). The output of the comparator 15 (COMP) and the output of the SR-FF16 (EX
REP) is added to the SEL control unit 17, and the SEL control unit 17
The logical operation as shown in (a), (b) or (a) to (c) of is performed. SEL2, SEL of the outputs obtained by the logical operation in the SEL control unit 17
5, add to SEL9 and SEL12.

【0025】[0025]

【表1】 [Table 1]

【0026】[0026]

【表2】 [Table 2]

【0027】表2において、例えばの(a) 、即ちEXRE
P ・(Inv)COMP の論理演算を行う時、前述したようにEX
REP が‘1’、COMPは‘0’のため、COMPを反転した(I
nv)COMP は‘1’となり、両者の論理積であるEXREP ・
(Inv)COMP =‘1’となる。又、の(b) の (Inv){EX
REP・(Inv)COMP }は上記の(a) を反転したものであ
るため、‘0’となる。
In Table 2, for example (a), that is, EXRE
When performing the logical operation of P ・ (Inv) COMP, EX
REP is '1' and COMP is '0', so COMP is reversed (I
nv) COMP becomes '1', which is the logical product of both, EXREP
(Inv) COMP = '1'. Also, in (b), (Inv) {EX
REP. (Inv) COMP} is an inversion of the above (a), and therefore becomes “0”.

【0028】〜の(a) 、(b) 又は(a) 、(b)、(c)
のなかで‘1’となるのはそれぞれ1つだけであり、こ
の‘1’となる演算結果に対応するSELの入力を選択
するように設定してある。前述したの場合、(a) が
‘1’、(b) が‘0’のため、図2に示すSEL2の
(a) 入力を切替え選択する。この結果、PC3では次の
クロックサイクルで、SEL2の(a) 入力 を経由する
フィードバックループにより(n+2)のカウント数を
出力する。これを図4の(1) に示す。
(A), (b) or (a), (b), (c) of
Among these, only one is "1", and the input of SEL corresponding to the operation result of "1" is set to be selected. In the case described above, since (a) is "1" and (b) is "0", the SEL2 shown in FIG.
(a) Select the input by switching. As a result, in the next clock cycle, the PC3 outputs the count number of (n + 2) by the feedback loop via the (a) input of the SEL2. This is shown in (1) of FIG.

【0029】又、表2のの(a) 、(b) は、前述した
の(a) 、(b)と同じ論理演算式で設定してあるため、
SEL5でも(a)入力を切替え選択し、IR6では次の
クロックサイクルで、SEL5の(a) 入力を経由するフ
ィードバックループにより(n+1)のデータを出力す
る。これを図4の(2) に示す。
Further, since (a) and (b) in Table 2 are set by the same logical operation formulas as (a) and (b) described above,
The SEL5 also selects and selects the (a) input, and the IR6 outputs (n + 1) data by the feedback loop via the (a) input of the SEL5 in the next clock cycle. This is shown in (2) of FIG.

【0030】次に表2のの場合、(a) は前述したの
(a) と同じ論理演算式で設定してあるため、(a) が
‘1’となりSEL9でも(a) 入力を切替え選択する。
そして、IR10では、例えば命令データ(n)の1クロ
ックサイクル前の命令データ、即ち(n−1)の命令デ
ータを読み出して出力するとともに、SEL9の(a)入
力を経由するフィードバックループにより(n−1)の
データをIR10に再入力して記憶する。そして、次のク
ロックサイルクでも、(n−1)の命令データを読み出
して出力する。これを図4の(3) に示す。尚、IR10の
出力を後段のゲート制御部(図示しない)等の回路に送
出する。
Next, in the case of Table 2, (a) is as described above.
Since it is set by the same logical operation formula as (a), (a) becomes '1' and SEL9 also selects (a) input by switching.
Then, in the IR10, for example, the instruction data of one clock cycle before the instruction data (n), that is, the instruction data of (n-1) is read and output, and the feedback loop via the (a) input of SEL9 Re-input the data of -1) into IR10 and store it. Then, even in the next clock cycle, the (n-1) instruction data is read and output. This is shown in (3) of FIG. The output of IR10 is sent to a circuit such as a gate control unit (not shown) in the subsequent stage.

【0031】尚、参考のため、表2のの(b) 、即ち(I
nv) {EXREP ・(Inv)COMP +REP ・COMP}の論理演算を
行うと、今の場合(RPC=3)、表1からEXREP は
‘1’、COMPは‘0’、又、REP はデコーダ7が繰り返
し命令を解読した最初のクロックサイクルだけ‘1’と
なるため、(Inv) {EXREP ・(Inv)COMP +REP ・COMP}
は‘0’となる。又、表2のの(c) 、即ちREP ・COMP
は同様にして‘0’となる。
For reference, (b) in Table 2, that is, (I
nv) {EXREP. (Inv) COMP + REP.COMP} logical operation, in this case (RPC = 3), from Table 1, EXREP is '1', COMP is '0', and REP is decoder 7 Becomes "1" only for the first clock cycle when the command repeatedly decodes (Inv) {EXREP ・ (Inv) COMP + REP ・ COMP}
Will be '0'. In addition, (c) in Table 2, that is, REP COMP
Similarly becomes "0".

【0032】次に、表1のの(a)、即ち(REP+EXREP)
・(Inv)(COMP)の論理演算を行うと、前述したようにEXR
EP は‘1’、COMPは‘0’のため、COMPを反転した(In
v)COMP は‘1’となる。又、REP はデコーダ7が繰り
返し命令を解読した最初のクロックサイクルだけ‘1’
となるのため、結局、(REP+EXREP)・(Inv)(COMP)=
‘1’となる。又、の(b) は上記の(a) を反転した
ものであるため‘0’となる。このの出力信号により
図3に示すSEL12は‘1’である(a) 入力を切替え選
択する。
Next, (a) in Table 1, that is, (REP + EXREP)
・ When the logical operation of (Inv) (COMP) is performed, the EXR
Since EP is "1" and COMP is "0", COMP is inverted (In
v) COMP becomes '1'. REP is '1' only for the first clock cycle when the decoder 7 decodes the repeated instruction.
Therefore, after all, (REP + EXREP) ・ (Inv) (COMP) =
It becomes "1". In addition, (b) of the above is "0" because it is the inversion of the above (a). With this output signal, the SEL 12 shown in FIG. 3 switches and selects (1) input which is "1".

【0033】この結果、RPC13の出力値(‘3')から
図3に示す減算器11で‘1’を減算した値(‘2')がS
EL12を介してRPC13に加えられるため、次のクロッ
クサイクルではRPC13からは‘2’を出力して比較器
15に加える。比較器15ではこの入力‘2’と予め設定し
た値‘1’を比較するが両者が等しくないため、比較器
15からは出力(COMP) として‘0’を出力してSR−F
F16のR端子に加える。SR−FF16ではCOMP‘0’を
入力したため、次のクロックサイクル(RPCの出力=
2)では(EXREP) として‘1’を出力する。(表1参
照)。
As a result, the value ('2') obtained by subtracting '1' from the output value ('3') of the RPC 13 by the subtracter 11 shown in FIG. 3 is S.
Since it is added to RPC13 via EL12, RPC13 outputs "2" in the next clock cycle and the comparator
Add to 15. The comparator 15 compares the input "2" with a preset value "1", but since the two are not equal, the comparator 15
SR-F outputs "0" as output (COMP) from 15
Add to the R terminal of F16. In the SR-FF16, since COMP'0 'is input, the next clock cycle (output of RPC =
In 2), "1" is output as (EXREP). (See Table 1).

【0034】上述したCOMP及びEXREP をSEL制御部17
に加え、SEL制御部17で前述したと同様にして表2の
〜の論理演算を行う。この場合、表1に示すように
RPC13の出力=2の時、COMP及びEXREP の値はRPC
13の出力=3の時と同じであるため、前述したRPC13
の出力=3の時と同様に〜はすべて(a)が‘1’と
なる。この結果、SEL2、5、9及び12は(a) 入力を
切替え選択する。
The above-mentioned COMP and EXREP are connected to the SEL control unit 17
In addition to the above, the SEL control unit 17 performs the logical operations of to in Table 2 in the same manner as described above. In this case, as shown in Table 1, when the output of RPC13 = 2, the values of COMP and EXREP are RPC.
Since the output of 13 is the same as when 3 = RPC13
In the same way as when the output of = 3, all of (a) are "1". As a result, SEL2, 5, 9, and 12 switch and select (a) input.

【0035】この結果、PC3はn+2のアドレス信号
を、IR6は(n+1)のデータを出力する。又、IR
10は(n−1)のデータを読み出して出力し、後段の回
路(図示しない)に加える(図4参照)。
As a result, the PC 3 outputs an n + 2 address signal and the IR 6 outputs (n + 1) data. Also, IR
10 reads (n-1) data and outputs it, and adds it to a circuit (not shown) in the subsequent stage (see FIG. 4).

【0036】次に、図3に示すSEL12は(a) 入力を切
替え選択しているため、次のクロックサイクルでは、R
PC13の出力(‘2')から減算器11で‘1’減じた値
(‘1’)がSEL12を介してRPC13に加えられ、この
値(‘1')をRPC13から比較部15に出力する。比較部1
5で、RPC13からの入力(‘1')と予め設定した値
‘1’とを比較し、両者が等しいため、COMPとして
‘1’を出力する。(表1参照)。
Next, in the SEL12 shown in FIG. 3, since (a) input is switched and selected, in the next clock cycle, R
Value obtained by subtracting "1" from subtracter 11 from the output ('2') of PC13
('1') is added to the RPC 13 via the SEL 12, and this value ('1') is output from the RPC 13 to the comparison unit 15. Comparison section 1
At 5, the input ('1') from the RPC 13 is compared with the preset value '1', and since they are equal, '1' is output as COMP. (See Table 1).

【0037】このCOMP出力とデコーダ7の出力(RE
P、RPC13の出力が‘2’及び‘1’の時にはREP
=‘0’となっている)とをSR−FF16に加えると、
表1に示すようにSR−FF16からはEXREP として
‘0’を出力する。このEXREP 値とCOMP値とをSEL制
御部17に加え、SEL制御部17で表2の〜に示す論
理演算を行う。
This COMP output and the output of the decoder 7 (RE
When the output of P and RPC13 is "2" and "1", REP
= '0') is added to SR-FF16,
As shown in Table 1, SR-FF16 outputs "0" as EXREP. The EXREP value and the COMP value are added to the SEL control unit 17, and the SEL control unit 17 performs the logical operation shown in Table 2 to.

【0038】表2において、の(a) 、即ちEXREP ・(I
nv)COMP は、上述したようにRPC13の出力=‘1’の
時EXREP は‘0’、COMPが‘1’のため(Inv)COMPは
‘0’となり、EXREP ・(Inv)COMP は‘0’となる。こ
のため、の(a) を反転した(b) 、即ち(Inv) {EXREP
・(Inv)COMP } は‘1’となる。
In Table 2, (a), that is, EXREP. (I
nv) COMP is "0" when the output of RPC13 = "1" as described above, and (Inv) COMP is "0" because COMP is "1", and EXREP ・ (Inv) COMP is "0". 'Becomes. Therefore, (a) is inverted to (b), that is, (Inv) {EXREP
・ (Inv) COMP} becomes '1'.

【0039】この結果、の信号により図2に示すSE
L2は(b) 入力を切替え選択して、通常の動作に戻る。
即ち、PC3の出力(n+2のアドレス信号)に加算器
1で‘1’を加算し、SEL2を介して入力した値(n
+3)を出力して命令メモリ4に加えて記憶する。(図
4の(1)参照)。
As a result, the SE signal shown in FIG.
L2 selects (b) input to switch to normal operation.
That is, the output (n + 2 address signal) of PC3 is added with "1" by the adder 1 and the value (n
+3) is output and stored in addition to the instruction memory 4. (See (1) in FIG. 4).

【0040】又、の(a) 、(b) はそれぞれ上述した
の(a) 、(b) と同じ論理演算式であるため、の(b) が
‘1’となり、このの信号により図2に示すSEL5
も(b) 入力を切替え選択して、通常の動作に戻る。即
ち、命令メモリ4に1クロックサイクル前に記憶してあ
った(n+2)のデータを読み出して、SEL5を介し
てIR6に加える。(図4の(2)参照)。
Since (a) and (b) in (1) and (b) are the same logical operation expressions as in (a) and (b), respectively, (b) becomes "1", and the signal of FIG. SEL5 shown in
Also (b) Selects the input by switching and returns to normal operation. That is, the (n + 2) data stored in the instruction memory 4 one clock cycle before is read and added to the IR 6 via the SEL 5. (See (2) in FIG. 4).

【0041】又、の(a) は上述したの(a) と同じで
あるため、(a) は‘0’となる。次に、の(b) 、即ち
(Inv) {EXREP ・(Inv)COMP +REP ・COMP}は、前述し
たようにEXREP とREP は‘0’、COMPは‘1’であるた
め、‘1’となる。この結果、の信号によりSEL9
は(b) 入力を切替え選択して通常の動作に戻る。即ち、
デコーダ7でリピート命令(n)の次の命令データ(n
+1)を解読して得られる出力を、SEL9を介してI
R10に入力して記憶する。そして、次のクロックサイク
ルで(n+1)の命令データを読み出して、後段の回路
(図示しない)に加え実行に移す。(図4の(3) 参
照)。
Since (a) in (a) is the same as (a) above, (a) becomes "0". Next, in (b), that is,
(Inv) {EXREP. (Inv) COMP + REP.COMP} is '1' because EXREP and REP are '0' and COMP is '1' as described above. As a result, SEL9
(B) Selects the input and returns to normal operation. That is,
In the decoder 7, the instruction data (n next to the repeat instruction (n)
The output obtained by decoding +1) is I through SEL9.
Input to R10 and memorize. Then, at the next clock cycle, (n + 1) instruction data is read out and added to the circuit (not shown) in the subsequent stage to be executed. (See (3) in Figure 4).

【0042】又、表2のの(a) 、即ち(REP+EXREP)・
(Inv)COMP は、前述したようにREPとEXREPは‘0’、CO
MPは‘1’のため、‘0’となる。このための(a)を
反転したの(b) は‘1’となる。このため、の信号
により図3に示すSEL12は(b) 入力を切替え選択し
て、通常の動作に戻る。
In addition, (a) in Table 2, that is, (REP + EXREP).
(Inv) COMP is "0" for REP and EXREP as described above, CO
Since MP is "1", it becomes "0". For this reason, (b) which is the reverse of (a) becomes '1'. Therefore, the SEL12 shown in FIG. 3 switches and selects the input (b) by the signal of and returns to the normal operation.

【0043】尚、上述したリピート命令により繰り返さ
れる命令データ(n−1)は、単一又は複数の命令デー
タのいずれであってもよい。この結果、リピート命令の
動作時に無駄なサイクルを挿入することなく命令データ
を実行することが出来、プロセッサにおいてより高速な
処理を行うことが可能となる。
The instruction data (n-1) repeated by the above-mentioned repeat instruction may be either a single instruction data or a plurality of instruction data. As a result, the instruction data can be executed without inserting a wasteful cycle during the operation of the repeat instruction, and the processor can perform higher-speed processing.

【0044】尚、図2に示すデコーダ7で、リピート命
令を解読しその繰り返し(指示)回数が1回の時には、
表2の〜の(a) 、即ちEXREP・(Inv)COMP は表1か
らEXREP が‘0’、COMPが‘1’のため、‘0’とな
る。このため、(a) を反転した、の(b) は‘1’と
なる。この結果、及びの信号によりSEL2及びS
EL5は(b) 入力を切替え選択して通常動作を行う。
When the decoder 7 shown in FIG. 2 decodes the repeat instruction and the number of repetitions (instructions) is one,
In Table 2 (a), that is, EXREP. (Inv) COMP is "0" because EXREP is "0" and COMP is "1" from Table 1. Therefore, (b) in which (a) is inverted becomes '1'. As a result, and the signals of and, SEL2 and S
EL5 performs the normal operation by (b) switching and selecting the input.

【0045】又、の(b) 、即ち(Inv) {EXREP ・(In
v)COMP +REP ・COMP}は、EXREPが‘0’、COMPが
‘1’、又デコーダ7がリピート命令を解読した最初の
クロックサイクルだけREP は‘1’となるため、‘0’
となる。の(c) 、即ちREP ・COMPは、‘1’となる。
この結果、の信号によりSEL9は(c) 入力を切替え
選択して、無処理(‘NOP’)8を表す信号をIR10
に加えるようにする。この場合には、IR10からは1ク
ロックサイクルだけ無処理(‘NOP’)の信号を出力
する。(図5参照)。
Further, in (b), that is, (Inv) {EXREP. (In
v) COMP + REP · COMP} is '0' because EXREP is '0', COMP is '1', and REP is '1' only in the first clock cycle when the decoder 7 decodes the repeat instruction.
Becomes (C), that is, REP / COMP becomes '1'.
As a result, the SEL 9 switches (c) the input by the signal of, and selects the signal representing the no processing ('NOP') 8 by IR10.
To be added to In this case, IR10 outputs a signal of no processing ('NOP') for one clock cycle. (See Figure 5).

【0046】尚、参考までに表2のの論理演算を行う
と、の(a) 、即ち(REP+EXREP)・(Inv)COMP は、前述
した値を用いると‘0’となる。したがって、の(a)
を反転したの(b) 、即ち(Inv) {(REP+EXREP)・(In
v)COMP }は‘1’となる。このため、の信号により
SEL12は(b) 入力を切替え選択して、引続き通常の動
作を行う。
For reference, when the logical operation of Table 2 is performed, (a), that is, (REP + EXREP). (Inv) COMP becomes "0" when the above-mentioned value is used. Therefore, of (a)
(B) that is the reverse of, that is, (Inv) {(REP + EXREP) ・ (In
v) COMP} becomes '1'. Therefore, the SEL 12 switches and selects the input (b) by the signal of, and continues the normal operation.

【0047】[0047]

【発明の効果】以上説明したように本発明によれば、繰
り返し命令の動作時に無駄なサイクルを挿入することな
く命令データを実行することが出来、プロセッサにおい
てより高速な処理を行うことが可能となる。
As described above, according to the present invention, it is possible to execute instruction data without inserting a wasteful cycle during the operation of a repetitive instruction, and it is possible to perform higher speed processing in a processor. Become.

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

【図1】は本発明の原理図、FIG. 1 is a principle diagram of the present invention,

【図2】は本発明の実施例の回路の構成を示すブロック
図、
FIG. 2 is a block diagram showing a circuit configuration of an embodiment of the present invention,

【図3】は実施例のSEL制御回路の構成を示すブロッ
ク図、
FIG. 3 is a block diagram showing a configuration of a SEL control circuit according to an embodiment,

【図4】は実施例の動作を説明するための図(その
1)、
FIG. 4 is a diagram (part 1) for explaining the operation of the embodiment;

【図5】は実施例の動作を説明するための図(その
2)、
FIG. 5 is a diagram (part 2) for explaining the operation of the embodiment;

【図6】は従来例の回路の構成を示すブロック図、FIG. 6 is a block diagram showing a circuit configuration of a conventional example,

【図7】は従来例の動作を説明するための図である。FIG. 7 is a diagram for explaining the operation of the conventional example.

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

100 は記憶部、 180 は制御部、 700はデコーダ を示す。 100 is a storage unit, 180 is a control unit, and 700 is a decoder.

───────────────────────────────────────────────────── フロントページの続き (72)発明者 市村 宏樹 栃木県小山市城東3丁目28番1号 富士通 デイジタル・テクノロジ株式会社内 (72)発明者 長沢 達也 栃木県小山市城東3丁目28番1号 富士通 デイジタル・テクノロジ株式会社内 ─────────────────────────────────────────────────── ─── Continuation of the front page (72) Hiroki Ichimura 3-28-1 Joto, Oyama-shi, Tochigi Prefecture Fujitsu Digital Technology Limited (72) Tatsuya Nagasawa 3-28-1 Joto, Oyama-shi, Tochigi Prefecture Issue within Fujitsu Digital Technology Limited

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 命令データを入力して解読した後出力す
るデコーダ(700)と、該デコーダ(700) の出力を入力し
て記憶する記憶部(100) とを有するプロセッサにおい
て、 該デコーダ(700) でn番目の命令データが繰り返しを指
示する命令であることを解読した時、該n番目より前の
所定の命令データを該記憶部(100) から所定回数だけ繰
り返し出力するための制御信号を出力する制御部(180)
を設け、 該デコーダ(700) で該n番目の命令データが繰り返しを
指示する命令であることを解読した時、該制御部(180)
の出力の制御信号により、該記憶部(100) において該n
番目の命令データを該n番目より前の所定の命令データ
と置き換えて、該n番目より前の所定の命令データを所
定回数だけ繰り返し出力するようにしたことを特徴とす
る前命令の繰り返し命令をもつプロセッサ。
1. A decoder having a decoder (700) for inputting and decoding instruction data and outputting the decoded data, and a storage section (100) for inputting and storing the output of the decoder (700). ), When decoding that the n-th instruction data is an instruction to repeat, it outputs a control signal for repeatedly outputting the predetermined instruction data before the n-th instruction from the storage unit (100) a predetermined number of times. Output control unit (180)
When the decoder (700) decodes that the n-th instruction data is an instruction to repeat, the control unit (180)
By the control signal of the output of
A repeat command of a previous command, characterized in that the predetermined command data before the n-th is replaced with the predetermined command data before the n-th, and the predetermined command data before the n-th is repeatedly output a predetermined number of times. A processor with.
JP28023591A 1991-10-28 1991-10-28 Processor having repeat instruction of preceding instruction Withdrawn JPH05120005A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP28023591A JPH05120005A (en) 1991-10-28 1991-10-28 Processor having repeat instruction of preceding instruction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP28023591A JPH05120005A (en) 1991-10-28 1991-10-28 Processor having repeat instruction of preceding instruction

Publications (1)

Publication Number Publication Date
JPH05120005A true JPH05120005A (en) 1993-05-18

Family

ID=17622187

Family Applications (1)

Application Number Title Priority Date Filing Date
JP28023591A Withdrawn JPH05120005A (en) 1991-10-28 1991-10-28 Processor having repeat instruction of preceding instruction

Country Status (1)

Country Link
JP (1) JPH05120005A (en)

Similar Documents

Publication Publication Date Title
JPS6351287B2 (en)
JP3237858B2 (en) Arithmetic unit
US5046040A (en) Microprogram control apparatus using don't care bits as part of address bits for common instructions and generating variable control bits
JPH05120005A (en) Processor having repeat instruction of preceding instruction
US5146479A (en) Up/down counter for counting binary data stored in flip flops
JP2906792B2 (en) Digital processor and control method thereof
JPH08166880A (en) Computer
JPS63153636A (en) Information processor
JPH0795269B2 (en) Instruction code decoding device
JP3117214B2 (en) Sequencer microprogram control method
JPS6260755B2 (en)
JP2812610B2 (en) Pipeline control method
JP3107595B2 (en) Memory access control device and memory access control method
JP2555882B2 (en) Signal processor
JPH0619700B2 (en) Arithmetic unit
JP2504974B2 (en) Sequencer high-speed processing method
JPH04251331A (en) Information processor
JPS6133721Y2 (en)
JPH01284926A (en) Instruction reading system for arithmetic unit
JPH06103337B2 (en) Algorithmic pattern generator circuit
JPH0659933U (en) Central processing unit
JPH1074190A (en) Parallel processor
KR19990065181A (en) Register control unit for microprocessors supporting multiple operating systems
JPH04155441A (en) Address generating circuit
JPS6198444A (en) Control memory system

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 19990107