JPH04245336A - Information processor - Google Patents

Information processor

Info

Publication number
JPH04245336A
JPH04245336A JP1044691A JP1044691A JPH04245336A JP H04245336 A JPH04245336 A JP H04245336A JP 1044691 A JP1044691 A JP 1044691A JP 1044691 A JP1044691 A JP 1044691A JP H04245336 A JPH04245336 A JP H04245336A
Authority
JP
Japan
Prior art keywords
vector number
vector
interrupt
cpu
generated
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
JP1044691A
Other languages
Japanese (ja)
Inventor
Noribumi Yoshimatsu
吉松 則文
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 JP1044691A priority Critical patent/JPH04245336A/en
Publication of JPH04245336A publication Critical patent/JPH04245336A/en
Pending legal-status Critical Current

Links

Landscapes

  • Bus Control (AREA)

Abstract

PURPOSE:To outputs an optional interruption vector number from the output of a generated vector number holding means by setting a vector transforming table in a CPU, and to enable a compatible operation even when an application program is altered. CONSTITUTION:An internal vector number holding means 11 holds an alternable interruption vector number outputted from the CPU, a decoding means 12 decodes the specific bits of the interruption vector number from the internal vector number holding means, and a vector transforming means 13 selects the interruption vector signal held previously with the output of the decoding means. The generated vector number holding means 14 generates an interruption vector number newly from the selected interruption vector number from the vector transforming means 13 and a part of the interruption vector number of the internal vector holding means 11.

Description

【発明の詳細な説明】[Detailed description of the invention]

【0001】0001

【産業上の利用分野】本発明は、割込み処理を行う情報
処理装置に関し、特に変更可能な任意の割込みベクタ番
号を生成する情報処理装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an information processing apparatus that performs interrupt processing, and more particularly to an information processing apparatus that generates an arbitrary changeable interrupt vector number.

【0002】0002

【従来の技術】制御装置および演算装置(以下総称して
CPUという)を使った情報処理装置においては、CP
Uは、通常の処理を行っている最中に、もし外部あるい
は内部から割込み要求があると、一時通常の処理を中断
し、予め用意されている割込み処理用のプログラムを実
行するように作られている。この様な割込み処理を行う
場合、CPUは、特定の割込み要因に対し、割込み要因
に特有な割込みベクタ番号を生成する。
[Prior Art] In an information processing device using a control device and an arithmetic device (hereinafter collectively referred to as a CPU), the CPU
U is designed to temporarily suspend normal processing and execute a pre-prepared interrupt processing program if an interrupt request is received from the outside or internally during normal processing. ing. When performing such interrupt processing, the CPU generates, for a specific interrupt factor, an interrupt vector number unique to the interrupt factor.

【0003】図3は、NEC製のCPUの、V30にお
ける割込み処理の概要を示すブロック図であり、この割
込み処理ブログラムのアドレスを受取るまでの方法を簡
単に説明する。
FIG. 3 is a block diagram showing an overview of interrupt processing in V30 of a CPU manufactured by NEC, and a method for receiving the address of this interrupt processing program will be briefly explained.

【0004】V30の割込み要因として、例えばNMI
(マスク不可能割込み)入力26による外部割込みが発
生した場合、CPU21は、まずNMI入力26に対し
決められている割込みベクタ「2」を生成する。CPU
21は割込みベクタ「2」を4倍したアドレスである「
8」番地のアドレスを出力し、外部記憶装置23の「8
」番地の該当アドレスに設定されている値24を読み込
む。
[0004] As an interrupt factor of V30, for example, NMI
(Non-maskable interrupt) When an external interrupt occurs due to the input 26, the CPU 21 first generates an interrupt vector "2" determined for the NMI input 26. CPU
21 is the address that is 4 times the interrupt vector “2”.
8” address of the external storage device 23 is output.
” The value 24 set in the corresponding address is read.

【0005】この8番地のアドレスには、割込み処理プ
ログラム25の置いてあるアドレスが、予め設定されて
いる。このCPU21は、この読込んだ値24を割込み
処理の開始アドレスとして割込み処理を開始する。
[0005] The address where the interrupt processing program 25 is located is set in advance at this address No. 8. The CPU 21 starts interrupt processing using the read value 24 as the interrupt processing start address.

【0006】この様なCPUが生成する割込みベクタ番
号は、幾つかの特定の割込み要因に対しCPUに固有の
値を持ち、例えばNEC製CPUのV30では、NMI
入力による割込みではベクタ番号「2」であり、ゼロ除
算による割込みでは、ベクタ番号「0」が生成される。 また、同一の命令コードをもつCPUの間でも、特定の
割込み要因に対して生成される割込みベクタ番号が異な
る場合もある。
[0006] The interrupt vector number generated by such a CPU has a value unique to the CPU for some specific interrupt factors. For example, in NEC's CPU V30, the NMI
For interrupts caused by input, the vector number is "2", and for interrupts caused by division by zero, vector number "0" is generated. Further, even among CPUs having the same instruction code, the interrupt vector numbers generated for a specific interrupt factor may differ.

【0007】[0007]

【発明が解決しようとする課題】一般に性能や機能を拡
張したCPUが作られる場合、新たに作られたCPUで
、それまで使われていたアプリケーション・プログラム
が実行できなければ、新たに作られたCPUでも実行で
きるように、再びアプリケーション・プログラムを作り
直さなければならず、アプリケーション・プログラムの
数が多ければ、大きな欠点となる。そのためこの性能や
機能を拡張してCPUが新たに作られる場合でも、それ
まで使われていたアプリケーション・プログラムが同様
に実行できるように、命令セットで互換性があるような
設計がなされている。
[Problem to be solved by the invention] Generally, when a CPU with expanded performance and functionality is created, if the newly created CPU cannot run the application program that was previously used, the newly created CPU will Application programs must be rewritten so that they can be executed by a CPU, which is a major drawback if the number of application programs is large. Therefore, even when new CPUs are created with enhanced performance and functionality, they are designed to have compatible instruction sets so that application programs that were previously used can be executed in the same way.

【0008】しかし、同様に命令実行を行うよう設計さ
れたCPUにおいても、機能拡張の要求などのため、特
定の割込み処理時に、CPUが生成する割込みベクタ番
号を、それまでとは違った番号にしなければならない場
合がある。この割込みベクタ番号が違うため、幾つかの
アプリケーション・プログラムで、同じ動作をしなくな
ることも起こりうる。
However, even in a CPU designed to execute instructions in the same way, due to requests for functional expansion, the interrupt vector number generated by the CPU during specific interrupt processing is changed to a different number than before. There are times when you have to. Because these interrupt vector numbers are different, some application programs may not perform the same operations.

【0009】また、同じアプリケーション・プログラム
を実行するために、幾つかのCPUで同一の命令セット
を採用し、同様に命令実行を行う場合があるが、この同
一の命令セットを持ち同様に命令実行を行うCPUの間
でも、割込み処理に関しては、特定の割込み要因に対し
てCPUの生成する割込みベクタ番号が異なる場合があ
る。
[0009] Furthermore, in order to execute the same application program, several CPUs may employ the same instruction set and execute instructions in the same way; Even among CPUs that perform interrupt processing, the interrupt vector numbers generated by the CPUs may differ for a specific interrupt factor.

【0010】従来のCPUでは、同一の命令セットを持
ったCPUの間で、特定の割込み要因に対し、CPUの
生成する割込みベクタ番号が異なるため、同一のアプリ
ケーション・プログラムを実行できない場合があるとい
う欠点を有していた。
[0010] In conventional CPUs, the same application program may not be able to be executed between CPUs with the same instruction set because the interrupt vector numbers generated by the CPUs are different for a specific interrupt factor. It had drawbacks.

【0011】本発明の目的は、このような問題を解決し
、CPUの内部に特定の割込み要因が発生したときに、
CPUが生成する割込みベクタ番号を、ベクタ変換テー
ブルに保持しておき、割込み要因が発生したときCPU
が生成する割込みベクタ番号を、このベクタ変換テーブ
ルの値に変換して生成するので、CPUが生成する割込
みベクタ番号を自由に変更することができるようにした
情報処理装置を提供することにある。
[0011] The purpose of the present invention is to solve such problems, and when a specific interrupt factor occurs inside the CPU,
The interrupt vector number generated by the CPU is stored in the vector conversion table, and when an interrupt factor occurs, the CPU
An object of the present invention is to provide an information processing device in which the interrupt vector number generated by a CPU can be freely changed since the interrupt vector number generated by the CPU is generated by converting it into the value of this vector conversion table.

【0012】0012

【課題を解決するための手段】本発明の情報処理装置の
構成は、CPUから出力される変更可能な割込みベクタ
番号を保持する内部ベクタ番号保持手段と、この内部ベ
クタ番号保持手段からの割込みベクタ番号のうち所定ビ
ットをデコードするデコード手段と、このデコード手段
の出力によって予め保持された割込みベクタ番号を選択
するベクタ変換手段と、このベクタ変換手段からの選択
された割込みベクタ番号と前記内部ベクタ保持手段の割
込みベクタ番号の一部とから新たに割込みベクタ番号を
生成し保持する生成ベクタ番号保持手段とを有し、この
生成ベクタ番号保持手段の出力により任意の割込みベク
タ番号を出力できるようにした事を特徴とする。
[Means for Solving the Problems] The configuration of the information processing device of the present invention includes an internal vector number holding means for holding a changeable interrupt vector number output from a CPU, and an interrupt vector number from the internal vector number holding means. a decoding means for decoding a predetermined bit of the number; a vector converting means for selecting an interrupt vector number previously held by the output of the decoding means; and an interrupt vector number selected from the vector converting means and holding the internal vector. The generated vector number holding means generates and holds a new interrupt vector number from a part of the interrupt vector number of the means, and an arbitrary interrupt vector number can be output by the output of the generated vector number holding means. characterized by things.

【0013】[0013]

【実施例】図1は本発明の一実施例を示すブロック図で
ある。本実施例においては、内部ベクタ番号レジスタ1
1は、従来CPUが割込みベクタ番号として生成してい
た16ビット幅の値を保持される。この内部ベクタ番号
(11)として生成される値が0から255までの値で
あれば、割込みベクタ番号(14)は内部ベクタ番号の
下位8ビットで表すことができ、上位8ビットは常に0
である。従って、ベクタ変換テーブル13には生成され
る割込みベクタ番号の下位8ビットの値のみを保持する
。デコーダ12は、内部ベクタ番号11の下位8ビット
をデコードし、ベクタ変換テーブル13に設定されてい
る値を順に選択する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 is a block diagram showing an embodiment of the present invention. In this embodiment, internal vector number register 1
1 is held as a 16-bit wide value that was conventionally generated by the CPU as an interrupt vector number. If the value generated as this internal vector number (11) is a value from 0 to 255, the interrupt vector number (14) can be represented by the lower 8 bits of the internal vector number, and the upper 8 bits are always 0.
It is. Therefore, the vector conversion table 13 holds only the values of the lower 8 bits of the generated interrupt vector number. The decoder 12 decodes the lower 8 bits of the internal vector number 11 and sequentially selects the values set in the vector conversion table 13.

【0014】割込み要因が発生すると、まずCPUは、
内部ベクタ番号レジスタ11に生成した内部ベクタ番号
を保持し、デコーダ12は、内部ベクタ番号レジスタ1
1の下位8ビットを見て、ベクタ変換テーブル13から
割込みベクタ番号の下位8ビットを選択する。そして1
6ビットの割込みベクタ番号を割込みベクタ番号レジス
タ14に保持して、内部ベクタ番号レジスタ11の上位
8ビットとベクタ変換テーブル13から選択された割込
みベクタ番号の下位8ビットとが割込みベクタ番号とし
て出力される。
[0014] When an interrupt factor occurs, the CPU first
The generated internal vector number is held in the internal vector number register 11, and the decoder 12 stores the generated internal vector number in the internal vector number register 1.
Look at the lower 8 bits of 1 and select the lower 8 bits of the interrupt vector number from the vector conversion table 13. and 1
A 6-bit interrupt vector number is held in the interrupt vector number register 14, and the upper 8 bits of the internal vector number register 11 and the lower 8 bits of the interrupt vector number selected from the vector conversion table 13 are output as the interrupt vector number. Ru.

【0015】図2は本発明の別の実施例を示すブロック
図である。本実施例では、第1の実施例に加え、特定の
割込み要因によってCPU内部で発生し内部ベクタ番号
レジスタ11に保持した内部ベクタ番号と、この内部ベ
クタ番号レジスタ11からの出力に対してベクタ変換テ
ーブル13aを使って変換され生成ベクタ番号レジスタ
16に保持した生成ベクタ番号のどちらを割込みベクタ
番号として割込みベクタ番号レジスタ14に出力するか
を選択するため、選択ビット15を、割込みベクタ変換
テーブル13aに持たせている。この選択ビット15が
「0」ならば、割込みベクタ番号として内部ベクタ番号
を出力し、レジスタ11に保持させ、選択ビット15が
「1」ならば、生成ベクタ番号を出力しレジスタ16に
保持させる。この選択ビット15もベクタ変換テーブル
13aの設定時に同時に設定される。
FIG. 2 is a block diagram showing another embodiment of the invention. In this embodiment, in addition to the first embodiment, vector conversion is performed for the internal vector number generated inside the CPU by a specific interrupt factor and held in the internal vector number register 11, and the output from this internal vector number register 11. In order to select which of the generated vector numbers converted using the table 13a and held in the generated vector number register 16 is to be output to the interrupt vector number register 14 as an interrupt vector number, select bit 15 is set in the interrupt vector conversion table 13a. I have it. If the selection bit 15 is "0", the internal vector number is output as the interrupt vector number and held in the register 11, and if the selection bit 15 is "1", the generated vector number is output and held in the register 16. This selection bit 15 is also set at the same time as setting the vector conversion table 13a.

【0016】CPUに割込み要因が発生し、内部ベクタ
番号(11)からベクタ変換テーブル13aを使って生
成ベクタ番号(16)が生成されるまでの過程は、第1
の実施例と同様である。
The process from when an interrupt factor occurs in the CPU to generating the generated vector number (16) from the internal vector number (11) using the vector conversion table 13a is the first step.
This is similar to the embodiment.

【0017】本実施例では、さらにデコーダ12により
ベクタ変換テーブル13aのベクタ番号が選択される時
、同時にアドレス選択ビット15も選択される。そして
CPUから出力される割込みベクタ番号レジスタ14の
割込みベクタ番号として、セレクタ17はアドレス選択
ビット15が「0」ならば、変換されていない内部ベク
タ番号を出力しレジスタ11に保持し、選択ビット15
が「1」ならば、レジスタ11の内部ベクタ番号が変換
されたレジスタ16からの生成ベクタ番号を割込みベク
タ番号14として選択する。
In this embodiment, when the decoder 12 selects the vector number in the vector conversion table 13a, the address selection bit 15 is also selected at the same time. Then, as the interrupt vector number of the interrupt vector number register 14 output from the CPU, if the address selection bit 15 is "0", the selector 17 outputs an unconverted internal vector number, holds it in the register 11, and selects the selection bit 15.
If is "1", the generated vector number from the register 16 into which the internal vector number of the register 11 has been converted is selected as the interrupt vector number 14.

【0018】[0018]

【発明の効果】以上説明したように本発明によれば、ア
プリケーション・プログラムでの互換性の問題に対して
アプリケーション・プログラムの実行の前に、CPU内
部にあるベクタ変換テーブルを設定する事により、特定
の割込み要因に対してCPUが生成する割込みベクタ番
号を、任意に変換する事ができ、同様に命令実行を行い
ながら、割込みベクタ番号が違うためにアプリケーショ
ン・プログラムが異なった動作をするという不具合を解
決することができるという大きな効果がある。
[Effects of the Invention] As explained above, according to the present invention, compatibility problems in application programs can be solved by setting the vector conversion table inside the CPU before execution of the application program. The interrupt vector number generated by the CPU for a specific interrupt factor can be converted arbitrarily, and the application program may operate differently due to the different interrupt vector number while executing the same instruction. It has the great effect of being able to solve the problem.

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

【図1】本発明の第1の実施例を示すブロック図。FIG. 1 is a block diagram showing a first embodiment of the present invention.

【図2】本発明の第2の実施例を示すブロック図。FIG. 2 is a block diagram showing a second embodiment of the present invention.

【図3】従来の割込み処理の概要を示すブロック図。FIG. 3 is a block diagram showing an overview of conventional interrupt processing.

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

11    内部ベクタ番号レジスタ 12    デコーダ 13    ベクタ変換テーブル 14    割込みベクタ番号レジスタ15    ア
ドレス選択ビット 16    生成ベクタ番号レジスタ 17    セレクタ 21    CPU 22    アドレス・バス 23    記憶装置 24    割込み処理アドレス 25    割込み処理プログラム 26    NMI割込み信号
11 Internal vector number register 12 Decoder 13 Vector conversion table 14 Interrupt vector number register 15 Address selection bit 16 Generated vector number register 17 Selector 21 CPU 22 Address bus 23 Storage device 24 Interrupt processing address 25 Interrupt processing program 26 NMI interrupt signal

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】  CPUから出力される変更可能な割込
みベクタ番号を保持する内部ベクタ番号保持手段と、こ
の内部ベクタ番号保持手段からの割込みベクタ番号のう
ち所定ビットをデコードするデコード手段と、このデコ
ード手段の出力によって予め保持された割込みベクタ番
号を選択するベクタ変換手段と、このベクタ変換手段か
らの選択された割込みベクタ番号と前記内部ベクタ保持
手段の割込みベクタ番号の一部とから新たに割込みベク
タ番号を生成し保持する生成ベクタ番号保持手段とを有
し、この生成ベクタ番号保持手段の出力により任意の割
込みベクタ番号を出力できるようにした事を特徴とする
情報処理装置。
1. Internal vector number holding means for holding a changeable interrupt vector number output from a CPU; decoding means for decoding predetermined bits of the interrupt vector number from the internal vector number holding means; vector converting means for selecting an interrupt vector number previously held by the output of the means; and a vector converting means for selecting an interrupt vector number previously held by the output of the means, and a new interrupt vector is generated from the selected interrupt vector number from the vector converting means and a part of the interrupt vector number of the internal vector holding means. 1. An information processing device comprising generated vector number holding means for generating and holding a number, and capable of outputting an arbitrary interrupt vector number by outputting the generated vector number holding means.
JP1044691A 1991-01-31 1991-01-31 Information processor Pending JPH04245336A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP1044691A JPH04245336A (en) 1991-01-31 1991-01-31 Information processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1044691A JPH04245336A (en) 1991-01-31 1991-01-31 Information processor

Publications (1)

Publication Number Publication Date
JPH04245336A true JPH04245336A (en) 1992-09-01

Family

ID=11750378

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1044691A Pending JPH04245336A (en) 1991-01-31 1991-01-31 Information processor

Country Status (1)

Country Link
JP (1) JPH04245336A (en)

Similar Documents

Publication Publication Date Title
JPS62197830A (en) Data processing system
JPH0348536B2 (en)
JPH0348537B2 (en)
JPH04245324A (en) Arithmetic unit
JPH04245336A (en) Information processor
KR100188374B1 (en) Central processing unit and an arithmetic operation processing unit
JP2553200B2 (en) Information processing device
JPS63113634A (en) Relative address calculation system for program counter
JPH03271829A (en) Information processor
JPH056281A (en) Information processor
JPS58200349A (en) Microprogram controller
JP2758624B2 (en) Speed control method of micro program
JP3531856B2 (en) Program control method and program control device
JPH05250156A (en) Risc processor
JP3888236B2 (en) Program counter circuit
JP2000231494A (en) Software execution system and software executing method
JPH036705A (en) Sequence controller
JPH0682321B2 (en) Micro controller
JPS5896346A (en) Hierarchical arithmetic system
JPS61114342A (en) Controller of data processor
JPH06324884A (en) Data processor
JPH03164945A (en) Data processor
JPH0455957A (en) Semiconductor integrated circuit
JPH052472A (en) Arithmetic unit
JPH036706A (en) Sequence controller