JPS6232540A - Information processor - Google Patents

Information processor

Info

Publication number
JPS6232540A
JPS6232540A JP17341985A JP17341985A JPS6232540A JP S6232540 A JPS6232540 A JP S6232540A JP 17341985 A JP17341985 A JP 17341985A JP 17341985 A JP17341985 A JP 17341985A JP S6232540 A JPS6232540 A JP S6232540A
Authority
JP
Japan
Prior art keywords
instruction
operand
machine language
execution
simulation
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP17341985A
Other languages
Japanese (ja)
Inventor
Takashi Horikawa
隆 堀川
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP17341985A priority Critical patent/JPS6232540A/en
Publication of JPS6232540A publication Critical patent/JPS6232540A/en
Pending legal-status Critical Current

Links

Landscapes

  • Executing Machine-Instructions (AREA)

Abstract

PURPOSE:To make it unnecessary to describe an operation for writing an operand, by containing an operation for writing an operation result stored in a specified place, in the operand of an instruction which becomes the cause for generating an exception, in an operation for executing an exception processing end instruction. CONSTITUTION:When an instruction executing simulation is ended, as an instruction executed after a result obtained by the instruction executing simulation is stored in a specified place in an information processor, an exception processing and instruction for storing the result of this instruction execution in the operand of a machine language instruction which becomes a simulation object, and executing an operation for shifting a control to an instruction to be executed after this machine language instruction is provided. In this way, the operand can be stored at higher speed than the case for storing the operand by a software, and also it becomes unnecessary to program a processing for storing the operand, therefore, the trouble for generating a program can be reduced.

Description

【発明の詳細な説明】 (産業上の利用分野) 本発明は、情報処理装置に関し、特にシミュレートすべ
き機械語命令において格納する必要のあるオペランドを
、ソフトウェアによる方法と比較し高速に格納できる例
外処理終了命令を持つ情報処理装置Hに関する。
Detailed Description of the Invention (Industrial Application Field) The present invention relates to an information processing device, and in particular can store operands that need to be stored in a machine language instruction to be simulated at high speed compared to a software method. The present invention relates to an information processing device H having an exception handling termination instruction.

(従来技術とその問題点) 計算機システム等の情報処理装置の中央処理装置におい
て、浮動小数点演算等のある特定の処理を高速に行なう
ため、中央処理装置に専用のハードウェア(例えば数値
演算用プロセ、す)を装着し、この処理を専用のハード
ウェアに受は持たせる方式はハフドブ、り(Intel
 Microprocessor andPeriph
eral Handbook :インテル社)等に記述
され広く行なわれている。この場合中央処理装置には、
この専用ハードウェアのための命令が準備されている。
(Prior art and its problems) In the central processing unit of an information processing device such as a computer system, in order to perform certain processing such as floating point calculations at high speed, the central processing unit is equipped with dedicated hardware (such as a numerical calculation , a system) is installed, and this processing is handled by dedicated hardware.
Microprocessor and Periph
This method is widely used and is described in the Intel Corporation's Intel Handbook. In this case, the central processing unit has
Instructions are provided for this specialized hardware.

更に、中央処理装置に専用ハードウェアが装着されてい
ない状態においても、専用ハードウェアのための命令が
含まれたプログラムを実行回着されていない状態で、中
央処理装置が専用ハードウェアのための命令を実行しよ
うとした場合には、例外事象を発生させ、命令実行のシ
ミーレーションに必要な情報を情報処理装置内の特定の
場所に格納した後、強制的にシミュレーション用のプロ
グラムに制御を移し、ここで専用ハードウェアが行なう
べき動作をシミュレートするのである。
Furthermore, even when no dedicated hardware is installed on the central processing unit, a program containing instructions for the dedicated hardware is executed. When an attempt is made to execute an instruction, an exception event is generated, information necessary for simulating instruction execution is stored in a specific location within the information processing device, and then control is forcibly transferred to the simulation program. , which simulates the operations that the dedicated hardware should perform.

この方式により、専用ハードウェアが装着された状態に
比べ速度の点では劣るものの、プログラムを全く変更す
ることなく実行させることを可能としている。また同様
の方式により、本来の中央処理装置が命令として持って
いない機能を、あたかも中央処理装置の命令セットの一
部として実現されているかのように見せ掛けることも行
なわれている。
This method makes it possible to run programs without making any changes, although the speed is slower than when dedicated hardware is installed. A similar method is also used to make functions that the central processing unit does not have as instructions appear as if they were implemented as part of the central processing unit's instruction set.

この命令実行のシミュレーションは以下に示す通シに行
なわれる。
This instruction execution simulation is performed in the following manner.

1)中央処理装置内の特定の場所に格納されている命令
実行のシミュレーションに必要な情報を用い、当該機械
語命苓により決定される演算をソフトウェアによりミー
レージして、演算結果を得る。
1) Using information necessary for simulating instruction execution stored in a specific location within the central processing unit, the calculation determined by the machine language is milled by software to obtain the calculation result.

2)命令語中のオペランド記述子を解析し、命令実行の
シミュレーションにより得られた結果を格納すべき場所
に関−する情報を得る。
2) Analyze the operand descriptor in the instruction word to obtain information regarding the location where the results obtained by simulating instruction execution should be stored.

3)2)で判明した演算結果を格納すべき場所に、1)
で得られている演算結果を格納する。
3) In the location where the calculation result found in 2) should be stored, 1)
Stores the calculation results obtained in .

ここで、シミーレージ、ンの処理速度を左右すると考え
られるのは1)及び2)の処理である。これらの内、1
)の処理は、シミュレーションすべ1命令に依存するこ
とに加え、中央処理装置内にこの処理を行なう機能がな
いことから、ソフトウェアによる命令実行のシミーレー
ションには必須の処理でおる。これに対し、2)の処理
は、総ての命令に共通した処理であり、通常の命令実行
に際しては中央処理装置内のハードウェアによりこの処
理を高速に行なっている。しかしながら、ソフトウェア
による命令実行のシミーレーションにおいてはこの処理
もプログラムで行なうため、命令実行をハードウェア及
び〉アームウェアで行なう場合に比べ、処理速度を低下
させる一因となっていた。
Here, the processes 1) and 2) are considered to affect the processing speed of the shimmy range. Among these, 1
) is an indispensable process for simulation of instruction execution by software because the simulation depends on a single instruction and there is no function to perform this process within the central processing unit. On the other hand, the process 2) is a process common to all instructions, and during normal instruction execution, this process is performed at high speed by hardware within the central processing unit. However, in the simulation of instruction execution by software, this processing is also performed by a program, which is a factor in lowering the processing speed compared to the case where instruction execution is performed by hardware or armware.

更に1このオペランドの解析処理は逐一記述しなければ
ならないため、プログラミング効率が悪く、また、オペ
ランドの指定方法が異なる中央処理装置に対してはそれ
ぞれ個別にオペランド解析処理を記述する必要があるこ
とから、このプログラムがソフトウェア賛意として蓄積
しがたいという欠点もらりた。
Furthermore, since the operand analysis process must be written one by one, programming efficiency is poor, and it is necessary to write the operand analysis process separately for each central processing unit that has a different method of specifying operands. However, the downside of this program is that it is difficult to accumulate software endorsements.

(発明の目的) 本発明の目的は、従来の情報処理装置における欠点を除
去すると共に機械語命令の実行をソフトウェアによりミ
ーレージする場合に不可欠な操作であるオペランドの格
納を中央処理装置の機械語命令実行手段によって行なう
ことにより、ソフトウェアでこの処理を行なう場合に比
べ高速に行なう機能をもつ情報処理装置を提供すること
である。
(Object of the Invention) An object of the present invention is to eliminate the drawbacks of conventional information processing devices, and to store operands, which is an essential operation when executing machine language instructions by software, by using machine language instructions in a central processing unit. It is an object of the present invention to provide an information processing device that has a function of performing this processing using an execution means at a higher speed than when performing this processing using software.

また、本発明の他の目的は、命令実行をシミュレートす
るソフトウェアの中に記述されていたオペランドを格納
するためのプログラムを不必要トすることにより、機械
語命令の実行をシミュレートするプログラムを作成する
手数を削減する情報処理装置を提供することである。
Another object of the present invention is to eliminate the need for a program for storing operands written in software for simulating instruction execution, so that the program for simulating the execution of machine language instructions can be improved. An object of the present invention is to provide an information processing device that reduces the number of steps involved in creating information.

(発明の構成) 本発明によれば、機械語命令を解読しこの命令を実行す
る機械語命令実行手段と、この機械語命令によって扱わ
れるオペランドの位置を認識するオペランド位tt g
 m手段と、オペランドを操作するオペランド操作手段
を持ち、更に、機械語命令実行手段で実行さねない機械
語命令を、ソフトウェアでシミュレートする例外処理起
動手段と、前記命令実行をシミュレートするだめに必要
な情報分保持するtW報保持手段とを持ち、前記列外処
理起動手段を作動させた場合に前記オペランド操作手段
により当該機械語命令のオペランドを取り出し、このオ
ペランドを情報保持手段に格納してソフトウェア(命令
実行シミュレーションプログラム)に制御を移す情報処
理装置であって、命令実行シミュレー7.J/の終T時
に、得られた結果を特定の場所に格納しておいてか仮実
行される館令として、特定の場所に格納された命令実行
の結果をオペランド操作手段により、当該機械語命令の
オペランドに格納し、当該機械6d命令の次に実行すべ
き命令に制御を移す動作を行なう例外処理路r命令を備
えることを特徴とする情報処理装置が得られる。
(Structure of the Invention) According to the present invention, a machine language instruction execution means that decodes a machine language instruction and executes this instruction, and an operand position tt g that recognizes the position of an operand handled by this machine language instruction.
m means, and operand manipulation means for manipulating operands, and further includes exception handling activation means for simulating, by software, machine language instructions that cannot be executed by the machine language instruction execution means, and means for simulating the execution of the instructions. and tW information holding means for holding information necessary for the processing, and when the out-of-line processing activation means is activated, the operand of the machine language instruction is retrieved by the operand operation means and this operand is stored in the information holding means. 7. An information processing device that transfers control to software (instruction execution simulation program) using an instruction execution simulation program. At the end of J/, the obtained result is stored in a specific location or temporarily executed, and the result of the execution of the instruction stored in the specific location is used by the operand operation means to execute the relevant machine language. There is obtained an information processing device characterized in that it is provided with an exception handling path r instruction which stores information in an operand of an instruction and transfers control to an instruction to be executed next to the machine 6d instruction.

更に本発明によれば、命令実行シミュレーションにより
得られた結果を格納する特定の場所として情報保持手段
を用いた情報処理装置が得られる。
Further, according to the present invention, an information processing device is obtained that uses an information holding means as a specific location for storing results obtained by instruction execution simulation.

更に又、本発明によれば、例外処理路r命令において、
命令実行シミュレーションにより得られた結果をオペラ
ンドとして指定することKより、命令実行シミュレーシ
ョンにより得られた結果を格納する特定の場所を任意に
取ることのできる情報処理装置が得られる。
Furthermore, according to the present invention, in the exception processing path r instruction,
By specifying the result obtained by the instruction execution simulation as an operand, an information processing device can be obtained in which a specific location for storing the result obtained by the instruction execution simulation can be arbitrarily set.

(構成の詳細な説明) 本発明は命令実行シミュレーションの終了時に、命令実
行シミュレーションにより得られた結果を情報処理装置
の中の特定の場所に格納してから実行される命令として
、この命令実行の結果を、シミュレーション対象となっ
ている機械語命令のオペランドに格納し、この機械語命
令の次に実行すべき命令に制御を移す動作を行なう例外
処理終了命令を備えることにより、ノブドウエアによっ
てオペランドを格納する場合に比べ高速にオペランドを
格納することができ、更に、オペランドを格納する処理
をプログラムする必要がなくなるため、プログラムを作
成する手数を削減することができる情報処理装置である
(Detailed explanation of the configuration) The present invention stores the results obtained by the instruction execution simulation in a specific location in the information processing device at the end of the instruction execution simulation, and then stores the results obtained by the instruction execution simulation as an instruction to be executed. By providing an exception handling end instruction that stores the result in the operand of the machine language instruction being simulated and transfers control to the instruction to be executed next after this machine language instruction, the operand can be stored using the no-build air. The information processing apparatus is capable of storing operands at a higher speed than when storing operands, and furthermore, since there is no need to program processing for storing operands, the number of steps required to create a program can be reduced.

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

第1図は本発明の一実施例である情報処理装置に係る計
算機システムの基本構成を示すブロック図、第2図ta
) 、 (b)は本発明の一実施例における計算機シス
テムの命令形式を示す図である。
FIG. 1 is a block diagram showing the basic configuration of a computer system related to an information processing device that is an embodiment of the present invention, and FIG.
) and (b) are diagrams showing an instruction format of a computer system in an embodiment of the present invention.

第1図において、本発明の一実施例は中央処理装置2と
記憶装置9を有する計算機システムで、中央処理装置に
はオペランドを操作するオペランド操作手段5を持つ記
憶制御部8と、これに接続される機械語命令制御部12
とを有している。この機械語命令制御部12には機械語
命令を実行するために、機械語命令を解読しこの命令を
実行する機械語命令実行手段3と、この機械語命令によ
って扱われるオペランドの位置を認識するオペランド位
置認識手段4と、本来機械語命令実行手段で実行される
べき機械語命令を、ハードウェアの構成上の理由のため
、あるいは、本来の中央処理装置が命令として持ってい
ない機能を実現するためにソフトウェアで命令実行をシ
ミユレートすることを目的とする手段、即ち例外処理起
動手段6とを有しており、記憶装置9にはソフトウェア
で命令実行をシミユレートするために必要な情報を保持
する情報保持手段7を有している。
In FIG. 1, one embodiment of the present invention is a computer system having a central processing unit 2 and a storage device 9. machine language instruction control unit 12
It has In order to execute the machine language instruction, this machine language instruction control unit 12 includes a machine language instruction execution means 3 that decodes the machine language instruction and executes this instruction, and recognizes the position of the operand handled by this machine language instruction. The operand position recognition means 4 and the machine language instruction that should originally be executed by the machine language instruction execution means are realized due to hardware configuration reasons or functions that the original central processing unit does not have as an instruction. Therefore, it has a means for simulating instruction execution by software, that is, an exception handling activation means 6, and a storage device 9 stores information that holds information necessary for simulating instruction execution by software. It has a holding means 7.

本実施例の情報保持手段7としてはスタックを用い、更
にシミュレーションにより得られた命令実行の結果を格
納する場所としてもこのスタックを用いる。
A stack is used as the information holding means 7 in this embodiment, and this stack is also used as a place to store the results of instruction execution obtained by simulation.

第2図において、本実施例における計算機システムの命
令は、命令コード21のほかに第2図(a)に示す形式
の命令としてオペランドを2つ持つ2オペランド記述部
22.23を有する命令であり、第2図(b)に示す形
式の命令としてオペランドを持たない命令である。各命
令が、第2図(a)に示す形式の命令か第2図(b)に
示す形式の命令かは、命令コード2゛1の値によって一
意に決定される。命令コード21は、この命令が行なう
べき動作を指定し、第1および第2オペランド記述部2
1.22は、この命令により操作されるオペランドの位
置を指定する。
In FIG. 2, the instruction of the computer system in this embodiment is an instruction having, in addition to an instruction code 21, a two-operand description section 22 and 23 having two operands as an instruction in the format shown in FIG. 2(a). , is an instruction having no operand as an instruction of the format shown in FIG. 2(b). Whether each instruction is in the format shown in FIG. 2(a) or in the format shown in FIG. 2(b) is uniquely determined by the value of the instruction code 2'1. The instruction code 21 specifies the operation to be performed by this instruction, and the first and second operand description sections 2
1.22 specifies the location of the operand operated by this instruction.

再び第1図を参照すると、本実施例における計算機シス
テムでは、機械語命令実行手段3の中に1機械語命令の
行なうべき動作を認識する機械語命令認識手段IOと、
次に実行すべき命令のアドレスを計算し、これを保持す
る命令位置保持手段11を持ち、更に、記憶装置9の中
に1ソフトウエアによるシミュレーションの必要な機械
語命令について、命令の実行をシミュレーションするプ
ログラムのアドレスを保持する例外ベクトル保持手段1
3を持つ。
Referring again to FIG. 1, in the computer system of this embodiment, the machine language instruction execution means 3 includes machine language instruction recognition means IO for recognizing the operation to be performed by one machine language instruction;
It has an instruction position holding means 11 that calculates and holds the address of the next instruction to be executed, and further includes a memory device 9 which simulates the execution of instructions for machine language instructions that need to be simulated by software. Exception vector holding means 1 that holds the address of the program to be executed
Has 3.

本実施例における計算機システムでは、命令の実行は以
下に通す通りに行なわれる。第3図はこの手順を示す7
0−チャートを示す。まず、機械語命令実行手段3が次
に実行すべき命令のアドレスを保持している命令位置保
持手段11により保持されているアドレスにより示され
る機械語命令を、記憶制御部8により記憶装置9から取
り出す(処理30)。次に、機械語命令認識手段10に
よりこの機械語命令の行なうべき動作を認識する(処理
31)。この機械語命令が機械語命令実行手段3におい
て実行可能であると認識された場合(判断32)には、
機械語命令実行手段3により次に示す通りに命令が実行
される。まず、この命令がオペランドを持つ命令(第2
図(a))か持たない命令(第2図(b))かを機械語
命令認識手段10によ#)認識する(判断33)。この
結果、実行すべき命令がオペランドを持たない命令(第
2図(b))の場合には、機械語命令実行手段3により
命令が実行される(処理34)。lた、実行すべき命令
がオペランドを2つ持つ命令(第2図(a))の場合に
は、操作するデータ即ちオペランドの位atオペランド
位置認識手段4により認識しく処理35)、これをオペ
ランド操作手段5によって取り出しく処理36)、命令
を機械語命令実行手段3によって実行(処理37)した
後、得られた結果をオペランド位置認識手段4により認
識されているオペランドの格納位置に、オペランド操作
手段5により格納する(処理38)。最後に、この命令
の次に実行すべき命令のアドレスを命令位置保持手段1
1によって計算し、ここで保持する(処理39)。
In the computer system in this embodiment, instructions are executed as follows. Figure 3 shows this procedure.
0 - Show chart. First, a machine language instruction indicated by an address held by the instruction position holding means 11 holding the address of the next instruction to be executed by the machine language instruction execution means 3 is transferred from the storage device 9 by the storage control section 8. Take out (process 30). Next, the machine language instruction recognition means 10 recognizes the operation to be performed by this machine language instruction (process 31). If this machine language instruction is recognized as executable by the machine language instruction execution means 3 (judgment 32),
The machine language instruction execution means 3 executes instructions as shown below. First, this instruction has an operand (second
The machine language instruction recognition means 10 recognizes whether the instruction has the command (FIG. 2(a)) or not (FIG. 2(b)) (determination 33). As a result, if the instruction to be executed is an instruction without operands (FIG. 2(b)), the instruction is executed by the machine language instruction execution means 3 (process 34). In addition, if the instruction to be executed is an instruction with two operands (FIG. 2(a)), the data to be manipulated, that is, the position of the operand, is recognized and processed by the operand position recognition means 4 (35). After the instruction is retrieved by the operation means 5 (process 36) and executed by the machine language instruction execution means 3 (process 37), the obtained result is transferred to the operand storage position recognized by the operand position recognition means 4, and the operand operation is performed. It is stored by means 5 (processing 38). Finally, the instruction position holding means 1 stores the address of the instruction to be executed next after this instruction.
1 and held here (process 39).

また、記憶制御部8により記憶装置9から取り出された
機械語命令が機械語命令実行手段3により実行できない
と認識された場合には例外処理起動手段6を動作させる
(処理40)aこの例外処理起動手段6の動作を以下に
示す。第4図はこの手順を示すフローチャートを示す。
Further, when it is recognized that the machine language instruction retrieved from the storage device 9 by the storage control unit 8 cannot be executed by the machine language instruction execution means 3, the exception handling activation means 6 is operated (process 40) a This exception handling The operation of the starting means 6 will be described below. FIG. 4 shows a flowchart illustrating this procedure.

まず、当該機械語命令がオペランドを持つ命令であると
機械語命令認識手段10により認識された場合(判断4
1)には、当該機械語命令が操作する第1および第2オ
ペランドの位置をオペランド位置認識手段4により認識
し、オペランド操作手段5によりこれらのオペランドを
取り出しく処理42)、このオペランドを第2オペラン
ド、第1オペランドの順に情報保持手段7であるスタ、
りに格納する(処理43)。次に、当該機械語命令の位
置に関する情報、即ち命令位置保持手段11に保持され
ているアドレスを記憶制御部8に渡し、これをスタ、り
に格納する(処理44)。最後に、記憶装置9内に存在
する、機械語命令の実行をシミュレーシ。
First, if the machine language instruction recognition means 10 recognizes that the machine language instruction is an instruction with operands (determination 4
In step 1), the operand position recognition means 4 recognizes the positions of the first and second operands operated by the machine language instruction, and the operand operation means 5 extracts these operands 42). an operand, a star which is information holding means 7 in order of the first operand,
(processing 43). Next, the information regarding the position of the machine language instruction, that is, the address held in the instruction position holding means 11, is passed to the storage control unit 8, and is stored in the star register (process 44). Finally, the execution of the machine language instructions existing in the storage device 9 is simulated.

ンするプログラムの位置を保持する例外ベクトル保持手
段13から、当該機械語命令の実行全シミーレーショ/
するプログラムのアドレスを記憶制御部8により取り出
しく処理45)、これを命令位置保持手段11に格納す
る(処理46)。これにより、当該機械語命令の実行を
シミュレーションするプログラムに制御が移る。第5図
は、第2図(a)に示された形式のオペランドを持つ命
令において例外処理起動手段6が起動され、当該機械語
命令の実行をシミュレーションするプログラムに制御が
移ったときにおけるスタックの状態を示す図である。
From the exception vector holding means 13 that holds the position of the program to be read, all execution simulation/execution information of the machine language instruction is
The address of the program to be executed is retrieved by the storage control unit 8 (process 45), and this is stored in the instruction position holding means 11 (process 46). As a result, control is transferred to a program that simulates the execution of the machine language instruction. FIG. 5 shows the stack when the exception handling activation means 6 is activated in an instruction having an operand in the format shown in FIG. 2(a) and control is transferred to a program that simulates the execution of the machine language instruction. It is a figure showing a state.

次に、本発明において備えられる例外処理終了命令(R
ETIWA命令と呼ぶ)について説明する。
Next, the exception handling termination instruction (R
(referred to as the ETIWA command) will be explained.

RETIWA命令は、第2図(b)に示す形式のオペラ
ンドを持たない命令であシ、機械語命令の実行をシミュ
レーションするプログラムによって得られた結果を情報
保持手段7(本実施例ではスタ、り)に格納してから実
行される命令である。第6図は、RETIWA命令を実
行する直前、即ち機械語命令の実行をシミュレーション
するプログラムによって得られた命令の実行結果を格納
したスタ、りの状態を示す図である。機械語命令の実行
をシミーレーシヨンするプログラムの最後に置かれるR
ETIWA命令は以下に示す通シに実行される。第7図
は、この手順を示すフローチャートを示す。前に示した
命令実行の手順により、RETIWA命令が記憶装置9
より取9出され(処理70)、機械語命令認識手段10
により認識されると、この命令はRETIWA命令であ
ることが判明する(判断71)。この命令は機械語命令
実行手段3によって実行可能な命令であるため、ここで
実行される。
The RETIWA instruction is an instruction having no operands in the format shown in FIG. ) is an instruction that is executed after being stored in FIG. 6 is a diagram showing the state of the register storing the instruction execution results obtained by a program that simulates the execution of machine language instructions immediately before executing the RETIWA instruction. R placed at the end of a program that simulates the execution of machine language instructions
The ETIWA instruction is executed as follows. FIG. 7 shows a flowchart illustrating this procedure. According to the instruction execution procedure shown above, the RETIWA instruction is stored in the storage device 9.
(processing 70), and the machine language instruction recognition means 10
When recognized, this instruction is found to be a RETIWA instruction (decision 71). Since this instruction is executable by the machine language instruction execution means 3, it is executed here.

まず、スタ、り50に格納されている、シミーレージ、
ンすべき命令の存在するアドレス51により示される機
械語命令を記憶制御部8により取り出しく処理72)、
この命令がオペランドを持つ命令かどうかt機械語命令
認識手段10により調べる(判断73)。この判断によ
り、機械語命令がオペランドを持つと判断された場合に
は、以下の判断73から処理8(1行なう。即ち、この
命令の第1オペランドについて、それが書き込む必要の
おるオペランドかどうかを機械語命令認識手段」0によ
#)認識する(判断73)。この第1オペランドが書き
込む必要のあるオペランドである場合には、このオペラ
ンドを:0き込むべき位置をオペランド位置認識手段4
によって認識しく処理74)、スタ、り50に格納され
ている、シミュレーションプログラムにより得られた第
1オペラ/ドロ1を取り出しく処理75)、これをオペ
ランド位置認識手段4によって認識されている位置にオ
ペランド操作手段5により格納する(処理76)。
First, the shimmy range stored in the starboard 50,
A process 72) in which the memory control unit 8 retrieves the machine language instruction indicated by the address 51 where the instruction to be read exists;
The machine language instruction recognition means 10 checks whether this instruction is an instruction having operands (determination 73). As a result of this judgment, if it is determined that the machine language instruction has an operand, the following judgments 73 to 8 (1) are performed. In other words, for the first operand of this instruction, determine whether it is an operand that needs to be written. The machine language command recognition means recognizes it (determination 73). If this first operand is an operand that needs to be written, the operand position recognition means 4 determines the position where this operand should be written.
The process 74) takes out the first opera/drone 1 obtained by the simulation program and is stored in the star 50, and moves it to the position recognized by the operand position recognition means 4. It is stored by the operand operation means 5 (processing 76).

次に、第2オペランドについても同様の処理を行なう。Next, similar processing is performed for the second operand.

即ち、第2オペランドについて、それが書き込む必要の
あるオペランドかどうかを機械語命令認識手段10によ
り認識する(判断77)。
That is, regarding the second operand, the machine language instruction recognition means 10 recognizes whether it is an operand that needs to be written (determination 77).

この第2オペランドが書き込む必要のあるオペランドで
ある場合には、このオペランドを書き込むべき位置をオ
ペランド位置認識手段4によって認識しく処理78)、
スタ、り50に格納されていル、シミュレーションプロ
グラムにより得られた第2オペランド62を取り出しく
処理79)、これをオペランド位置認識手段4によって
認識されている位置にオペランド操作手段5により格納
する(処理80)。最後に、スタ、り50に格納されて
いる、シミュレーションする命令のアドレス51に置か
れている命令の次に実行すべき命令のアドレスを命令位
置保持手段11によって計算しこれを保持して(処理8
1)、命令の実行を終わる。
If this second operand is an operand that needs to be written, the operand position recognition means 4 recognizes the position where this operand should be written (78);
A process 79) for extracting the second operand 62 obtained by the simulation program stored in the register 50, and storing it in a position recognized by the operand position recognition means 4 by the operand operation means 5 (process 79) 80). Finally, the instruction position holding means 11 calculates and holds the address of the instruction to be executed next to the instruction placed at the address 51 of the instruction to be simulated stored in the star register 50 (processing 8
1), the execution of the instruction ends.

以上本発明の一実施例について説明したが、これより明
らかなように本発明の主旨は、情報処理装置の機械語命
令実行手段によっては実行できない命令を、あたかも機
械語命令実行手段によって実行されたように見せ掛ける
ための方策として、例外事象の発生によりッフトウエア
に制御を移す方式の情報処理装置において、シミーレー
ジ、ンプログラムにより特定の場所に格納された命令の
実行結果を、シミュレーション対象となっている命令の
オペランドに書き込む操作を含む例外処理終了命令を用
意することによって、シミュレーシ璽ンプログラムにお
いてオペランドを書き込む操作を簡略化することであり
、この主旨に背かない限9例外処理手段にはいくつかの
実現方法がbることは明らかでおろう。本実施例ではオ
ペランド数がOまたは2個に固定され、例外処理終了命
令はオペランドを持たない形式の計算機システムを例に
取って説明したが、オペランド数は任意の個数(命令コ
ードによって決まる)である計算機システムにも適用で
きることは明らかであり、また、オペランドを持つ形式
の例外処理終了命令も本実施例から容易に類推でさるこ
とは明らかである。
An embodiment of the present invention has been described above, and as is clear from this, the gist of the present invention is to execute instructions that cannot be executed by the machine language instruction execution means of an information processing device as if they were executed by the machine language instruction execution means. As a measure to make it look like this is the case, in an information processing device that transfers control to software upon the occurrence of an exception event, the execution results of instructions stored in a specific location by a shimmy program are simulated. The goal is to simplify the operation of writing operands in a simulation program by preparing an exception handling termination instruction that includes an operation of writing to the operand of an instruction. It is clear that there are two ways to achieve this. In this embodiment, the number of operands is fixed to O or 2, and the exception handling termination instruction has no operands. However, the number of operands can be any number (determined by the instruction code). It is obvious that the present invention can be applied to a certain computer system, and it is also obvious that an exception handling termination instruction having an operand can be easily deduced from this embodiment.

更に、本実施例では例外発生時に情報保持手段に格納す
る情報として、例外発生の原因となった命令のアドレス
、第1および第2オペランドの値のみを格納する計算機
システムを例に取ったが、ここで示した情報以外の情報
(例えば、例外発生の原因となった命令の次に実行すべ
き命令のアドレス)をも格納する情報処理装置にも適用
できることも明らかであろう。
Furthermore, in this embodiment, a computer system is taken as an example in which only the address of the instruction that caused the exception and the values of the first and second operands are stored as information stored in the information holding means when an exception occurs. It is obvious that the present invention can also be applied to an information processing device that stores information other than the information shown here (for example, the address of the instruction to be executed next to the instruction that caused the exception).

また本実施例では、情報保持手段としてスタ。Further, in this embodiment, a star is used as an information holding means.

りを使用しているが、この代わシに中央処理装置内のレ
ジスタを用いることも考えられる。この場合には、オペ
ランドを格納するために用いるレジスタを退避する必要
がある。
However, it is also possible to use a register in the central processing unit instead. In this case, it is necessary to save the register used to store the operand.

(発明の効果) 本発明は以上説明したように例外処理終了命令を行なう
操作の中に、特定の場所に格納された演算結果を、例外
発生の原因となった命令のオペランドに書き込む操作を
含めるため、命令の実行をシミュレートするプログラム
において、オペランドを書き込む操作を行なう場合に比
較し、オペランドを書き込む操作を記述する必要が無く
なシ、この操作を記述する手数を不必要とすることを可
能とする効果がある。
(Effects of the Invention) As explained above, the present invention includes an operation of writing the operation result stored in a specific location to the operand of the instruction that caused the exception in the operation of executing the exception handling termination instruction. Therefore, in a program that simulates the execution of an instruction, there is no need to write an operation to write an operand, compared to when writing an operand, and it is possible to eliminate the need for writing this operation. This has the effect of

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

第1図は本発明に係る情報処理装置の一実施例である計
算機システムに基本構成を示すブロック図、第2図(a
) 、 (b)は本発明の一実施例における計算機シス
テムの命令形式金示す図、第3図は本発明の一実施例に
おける計算機システムが命令を実行する手順を示すフロ
ー図、第4図は本発明の一実施例における例外処理起動
手段の動作を示すフロー図、第5図は本発明の一実施例
において例外処理手段が起動され、機械語命令の実行?
シミーレージ、ンするプログラムに制御が移ったときに
おけるスタックの状態を示す図、第6図は本発明の一実
施例において機械語命令の実行をシミュレーシヨンする
プログラムによって得らtした命令の実行結果を格納し
たスタ、りの状態を示す図、第7図は本発明の一実施例
における例外処理終了命令の動作を示すフロー図である
。 1・・・・・・情報処理装置である計算機システム、2
・・・・・・中央処理装置、3・・・用機械語命令実行
手段、4・・・・・・オヘランド位置認識手段、5・川
・・オペランド操作手段、6・・・・・・例外処理起動
手段、7・旧・・情報保持手段、8・・・・・・記憶制
御部、9・・・・・・記憶装置、10・・・・・・機械
語命令認識手段、11・旧・・命令位置保持手段、12
・・・・・・機械語命令制御部、13・・・・・・例外
ベクトル保持手段、21・・・・・・命令コード、22
・・・・・・第1オペランド記述部、23・・・用第2
オペランド記述部、50・・・・・・スタ、り、51・
・・・・・シミ。 レージ、ンすべき命令の存在するアドレス、52・・・
・・・第1オペランドの値、53・旧・・第2オペラン
ドの値、61・・・・・・シミュレートプログラムにょ
シ得られた第1オペランド、62・・・・・・シミュレ
ートプログラムにより得られた第2オペランド。 第 2 図 茅5 回
FIG. 1 is a block diagram showing the basic configuration of a computer system which is an embodiment of the information processing apparatus according to the present invention, and FIG.
), (b) is a diagram showing the instruction format of the computer system according to an embodiment of the present invention, FIG. FIG. 5 is a flowchart showing the operation of the exception processing activation means in an embodiment of the present invention.
Figure 6 is a diagram showing the state of the stack when control is transferred to a program that executes a simulation. FIG. 7 is a flowchart showing the operation of an exception handling termination instruction in an embodiment of the present invention. 1... Computer system that is an information processing device, 2
...Central processing unit, 3.Machine language instruction execution means, 4.Oheland position recognition means, 5.Operand operation means, 6.Exception Processing activation means, 7. Old information holding means, 8. Storage control unit, 9. Storage device, 10. Machine language instruction recognition means, 11. Old ...Command position holding means, 12
... Machine language instruction control unit, 13 ... Exception vector holding means, 21 ... Instruction code, 22
......first operand description section, second for 23...
Operand description section, 50...star, ri, 51.
...Stain. address where the instruction to be loaded exists, 52...
...Value of the first operand, 53. Old... Value of the second operand, 61... First operand obtained by the simulation program, 62... The resulting second operand. 2nd illustration 5 times

Claims (1)

【特許請求の範囲】 1、機械語命令を解読しこの命令を実行する機械語命令
実行手段と、この機械語命令によつて扱われるオペラン
ドの位置を認識するオペランド位置認識手段と、オペラ
ンドを操作するオペランド操作手段を持ち、更に、機械
語命令実行手段で実行されない機械語命令を、ソフトウ
ェアでシミュレートする例外処理起動手段と、前記命令
実行をシミュレートするために必要な情報を保持する情
報保持手段とを持ち、前記例外処理起動手段を作動させ
た場合に、前記オペランド操作手段により当該機械語命
令のオペランドを取り出し、このオペランドを情報保持
手段に格納してソフトウェア(命令実行シミュレーショ
ンプログラム)に制御を移す情報処理装置であつて、命
令実行シミュレーションの終了時に、得られた結果を特
定の場所に格納しておいてから実行される命令として、
特定の場所に格納された命令実行の結果をオペランド操
作手段により、当該機械語命令のオペランドに格納し、
当該機械語命令の次に実行すべき命令に制御を移す動作
を行なう例外処理終了命令を備えることを特徴とする情
報処理装置。 2 命令実行シミュレーションにより得られた結果を格
納する特定の場所として情報保持手段を用いたことを特
徴とする、特許請求の範囲第1項記載の情報処理装置。 3、例外処理終了命令において、命令実行シミュレーシ
ョンにより得られた結果をオペランドとして指定するこ
とにより、命令実行シミュレーションにより得られた結
果を格納する特定の場所を任意に取ることのできること
を特徴とする特許請求の範囲第1項記載の情報処理装置
[Scope of Claims] 1. Machine language instruction execution means for decoding a machine language instruction and executing this instruction, operand position recognition means for recognizing the position of an operand handled by this machine language instruction, and operating the operand. further includes an exception handling activation means for simulating in software a machine language instruction that is not executed by the machine language instruction execution means, and an information holding means for holding information necessary for simulating the execution of the instruction. and when the exception processing activation means is activated, the operand of the machine language instruction is retrieved by the operand operation means, the operand is stored in the information storage means, and the operand is controlled by software (instruction execution simulation program). An information processing device that transfers an instruction, and at the end of an instruction execution simulation, stores the obtained result in a specific location and then executes the instruction.
storing the result of instruction execution stored in a specific location in the operand of the machine language instruction using an operand manipulation means;
An information processing device comprising an exception handling end instruction that transfers control to an instruction to be executed next to the machine language instruction. 2. The information processing device according to claim 1, characterized in that information holding means is used as a specific location for storing results obtained by instruction execution simulation. 3. A patent characterized in that by specifying the results obtained from instruction execution simulation as an operand in the exception handling termination instruction, a specific location for storing the results obtained from instruction execution simulation can be arbitrarily set. An information processing device according to claim 1.
JP17341985A 1985-08-06 1985-08-06 Information processor Pending JPS6232540A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP17341985A JPS6232540A (en) 1985-08-06 1985-08-06 Information processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP17341985A JPS6232540A (en) 1985-08-06 1985-08-06 Information processor

Publications (1)

Publication Number Publication Date
JPS6232540A true JPS6232540A (en) 1987-02-12

Family

ID=15960096

Family Applications (1)

Application Number Title Priority Date Filing Date
JP17341985A Pending JPS6232540A (en) 1985-08-06 1985-08-06 Information processor

Country Status (1)

Country Link
JP (1) JPS6232540A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS63247834A (en) * 1987-04-02 1988-10-14 Hitachi Ltd Processing method for pseudo instruction of floating point function
JPH01222327A (en) * 1988-03-01 1989-09-05 Nec Corp Program execution and control system

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS63247834A (en) * 1987-04-02 1988-10-14 Hitachi Ltd Processing method for pseudo instruction of floating point function
JPH07120286B2 (en) * 1987-04-02 1995-12-20 株式会社日立製作所 Floating-point function pseudo-instruction processing method
JPH01222327A (en) * 1988-03-01 1989-09-05 Nec Corp Program execution and control system

Similar Documents

Publication Publication Date Title
JPS6028015B2 (en) information processing equipment
JPS6212529B2 (en)
JPS6232540A (en) Information processor
CA1155231A (en) Pipelined digital processor arranged for conditional operation
JP2727023B2 (en) Information processing device
JPS61221827A (en) Information processor
JPH0954694A (en) Pipeline processor and its processing method
JPS62254237A (en) Inter-printer type branch instruction executing system
JP3140028B2 (en) Subroutine argument passing method
JPS595354A (en) Data processing device
JPS6022787B2 (en) Command control method
JP3416698B2 (en) Programmable controller
JPS5829051A (en) Operation processing device
JPH0259829A (en) Microcomputer
JPH03196204A (en) Programmable controller
JPS6042983B2 (en) Command control method
JPH0423102A (en) Programming device for programmable controller
JPH04167146A (en) Address tracing system for information processor
JPS60220468A (en) Vector arithmetic control system
JPS58109932A (en) Comparison and arithmetic device for electronic computer
JPH02113335A (en) Computer with tag
JPH03168845A (en) Instruction execution control system
JPS63301331A (en) Processing system for program interruption
JPS60175154A (en) Replacing method of instruction
JPS629932B2 (en)