JPH0336629A - Information processor - Google Patents
Information processorInfo
- Publication number
- JPH0336629A JPH0336629A JP17227989A JP17227989A JPH0336629A JP H0336629 A JPH0336629 A JP H0336629A JP 17227989 A JP17227989 A JP 17227989A JP 17227989 A JP17227989 A JP 17227989A JP H0336629 A JPH0336629 A JP H0336629A
- Authority
- JP
- Japan
- Prior art keywords
- stack
- signal
- output
- read
- circuit
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Landscapes
- Executing Machine-Instructions (AREA)
Abstract
Description
【発明の詳細な説明】
〔概要〕
本発明は、マイクロプロセッサ等の内部シーケンス制御
にマイクロ命令を使用する情報処理装置に係り、特にV
LSIにおいて使用されるマイクロプログラムのサブル
ーチン分岐機能を有するマイクロ制御装置に関し、
スタックが2個の場合にハードウェア量を低減し、制御
および構造が簡単で処理速度を向上させる情報処理装置
を提供することを目的とし、2個のスタックと、前記ス
タックを特定するスタックポインタと、を備えた情報処
理装置において、前記スタックポインタは、前記スタッ
クの書込信号または読出信号に応じて反転する1ビット
のレジスタを有し、前記書込信号または読出信号および
前記レジスタの値により書込指示信号または読出指示信
号を出力する指示信号出力手段を備えて構成する。[Detailed Description of the Invention] [Summary] The present invention relates to an information processing device that uses microinstructions for internal sequence control of a microprocessor, etc.
To provide an information processing device that reduces the amount of hardware when there are two stacks, has simple control and structure, and improves processing speed, regarding a microcontroller having a subroutine branching function of a microprogram used in an LSI. In an information processing device having two stacks and a stack pointer for specifying the stack, the stack pointer is a 1-bit register that is inverted according to a write signal or a read signal of the stack. and instruction signal output means for outputting a write instruction signal or a read instruction signal according to the write signal or read signal and the value of the register.
本発明は、マイクロプロセッサ等の内部シーケンス制御
にマイクロ命令を使用する情報処理装置に係り、特にv
t、stに使用されるマイクロプログラムのサブルーチ
ン分岐機能を有するマイクロ制御装置に関する。The present invention relates to an information processing device that uses microinstructions for internal sequence control of a microprocessor, and in particular,
The present invention relates to a microcontroller having a subroutine branching function for microprograms used in t and st.
マイクロ制御装置においては、あるルーチン処理を実行
中にサブルーチン処理に分岐する場合、サブルーチン処
理終了後に元のルーチン処理に戻るためのアドレスデー
タ(以下、戻りアドレスデータと呼ぶ。)を記憶するた
めのレジスタが必要となる。このようなサブルーチン分
岐処理において、分岐が階層構造(ネスト構造)を持つ
場合は戻りアドレスデータを保持するためのスタック構
造の複数のレジスタ(以下、スタックと呼ぶ。)と、ス
タックを特定すうため、のスタックポインタが設けられ
ている。In a microcontroller, when branching to subroutine processing during execution of a certain routine processing, a register is used to store address data (hereinafter referred to as return address data) for returning to the original routine processing after the subroutine processing is completed. Is required. In such subroutine branch processing, if the branch has a hierarchical structure (nested structure), there are multiple registers in the stack structure (hereinafter referred to as stacks) to hold return address data, and in order to specify the stack, A stack pointer is provided.
一般にスタックポインタは、ポインタの示す値とスタッ
クが1対1に対応する必要があるため、ネスト構造がn
構造ならば、スタックポインタの値はn+1を示す必要
がある。In general, the stack pointer requires a one-to-one correspondence between the value indicated by the pointer and the stack, so the nested structure is
If it is a structure, the value of the stack pointer must indicate n+1.
スタックポインタではサブルーチン分岐命令があると、
ポインタを1加算(または減算)シ、マイクロ制御装置
は当該ポインタに相当するスタックに戻りアドレスデー
タの書込みを行う。また、戻り命令があるとポインタを
1減算(または加算)し、マイクロ制御装置は当該ポイ
ンタに相当するスタックの戻りアドレスデータの読出し
を行う。When there is a subroutine branch instruction with the stack pointer,
After adding (or subtracting) the pointer by 1, the microcontroller returns to the stack corresponding to the pointer and writes address data. Furthermore, when there is a return instruction, the pointer is subtracted (or added) by 1, and the microcontroller reads return address data from the stack corresponding to the pointer.
一方、VLSI等ではハードウェア規模の制限からスタ
ックの個数に限度がありスタックが2個で構成される場
合が多い。そこで、以下においてはスタックが2個の場
合について述べる。On the other hand, in VLSI and the like, there is a limit to the number of stacks due to hardware scale limitations, and the number of stacks is often two. Therefore, the case where there are two stacks will be described below.
第9図にスタックが2個の場合におけるスタックの使用
状態の説明図を示す。以下、各スタックを第1スタツク
および第2スタツクと呼び、スタックポインタは2ビッ
トのカウンタレジスタで構成されているものとする。FIG. 9 shows an explanatory diagram of how the stacks are used when there are two stacks. Hereinafter, each stack will be referred to as a first stack and a second stack, and it is assumed that the stack pointer is composed of a 2-bit counter register.
スタックポインタの値が00”の場合にはスタックは使
用されておらず、メインルーチンの処理を行っているこ
とを示している。スタックポインタの値が“01“の場
合には、第1スタツクが使用されており、サブルーチン
処理(以下、第1サブルーチン処理と呼ぶ。)を行って
いることを示している。スタックポインタの値が“10
″の場合には、第2スタツクも使用されており、第1サ
ブルーチン処理においてさらにサブルーチン処理(以下
、第2サブルーチン処理と呼ぶ。)を行っていることを
示している。If the stack pointer value is 00, it indicates that the stack is not in use and the main routine is processing. If the stack pointer value is 01, the first stack is This indicates that subroutine processing (hereinafter referred to as the first subroutine processing) is being performed.The value of the stack pointer is "10".
'' indicates that the second stack is also being used, and subroutine processing (hereinafter referred to as second subroutine processing) is being performed in addition to the first subroutine processing.
上記従来の情報処理装置においては、スタックポインタ
をカウンタレジスタで構成した場合、スタックが2個の
場合でも2ビットのカウンタレジスタが必要であり、ハ
ード乞エア量が増加し、制御および構造が複雑化すると
ともに、処理速度が低下するという問題点があった。In the conventional information processing device described above, when the stack pointer is configured with a counter register, a 2-bit counter register is required even if there are two stacks, which increases the amount of hardware required and complicates the control and structure. At the same time, there was a problem in that the processing speed decreased.
上記課題に鑑み、本発明は、スタックが2個の場合にハ
ードウェア量を低減し、制御および構造が簡単で処理速
度を向上させる情報処理装置を提供することを目的とす
る。In view of the above problems, an object of the present invention is to provide an information processing device that reduces the amount of hardware when there are two stacks, has simple control and structure, and improves processing speed.
ネスト構造が2構造の場合、すなわちスタックが2個の
場合にのみ着目すると、2つのスタックのうち一方が選
択されていないならば、一義的に他方のスタックが選択
されていることが決まる。Focusing only on the case where there are two nested structures, that is, when there are two stacks, if one of the two stacks is not selected, it is univocally determined that the other stack is selected.
これによりスタックポインタの値は2つの値を示せれば
良いこととなる。As a result, the value of the stack pointer only needs to indicate two values.
そこで、第1図の原理説明図に示すように、本発明は2
個のスタック2A、2Bと、前記スタックを特定するス
タックポインタ3と、を備えた情報処理装置1において
、スタックポインタ3は、前記スタックの書込信号また
は読出信号に応じて反転する1ビットのレジスタ4を有
し、前記書込信号または前記読出信号、およびレジスタ
4の値にまり書込指示信号または読出指示信号を出力す
る指示信号出力手段5を備えて構成した。Therefore, as shown in the principle explanatory diagram of FIG.
In an information processing device 1 comprising two stacks 2A and 2B and a stack pointer 3 for specifying the stack, the stack pointer 3 is a 1-bit register that is inverted according to a write signal or a read signal of the stack. 4, and an instruction signal output means 5 for outputting a write instruction signal or a read instruction signal based on the write signal or the read signal and the value of the register 4.
本発明は以上のように構成したので、指示信号出力手段
5はスタックの書込信号または読出信号および1ビット
のレジスタの値との組み合わせにより、容易にスタック
を特定することができるとともに、当該スタックについ
ての書込指示信号または読出指示信号を出力することが
できる。Since the present invention is configured as described above, the instruction signal output means 5 can easily specify the stack by a combination of the write signal or read signal of the stack and the value of the 1-bit register. It is possible to output a write instruction signal or a read instruction signal for.
本発明の実施例について第1図乃至第8図を参照して詳
細に説明する。Embodiments of the present invention will be described in detail with reference to FIGS. 1 to 8.
第1図に示すように、情報処理装置1は第ニスタック2
Aおよび第2スタツク2Bの2個のスタックと、スタッ
クを特定し当該スタックの読出または書込を指示するス
タックポインタ3と、を備えて構成されている。As shown in FIG.
The stack pointer 3 includes two stacks, A and a second stack 2B, and a stack pointer 3 that specifies the stack and instructs reading or writing of the stack.
スタックポインタ3は読出信号または書込信号の入力に
より反転する1ビットのレジスタ4と、読出信号または
書込信号およびレジスタ4の出力信号に基づいてスタッ
クを特定し当該スタックの読出または書込を指示する指
示信号を出力する指示信号出力手段5と、を備えて構成
されている。The stack pointer 3 identifies a stack based on a 1-bit register 4 that is inverted by the input of a read signal or a write signal, the read signal or write signal, and the output signal of the register 4, and instructs reading or writing of the stack. and an instruction signal output means 5 for outputting an instruction signal.
情報処理装置1にスタックの読出し信号または書込信号
が人力されると、指示信号出力手段5はレジスタおよび
人力された信号の組み合わせにより、スタックを特定し
当該スタックの読出または書込を指示する指示信号6を
出力する。これにより当該スタックに戻りアドレスデー
タが書込まれ、または当該スタックより戻りアドレスデ
ータが読出されることになる、
第2図に本発明を描画処理装置に適用した場合のブロッ
ク図を示す。When a stack read signal or a write signal is manually input to the information processing device 1, the instruction signal output means 5 identifies the stack by a combination of the register and the input signal, and outputs an instruction to read or write the stack. Outputs signal 6. As a result, return address data is written to or read from the stack. FIG. 2 shows a block diagram when the present invention is applied to a drawing processing device.
描画処理装置7は、システム全体の制御を行うホストC
PU8と、システム全体の制御用データ等を格納するシ
ステムメモリ9と、描画処理の制御を行う描画処理プロ
セッサIOと、グラフィックデータを格納するグラフィ
ックメモリ11と、グラフィックデータに基づいて表示
を行う表示装置12と、システム制御用データのやり取
りを行うホストバス13と、グラフィックデータのやり
取りを行うグラフィックバス14と、を備えている。The drawing processing device 7 is a host C that controls the entire system.
A PU 8, a system memory 9 that stores control data for the entire system, a drawing processor IO that controls drawing processing, a graphic memory 11 that stores graphic data, and a display device that performs display based on the graphic data. 12, a host bus 13 for exchanging system control data, and a graphic bus 14 for exchanging graphic data.
描画処理プロセッサ10はホストバス13とのデータの
やり取りのインターフェース動作を行うホストバスイン
ターフェース部15と、グラフィックデータの演算等を
行う描画演算部16と、グラフィックバス14とのデー
タのやり取りのインターフェース動作を行うグラフィッ
クバスインターフェース部17と、を備えている。The drawing processing processor 10 includes a host bus interface section 15 that performs an interface operation for exchanging data with the host bus 13, a drawing operation section 16 that performs operations on graphic data, etc., and an interface operation for exchanging data with the graphic bus 14. A graphic bus interface unit 17 is provided.
描画演算部16は第3図に示すように、制御信号により
描画演算部16全体の制御を行うマイクロ制御部40と
、加算器41、乗算器42、シフタ43等の演算蓋群と
、ワーク用のレジスタ44と、内部でデータのやりとり
を行う内部バス45と、を備えて構成されている。As shown in FIG. 3, the drawing calculation unit 16 includes a microcontroller 40 that controls the entire drawing calculation unit 16 by control signals, a calculation lid group such as an adder 41, a multiplier 42, a shifter 43, and a workpiece. It is configured to include a register 44 and an internal bus 45 for exchanging data internally.
ここで、描画処理装置7の動作について説明する。Here, the operation of the drawing processing device 7 will be explained.
ホストCPU8は、システムメモリ9のデータ等に基づ
いて描画コマンドおよびパラメータをホストバス13お
よびホストバスインタフェース部15を介して、描画演
算部16に出力する。描画演算部16はコマンドを解析
し、パラメータに基づいて円などの描画アドレスを発生
し、グラフィックパスインターフェース部17およびグ
ラフィックバス14を介して、グラフィックメモリ1に
出力する。さらに表示装置12は、グラフィックメモリ
11のデータに基づいて表示を行う。The host CPU 8 outputs drawing commands and parameters to the drawing calculation section 16 via the host bus 13 and the host bus interface section 15 based on data etc. in the system memory 9. The drawing calculation unit 16 analyzes the command, generates a drawing address for a circle, etc. based on the parameters, and outputs it to the graphic memory 1 via the graphic path interface unit 17 and the graphic bus 14. Furthermore, the display device 12 performs display based on the data in the graphic memory 11.
描画演算部16のマイクロ制御部40は第4図に示すよ
うに、ホストCPU8等からのコマンドよりマイクロ命
令の開始アドレスを発生するコマンドデコーダ18と、
後述する分岐制御回路20の出力信号に基づいて次に処
理すべきマイクロ命令の読出アドレスを選択するセレク
タ19と、後述するマイクロ命令レジスタのコードに基
づいて分岐制御を行う分岐制御回路20と、セレクタ1
9により選択されたアドレスデータを格納するアドレス
レジスタ21と、アドレスレジスタ21内のアドレスデ
ータに対応するマイクロ命令を格納したマイクロROM
22と、マイクロROM22より読出したマイクロ命令
を格納するマイクロ命令レジスタ23と、アドレスをイ
ンクリメントするためのインクリメンタ24と、スタッ
クポインタを有し戻りアドレスをスタックするスタック
回路25と、を備えている。As shown in FIG. 4, the microcontroller 40 of the drawing calculation unit 16 includes a command decoder 18 that generates the start address of a microinstruction from a command from the host CPU 8 or the like;
A selector 19 that selects a read address of a microinstruction to be processed next based on an output signal of a branch control circuit 20 (described later), a branch control circuit 20 that performs branch control based on a code of a microinstruction register (described later), and a selector 1
an address register 21 that stores address data selected by 9; and a micro ROM that stores microinstructions corresponding to the address data in the address register 21.
22, a microinstruction register 23 for storing microinstructions read from the microROM 22, an incrementer 24 for incrementing addresses, and a stack circuit 25 having a stack pointer and stacking return addresses.
マイクロ制御部40では、コマンドデコーダ18により
ホストCPU8等より与えられたコマンドを解析して、
マイクロ命令の開始アドレスを発生し、セレクタ19に
出力する。セレクタ19は、コマンドデコーダ18の出
力、インクリメンタ24の出力、スタック回路25の出
力、またはマイクロ命令レジスタ23の分岐アドレスお
よび分岐制御回路20の出力より、次のマイクロ命令の
読出アドレスを選択し、アドレスレジスタ21に出力す
る。このとき、インクリメンタ24はアドレスレジスタ
の値に1を加算して出力する。マイクロROM22はア
ドレスレジスタ21の出力に基づいてマイクロ命令を読
出し、マイクロ命令レジスタ23に出力する。マイクロ
命令レジスタ23に格納されたデータは各演算器の制御
信号として出力される。In the microcontroller 40, the command decoder 18 analyzes the command given from the host CPU 8, etc.
A start address of a microinstruction is generated and output to the selector 19. The selector 19 selects the read address of the next microinstruction from the output of the command decoder 18, the output of the incrementer 24, the output of the stack circuit 25, or the branch address of the microinstruction register 23 and the output of the branch control circuit 20, Output to address register 21. At this time, the incrementer 24 adds 1 to the value of the address register and outputs the result. The micro ROM 22 reads a micro instruction based on the output of the address register 21 and outputs it to the micro instruction register 23. The data stored in the microinstruction register 23 is output as a control signal for each arithmetic unit.
一方、スタック回路25は、マイクロ命令でサブルーチ
ン分岐命令が実行されると、戻りアドレスとしてインク
リメンタ24の出力を取り込む。On the other hand, when a subroutine branch instruction is executed by a microinstruction, the stack circuit 25 takes in the output of the incrementer 24 as a return address.
また、スタック回路25はマイクロ命令で戻り命令が実
行されると、戻りアドレスをセレクタ19に出力する。Furthermore, when a return instruction is executed as a microinstruction, the stack circuit 25 outputs a return address to the selector 19.
第5図にスタック回路25内のスタックポインタのブロ
ック図を示す。FIG. 5 shows a block diagram of the stack pointer in the stack circuit 25.
スタックポインタ26内に書込信号または読出信号が入
力されると、OR回路27は書込信号と読出信号の論理
和をとり、遅延回路28に出力する。遅延回路28はス
タックの書込処理または読出処理が終了後にTフリップ
フロラプ回路29にOR回路27の出力信号を出力する
。Tフリップフロラプ回路29は遅延回路28の出力信
号が出力されるごとに出力を反転し、第1 AND回路
30の一方の入力端子、第2AND回路31の一方の入
力端子およびインバータ32の入力端子に出力信号を出
力する。インバータ32の出力信号は第3AND回路3
3の一方の入力端子および第4AND回路34の一方の
入力端子に入力される。さらに第LAND回路30の他
方の入力端子および第3AND回路33の他方の入力端
子には書込信号が入力され、第2AND回路31の他方
の入力端子および第4AND回路34の他方の入力端子
には読出信号が入力される。この場合において、第1〜
第4AND回路回路はそれぞれ、第2スタツク書込指示
信号35、第1スタツク読出指示信号36、第1スタツ
ク書込指示信号37、第2スタツク読出指示信号38を
出力することになる。When a write signal or a read signal is input into the stack pointer 26 , the OR circuit 27 takes the logical sum of the write signal and the read signal, and outputs the result to the delay circuit 28 . The delay circuit 28 outputs the output signal of the OR circuit 27 to the T flip-flop circuit 29 after the stack write process or read process is completed. The T flip-flop circuit 29 inverts the output every time the output signal of the delay circuit 28 is output, and connects one input terminal of the first AND circuit 30, one input terminal of the second AND circuit 31, and the input terminal of the inverter 32. Output the output signal to. The output signal of the inverter 32 is the third AND circuit 3
3 and one input terminal of the fourth AND circuit 34. Furthermore, a write signal is input to the other input terminal of the second LAND circuit 30 and the other input terminal of the third AND circuit 33, and the other input terminal of the second AND circuit 31 and the other input terminal of the fourth AND circuit 34 are input. A read signal is input. In this case, the first to
The fourth AND circuit outputs a second stack write instruction signal 35, a first stack read instruction signal 36, a first stack write instruction signal 37, and a second stack read instruction signal 38, respectively.
第6図に描画演算部の動作状態説明図を示す。FIG. 6 shows an explanatory diagram of the operating state of the drawing calculation section.
例えば、Tフリップフロラプ回路29の出力が“1“の
状態で、書込信号が“1”になると、第2スタツク2B
にアドレスデータが書込まれることになる。For example, when the output of the T flip-flop circuit 29 is "1" and the write signal becomes "1", the second stack 2B
Address data will be written to.
第7図に描画演算部の処理状態説明図を示す。FIG. 7 shows an explanatory diagram of the processing state of the drawing calculation section.
ここで、コロン(:)の前の数字は、処理後のTフリッ
プフロラプ回路29の出力を示している。Here, the number before the colon (:) indicates the output of the T flip-flop circuit 29 after processing.
例えば、初期状態で書込信号が入力されると、第1スタ
ツク2Aにアドレスデータを書込み、Tフリップフロラ
プ回路29の出力は1“になる。次に、この状態で、さ
らに書込信号が人力された場合には処理は反時計回りの
方へ進み、第2スタツク2Bにアドレスデータを書込み
、Tフリップフロラプ回路29の出力は“0”になる。For example, when a write signal is input in the initial state, address data is written to the first stack 2A, and the output of the T flip-flop circuit 29 becomes 1". Next, in this state, a further write signal is input. In the case of manual operation, the process proceeds counterclockwise, address data is written to the second stack 2B, and the output of the T flip-flop circuit 29 becomes "0".
また、読出信号が入力された場合には、処理は時計回り
の方へ進み、第1スタック2人のアドレスデータを読出
し、Tフリップフロラプ回路29の出力は′O″になる
。Further, when a read signal is input, the process proceeds clockwise, the address data of the two people in the first stack are read out, and the output of the T flip-flop circuit 29 becomes 'O'.
次に、第8図の描画演算部の処理タイミングチャートを
参照して動作の一例について説明する。Next, an example of the operation will be described with reference to the processing timing chart of the drawing calculation unit shown in FIG.
ここで、初期状態すなわちメインルーチン処理の開始状
態ではTフリップフロラプ回路29の出力は“0”で・
あり、書込信号も読出信号も入力されていないものとし
、第1サブルーチン処理で第2サブルーチン処理を行っ
た後、メインルーチン処理に戻る場合について説明する
。Here, in the initial state, that is, the start state of the main routine processing, the output of the T flip-flop circuit 29 is "0".
A case will be described in which, after performing the second subroutine process in the first subroutine process, the process returns to the main routine process, assuming that the write signal and the read signal are not input.
まず、メインルーチン処理においてサブルーチン分岐命
令が実行されると、マイクロ制御装置は書込信号を“1
”にし、OR回路27の出力は“1”になる。一方、T
フリップフロラプ回路29の出力が“0”であるのでイ
ンノく一夕32の出力は“1”となり、第3AND回路
33の入力はいずれも“1”となり、第3AND回路3
3の出力は“■”になる。すなわち、第1スタ・ソク書
込信号が出力されるので、第1スタ・ツク2Aに戻りア
ドレスが書き込まれ、処理を第1サブルーチンに移すこ
ととなる。First, when a subroutine branch instruction is executed in main routine processing, the microcontroller sends a write signal to “1”.
”, the output of the OR circuit 27 becomes “1”. On the other hand, T
Since the output of the flip-flop circuit 29 is "0", the output of the input circuit 32 is "1", and the inputs of the third AND circuit 33 are both "1", and the output of the third AND circuit 32 is "1".
The output of 3 becomes “■”. That is, since the first star/socket write signal is output, the return address is written to the first star/socket 2A, and the process is shifted to the first subroutine.
第1スタツク2Aに戻りアドレスの書込み終了後、遅延
回路28の出力は“■”になり、これによりTフリップ
フロラプ回路29の出力は反転し、“1”になる。さら
にこれに伴い、インノく一夕の出力は′0”になる。After returning to the first stack 2A and finishing writing the address, the output of the delay circuit 28 becomes "■", and as a result, the output of the T flip-flop circuit 29 is inverted and becomes "1". Furthermore, along with this, the output of Inno Kui becomes '0'.
次に、第1サブルーチンにおいてサブルーチン分岐命令
が実行されると、74イクロ制御装置は書込信号を“1
”にし、OR回路27の出力は“1”になる。一方、T
フリップフロラプ回路29の出力がl”であるのでイン
バータ32の出力は0”となり、第1AND回路30の
入力はいずれも“l“となり、第1AND回路30の出
力は“1”になる。すなわち、第2スタツク書込指示信
号35が出力されるので第2スタツク2Bに戻りアドレ
スが書き込まれ、処理を第2サブルーチンに移すことと
なる。Next, when the subroutine branch instruction is executed in the first subroutine, the 74 microcontroller sets the write signal to “1”.
”, the output of the OR circuit 27 becomes “1”. On the other hand, T
Since the output of the flip-flop circuit 29 is "1", the output of the inverter 32 is "0", the inputs of the first AND circuit 30 are both "1", and the output of the first AND circuit 30 is "1". That is, since the second stack write instruction signal 35 is output, the return address is written to the second stack 2B, and the process is shifted to the second subroutine.
第2スタツク2Bに戻りアドレスの書込み終了後、遅延
回路28の出力は“■”になり、これによりTフリップ
フロラプ回路29の出力は反転し、“O”になる。さら
にこれに伴い、インバータの出力は“■”になる。After returning to the second stack 2B and writing the address, the output of the delay circuit 28 becomes "■", and the output of the T flip-flop circuit 29 is thereby inverted and becomes "O". Furthermore, along with this, the output of the inverter becomes "■".
その後、第2サブルーチンの処理が終了し、第2サブル
ーチンにおいて復帰命令が実行されると、マイクロ制御
装置は読出信号を“1”にし、OR回路27の出力は“
1”になる。一方、Tフリップフロラプ回路の出力が“
0“であるのでインバータ32の出力は“1nとなり、
第4AND回路34の入力はいずれも“■”となり、第
4AND回路34の出力は“1”になる。Thereafter, when the processing of the second subroutine is completed and a return instruction is executed in the second subroutine, the microcontroller sets the read signal to "1", and the output of the OR circuit 27 becomes "1".
1". On the other hand, the output of the T flip-flop circuit becomes "
0", the output of the inverter 32 becomes "1n,
The inputs of the fourth AND circuit 34 are all "■", and the output of the fourth AND circuit 34 is "1".
すなわち、第2スタツク読出指示信号38が出力される
ので、第2スタツク2Bより戻りアドレスが読出され、
処理を第1サブルーチンに移すこととなる。That is, since the second stack read instruction signal 38 is output, the return address is read from the second stack 2B.
The process will be moved to the first subroutine.
第2スタツク2Bより戻りアドレスの読出し終了後、遅
延回路28の出力は1″になり、これによりTフリップ
フロラプ回路29の出力は反転し、“1”になる。After the readout of the return address from the second stack 2B is completed, the output of the delay circuit 28 becomes 1'', and as a result, the output of the T flip-flop circuit 29 is inverted and becomes 1''.
さらにその後、第1サブルーチンの処理が終了し、第1
サブルーチン、において復帰命令が実行されると、マイ
クロ制御装置は読出信号を“l″番こし、OR回路27
の出力は11になる。一方、Tフリップフロラプ回路2
9の出力が0”であるのでインバータ32の出力は1″
となっており、第2AND回路31の入力はいずれも“
1“となり、第2AND回路31の出力は“1′になる
。すなわち、第1スタツク読出指示信号36が出力され
るので、第1スタ・どり2Aより戻りアドレスが読出さ
れ、処理をメインルーチン処理に移すこととなる。After that, the processing of the first subroutine ends, and the first
When the return command is executed in the subroutine, the microcontroller sets the read signal to "1" and outputs the OR circuit 27.
The output of will be 11. On the other hand, T flip-flop circuit 2
Since the output of inverter 9 is 0'', the output of inverter 32 is 1''.
The inputs of the second AND circuit 31 are both "
1", and the output of the second AND circuit 31 becomes "1'. That is, since the first stack read instruction signal 36 is output, the return address is read from the first stack readout 2A, and the processing is shifted to the main routine processing.
第1スタツク2Aより戻りアドレスの読出し終了後、遅
延回路28の出力は“1”になり、これによりTフリッ
プフロラプ回路29の出力は反転し、′1“になる。さ
らにこれに伴い、インノ<−タの出力は0”になる。After reading the return address from the first stack 2A, the output of the delay circuit 28 becomes "1", and the output of the T flip-flop circuit 29 is thereby inverted and becomes '1'. The output of <- data becomes 0''.
以上のように、メインルーチン処理、第1サブルーチン
処理、第2サブルーチン処理、第1サブルーチン処理、
メインルーチン処理の順番で処理が行われることになる
。As described above, main routine processing, first subroutine processing, second subroutine processing, first subroutine processing,
Processing will be performed in the order of main routine processing.
本発明は以上のように構成したので、2個のスタックを
特定するのに、1ビットのレジスタのみで行うことがで
き、ハードウェア量が低減し、制御および構造が簡単で
、処理速度を向上できるという効果を奏する。Since the present invention is configured as described above, it is possible to specify two stacks using only a 1-bit register, which reduces the amount of hardware, simplifies control and structure, and improves processing speed. It has the effect of being able to do it.
【図面の簡単な説明】
第■図は本発明の原理説明図、
第2図は本発明に係る描画処理装置のブロック図、
第3図は本発明に係る描画演算部のブロック図、第4図
はマイクロ制御部のブロック図、第5図は本発明におけ
るスタックポインタのブロック図、
第6図は本発明における描画演算部の動作状態説明図、
第7図は本発明における描画演算部の処理状態説明図、
第8図は本発明における描画演算部の処理タイミングチ
ャート、
第9図は従来のスタック使用状態の説明図である。
1・・・情報処理装置
2A・・・第1スタツク
2B・・・第2スタツク
3・・・スタックポインタ
4・・・レジスタ
5・・・指示信号出力手段
6・・・指示信号
7・・・描画処理装置
8・・・ホストCPU
9・・・システムメモリ
10・・・描画処理プロセッサ
11・・・グラフィックメモリ
12・・・表示装置
13・・・ホストバス
14・・・グラフィックバス
15・・・ホストバスインターフェース部16・・・描
71画演算部
17・・・グラフィックバスインターフェース部18・
・・コマンドデコーダ
19・・・セレクタ
20・・・分岐制御回路
21・・・アドレスレジスタ
22・・・マイクロROM
23・・・マイクロ命令レジスタ
24・・・インクリメンタ
25・・・スタック回路
26・・・スタックポインタ
27・・・OR回路
28・・・遅延回路
29・・・Tフリツプフロツプ回路
30・・・第1AND回路
31・・・第2AND回路
32・・・インバータ
33・・・第3AND回路
34・・・第1AND回路
35・・・第2スタツク書込指示信号
36・・・第1スタツク読出指示信号
37・・・第1スタツク書込指示信号
38・・・第2スタツク読出指示信号
40・・・マイクロ制御部
41・・・加算器
42・・・乗算器
43・・・シック
44・・・レジスタ
45・・・内部バス[Brief Explanation of the Drawings] Figure 2 is a diagram explaining the principle of the present invention, Figure 2 is a block diagram of a drawing processing device according to the present invention, Figure 3 is a block diagram of a drawing calculation unit according to the present invention, and Figure 4 is a block diagram of a drawing processing unit according to the present invention. Figure 5 is a block diagram of the microcontroller, Figure 5 is a block diagram of the stack pointer in the present invention, Figure 6 is an explanatory diagram of the operating state of the drawing calculation unit in the invention, and Figure 7 is the processing of the drawing calculation unit in the invention. FIG. 8 is a processing timing chart of the drawing calculation unit according to the present invention, and FIG. 9 is an explanatory diagram of the conventional stack usage state. 1... Information processing device 2A... First stack 2B... Second stack 3... Stack pointer 4... Register 5... Instruction signal output means 6... Instruction signal 7... Drawing processing device 8...Host CPU 9...System memory 10...Drawing processing processor 11...Graphic memory 12...Display device 13...Host bus 14...Graphic bus 15... Host bus interface unit 16...Drawing 71-stroke calculation unit 17...Graphic bus interface unit 18.
...Command decoder 19...Selector 20...Branch control circuit 21...Address register 22...Micro ROM 23...Micro instruction register 24...Incrementer 25...Stack circuit 26...・Stack pointer 27...OR circuit 28...Delay circuit 29...T flip-flop circuit 30...First AND circuit 31...Second AND circuit 32...Inverter 33...Third AND circuit 34... ...First AND circuit 35...Second stack write instruction signal 36...First stack read instruction signal 37...First stack write instruction signal 38...Second stack read instruction signal 40...・Micro control unit 41... Adder 42... Multiplier 43... Thick 44... Register 45... Internal bus
Claims (1)
するスタックポインタ(3)と、を備えた情報処理装置
(1)において、 前記スタックポインタ(3)は、前記スタック(2A、
2B)の書込信号または読出信号に応じて反転する1ビ
ットのレジスタ(4)を有し、前記書込信号または読出
信号および前記レジスタ(4)の値により書込指示信号
または読出指示信号(6)を出力する指示信号出力手段
(5)を備えて構成したことを特徴とする情報処理装置
。[Scope of Claims] An information processing device (1) comprising two stacks (2A, 2B) and a stack pointer (3) that specifies the stack, wherein the stack pointer (3) specifies the stack (2A,
It has a 1-bit register (4) that is inverted according to the write signal or read signal of 2B), and the write instruction signal or read instruction signal ( 6). An information processing apparatus comprising: an instruction signal output means (5) for outputting the instruction signal output means (5).
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP17227989A JPH0336629A (en) | 1989-07-04 | 1989-07-04 | Information processor |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP17227989A JPH0336629A (en) | 1989-07-04 | 1989-07-04 | Information processor |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH0336629A true JPH0336629A (en) | 1991-02-18 |
Family
ID=15938974
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP17227989A Pending JPH0336629A (en) | 1989-07-04 | 1989-07-04 | Information processor |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH0336629A (en) |
-
1989
- 1989-07-04 JP JP17227989A patent/JPH0336629A/en active Pending
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US4229801A (en) | Floating point processor having concurrent exponent/mantissa operation | |
| JPH10187661A (en) | How to write a scalar value into a vector in a computer | |
| JP3237858B2 (en) | Arithmetic unit | |
| US5757685A (en) | Data processing system capable of processing long word data | |
| JPH0414385B2 (en) | ||
| JPH0769791B2 (en) | Microprocessor | |
| JPS60136870A (en) | vector processing device | |
| JPS623461B2 (en) | ||
| US5390306A (en) | Pipeline processing system and microprocessor using the system | |
| US5742842A (en) | Data processing apparatus for executing a vector operation under control of a master processor | |
| JPH0461390B2 (en) | ||
| JPS5938677B2 (en) | Control word transfer control device | |
| US5812845A (en) | Method for generating an object code for a pipeline computer process to reduce swapping instruction set | |
| JPH0222413B2 (en) | ||
| JPS63111535A (en) | Data processor | |
| JP2812610B2 (en) | Pipeline control method | |
| JPH07110769A (en) | Vliw type computer | |
| JPS58200349A (en) | Microprogram controller | |
| JPS6119065B2 (en) | ||
| JP2731618B2 (en) | emulator | |
| JPH033047A (en) | Memory with arithmetic function | |
| JPH0452986B2 (en) | ||
| JPH04195629A (en) | Arithmetic flag generator | |
| EP0401745A2 (en) | Data processor for high-speed access to stack area data | |
| JPS6028014B2 (en) | microprocessor |