Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JPS6149693B2 - - Google Patents
[go: Go Back, main page]

JPS6149693B2 - - Google Patents

Info

Publication number
JPS6149693B2
JPS6149693B2 JP56132717A JP13271781A JPS6149693B2 JP S6149693 B2 JPS6149693 B2 JP S6149693B2 JP 56132717 A JP56132717 A JP 56132717A JP 13271781 A JP13271781 A JP 13271781A JP S6149693 B2 JPS6149693 B2 JP S6149693B2
Authority
JP
Japan
Prior art keywords
operand
bus
instruction
specifier
unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired
Application number
JP56132717A
Other languages
Japanese (ja)
Other versions
JPS5835643A (en
Inventor
Yasushi Fukunaga
Tadaaki Bando
Yoshinari Hiraoka
Kotaro Hirasawa
Hidekazu Matsumoto
Toshuki Ide
Takeshi Kato
Hiroaki Nakanishi
Tetsuya Kawakami
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.)
Hitachi Ltd
Hitachi Industry and Control Solutions Co Ltd
Original Assignee
Hitachi Engineering Co Ltd Ibaraki
Hitachi 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 Hitachi Engineering Co Ltd Ibaraki, Hitachi Ltd filed Critical Hitachi Engineering Co Ltd Ibaraki
Priority to JP56132717A priority Critical patent/JPS5835643A/en
Priority to US06/408,924 priority patent/US4530050A/en
Priority to DE8282107598T priority patent/DE3278442D1/en
Priority to EP82107598A priority patent/EP0073424B1/en
Priority to KR8203773A priority patent/KR880000297B1/en
Priority to CA000410221A priority patent/CA1186801A/en
Publication of JPS5835643A publication Critical patent/JPS5835643A/en
Publication of JPS6149693B2 publication Critical patent/JPS6149693B2/ja
Granted legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30145Instruction analysis, e.g. decoding, instruction word fields
    • G06F9/30149Instruction analysis, e.g. decoding, instruction word fields of variable length instructions
    • G06F9/30152Determining start or end of instruction; determining instruction length

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Quality & Reliability (AREA)
  • Executing Machine-Instructions (AREA)
  • Detection And Correction Of Errors (AREA)

Description

【発明の詳細な説明】 本発明は、オペランドのアドレツシングモード
を指定するオペランド指定子が処理の種類および
オペランド数を指定するオペコード部分から独立
している不定長命令のエラーを検出するデータ処
理装置に関するものである。
DETAILED DESCRIPTION OF THE INVENTION The present invention provides a data processing method for detecting errors in indefinite-length instructions in which an operand specifier that specifies the addressing mode of an operand is independent from an opcode portion that specifies the type of processing and the number of operands. It is related to the device.

オペランド指定子の長さは、アドレツシングモ
ードに対応して任意に変り、命令の長さが可変で
あることからこのような命令を可変長命令と呼ぶ
こともある。
The length of the operand specifier changes arbitrarily depending on the addressing mode, and since the length of the instruction is variable, such an instruction is sometimes called a variable length instruction.

「不定長命令」と「可変長命令」との間には特
別の意味上の差異はなく、「不定長命令」なる用
語を「可変長命令」なる用語に置き換えても同一
の意味を持つ。しかし、ここでは、便宜上、本願
発明が扱う命令を不定長命令、従来の命令を可変
長命令と称している。
There is no particular difference in meaning between "undefined length instructions" and "variable length instructions," and even if the term "undefined length instructions" is replaced with the term "variable length instructions," they have the same meaning. However, here, for convenience, the instructions handled by the present invention are referred to as indefinite length instructions, and the conventional instructions are referred to as variable length instructions.

可変長のオペランド指定子を持つ命令体系とし
て、公知の代表的な2つの例を次に示す。
Two typical examples of well-known instruction systems having variable-length operand specifiers are shown below.

1つはバローズ社(Burroughs Corporation)
の計算機B1700をCOBOL/RPG向きのアーキテ
クチヤとした時の命令フオーマツトであり、これ
は、「B1700 COBOL/RPG−S−Language、
1058823−015、Copyright 1973、Burroughs
Corporation」に示されている。
One is Burroughs Corporation.
This is the instruction format when the computer B1700 has an architecture suitable for COBOL/RPG.
1058823−015, Copyright 1973, Burroughs
Corporation”.

今1つの例は、DEC社(Digital Equipment
Corporation)の計算機VAX11/780のアーキテ
クチヤが有する可変長となるオペランド指定子を
持つ命令体系であり、これは、「VAX11
Architecture Handbook、Copyright 1979」およ
びUSP No.4236206に示されている。
Another example is DEC (Digital Equipment)
This is an instruction system with variable-length operand specifiers that is part of the architecture of the VAX11/780 computers of
Architecture Handbook, Copyright 1979” and USP No. 4236206.

ここに示した従来の2つの命令体系では、オペ
ランドの形式、アドレツシングモードを指定する
部分が、可変長のオペランド指定子で規定され、
オペコードから独立であるといつた特徴がある。
In the two conventional instruction systems shown here, the part that specifies the operand format and addressing mode is specified by a variable-length operand specifier.
It has the characteristic that it is independent from the opcode.

しかしながら、従来の可変長命令では、処理す
るオペランドの数と、処理するオペランドのアド
レツシングモードを指定するオペランド指定子が
1対1に対応づけられており、例えば A+B→B A+B→C という2つの処理(オペレーシヨン)に対し、2
つのオペコードを割当てる必要があつた。
However, in conventional variable-length instructions, there is a one-to-one correspondence between the number of operands to be processed and the operand specifier that specifies the addressing mode of the operands to be processed. For one processing (operation), two
It was necessary to allocate two opcodes.

具体的には、後述するが、オペコードデコード
手段がオペランドの最終であることを示す信号を
出力した時に、終了フラツグのセツトが検出され
ない場合当該命令をエラーとして検出するように
していることである。
Specifically, as will be described later, when the operation code decoding means outputs a signal indicating the end of the operand, if the set of the end flag is not detected, the instruction is detected as an error.

以下、まず、本願発明の対象である不定長命令
を扱うデータ処理装置を図面を参照して詳細に説
明する。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS First, a data processing device that handles undefined length instructions, which is the object of the present invention, will be described in detail with reference to the drawings.

第1図は本発明が適用されるデータ処理システ
ムの基本的な概念図である。
FIG. 1 is a basic conceptual diagram of a data processing system to which the present invention is applied.

メモリ装置1と、複数の中央処理装置2が共通
バス3で接続されており、共通バス3を介して相
互の間の情報交換が可能となつている。
A memory device 1 and a plurality of central processing units 2 are connected by a common bus 3, and information can be exchanged between them via the common bus 3.

メモリ装置1は、命令および命令が扱うオペラ
ンドを格納するメモリ部11と、この命令および
オペランドの読み出し、書き込みを制御するメモ
リ制御部12で構成され、メモリ部11とメモリ
制御部12はメモリバス13で接続されている。
The memory device 1 includes a memory unit 11 that stores instructions and operands handled by the instructions, and a memory control unit 12 that controls reading and writing of the instructions and operands. connected with.

このような従来例にあつては、命令のエラー検
出が困難であつた。
In such conventional examples, it is difficult to detect errors in instructions.

本発明の目的は、複数個の処理するオペランド
数に対し、オペランド指定子を共用できる不定長
命令のエラー検出能力を向上させたデータ処理装
置を提供するにある。
SUMMARY OF THE INVENTION An object of the present invention is to provide a data processing device that can share an operand specifier for a plurality of operands to be processed and has improved error detection capability for undefined length instructions.

本発明の特徴は、オペランドのアドレツシング
モードを指定する各オペランド指定子にそれぞれ
オペランド指定子の終了情報(以下フラツグと呼
ぶ)を付加し、この終了フラツグの内容と、オペ
コードが指示するオペランドの数によりエラー検
出を行うようにしていることである。
A feature of the present invention is that operand specifier termination information (hereinafter referred to as a flag) is added to each operand specifier that specifies the addressing mode of the operand, and the contents of this termination flag and the operand specified by the opcode are Error detection is performed based on the number of errors.

つまり、A+B→Bという処理では、2つのオ
ペランドを処理し、2つ目のオペランドに対して
は、これを2度使用するということを、オペコー
ドで特別に規定する必要があるからである。
In other words, in the process of A+B→B, it is necessary to specifically specify in the operation code that two operands are processed and that the second operand is used twice.

もし、A+B→Bという処理で、オペランド数
を3とし、オペランド指定子を3つ用意すれば、
A+B→Bと、A+B→Cの区別を意識する必要
はないが、A+B→Bの処理では、全く同一のオ
ペランド指定子を2つ設ける必要があり、これ
は、オペランド指定子そのものが、複数バイト
(一般に長いものは7バイト)をとる時、メモリ
の実装効率を著しく低下し、好ましくない。
If we process A+B→B and set the number of operands to 3 and prepare 3 operand specifiers, then
There is no need to be aware of the distinction between A+B→B and A+B→C, but in the process of A+B→B, it is necessary to provide two identical operand specifiers. (Generally, a long one is 7 bytes), which is not preferable because it significantly reduces memory implementation efficiency.

そもそも、A+B→Bと、A+B→Cの処理を
区別することは、メモリの実装効率を高める為に
なされたものである。(A+B→Bではオペラン
ド指定子を2つで済むようにした) このように、従来の方式では、同一のオペラン
ドを複数回使用する処理に対しては、他の同機能
の処理と区別する必要があり、オペコードで指定
可能な処理数に制限があつた。
In the first place, the distinction between processing A+B→B and processing A+B→C was made in order to improve memory implementation efficiency. (For A+B→B, only two operand specifiers are required.) In this way, in the conventional method, processes that use the same operand multiple times need to be distinguished from other processes with the same function. There was a limit to the number of operations that could be specified using an opcode.

尚A+B→Bという例で説明したが、これはA
−B→Bという処理も同様であり、AとBの演算
をし、その結果をBに格納するという例の全てに
いえることである。一般にこれをAOPB→Bと表
現している。
Although I explained using the example of A+B→B, this is A
The same goes for the process -B→B, and applies to all examples in which A and B are operated on and the result is stored in B. Generally, this is expressed as AOPB→B.

メモリ装置1の動作については、特願昭55−
160758号明細書に詳細に記載しているが、本発明
の要部とは直接関係ないので、この部分の詳細説
明は省略する。
Regarding the operation of the memory device 1, please refer to the patent application filed in 1983-
Although it is described in detail in the specification of No. 160758, detailed explanation of this part will be omitted because it is not directly related to the main part of the present invention.

中央処理装置2は、共通バス3に複数台接続可
能で(図示では2台)、それぞれ、メモリ装置1
より命令及びオペランドをアクセスして順次命令
の処理をしていく。
A plurality of central processing units 2 can be connected to the common bus 3 (two units in the figure), and each central processing unit 2 can be connected to the common bus 3.
The instructions and operands are accessed and the instructions are sequentially processed.

ここでは高速化のため、一度読み出された命
令、オペランドをそれぞれコピーしている命令キ
ヤツシユ21(高速バツフアメモリ)およびオペ
ランドキヤシユ22(高速バツフアメモリ)を有
し、また命令のフエツチ、デコード及びオペラン
ドアドレス演算を行うユニツト23と、オペラ
ンドのフエツチおよび命令の実行を行うEユニツ
トを有し、それぞれがパイプライン処理を行う例
を示している。
In order to increase speed, there is an instruction cache 21 (high-speed buffer memory) and an operand cache 22 (high-speed buffer memory) in which instructions and operands once read are copied, respectively, and instruction fetches, decodes, and operand addresses are provided. An example is shown in which there is a unit 23 that performs arithmetic operations, and an E unit that fetches operands and executes instructions, each of which performs pipeline processing.

このような、命令のキヤツシユ、オペランドキ
ヤツシユの使い方、或いは、ユニツトとEユニ
ツトがパイプライン処理すること自体は公知であ
る。
The use of an instruction cache, an operand cache, and pipeline processing between the unit and the E unit are well known.

さて、第2図Aは、中央処理装置2が扱う不定
長命令のフオーマツトを示している。
Now, FIG. 2A shows the format of an indefinite length instruction handled by the central processing unit 2.

1つの命令は、1ないし数バイトで構成される
オペレーシヨンコード(これは通称、オペコード
と呼ばれている)OPと、終了フラツグSを伴つ
た1ないし複数バイトのオペランド指定子OS
1,OS2……OSnから構成されている。
One instruction consists of an operation code (commonly called an opcode) OP consisting of one or several bytes, and an operand specifier OS of one or more bytes with an end flag S.
1, OS2... Consists of OSn.

オペコードOPでは、その命令の処理内容(処
理の種類)、処理に必要なオペランドの数および
オペランドの属性(データ長、リード/ライトの
区別、データタイプ:固定小数点/浮動小数点…
…等)が示される。
The operation code OP describes the processing content of the instruction (processing type), the number of operands required for processing, and the attributes of the operands (data length, read/write distinction, data type: fixed point/floating point...
...etc.) are shown.

オペコードOPの後には、当該オペコードOPで
示されるオペランドの数以下のオペランド指定子
OS1,OS2……が示されていて、1つの命令
(正式には命令語:インストラクシヨン・ワー
ド)が構成される。
An opcode OP is followed by an operand specifier that is less than or equal to the number of operands indicated by the opcode OP.
OS1, OS2, etc. are shown and constitute one instruction (formally, an instruction word).

オペランド指定子は、該当命令で使用されるオ
ペランドの順番に並んでいて、最後のオペランド
指定子のみ、終了フラツグSが「1」にセツトさ
れている。もし、オペランド指定子の数が、オペ
コードOPで指定されるオペランド数より少ない
場合は、最後のオペランド指定子に対応するオペ
ランドが繰返し、使用される。
The operand specifiers are arranged in the order of the operands used in the relevant instruction, and only the last operand specifier has the end flag S set to "1". If the number of operand specifiers is less than the number of operands specified by the opcode OP, the operand corresponding to the last operand specifier is used repeatedly.

同一のオペランドを繰返し使用するには、いろ
いろな実現方法があるが、最も望ましい方法は、
最後のオペランド指定子を繰返し使用することで
あろう。この点については後で詳細に述べる。
There are various ways to use the same operand repeatedly, but the most desirable method is
The last operand specifier would be used repeatedly. This point will be discussed in detail later.

オペコードOPで指定するオペランド数と、オ
ペランド指定子の数が不一致の例を次に説明す
る。
An example where the number of operands specified by the opcode OP and the number of operand specifiers do not match is explained below.

例えば、オペコードOPが加算処理の場合、そ
のフアンクシヨンは、 A+B→C で、3つのオペランドを必要とするが、オペラン
ド指定子が1つの場合は、 A+A→A 2つの場合は、 A+B→B という処理が、同一のオペコードで可能となる。
オペランド指定子の具体的な例を第2図Bに示し
ている。
For example, if the opcode OP is an addition operation, the function is A + B → C, which requires three operands, but if there is one operand specifier, it is A + A → A, and if there are two, it is A + B → B. is possible with the same opcode.
A specific example of an operand specifier is shown in FIG. 2B.

ここでは、No.1〜No.24の例を示し、そのフオ
ーマツトと、これに対応するオペランドを1対1
対応で示している。
Here, we will show examples No. 1 to No. 24, and compare their formats and corresponding operands one-to-one.
It is shown in correspondence.

第2図Bにおいて、オペランドの( )は、
( )内の値をアドレスとしたメモリの内容であ
ることを示している。
In Figure 2B, the operand ( ) is
Indicates that the value in parentheses is the memory content whose address is the address.

また、フオーマツト中、DISPは、変位を、IM
はイミーデイエツト(データ直接)を示し、添字
はその大きさをビツト数で示している。
Also, during formatting, DISP calculates the displacement, IM
indicates immediate data (direct data), and the subscript indicates its size in bits.

更に、Rxはインデツクスレジスタ、Rnはジエ
ネラルレジスタを示し、Lはオペランドの大きさ
をバイト単位で示したものである。
Further, Rx indicates an index register, Rn indicates a general register, and L indicates the size of the operand in bytes.

第2図Bにおいて、そのフオーマツトとオペラ
ンドの関係は、或程度理解できると思われるが、
以下、簡単に説明する。
In Figure 2B, the relationship between the format and operands can be understood to some extent;
A brief explanation will be given below.

No.1は、レジスタ直接のアドレス指定で、Rn
で示されるジエネラルレジスタそのものが、直接
オペランドとなるものである。
No.1 is register direct addressing, Rn
The general register indicated by is itself a direct operand.

No.2以下は、全て、メモリをオペランドとす
るもので、そのアドレス計算がオペランドの欄に
示された形で行なわれる。
All of No. 2 and below use memory as an operand, and the address calculation is performed in the form shown in the operand column.

No.2は、間接アドレス指定で、Rnで示される
ジエネラルレジスタの内容がオペランドのアドレ
スとなるものである。
No. 2 is indirect addressing, in which the contents of the general register indicated by Rn are the address of the operand.

No.3、5、7では、Rnで示されるジエネラル
レジスタの内容に、DISPで示される値が加算さ
れて、これがオペランドのアドレスになつてい
る。
In Nos. 3, 5, and 7, the value indicated by DISP is added to the contents of the general register indicated by Rn, and this becomes the address of the operand.

No.4、6、8では、No.3、5、7で求められ
たアドレスのメモリの内容が、オペランドのアド
レスとなるものである。
In Nos. 4, 6, and 8, the contents of the memory at the addresses determined in Nos. 3, 5, and 7 are the addresses of the operands.

No.9〜11は、イミーデイエツトデータで、
IM8、IM16、IM32の値そのものがオペランドとな
つている。
No.9 to 11 are immediate data,
The values of IM 8 , IM 16 , and IM 32 themselves are operands.

No.12〜17は、ジエネラルレジスタRnの代りに
プログラムカウンタPCが使用されることが、
No.3〜8とは異なるだけである。PCは、デコー
ドするオペランド指定子の次のアドレスを保持し
ている。
For Nos. 12 to 17, program counter PC is used instead of general register Rn.
It is only different from Nos. 3 to 8. The PC holds the next address of the operand specifier to decode.

No.18〜24は、No.3〜8にさらにインデツクス
レジスタRxの値が加算されることが異なり、ま
たインデツクスレジスタRxの値は、オペランド
のデータ長L分乗算された値が加算される。
Nos. 18 to 24 differ in that the value of the index register Rx is further added to Nos. 3 to 8, and the value of the index register Rx is added by the value multiplied by the data length L of the operand. Ru.

これは、データ長にかかわらず、インデツクス
レジスタRxの値を、先頭から変位としてセツト
できるようにするため必要となる処理である。
This is a necessary process in order to be able to set the value of the index register Rx as a displacement from the beginning, regardless of the data length.

つまり、L(データ長を示す)を乗算すること
により、インデツクスレジスタRxは、データ長
にかかわらず、先頭から何番目のデータであるか
を示す値を入れておけばよいことになる。
In other words, by multiplying by L (indicating the data length), the index register Rx only needs to contain a value indicating the number of data from the beginning, regardless of the data length.

例えば、インデツクスレジスタRxに「10」が
入つていると、これは先頭から10番目のデータ
で、そのアドレスは、バイトの場合は10を加算
(L=1)、ワードの場合は20を加算(L=2)、
ロングワード(Long Word)では40を自動的に
加算し(L=4)、ユーザはデータ長にかかわら
ず、インデツクスレジスタRxの値をセツトでき
る。
For example, if "10" is stored in the index register Rx, this is the 10th data from the beginning, and its address is: if it is a byte, add 10 (L = 1), if it is a word, add 20. (L=2),
For long words, 40 is automatically added (L=4), and the user can set the value of the index register Rx regardless of the data length.

第3図は、第1図の中央処理装置2のより具体
的なブロツク構成図である。
FIG. 3 is a more specific block diagram of the central processing unit 2 shown in FIG.

第1図におけるユニツト23は、第3図にお
いて、命令フエツチユニツト(IFU)25、アラ
イナ(ALIG)26、デコードユニツト(DU)2
7およびアドレス計算ユニツト(AU)28部分
がこれに対応し、Eユニツト24にはオペランド
フエツチユニツト(OFU)29、実行ユニツト
(EU)30が対応している。第1図では、ユニ
ツト23とEユニツト24がパイプライン処理を
行う旨述べたが、それぞれのユニツトは第3図に
示すように更に命令フエツチユニツトIFU25、
デコードユニツトDU27、アドレス計算ユニツ
トAU28、オペランドフエツチユニツトOFU2
9、実行ユニツト30に分割され、それぞれがパ
イプライン処理をする例を示している。
The unit 23 in FIG. 1 is an instruction fetch unit (IFU) 25, an aligner (ALIG) 26, and a decode unit (DU) 2 in FIG.
7 and an address calculation unit (AU) 28 correspond to this, and the E unit 24 corresponds to an operand fetch unit (OFU) 29 and an execution unit (EU) 30. In FIG. 1, it was stated that the unit 23 and the E unit 24 perform pipeline processing, but each unit further includes an instruction fetch unit IFU 25, as shown in FIG.
Decode unit DU27, address calculation unit AU28, operand fetch unit OFU2
9, the execution unit 30 is divided into execution units 30, each of which performs pipeline processing.

しかしながら、本願発明の要旨は、このような
パイプライン処理そのものとは直接関係ないの
で、パイプライン処理については詳細な説明は省
略している。尚、パイプライン処理そのものは周
知であるが、USP4025771号には、パイプライン
高速信号プロセツサが示されている。
However, since the gist of the present invention is not directly related to such pipeline processing itself, a detailed explanation of pipeline processing is omitted. Incidentally, pipeline processing itself is well known, and USP 4025771 discloses a pipeline high-speed signal processor.

ところで、第3図において、命令フエツチユニ
ツト25は、命令を先行してフエツチするための
プログラムカウンタ50を有し、命令キヤツシユ
21より次に実行されるであろう命令を先行して
読み出す処理を行なつている。
By the way, in FIG. 3, the instruction fetch unit 25 has a program counter 50 for fetching an instruction in advance, and performs a process of reading an instruction that will be executed next from the instruction cache 21 in advance. ing.

アドレスライン100により、読み出したいア
ドレスが命令キヤツシユ21に送られ対応する命
令4バイト分がデータライン101により命令フ
エツチユニツトIFU25に送出される。
An address to be read is sent to the instruction cache 21 via the address line 100, and 4 bytes of the corresponding instruction are sent to the instruction fetch unit IFU 25 via the data line 101.

命令キヤツシユ21に、対応する命令がなかつ
た場合は、共通バス3を介して、メモリ1から該
当の命令を読み出し、この命令は命令キヤツシユ
21にストアされる。キヤツシユの動作は周知で
あり、例えば、「A Guide to the IBM
System/370Model 168」に示されている。
If there is no corresponding instruction in the instruction cache 21, the corresponding instruction is read from the memory 1 via the common bus 3, and this instruction is stored in the instruction cache 21. The operation of the cache is well known; for example, "A Guide to the IBM
System/370Model 168”.

命令4バイト分が命令フエツチユニツト25に
送出されると、プログラムカウンタ50はプラス
4(+4)され、次の命令の送出要求を命令キヤ
ツシユ21に出力する。
When four bytes of instructions are sent to the instruction fetch unit 25, the program counter 50 is incremented by four (+4), and a request to send the next instruction is output to the instruction cache 21.

この動作は、命令フエツチユニツトIFU25内
にあるバツフア(図示せず)が満杯になるまで続
けられる。
This operation continues until the buffer (not shown) in instruction fetch unit IFU 25 is full.

命令フエツチユニツトIFU25からは、バス1
03を介して、あらかじめ読み出しておいた命令
がアライナ(ALIG)26に送出される。
From the instruction fetch unit IFU25, bus 1
03, the command read out in advance is sent to the aligner (ALIG) 26.

アライナ26は、デコードユニツトDU27か
らの信号線102に指示されたバイト数だけシフ
ト処理を行い、バス104に該当の命令を送出す
る。
The aligner 26 performs a shift process by the number of bytes specified on the signal line 102 from the decoding unit DU 27, and sends the corresponding command to the bus 104.

信号線102の値を適当に操作することで、バ
ス104には第5図に示すように、命令の第1オ
ペランド指定子処理時には、左端にオペコード
OPが、続いて第1番目のオペランド指定子が並
ぶように、2番目以降のオペランド指定子処理時
には、1バイトのダミーをおいてオペランド指定
子が配置して出力される。上記制御は、後で詳し
く説明する。
By appropriately manipulating the value of the signal line 102, as shown in FIG.
When processing the second and subsequent operand specifiers, the operand specifiers are arranged with a 1-byte dummy and output so that the OP is lined up followed by the first operand specifier. The above control will be explained in detail later.

デコードユニツト(DU)27は、アライナ2
6(ALIG)より送出されたオペコード及びオペ
ランド指定子をデコードして、アドレス計算ユニ
ツトAU28へ下記の情報を送る。
The decoding unit (DU) 27 is the aligner 2
6 (ALIG) and sends the following information to address calculation unit AU28.

(1) バス105を介してアドレツシングモードを
送る。
(1) Send addressing mode via bus 105.

アドレツシングモードには、先に説明の如
く、次の(a)〜(h)があり、このうち1つが指定さ
れる。
As explained above, the addressing mode includes the following (a) to (h), one of which is designated.

(a):レジスタ直接……No.1 (b):Rn……No.2 (c):Rn+DISPタイプ……No.3、5、7 (d):Rn+DISPインダイレクトタイプ……
No.4、6、8 (e):イミーデイエツト……No.9、10、11 (f):PC+DISPタイプ……No.12、14、16 (g):PC+DISPインダイレクトタイプ……
No.13、15、17 (h):(b)〜(d)でインデツクス付タイプ……No.18
〜24 尚No.1〜No.24は第2図Bに示すオペランド
指定子フオーマツトのNo.1〜24に対応してい
る。
(a): Register direct...No.1 (b): Rn...No.2 (c): Rn+DISP type...No.3, 5, 7 (d): Rn+DISP indirect type...
No.4, 6, 8 (e): Immediate type...No.9, 10, 11 (f): PC+DISP type...No.12, 14, 16 (g): PC+DISP indirect type...
No.13, 15, 17 (h): (b) to (d) with index type...No.18
~24 Note that No. 1 to No. 24 correspond to No. 1 to No. 24 of the operand specifier format shown in FIG. 2B.

(2) バス106を介して、DISPまたはイミーデ
イエツトデータを32ビツトで送る。
(2) Send DISP or immediate data in 32 bits via bus 106.

(3) バス107を介してジエネラルレジスタRn
のアドレスを送る。
(3) General register Rn via bus 107
Send the address.

(4) バス108を介してインデツクスレジスタ
RRxのアドレス、 および (5) バス116を介してアドレス演算に使用する
プログラムカウンタの値を送る。
(4) Index register via bus 108
Sends the address of RRx, and (5) the value of the program counter used for address calculation via bus 116.

アドレス計算ユニツトAU28は、バス105
によつて示されたアドレツシングモードに従い、
上記(a)、(e)以外の時は、オペランドのアドレス計
算を行い、バス109に計算後のアドレスを送出
する。
The address calculation unit AU28 is connected to the bus 105.
According to the addressing mode indicated by
In cases other than (a) and (e) above, the operand address is calculated and the calculated address is sent to the bus 109.

一方、(a)の場合は、バス107の内容を、その
まゝバス113に送出し、(e)の場合はバス106
の内容をバス109に送出する。
On the other hand, in the case of (a), the contents of the bus 107 are sent as is to the bus 113, and in the case of (e), the contents of the bus 107 are sent as is to the bus 113.
The contents of the message are sent to the bus 109.

オペランドフエツチユニツトOFU29は、上
記(a)、(e)以外の時は、送られたアドレスが示され
ているバス109の内容を、バス110に送出
し、オペランドがリード時には、オペランドキヤ
ツシユ22にリード処理を要求する。
In cases other than (a) and (e) above, the operand fetch unit OFU 29 sends the contents of the bus 109 indicated by the sent address to the bus 110, and when the operand is read, it sends the contents of the bus 109 to the operand cache 22. request read processing.

リードオペランドが、オペランドキヤツシユ2
2からバス111に送出されると、オペランドフ
エツチユニツトOFU29は、バス112を介し
て実行ユニツトEU30に、読み出されたオペラ
ンドを送出し、またオペランドがそろつた旨を連
絡する。
Read operand is operand cache 2
2, the operand fetch unit OFU 29 sends the read operand to the execution unit EU 30 via the bus 112 and notifies that the operands are ready.

オペランドがライト時は、実行ユニツトEU3
0からの書き込みデータが、バス111に出力さ
れるまで、オペランドフエツチユニツトOFU2
9は、アドレスをバス110に送出し続ける。
When the operand is written, execution unit EU3
Operand fetch unit OFU2 continues until write data from 0 is output to bus 111.
9 continues to send addresses onto bus 110.

一方、上記(a)に対しては、オペランドフエツチ
ユニツトOFU29は、アドレス計算ユニツトAU
28より送出されたレジスタアドレス113によ
り、自身が有するジユネラルレジスタ(図示せ
ず)のアクセスを行う。(a)以外と異なるのは、メ
モリアクセスするか、レジスタをアクセスするか
の差異のみである。
On the other hand, for (a) above, the operand fetch unit OFU29 is the address calculation unit AU.
The register address 113 sent from 28 accesses the universal register (not shown) that it has. The only difference from (a) is whether memory access or register access is performed.

また、(e)に対しては、バス109の内容をその
ままバス111に送出し、実行ユニツトEU30
にオペランドがそろつた旨を連絡する。
For (e), the contents of the bus 109 are sent as they are to the bus 111, and the execution unit EU30
Notify that the operands are available.

また、実行ユニツトEU30は、デコードユニ
ツトDU27からオペコードバス114を介して
送出されたマイクロプログラムの先頭アドレスを
受信し、リード時は、バス112のオペランドを
用いて、ライト時は、オペランド(データ)をバ
ス111に出力して順次、命令の処理を行う。
The execution unit EU30 also receives the start address of the microprogram sent from the decoding unit DU27 via the opcode bus 114, and uses the operands on the bus 112 when reading, and uses the operands (data) when writing. The commands are output to the bus 111 and sequentially processed.

また、命令が分岐命令の場合は、バス115を
用いて、新たなプログラムカウンタ値を命令フエ
ツチユニツトIFU25のプログラムカウンタ50
や、後述するデコードユニツトDU27内のDPレ
ジスタ69にセツトすると同時に、パイプライン
処理で先行的に処理されていたオペランドの各ユ
ニツトにおける処理結果をキヤンセルさせる。
If the instruction is a branch instruction, the new program counter value is sent to the program counter 50 of the instruction fetch unit IFU 25 using the bus 115.
At the same time, the processing result in each unit of the operand that was previously processed in the pipeline processing is canceled.

以上が、1つのオペランド指定子に対する処理
の概略で、各ユニツト25〜30は、パイプライ
ン処理で、順次オペランド指定子の処理を並列に
処理してく。
The above is an outline of the processing for one operand specifier, and each unit 25 to 30 sequentially processes the operand specifiers in parallel using pipeline processing.

次に、本発明の要旨に関係するデコードユニツ
ト27について、具体例を示し詳細に説明する。
Next, the decoding unit 27 related to the gist of the present invention will be described in detail with reference to a specific example.

第4図は、第3図に示すデコードユニツトDU
27の具体的な実施例を示すブロツク図である。
Figure 4 shows the decoding unit DU shown in Figure 3.
FIG. 27 is a block diagram showing a specific example of No. 27.

DPレジスタ69は、デコードユニツトDU27
がデコードする命令の先頭を示しており、第1番
目のオペランド指定子デコード時は、オペコード
のアドレスを、第2番目以下のデコード時は、該
当オペランド指定子の先頭−1のアドレスを示し
ている。
The DP register 69 is connected to the decoding unit DU27.
indicates the beginning of the instruction to be decoded, and when decoding the first operand specifier, it indicates the address of the opcode, and when decoding the second and subsequent operand specifiers, it indicates the address of the first minus one of the corresponding operand specifier. .

上記アドレスは、バス102を介して第3図に
示すアライナALIG26、命令フエツチユニツト
IFU25に送出されているため、バス104に
は、第5図に示すように、1バイト目には、第1
オペランド指定子の読み出しの場合は、Aに示す
ように、オペコードOP、第2オペランド指定子
以下の読み出しの場合は、Bに示すように、ダミ
ーのデータ、第2バイト目には、終了フラツグS
を含んだオペランド指定子の先頭バイトが、第3
バイト目から第7バイト目には、オペランド指定
子のその他の情報が出力される。
The above address is sent via bus 102 to the aligner ALIG 26 and instruction fetch unit shown in FIG.
Since it is sent to the IFU 25, the first byte is sent to the bus 104 as shown in FIG.
When reading an operand specifier, as shown in A, the operation code is OP. When reading from the second operand specifier and below, as shown in B, dummy data is written, and the end flag S is placed in the second byte.
The first byte of the operand specifier containing
Other information of the operand specifier is output from the 7th byte to the 7th byte.

バス204は、第何番目のオペランドの処理を
しているかを示す情報で、本情報が全オペランド
処理終了を示している時、バス104の第1バイ
トはオペコードレジスタ64にセツトされる。
The bus 204 is information indicating which operand is being processed, and when this information indicates that all operands have been processed, the first byte of the bus 104 is set in the opcode register 64.

オペコードレジスタ64の出力は、該当命令の
実行ユニツトEU30のマイクロプログラムの先
頭アドレスを求めるオペコードデコードユニツト
61と、該当命令のオペランドに対する情報を有
するオペランド情報ROM63に送られる。
The output of the operation code register 64 is sent to the operation code decode unit 61 which obtains the start address of the microprogram of the execution unit EU 30 of the relevant instruction, and to the operand information ROM 63 which has information regarding the operand of the relevant instruction.

ROM61の出力結果201は先頭アドレスレ
ジスタ62にセツトされ、オペコードバス114
を介して、第1オペランドがオペランドフエツチ
ユニツトOFU29から実行ユニツトEU30に渡
されるのに同期して、EU30に送出される。
The output result 201 of the ROM 61 is set in the start address register 62 and is sent to the operation code bus 114.
is sent to the EU 30 via the first operand synchronously with the first operand being passed from the operand fetch unit OFU 29 to the execution unit EU 30.

ROM63は、例えば第6図に示す構成で、そ
の中には、第6図に示すような情報があらかじめ
入力されており、オペコードと第何番目のオペラ
ンドの処理であるかの情報をアドレスとして読み
出される。
The ROM 63 has the configuration shown in FIG. 6, for example, and the information shown in FIG. 6 is input in advance, and the information about the operation code and the number of the operand to be processed is read out as an address. It can be done.

すなわち、オペコードレジスタ64に、第1バ
イト目がセツトされた時には、セレクタSEL81
で、バス200側が選ばれるため、オペコードを
アドレスとして、その第1オペランドに関する情
報が読み出される。
That is, when the first byte is set in the operation code register 64, the selector SEL81
Since the bus 200 side is selected, information regarding the first operand is read using the opcode as an address.

読み出された情報としては、 (1) オペランドの属性、すなわち、リードオペラ
ンドであるか、ライトオペランドであるかの情
報R/Wや、オペランドのデータ長L(バイ
ト、ワード、ロングワード)を示す情報、 (2) オペランドの最終であることを示すフラツ
グ、および、 (3) 同一命令の次オペランドの情報が入つている
アドレス、 がある。
The information read out includes: (1) Attributes of the operand, that is, information indicating whether it is a read operand or a write operand, R/W, and the data length L (byte, word, long word) of the operand. (2) a flag indicating the last operand; and (3) an address containing information about the next operand of the same instruction.

(1)はユニツト105−1に出力され、アドレス
計算ユニツトAU28に出力され、また(2)は、バ
ス203に出力され、デコード処理終了バイト数
検出器65に送出される。
(1) is output to the unit 105-1 and then to the address calculation unit AU28, and (2) is output to the bus 203 and sent to the decoding completed byte number detector 65.

また、(2)、(3)の情報は、レジスタ83にラツチ
された後、バス204に出力され、次のオペラン
ドを読み出すアドレスとして使用される。
Furthermore, the information in (2) and (3) is latched in the register 83, then output to the bus 204, and is used as an address for reading the next operand.

(2)の情報のラツチ情報が、セレクタ81の選択
端子Sに入力されるため、(2)の情報が“1”の場
合は、オペコードレジスタ64の内容(200)が
使用され、“0”の場合は(3)の情報が使用され
る。
Since the latch information of the information in (2) is input to the selection terminal S of the selector 81, if the information in (2) is "1", the content (200) of the operation code register 64 is used, and it is set to "0". In this case, the information in (3) is used.

一方、バス104の中で、終了フラツグSを示
す信号線205は、デコード処理終了バイト数検
出器65に送出される。
On the other hand, in the bus 104, a signal line 205 indicating the end flag S is sent to a decoding end byte number detector 65.

また、オペランド指定子の先頭7ビツトは、バ
ス206により、オペランド指定子デコーダ66
に送られる。7ビツトの情報によりオペランド指
定子のデコードを行うが、その例を第7図により
説明する。
Furthermore, the first seven bits of the operand specifier are transferred to the operand specifier decoder 66 via the bus 206.
sent to. The operand specifier is decoded using 7-bit information, and an example thereof will be explained with reference to FIG.

たとえば、第2図BのNo.3に示す(Rn+
DISP8)のオペランド指定子が送られると、第7
図Aのように上位7ビツトの中の更に3ビツトが
010であることを検出して、下記情報が出力でき
る。
For example, as shown in No. 3 in Figure 2B (Rn+
When the operand specifier of DISP 8 ) is sent, the seventh
As shown in Figure A, three more bits of the top seven bits
010 is detected and the following information can be output.

(1) 2バイト長のオペランド指定子であること、 (2) バス208の内容をバス106へ出力する場
合、DISPの桁合せを行うため3バイトの右シ
フトが必要であること、 (3) DISP値として4バイト化を図るため、上位
3バイトについては、DISP8の最上位ビツトを
符号拡張して出力すること、 (4) Rn+DISPでもつてオペランドのアドレスが
計算できること、 (5) Rnの情報は1バイト目の下位4ビツトに存
在すること、 の5つである。同様に、第2図BのNo.7の(Rn
+DISP32)が送られてくると、第7図Bに示すよ
うに上位7ビツトが1110110であることを検出し
て、下記情報が出力できる。
(1) It must be a 2-byte long operand specifier; (2) When outputting the contents of bus 208 to bus 106, a 3-byte right shift is required to align the digits of DISP; (3) In order to convert the DISP value into 4 bytes, the most significant bit of DISP 8 must be sign-extended and output for the upper 3 bytes. (4) The operand address can be calculated using Rn + DISP. (5) Rn information exists in the lower 4 bits of the first byte. Similarly, (Rn
+DISP 32 ) is sent, it detects that the upper 7 bits are 1110110 as shown in FIG. 7B, and the following information can be output.

(1) 6バイト長のオペランド指定子であること、 (2) バス208の内容をバス106へ出力する場
合、DISPの桁合せを行うため1バイト左シフ
トが必要であること、 (3) DISPは32ビツト全てが指定されているため
そのまま出力しなければならないこと、 (4) Rn+PISPでもつてオペランドのアドレスが
計算できること、 (5) Rnの情報は、オペランド指定子の2バイト
目の下位4ビツトに存在すること、 の5つである。
(1) Must be a 6-byte operand specifier; (2) When outputting the contents of bus 208 to bus 106, a 1-byte left shift is required to align the digits of DISP; (3) DISP (4) The address of the operand can be calculated using Rn + PISP. (5) The information on Rn is stored in the lower 4 bits of the second byte of the operand specifier. There are five things: Existence.

以上2つの例につき示したがこれらをまとめて
みると次のようになる。
The two examples above have been shown, but if we summarize them, we get the following.

オペランド指定子デコーダ66は、送られてき
たオペランド指定子をデコードし、次にあげる情
報をそれぞれ出力する。
The operand specifier decoder 66 decodes the received operand specifier and outputs the following information.

(1) バス215へは、オペランド指定子の長さを
バイト単位で出力する。例えば、第2図Bの
No.3のオペランド指定子で、(Rn+DISP8)のオ
ペランド指定子が送られてきた時は、“2”を
出力する。
(1) The length of the operand specifier is output to the bus 215 in bytes. For example, in Figure 2B
When the No. 3 operand specifier (Rn+DISP 8 ) is sent, "2" is output.

(2) バス211へは、デイスプレースメント
(DISP)/イミーデイエツト(IM)データ用
アライナ67に対するシフトバイト数を出力す
る。
(2) The number of shift bytes for the displacement (DISP)/immediate data aligner 67 is output to the bus 211.

例えば、(Rn+DISP8)のオペランド指定子の
場合は、第7図Aに示した如く3バイト右シフ
トを、(Rn+DISP32)の場合は、第7図Bに示
した如く1バイト左シフトを指示する。
For example, the operand specifier (Rn+DISP 8 ) specifies a 3-byte right shift as shown in Figure 7A, and the operand specifier (Rn+DISP 32 ) specifies a 1-byte left shift as shown in Figure 7B. do.

(3) バス212へは、アライナ67に対するマス
クバイトの指示データを出力する。
(3) Mask byte instruction data for the aligner 67 is output to the bus 212 .

これは、アライナ67に対し、バス106に
出力する4バイトのデータ中、上位2バイト、
又は3バイトのマスクを指示することで、1バ
イトや2バイトのDISP、IM情報の符号拡張に
よる4バイト化を図るためのものである。
This is for the aligner 67, of the 4 bytes of data output to the bus 106, the upper 2 bytes,
Alternatively, by instructing a 3-byte mask, 1-byte or 2-byte DISP or IM information is sign-extended to 4-byte information.

例えば、DISP8の時には、第7図Aに示す如
く3バイトシフト、DISP32の時は第7図Bの
如く前に「−Rn」という余分な1バイトがあ
るため、1バイト左シフトする。
For example, when DISP 8 , as shown in FIG. 7A, there is a 3-byte shift, and when DISP 32 , as shown in FIG. 7B, there is an extra byte "-Rn" in front, so there is a 1-byte left shift.

これは、DISP8の時、上3バイトにはDISP8
の符号ビツトを拡張して入れておかないと、32
ビツトの正常なアドレス計算ができないからで
ある。(バス212はその指定のためのもの) (4) バス105−2へはアドレツシングモードを
出力し、これによつてアドレス計算ユニツト
AU28の動作モードを指示する。
This means that when DISP 8 is used, DISP 8 is written in the upper 3 bytes.
If you do not expand the sign bit of
This is because correct bit address calculation cannot be performed. (Bus 212 is for that specification.) (4) Outputs the addressing mode to bus 105-2, thereby controlling the address calculation unit.
Indicates the operating mode of AU28.

アドレツシングモードについては、第3図の
アドレス計算ユニツトAU28の説明に関連し
て、(a)〜(h)の8つのモードがあることを既に説
明した。
Regarding the addressing modes, it has already been explained that there are eight modes (a) to (h) in connection with the explanation of the address calculation unit AU28 in FIG.

(5) バス216へはジエネラルレジスタRnの存
在する位置が、1バイト目か2バイト目かを示
す情報を出力する。
(5) Information indicating whether the general register Rn is located in the first byte or the second byte is output to the bus 216.

(Rn+DISP8)時は1バイト目、(Rn+
DISP32)時には2バイト目が指示される。
(Rn+DISP 8 ), the 1st byte, (Rn+
DISP 32 ) Sometimes the second byte is indicated.

一方、バス108へは、オペランド指定子の中
のインデツクスレジスタRxの部分を出力する。
On the other hand, the portion of the index register Rx in the operand specifier is output to the bus 108.

また、セレクタ68は、信号216で指定され
たジエネラルレジスタRnの存在する位置(1バ
イト目か2バイト目かの信号)によつて、Rnに
対応する部分(バス207の内容或いはバス21
0の内容)をバス107へ出力する。
Furthermore, the selector 68 selects the part corresponding to Rn (the contents of the bus 207 or the bus 21
0 contents) to the bus 107.

アライナ57は、前述したように、オペランド
指定子の2バイト目から7バイト目までがバス2
08によつて与えられるため、信号線211で与
えられたシフト数だけシフト処理を行い、且つ信
号線212で与えられたマスク部に対しては、符
号の拡張を行い、バス106に4バイトのデータ
として出力する。
As mentioned above, the aligner 57 uses the bus 2 bytes 2 to 7 of the operand specifier.
08, the shift processing is performed by the number of shifts given by the signal line 211, and the mask part given by the signal line 212 is sign extended, and 4 bytes are sent to the bus 106. Output as data.

これらは、第7図A,Bに示した通りである。
デコード処理終了バイト数検出器65について説
明する。
These are as shown in FIGS. 7A and 7B.
The decoding completed byte number detector 65 will be explained.

この部分は、本発明になる不定長命令(Sビツ
ト付加したもの)を扱う場合の要部でもある。
This part is also the main part when handling an undefined length instruction (one with S bit added) according to the present invention.

デコード処理終了バイト数検出器65には、前
述した如く、オペランド終了フラツグEを示す信
号線203、オペランド指定子のストツプビツト
Sを示す信号線205及びオペランド指定子のバ
イト数(OSB)を示す信号線215の3つの信号
線が入力されており、信号線214へは、次のオ
ペランド指定子のアドレスを示すため、DP69
の加算値DPINCBをバイト単位で出力する。この
場合のアルゴリズムは次の通りである。
As described above, the decoding processing end byte number detector 65 includes a signal line 203 indicating the operand end flag E, a signal line 205 indicating the stop bit S of the operand specifier, and a signal indicating the number of bytes of the operand specifier (OS B ). Three signal lines, line 215, are input, and DP69 is input to signal line 214 to indicate the address of the next operand specifier.
Outputs the added value DPINC B in bytes. The algorithm in this case is as follows.

E=1であれば、 DPINCB=OSB これ以外で、S=0であれば、 DPINCB=OSB−1 また、S=1であれば DPINCB=0 すなわち、 (1) オペランドの終了フラツグEが“1”の場合
は、該当命令の処理は終了したため、次の命令
の先頭をさすように、DPレジスタ69がオペ
ランド指定子のバイト数分(OSB)加算される
よう信号線214に出力される。
If E = 1, DPINC B = OS B Otherwise, if S = 0, DPINC B = OS B -1 Also, if S = 1, DPINC B = 0 That is, (1) End of operand If the flag E is "1", processing of the corresponding instruction has been completed, and the signal line 214 is added so that the DP register 69 is incremented by the number of bytes of the operand specifier (OS B ) to point to the beginning of the next instruction. is output to.

(2) (1)でなく、また終了フラツグSがセツトされ
ていない場合は、次のオペランド指定子が1バ
イトのダミーを先頭バイトにおいて、バス10
4に出力させるため、(オペランド指定子のバ
イト数:OSB)−1の値が加算されるよう信号
線214に出力される。
(2) If (1) is not met, and the end flag S is not set, the next operand specifier is a 1-byte dummy in the first byte, and the end flag S is not set.
4, it is output to the signal line 214 so that a value of (number of bytes of operand specifier: OS B )-1 is added.

(3) (1)でなく、また終了フラツグSがセツトされ
ている場合は、DPレジスタ69が、そのまゝ
の値をとるよう、“0”が出力される。これに
よつて、同一のオペランド指定子を、次のオペ
ランドに対する処理にも使用することになり、
同一のオペランドが繰返し使用されることにな
る。
(3) If (1) is not satisfied and the end flag S is set, "0" is output so that the DP register 69 takes the same value. This causes the same operand specifier to be used to process the next operand,
The same operand will be used repeatedly.

第8図は、デコード処理終了バイト数検出器6
5における上記アルゴリズムを実現するハードウ
エア構成を示している。
FIG. 8 shows the decoding completed byte number detector 6.
5 shows a hardware configuration for realizing the above algorithm in No. 5.

つまり、E=1の場合は、出力ゲート301が
開き、バス214にはバス215の内容OSBが出
力され、E=0の時は、S=0のとき力ゲート3
03が開き、OSB−1を出力し、またS=1のと
き出力ゲート302が開き、“0”が出力される
ようになつている。
In other words, when E=1, the output gate 301 opens and the content OS B of the bus 215 is output to the bus 214, and when E=0, the output gate 301 opens when S=0.
03 opens and outputs OS B -1, and when S=1, the output gate 302 opens and outputs "0".

本発明においては、Eが“1”の時、Sビツト
が“1”でなければ、オペランド数より多いオペ
ランド指定子が有ることを意味し、これをエラー
として検出しようとするものである。第8図では
アンドゲート304がオンとなり信号105−3
を出力し、アドレス計算ユニツトAU28に対
し、該当エラー発生するようになつている。
In the present invention, if the S bit is not "1" when E is "1", it means that there are more operand specifiers than the number of operands, and this is detected as an error. In FIG. 8, AND gate 304 is turned on and signal 105-3
is output, and the corresponding error occurs in the address calculation unit AU28.

アドレス計算ユニツトAU28では、信号10
5−3を以下のユニツト(オペランドフエツチユ
ニツトOFU29)に連絡し、最終的に実行ユニ
ツトEU30にエラー発生が連絡されるようにな
つている。
In address calculation unit AU28, signal 10
5-3 is communicated to the following unit (operand fetch unit OFU 29), and finally the execution unit EU 30 is notified of the error occurrence.

尚第8図において、304,305はインバー
タ、306,307はアンドゲート、308は減
算器である。
In FIG. 8, 304 and 305 are inverters, 306 and 307 are AND gates, and 308 is a subtracter.

加算器71は、現在のDPレジスタ69の値
と、信号線214の値を加算し、セレクタ70を
介して、DPレジスタ69にセツトすることで次
のオペランド指定子のアドレスをバス102に出
力することが可能となる。これにより、アライナ
ALIG26は、次のオペランド指定子を第5図
A,Bに示すフオーマツトでバス104に出力で
きる。
The adder 71 adds the current value of the DP register 69 and the value of the signal line 214, and outputs the address of the next operand specifier to the bus 102 by setting it in the DP register 69 via the selector 70. becomes possible. This allows the aligner
ALIG 26 can output the next operand specifier to bus 104 in the format shown in FIGS. 5A and 5B.

一方、セレクタ70によつて、バス115の内
容を選択してDPレジスタ69にセツトすること
で前述した分岐命令におけるDPレジスタ69の
変更も可能となる。
On the other hand, by selecting the contents of the bus 115 and setting them in the DP register 69 using the selector 70, it is also possible to change the DP register 69 in the aforementioned branch instruction.

尚加算器72は、DPレジスタ69の値に、該
当オペランド指定子の長さを示す信号線215の
値(OSB)を加え、さらにキヤリー入力“1”を
加えることで、デコードしているオペランド指定
子の次のアドレスをバス116に出力する。
The adder 72 adds the value of the signal line 215 (OS B ) indicating the length of the corresponding operand specifier to the value of the DP register 69, and further adds a carry input "1" to the value of the operand being decoded. Outputs the next address of the specifier onto bus 116.

アドレス計算ユニツトAU28は、バス116
の内容をアドレス計算に使用するプログラムカウ
ンタPCの値として利用する。
The address calculation unit AU28 is connected to the bus 116.
The contents of are used as the value of the program counter PC used for address calculation.

このように、本発明によれば、オペランド数と
オペランド指定子の個数の合理性チエツクを行う
ことにより、エラー検出率を向上させることがで
きる。
As described above, according to the present invention, the error detection rate can be improved by checking the rationality of the number of operands and the number of operand specifiers.

尚上記実施例においては、終了フラツグSはオ
ペランド指定子の最上位ビツトに付加されている
が、必ずしもこの部分に限定する必要はなく、オ
ペランド指定子のどこかに終了フラツグを設けれ
ばよい。
In the above embodiment, the end flag S is added to the most significant bit of the operand specifier, but it is not necessarily limited to this part, and the end flag may be provided somewhere in the operand specifier.

また、同一のオペランドを複数回繰返し、利用
するのに、上記実現例では、DPレジスタ69の
内容を更新させずに、同一のオペランド指定子を
繰返しデコードすることによりこれを実現してい
るが、これ以外にもデコードユニツトから実行ユ
ニツトEU30に特別な信号を送り、先に求めら
れたオペランドを繰返し利用するように指示して
もよい。
Furthermore, in the above implementation example, the same operand is repeatedly used multiple times by repeatedly decoding the same operand specifier without updating the contents of the DP register 69. In addition to this, a special signal may be sent from the decoding unit to the execution unit EU30 to instruct it to repeatedly use the previously requested operand.

第9図はオペランド指定子の1ビツトに終了フ
ラツグSを設けることで、AOPB→Cのレパート
リーに対し同一オペコード(OP)で各種のオペ
ランド指定が可能なことを示し、同時にエラー検
出可能な命令を示している。すなわち、Sビツト
によつてオペランド指定が終了したことを指示さ
れるため、OPで必要となるオペランド数より少
ないオペランドでSの指示があると、それを繰返
し使用し、A、B、Cの3つのオペランドを指定
しているのにCの部分でSの指示がないとエラー
として検出する。
Figure 9 shows that by setting an end flag S in one bit of the operand specifier, it is possible to specify various operands with the same opcode (OP) for the AOPB→C repertoire, and at the same time, it is possible to specify an instruction that can detect errors. It shows. In other words, since the S bit indicates that the operand specification has ended, if S is specified with fewer operands than the number of operands required by the OP, it will be used repeatedly and the three operands A, B, and C will be used. If two operands are specified but S is not specified in the C part, it will be detected as an error.

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

第1図は本発明が適用されるデータ処理システ
ムの基本的な概念図、第2図A,Bは本発明に使
用される不定長命令のフオーマツト及び、オペラ
ンド指定子のフオーマツトを示す図、第3図は第
1図の中央処理装置の具体的な一実施例ブロツク
構成図、第4図は、本発明の要部である第3図の
デコードユニツトの具体的な一実施例ブロツク
図、第5図は第4図の説明に用いられるオペラン
ド指定子のフオーマツト、第6図は第4図のオペ
ランド情報ROM63の内容を説明するための説
明図、第7図は第4図のオペランド指定子デコー
ド66の動作説明に用いる説明図、第8図は、第
4図のデコード処理終了バイト数検出器65のハ
ード構成を示す一実施例図、第9図は本発明によ
る各種のオペランド指定およびエラー検出可能な
命令を示す説明図である。 27……デコードユニツト、61……オペコー
ドデコードユニツト、63……オペランド情報
ROM、65……デコード処理終了バイト数検出
器、66……オペランド指定子デコーダ。
FIG. 1 is a basic conceptual diagram of a data processing system to which the present invention is applied, FIGS. 3 is a block diagram of a specific embodiment of the central processing unit shown in FIG. 1, and FIG. 4 is a block diagram of a specific embodiment of the decoding unit of FIG. Figure 5 is the format of the operand specifier used to explain Figure 4, Figure 6 is an explanatory diagram to explain the contents of the operand information ROM 63 in Figure 4, and Figure 7 is the operand specifier decoding in Figure 4. 66, FIG. 8 is an example diagram showing the hardware configuration of the decoding completed byte number detector 65 shown in FIG. 4, and FIG. 9 shows various operand specifications and error detection according to the present invention. It is an explanatory diagram showing possible commands. 27...Decode unit, 61...Opcode decode unit, 63...Operand information
ROM, 65...Detector for number of bytes at the end of decoding process, 66...Operand specifier decoder.

Claims (1)

【特許請求の範囲】[Claims] 1 オペランドのアドレツシングモードを指定す
るオペランド指定子が処理の種類およびオペラン
ドの数を指定するオペコード部分から独立してい
る命令を扱うデータ処理装置において、該命令
は、少なくともオペランド指定子に対応して付加
されたオペランド指定子の終了情報を含み、デコ
ード手段は、少なくともオペコードデコード手段
と、オペランド指定子デコード手段とオペランド
指定子に付加された終了情報の検出を行う終了フ
ラツグ検出手段を有し、該オペコードデコード手
段が、当該命令の最後のオペランドであることを
示す信号を出力したとき、該終了情報検出手段が
終了情報のセツトを検出しない場合、当該命令を
エラーとして検出するようにしたことを特徴とす
る不定長命令のエラー検出を行うデータ処理装
置。
1. In a data processing device that handles an instruction in which an operand specifier that specifies the addressing mode of an operand is independent from an opcode part that specifies the type of processing and the number of operands, the instruction The decoding means includes at least operation code decoding means, operand specifier decoding means, and end flag detection means for detecting the end information added to the operand specifier, When the operation code decoding means outputs a signal indicating that it is the last operand of the instruction, if the end information detection means does not detect the set of end information, the instruction is detected as an error. A data processing device that detects errors in undefined length instructions.
JP56132717A 1981-08-26 1981-08-26 Data processing device for error detection of undefined length instruction Granted JPS5835643A (en)

Priority Applications (6)

Application Number Priority Date Filing Date Title
JP56132717A JPS5835643A (en) 1981-08-26 1981-08-26 Data processing device for error detection of undefined length instruction
US06/408,924 US4530050A (en) 1981-08-26 1982-08-17 Central processing unit for executing instructions of variable length having end information for operand specifiers
DE8282107598T DE3278442D1 (en) 1981-08-26 1982-08-19 Central processing unit for executing instructions of variable length
EP82107598A EP0073424B1 (en) 1981-08-26 1982-08-19 Central processing unit for executing instructions of variable length
KR8203773A KR880000297B1 (en) 1981-08-26 1982-08-23 Central processing unit for executing instructions of variable length
CA000410221A CA1186801A (en) 1981-08-26 1982-08-26 Central processing unit for executing instructions of variable length

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP56132717A JPS5835643A (en) 1981-08-26 1981-08-26 Data processing device for error detection of undefined length instruction

Publications (2)

Publication Number Publication Date
JPS5835643A JPS5835643A (en) 1983-03-02
JPS6149693B2 true JPS6149693B2 (en) 1986-10-30

Family

ID=15087925

Family Applications (1)

Application Number Title Priority Date Filing Date
JP56132717A Granted JPS5835643A (en) 1981-08-26 1981-08-26 Data processing device for error detection of undefined length instruction

Country Status (1)

Country Link
JP (1) JPS5835643A (en)

Also Published As

Publication number Publication date
JPS5835643A (en) 1983-03-02

Similar Documents

Publication Publication Date Title
KR100327778B1 (en) Data processing method using multiple instruction sets
KR880000297B1 (en) Central processing unit for executing instructions of variable length
KR100327776B1 (en) Data processing method using multiple instruction sets
US5694587A (en) Specialized millicode instructions for test PSW validity, load with access test, and character translation assist
US4398245A (en) Data processing system having an instruction pipeline for processing a transfer instruction
EP0220684B1 (en) Data processing system
JP3203401B2 (en) Data processing device
JPH0429093B2 (en)
US5802359A (en) Mapping processor state into a millicode addressable processor state register array
JPH10232779A (en) Method and device for parallel instruction processing
JPH07120278B2 (en) Data processing device
EP0010197B1 (en) Data processing system for interfacing a main store with a control sectron and a data processing section
JPS645330B2 (en)
JPH07120338B2 (en) Method for a data processor to coordinate the execution of instructions by a coprocessor and the data processor
JP2006527420A (en) Coding data access program instructions
JP2000137612A (en) Method for setting condition and conducting test by special millicode instruction
JPS6149692B2 (en)
JPS6160459B2 (en)
JPS6149693B2 (en)
US5754810A (en) Specialized millicode instruction for certain decimal operations
JPS623336A (en) Conditional branch system
JPS6149694B2 (en)
US4812989A (en) Method for executing machine language instructions
JPS6355634A (en) Data processing system
JP2824484B2 (en) Pipeline processing computer