JP2009193525A - Interruption control device - Google Patents
Interruption control device Download PDFInfo
- Publication number
- JP2009193525A JP2009193525A JP2008036242A JP2008036242A JP2009193525A JP 2009193525 A JP2009193525 A JP 2009193525A JP 2008036242 A JP2008036242 A JP 2008036242A JP 2008036242 A JP2008036242 A JP 2008036242A JP 2009193525 A JP2009193525 A JP 2009193525A
- Authority
- JP
- Japan
- Prior art keywords
- interrupt
- notified
- factor
- interrupt factor
- processor
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Abstract
Description
本発明は、1つ以上のプロセッサを具備するコンピュータシステムに搭載される割込制御装置に関するものである。 The present invention relates to an interrupt control device mounted on a computer system including one or more processors.
コンピュータシステムにおいては、搭載された各種周辺装置等からの割込をプロセッサで適切に処理する必要がある。特に、近年、急速に普及しているマルチプロセッサシステムにおいては、搭載されている複数のプロセッサで、矛盾なく、より効率的に割込を処理することが求められている。 In a computer system, it is necessary to appropriately process interrupts from various peripheral devices mounted on the computer system. In particular, in recent years, multiprocessor systems that are rapidly spreading are required to handle interrupts more efficiently without any contradiction among a plurality of installed processors.
例えば、ある周辺装置からの割込に対し、複数のプロセッサで同時に割込処理を行ってしまうと正しく動作しないため、いずれかのプロセッサで排他的に割込処理を行わなければならない。 For example, if an interrupt process from a certain peripheral device is simultaneously performed by a plurality of processors, the processor does not operate correctly. Therefore, an interrupt process must be performed exclusively by one of the processors.
そのため、従来のこの種のコンピュータシステムでは、特定のプロセッサでのみ割込処理を行うか、各周辺装置からの割込を各プロセッサに重複しないように分割して通知することで、割込処理を複数のプロセッサで分散して行う方式が採られる場合があった。 Therefore, in this type of conventional computer system, interrupt processing is performed only by a specific processor, or interrupt processing from each peripheral device is divided and notified so as not to overlap each processor. In some cases, a distributed method is used by a plurality of processors.
しかしながら、この場合には、特定のプロセッサに割込処理が集中し、システム性能のボトルネックが生じるため、割込処理は複数のプロセッサで柔軟に行われることが好ましい。 However, in this case, interrupt processing concentrates on a specific processor and a bottleneck in system performance occurs. Therefore, it is preferable that the interrupt processing is performed flexibly by a plurality of processors.
そのための方策としては、各プロセッサの負荷状態や実行されているプログラムの優先度等を調べ、その結果から最も負荷の軽いプロセッサ等を選択し、そのプロセッサに割込を通知し、割込処理を行う方式があった(例えば特許文献1)。 For this purpose, check the load status of each processor, the priority of the program being executed, etc., select the processor with the lightest load from the results, notify the processor of the interrupt, and execute the interrupt processing. There was a method to perform (for example, Patent Document 1).
また、全てのプロセッサに割込を通知し、最も早く応答したプロセッサが、何らかの排他制御手段でもって割込を取得し、割込処理を行う方式があった(例えば特許文献2)。 In addition, there is a method in which an interrupt is notified to all the processors, and the processor that responds the earliest acquires the interrupt by some kind of exclusive control means and performs the interrupt processing (for example, Patent Document 2).
しかしながら、上記特許文献1に示されるような各プロセッサに割込を通知する方式では、各プロセッサに対して独立に割込を通知する手段およびどのプロセッサに割込を通知するかを選択する手段が必要となるので、装置が複雑となり規模が大きくなるという問題点があった。そして、プロセッサの数が変更となると、大掛かりな変更が必要となり、その都度作り直す必要があるという問題点があった。
However, in the method of notifying each processor of the interrupt as disclosed in
また、特許文献2に示されるような全プロセッサに割込を通知する方式では、各プロセッサによる割込処理が競合しないようにするための排他制御手段を具備する必要があり、加えて、各プロセッサで実行される割込処理においては、具備された排他制御手段を使用するように作り込まないといけないという問題点があった。そして、各プロセッサで実行される割込処理で排他制御手段を使用する分、処理オーバーヘッドが増大するので、システム性能が劣化するという問題点があった。
Further, in the method for notifying all processors as shown in
本発明は、上記に鑑みてなされたものであって、コンピュータシステムが複数のプロセッサを有する場合であっても、各プロセッサへの独立した割込通知および各プロセッサで実行される割込処理での排他制御を行わなくても、矛盾なく効率的に割込を処理する割込制御装置を得ることを目的とする。 The present invention has been made in view of the above, and even when a computer system includes a plurality of processors, independent interrupt notification to each processor and interrupt processing executed by each processor. It is an object of the present invention to obtain an interrupt control device that processes interrupts efficiently without contradiction without performing exclusive control.
上述した課題を解決し、目的を達成するために、本発明は、1つ以上のプロセッサを具備するコンピュータシステムに搭載され、周辺装置から発生する割込信号を受付け、前記プロセッサに割込信号を発生し、前記プロセッサからの通知要求に対してどの周辺装置から割込が発生しているかを特定するための割込要因を通知する割込制御装置であって、周辺装置からの割込信号を受付けて割込要因として保持する割込受付部と、前記割込受付部が保持する割込要因の中からプロセッサに通知する割込要因を1つ選択する割込選択部と、前記割込受付部が保持する割込要因のうちプロセッサに既に通知した割込要因を通知済み割込要因として記録する通知済み割込要因記録部と、を備え、プロセッサから割込要因の通知要求を受け取ったとき、前記割込選択部は、前記割込受付部が保持する割込要因で前記通知済み割込要因記録部に記録されていない割込要因を1つ選択して前記プロセッサに通知するとともに、該通知した割込要因を前記通知済み割込要因記録部に記録する、ことを特徴とする。 In order to solve the above-described problems and achieve the object, the present invention is mounted on a computer system including one or more processors, receives an interrupt signal generated from a peripheral device, and sends the interrupt signal to the processor. An interrupt control device for notifying an interrupt factor for identifying which peripheral device is generating an interrupt in response to a notification request from the processor, wherein an interrupt signal from the peripheral device is received. An interrupt reception unit that receives and holds as an interrupt factor, an interrupt selection unit that selects one interrupt factor to be notified to the processor from the interrupt factors held by the interrupt reception unit, and the interrupt reception The interrupt factor recording unit records the interrupt factor already notified to the processor among the interrupt factors held by the processor as a notified interrupt factor, and receives an interrupt factor notification request from the processor , The recording interrupt selection unit selects one interrupt factor that is not recorded in the notified interrupt factor recording unit among the interrupt factors held by the interrupt reception unit, and notifies the processor of the selected interrupt factor. The interrupt factor thus recorded is recorded in the notified interrupt factor recording unit.
この発明によれば、複数の割込要因を受付けている場合でも、プロセッサから割込要因の通知要求を受け取ったとき、未だプロセッサに通知していない割込要因を1つ選択して該プロセッサに通知し、該通知した割込要因を通知済みとして記録するように構成するので、コンピュータシステムが複数のプロセッサを有する場合であっても、各プロセッサには重複しない割込要因が通知され、各プロセッサへの独立した割込通知および各プロセッサで実行される割込処理での排他制御を行わなくても、矛盾なく効率的に割込を処理する割込制御装置を得ることができるという効果を奏する。 According to the present invention, even when a plurality of interrupt factors are accepted, when an interrupt factor notification request is received from a processor, one interrupt factor that has not yet been notified to the processor is selected and the processor is selected. Since it is configured to notify and record the notified interrupt factor as already notified, even if the computer system has a plurality of processors, each processor is notified of an interrupt factor that does not overlap, and each processor There is an effect that it is possible to obtain an interrupt control device that can efficiently process an interrupt without contradiction without performing independent interrupt notification and exclusive control in an interrupt process executed by each processor. .
以下に、本発明にかかる割込制御装置の実施の形態を図面に基づいて詳細に説明する。なお、この実施の形態によりこの発明が限定されるものではない。 Embodiments of an interrupt control device according to the present invention will be described below in detail with reference to the drawings. Note that the present invention is not limited to the embodiments.
実施の形態1.
図1は、本発明にかかる実施の形態1の割込制御装置が適用されるコンピュータシステムの構成を示す図である。
FIG. 1 is a diagram showing a configuration of a computer system to which the interrupt control device according to the first embodiment of the present invention is applied.
図1において、実施の形態1のコンピュータシステム100は、少なくとも1個(ここでは3個)のプロセッサ11〜13を有し、演算や割込処理を行うプロセッサ部1と、複数(ここでは5個)の周辺装置31〜35と、周辺装置31〜35から割込が発生したとき、割込信号4をプロセッサ部1に送信してプロセッサ11〜13に割込要因を参照させ、プロセッサ11〜13の何れか1つに割込を認識させる割込制御装置2と、から構成される。本発明の実施の形態1のコンピュータシステム100を含めた一般的なコンピュータシステムはメモリ等の装置も具備されるが、本発明の実施の形態1のコンピュータシステム100においては本質的な部分ではないので省略している。
In FIG. 1, a
割込制御装置2は、割込受付部21、割込選択部22、通知済み割込要因記録部23、および割込要因レジスタ24をさらに有する。
The
割込受付部21は、周辺装置31〜35から割込信号を受付け、この割込信号の割込要因を受付けた割込要因として保持する。割込受付部21が割込信号を受付けると、割込制御装置2は、この受付けた割込信号を割込信号4としてプロセッサ部1に送信する。
The
割込選択部22は、受付けた割込要因のうち、プロセッサ11〜13から参照されたときに通知する割込要因を1つ選択し、割込要因レジスタ24に割込要因を特定する値を設定する。プロセッサ部1が割込信号4を受付けると、プロセッサ11〜13がこの割込要因レジスタ24を参照して、どの割込要因が発生しているかを読む。割込選択部22は、プロセッサ11〜13のうちの1つが割込要因レジスタ24に設定されている値を読むと、読まれた値の割込要因を通知済みとして割込要因レジスタ24の値を元に戻すとともに、この割込要因が通知済みであることがわかるように通知済み割込要因記録部23の値を設定する。そして、割込選択部22は、割込要因レジスタ24に受付けた割込要因のうちのまだ通知されていない割込要因があれば、1つ選択して割込要因レジスタ24の値を設定する。
The
プロセッサ11〜13のうちの1つによる割込要因の割込処理が終わり、該割込要因を発生した周辺装置31〜35から該割込がクリアされると、割込選択部22は、受付けた割込要因および通知済み割込要因記録部23の該割込要因に該当する部分の値を元に戻す。
When the interrupt processing of the interrupt factor by one of the processors 11 to 13 is completed and the interrupt is cleared from the
ここで、割込選択部22により割込要因レジスタ24の値が決定される様子をより具体的に説明する。図2は、割込選択部22により割込要因レジスタ24の値が決定される様子を説明する図である。
Here, how the value of the
図2において、割込要因受付部21が受付けた割込要因においては、各周辺装置から割込信号が入力され、それを割込受付部21で受け付けた場合を1、各周辺装置から割込信号が入力されていない場合は0で表している。ここでは、一例として、周辺装置31、32、34から割込信号が入力されており、周辺装置33、35からは割込信号が入力されていないことを意味している。なお、割込信号が入力されている場合を0、入力されていない場合を1としてもかまわない。
In FIG. 2, the interrupt factor accepted by the interrupt
通知済み割込要因記録部23が記録している通知済み割込要因においては、プロセッサ11〜13のうちの1つが割込要因レジスタ24を参照し、周辺装置31〜35のうちのどの周辺装置から割込が発生しているかを認識した場合を1、まだ認識していない場合を0で表している。ここでは、一例として、周辺装置31から割込信号が入力されていることを認識しており、他の周辺装置32〜35からの割込信号はまだ認識していないことを意味している。なお、プロセッサが認識している場合を0、認識していない場合を1としてもかまわない。
In the notified interrupt factor recorded by the notified interrupt
未通知の割込要因においては、プロセッサ11〜13のうちのいずれのプロセッサも認識していない周辺装置からの割込信号がある場合を1、そうでない場合を0で表している。すなわち、受付けた割込要因が1であり、かつ、通知済み割込要因記録部23が0である場合に1となり、他の場合は0と表される。ここでは、周辺装置32、34からの割込信号がまだプロセッサ11〜13で認識されていないこととなるので、ここが1となり、他は0となっている。なお、まだプロセッサが認識していない周辺装置からの割込信号を0、そうでない場合を1としてもかまわない。
In the unreported interrupt factor, 1 indicates that there is an interrupt signal from a peripheral device that is not recognized by any of the processors 11 to 13, and 0 indicates otherwise. In other words, it is 1 when the accepted interrupt factor is 1 and the notified interrupt
割込要因レジスタ24においては、プロセッサに通知したい周辺装置からの割込信号がある場合を1、そうでない場合を0で表している。ここでは、未通知となっている周辺装置32、34からの割込信号のうち、周辺装置32からの割込信号をプロセッサに通知したいと判断し、割込要因レジスタに設定したことを意味している。
In the
このように、割込選択部22は、割込受付部21で受け付けた各周辺装置からの割込信号に対して、通知済み割込要因記録部23に記録している既にプロセッサに通知した割込要因を参照し、未通知である割込要因を抜き出し、未通知の割込要因が複数あればそのうちのいずれか1つを選択して、割込要因レジスタ24に設定する。
In this way, the
次に、以上のように構成される実施の形態1のコンピュータシステム100の、周辺装置31〜35からの割込をプロセッサ11〜13のいずれか1つに処理させる動作を、具体的なシナリオの例に沿って説明する。図3は、実施の形態1のコンピュータシステム100の割込を処理させる動作を具体的に説明する図である。
Next, the operation of causing the
図3において、受付けた割込要因、通知済み割込要因記録部23に記録される通知済み割込要因、割込要因レジスタ24の各値は、図2の下4桁、すなわち、周辺装置31、32、33、34にて発生した割込要因の様子を抜粋して示している。
In FIG. 3, the received interrupt factor, the notified interrupt factor recorded in the notified interrupt
まず、初期状態では、割込が全く発生していない状態であり、受付けた割込要因、通知済み割込要因、および割込要因レジスタ24の値は全て「0000」となっている(図中シナリオ欄番号1)。ここで、周辺装置31から割込が発生したとすると、受付けた割込要因は「0001」に変化する(図中シナリオ欄番号2)。この時、まだプロセッサ11〜13には通知していないため、通知済み割込要因は「0000」のまま変化しない。その結果、割込要因レジスタ24の値は「0001」に設定される。
First, in the initial state, no interrupt has occurred, and the accepted interrupt factor, the notified interrupt factor, and the value of the interrupt factor register 24 are all “0000” (in the figure). Scenario column number 1). Here, if an interrupt is generated from the
周辺装置31から割込が発生したことで、割込信号4がプロセッサ部1に出力され、プロセッサ11〜13は割込が発生したことを認識する。これにより、プロセッサ11〜13はどの割込要因が発生したかを調べるため、割込要因レジスタ24を参照しようとする。
When an interrupt is generated from the
ここで、仮にプロセッサ11が最も早く割込に応答し、割込要因レジスタ24を参照したとすると、プロセッサ11には割込要因レジスタ24の値として「0001」が参照される。その結果、プロセッサ11は、周辺装置31からの割込要因を認識し、その割込処理を開始する。
Here, if the processor 11 responds to the interrupt earliest and references the interrupt factor register 24, “0001” is referred to the processor 11 as the value of the interrupt
一方で、割込選択部22においては、プロセッサ11により割込要因レジスタ24が参照されたので、そのときの値「0001」を通知済み割込要因に反映し、結果として、通知済み割込要因は「0001」となり、さらに割込要因レジスタ24は「0000」に設定される(図中シナリオ欄番号3)。
On the other hand, in the interrupt
そのため、プロセッサ11よりも遅く割込に応答したプロセッサ12、13が割込要因レジスタ24を参照すると、その値として「0000」が参照され、処理すべき割込がないため、割込処理は行われない。
Therefore, when the
プロセッサ11での割込処理が終わり、周辺装置11からの割込がクリアされると、受付けた割込要因は「0000」に戻り、同時に通知済み割込要因も「0000」に戻る(図中シナリオ欄番号4)。 When the interrupt processing in the processor 11 is completed and the interrupt from the peripheral device 11 is cleared, the accepted interrupt factor returns to “0000” and at the same time, the notified interrupt factor also returns to “0000” (in the figure). Scenario column number 4).
続いて、周辺装置32から割込が発生し、プロセッサが応答する前にすかさず周辺装置34から割込が発生したとする。この場合は、受付けた割込要因は、周辺装置32から割込が発生した時点で「0010」となり(図中シナリオ欄番号5)、周辺装置34から割込が発生した時点で「1010」と変化する(図中シナリオ欄番号6)。通知済み割込要因は「0000」で変わらない。割込要因レジスタ24は、周辺装置32から割込が発生した時点で「0010」となり(図中シナリオ欄番号5)、周辺装置34から割込が発生した時点では「0010」のまま変わらない(図中シナリオ欄番号6)。
Subsequently, it is assumed that an interrupt is generated from the
周辺装置32から割込が発生した時点で、プロセッサ部1には割込信号4が出力され、プロセッサ11〜13は割込が発生したことを認識する。これにより、プロセッサ11〜13はどの周辺装置からの割込が発生したかを調べるため、割込要因レジスタ24を参照しようとする。
When an interrupt is generated from the
ここで、仮にプロセッサ11が最も早く割込に応答し、割込要因レジスタ24を参照したとすると、プロセッサ11には割込要因レジスタ24の値として「0010」が参照される。その結果、プロセッサ11は、周辺装置32から割込が発生していることを認識し、その割込処理を開始する。
Here, if the processor 11 responds to the interrupt earliest and references the interrupt factor register 24, “0010” is referred to as the value of the interrupt factor register 24 by the processor 11. As a result, the processor 11 recognizes that an interrupt has occurred from the
一方で、割込選択部22においては、プロセッサ11により割込要因レジスタ24が参照されたので、そのときの値「0010」を通知済み割込要因に反映し、結果として、通知済み割込要因は「0010」となり、割込要因レジスタ24には、残りの未通知である周辺装置34の割込信号が反映され「1000」に設定される(図中シナリオ欄番号7)。
On the other hand, in the interrupt
プロセッサ11に次いで、仮にプロセッサ12が割込に応答したとすると、プロセッサ12には割込要因レジスタ24の値として「1000」が参照される。その結果、プロセッサ12は、周辺装置34から割込が発生していることを認識し、その割込処理を開始する。
If the
割込選択部22においては、プロセッサ12により割込要因レジスタ24が参照されたので、そのときの値「1000」を通知済み割込要因に反映し、結果として、通知済み割込要因は「1010」となり、割込要因レジスタには、残りの未通知である割込要因はないので「0000」に設定される(図中シナリオ欄番号8)。
In the interrupt
そのため、残りのプロセッサが割込要因レジスタ24を参照しても、その値として「0000」が参照され、処理すべき割込がないため、割込処理は行われない。 Therefore, even if the remaining processors refer to the interrupt factor register 24, “0000” is referred to as the value thereof, and there is no interrupt to be processed, so that no interrupt processing is performed.
プロセッサ11での割込処理が終わり、周辺装置32からの割込がクリアされると、受付けた割込要因は「1000」に変化し、同時に通知済み割込要因も「1000」に変化させる(図中シナリオ欄番号9)。
When the interrupt processing in the processor 11 is completed and the interrupt from the
ここで、周辺装置33から割込が発生したとすると、受付けた割込要因は「1100」に変化する。通知済み割込要因は「1000」のまま変化しない。その結果、割込要因レジスタ24は「0100」に設定される(図中シナリオ欄番号10)。
Here, if an interrupt is generated from the
周辺装置33から割込が発生したことで、再び割込信号4が出力され、プロセッサ11〜13は割込が発生したことを認識する。ここで、仮にプロセッサ13が最も早く割込に応答し、割込要因レジスタ24を参照したとすると、プロセッサ13には割込要因レジスタ24の値として「0100」が参照され、周辺装置33から割込が発生していることを認識し、その割込処理を開始する。
When an interrupt is generated from the
割込選択部22においては、プロセッサ13により割込要因レジスタ24が参照されたので、そのときの値「0100」を通知済み割込要因に反映し、結果として、通知済み割込要因は「1100」となり、さらに割込要因レジスタは「0000」に設定される(図中シナリオ欄番号11)。
In the interrupt
他のプロセッサは、割込要因レジスタ24を参照しても、その値として「0000」が参照され、処理すべき割込がないため、割込処理は行わない。 Even if the other processor refers to the interrupt factor register 24, “0000” is referred to as the value thereof, and there is no interrupt to be processed, so the interrupt processing is not performed.
この後、プロセッサ12での割込処理が終わり、周辺装置34からの割込がクリアされると、受付けた割込要因は「0100」に変化し、同時に通知済み割込要因も「0100」に変化させる(図中シナリオ欄番号12)。次いで、プロセッサ13での割込処理が終わり、周辺装置33からの割込がクリアされると、受付けた割込要因は「0000」に戻り、同時に通知済み割込要因も「0000」に戻る(図中シナリオ欄番号13)。
Thereafter, when the interrupt processing in the
このように、本実施の形態1によれば、複数の割込要因を受付けている場合でも、プロセッサから割込要因の読み出し要求を受け取ったとき、未だプロセッサに通知していない割込要因を1つ選択して該プロセッサに通知し、該通知した割込要因を通知済みとして記録するように構成するので、コンピュータシステムが複数のプロセッサを有する場合であっても、各プロセッサには重複しない割込要因が通知され、各プロセッサへの独立した割込通知および各プロセッサで実行される割込処理での排他制御を行わなくても、矛盾なく効率的に割込を処理する割込制御装置を得ることができる。すなわち、各プロセッサへの独立した割込通知は不要であるから、プロセッサの数が変更になった場合であっても、各プロセッサに割込を通知するための割込信号やその制御回路を作り変えることはなく、そのままの構成で使用することができる。また、各プロセッサで実行される割込処理での排他制御は不要であるから、排他制御に伴う処理オーバーヘッドは発生しないので、システム性能は劣化しない。 As described above, according to the first embodiment, even when a plurality of interrupt factors are accepted, when an interrupt factor read request is received from the processor, the interrupt factors that have not yet been notified to the processor are 1 The selected interrupt factor is notified and the notified interrupt factor is recorded as notified. Therefore, even when the computer system has a plurality of processors, interrupts that do not overlap each processor Get an interrupt control device that processes the interrupts efficiently without contradiction, without the cause being notified and without performing independent interrupt notification to each processor and exclusive control in the interrupt processing executed by each processor be able to. In other words, since independent interrupt notification to each processor is unnecessary, even if the number of processors is changed, an interrupt signal and its control circuit for notifying each processor of interrupts are created. There is no change and it can be used as it is. In addition, since exclusive control in the interrupt processing executed by each processor is unnecessary, processing overhead associated with exclusive control does not occur, and system performance does not deteriorate.
実施の形態2.
本発明の実施の形態2においては、割込要因に優先順位を設定し、未通知の割込要因が複数ある場合に、割込選択部22が最も優先度の高い割込要因を選択して割込要因レジスタ24に設定することが特徴となっている。
In
実施の形態2の割込制御装置においては、割込受付部21に保持される受付けた割込要因、通知済み割込要因記録部23が記録する通知済み割込要因、割込要因レジスタ24について、各周辺装置31〜35の割込信号に対応する値を格納する場所を、優先順位がより高い周辺装置が右側に来るように配置する。例えば、各周辺装置31〜35からの割込要因の優先度は、高い方から順に、周辺装置34からの割込要因、周辺装置32からの割込要因、周辺装置31からの割込要因、周辺装置33からの割込要因、周辺装置35からの割込要因であったとすると、値の配列方法は、図4に示すように、各要因およびレジスタ24において、優先度の高いものから順に、予め最下位(右側)から配置される。
In the interrupt control device according to the second embodiment, the accepted interrupt factor held in the interrupt
そして、割込選択部22は、未通知の割込要因が複数ある場合、下位側(右側)の割込要因を選択するように構成する。その結果、割込選択部22は、常により優先度の高い割込要因を選択することとなる。
Then, when there are a plurality of unreported interrupt factors, the interrupt
なお、ここでは、優先度の高いものから順に、下位(右側)から並べておくこととしたが、上位(左側)から並べておき、上位側(左側)の割込信号を選択するように構成するようにしてもなんら問題ない。 In this example, the lower priority (right side) is arranged in order from the highest priority, but the higher order (left side) is arranged, and the higher order (left side) interrupt signals are selected. But there is no problem.
また、割込選択部22は、より優先度の高い割込が発生した場合は、プロセッサによる割込要因レジスタ24の参照に競合しない範囲で、割込要因レジスタ24の値を再設定するように構成してもよい。
Further, when a higher priority interrupt occurs, the interrupt
例えば、上記実施の形態1においては、周辺装置32から割込が発生した後、プロセッサが割込要因レジスタ24を参照する前に、周辺装置34から割込が発生した時、割込要因レジスタ24の値は「0010」のまま変更していないが、これをより優先度の高い周辺装置34からの割込を伝えるために「1000」に変更するように構成する。(図4のように配置した場合は「0010」から「0001」に変更する。)
For example, in the first embodiment, when an interrupt is generated from the
このように、実施の形態2によれば、実施の形態1の割込制御装置により得られる効果に加えて、より優先度の高い割込から順にプロセッサで処理されるようになるという効果が得られる。 As described above, according to the second embodiment, in addition to the effect obtained by the interrupt control device according to the first embodiment, there is an effect that processing is performed by the processor in order from higher priority interrupts. It is done.
実施の形態3.
本発明の実施の形態3においては、各周辺装置からの割込要因に対する優先度を定義した優先度テーブルを具備し、割込選択部22は、その優先度テーブルを参照し、優先順位の高い割込を割込要因レジスタ24に設定することが特徴である。
In
図5は、本発明の実施の形態3における割込制御装置の構成を示す図である。図5においては、割込制御装置2は、実施の形態1および2の割込制御装置2の構成に加えて、周辺装置31〜35の割込要因の優先度が記述されている優先度テーブル25を有する。割込選択部22は、プロセッサ11〜13に未通知の割込要因が複数ある場合は、優先度テーブル25を参照し、より高い優先度の割込要因を選択して、割込要因レジスタ24に設定する。
FIG. 5 is a diagram showing the configuration of the interrupt control device according to
図6は、優先度テーブル25の一例を示したものである。このように、優先度テーブル25には、割込要因の優先度が保持されている。この例では、実施の形態1に引き続いて、各周辺装置31〜35は夫々1つの割込要因を発生し、割込要因の優先度は、数字が小さいものほど優先度が高いものとし、周辺装置34からの割込要因が最も優先度が高く、以下、周辺装置32、33、31、35と続くようにしている。
FIG. 6 shows an example of the priority table 25. Thus, the priority table 25 holds the priority of the interrupt factor. In this example, following the first embodiment, each
なお、優先度テーブル25の構成は、優先度が判るようになっていればどのような構成の優先度テーブルであってもよい。優先度は数値が大きいものを優先度が高いとしてもかまわないし、単に優先度順に割込信号を並べたものであってもかまわない。 The configuration of the priority table 25 may be a priority table of any configuration as long as the priority can be understood. As for the priority, a numerical value with a large numerical value may be set with a high priority, or an interrupt signal may be simply arranged in order of priority.
また、割込要因の優先度は重複しない、すなわち複数の割込要因に同じ優先度を設定しないことが望ましいが、複数の割込信号に同じ優先度を設定してもかまわない。この場合は、プロセッサに未通知の割込信号が複数あり、かつ、それらが同じ優先度である場合、いずれか1つの割込信号を何らかの方法で選択し、割込要因レジスタ24に設定するように構成する。
Further, it is desirable that the priority of the interrupt factors does not overlap, that is, it is desirable not to set the same priority for a plurality of interrupt factors, but the same priority may be set for a plurality of interrupt signals. In this case, when there are a plurality of interrupt signals not notified to the processor and they have the same priority, any one of the interrupt signals is selected by some method and set in the interrupt
複数の同じ優先度である割込信号からいずれか1つを選択する方法については、ここでは限定しないが、例えば、優先度テーブル25の上位に定義されているものを選択する、下位に定義されているものを選択する、先に割込が発生した方を選択する、後から割込が発生した方を選択する、割込の発生頻度や周期などから選択するなど、種々の方法が考えられる。 A method for selecting any one of a plurality of interrupt signals having the same priority is not limited here, but, for example, the one defined in the upper level of the priority table 25 is selected and defined in the lower level. Various methods can be considered, such as selecting the one that has been interrupted first, selecting the one that has been interrupted later, selecting from the frequency and period of occurrence of the interrupt, etc. .
このように、実施の形態3によれば、割込要因に対する優先度を定義した優先度テーブル25を具備し、割込選択部22は、その優先度テーブル25を参照し、優先順位の高い割込を割込要因レジスタ24に設定するようにしたので、優先度テーブルの内容を変更するのみで各周辺装置31〜35からの割込信号の優先度を簡単に変更できるので、実施の形態2の割込制御装置に比べて、システムの動作に合わせてより柔軟により最適な割込の優先度を設定することができるという効果が得られる。
As described above, according to the third embodiment, the priority table 25 that defines the priority with respect to the interrupt factor is provided, and the interrupt
実施の形態4.
ところで、本発明の実施の形態3の割込制御装置では、優先度テーブル25を具備することによって各周辺装置31〜35からの割込信号の優先度を設定するようにしたが、本実施の形態4の割込制御装置においては、この優先度テーブル25をプロセッサ11〜13から変更できるようにする。プロセッサ11〜13からの変更を可能とすることで、システムの動作に合わせて動的に割込の優先度を設定することができるようになる。
By the way, in the interrupt control device according to the third embodiment of the present invention, the priority of the interrupt signals from the
実施の形態5.
本発明の実施の形態5の割込制御装置は、割込選択部22が、ある時間が経過したら、通知済み割込要因記録部23の内容をクリアし、各周辺装置31〜35からの割込要因を再度プロセッサ11〜13に通知する。
In the interrupt control device according to the fifth embodiment of the present invention, the interrupt
図7は、この発明の実施の形態5における割込制御装置2の構成図である。図7において、割込制御装置2はタイマ26を備え、割込選択部22は、タイマ26にてある時間が経過したことを認識すると、通知済み割込要因記録部23の内容をクリアし、割込要因レジスタ24の値を再設定する。
FIG. 7 is a configuration diagram of the interrupt
割込選択部22は、プロセッサ11〜13が割込要因レジスタ24を参照すると、その内容を通知済み割込要因記録部23に反映し、割込要因レジスタ24の値を設定する。同時にタイマ26を起動する。
When the processors 11 to 13 refer to the interrupt factor register 24, the interrupt
タイマ26は、予め設定された時間経過すると、割込選択部22に通知する。割込選択部22は、タイマ26からの通知を受けると、通知済み割込要因記録部23の内容をクリアする。通知済み割込要因をクリアしたことで、割込受付部21で受け付けている各周辺装置からの割込要因のうち、これまでは通知済みとして割込要因レジスタ24に設定していなかったものも再度割込要因レジスタ24に設定可能とする。
The
割込選択部22は、タイマ26からの通知を受け、通知済み割込要因記録部23の内容をクリアすると、改めて未通知の割込要因を調べ直し、そのうちのいずれか1つを割込要因レジスタ24に設定する。
When the interrupt
このように、実施の形態5によれば、実施の形態1による割込制御装置によって得られる効果に加えて、割込処理を実行しているプロセッサ11〜13に何らかの障害が発生した場合であっても、別のプロセッサにて改めて割込処理を開始することができ、システムの稼働率を高くすることができるという効果が得られる。 As described above, according to the fifth embodiment, in addition to the effect obtained by the interrupt control device according to the first embodiment, there is a case where some failure occurs in the processors 11 to 13 that are executing the interrupt processing. However, the interrupt processing can be started again by another processor, and the system operating rate can be increased.
実施の形態6.
実施の形態5の割込制御装置は、タイマ26を具備し、割込選択部22はこのタイマ26によりある時間が経過したら通知済み割込要因記録部23の内容をクリアするとしたが、周辺装置31〜35の割込要因毎に夫々異なるタイマを有するようにしてもよい。
Embodiment 6 FIG.
The interrupt control device according to the fifth embodiment includes a
そこで、本発明の実施の形態6の割込制御装置は、各周辺装置31〜35からの割込要因毎に夫々異なるタイマを備える。割込選択部22は、プロセッサ11〜13が割込要因レジスタ24を参照すると、その内容を通知済み割込要因記録部23が記録する通知済み割込要因に反映し、かつ、その内容で示されている周辺装置からの割込要因用に用意されたタイマ26を起動する。
Therefore, the interrupt control device according to the sixth embodiment of the present invention includes a different timer for each interrupt factor from each of the
割込選択部22は、タイマ26からの通知を受けると、そのタイマと対応付けられている割込要因のみを、通知済み割込要因記録部23に記録されている通知済み割込要因の内容からクリアする。別の周辺装置からの割込要因については、通知済み割込要因記録部23に記録されている通知済み割込要因の内容からはクリアしない。
When the interrupt
このように、実施の形態6によれば、実施の形態5による割込制御装置に比べて、プロセッサ11〜13の障害等に対して、より柔軟性の高いコンピュータシステムを得ることができるという効果が得られる。 As described above, according to the sixth embodiment, compared with the interrupt control device according to the fifth embodiment, it is possible to obtain a more flexible computer system against the failure of the processors 11 to 13. Is obtained.
実施の形態7.
また、上記タイマ26は、起動してから割込選択部22に通知するまでの時間、すなわちタイムアウト時間を、プロセッサ11〜13から設定、変更できるように構成されてもよい。そこで、本発明の実施の形態7の割込制御装置は、タイムアウト時間をプロセッサ11〜13から設定できるようにする。
Embodiment 7 FIG.
In addition, the
このように、実施の形態7によれば、システムの動作に応じて、プロセッサ11〜13により動的にタイマのタイムアウト時間を変更できるようにしたので、実施の形態6による割込制御装置に比べて、プロセッサの障害等に対して、さらに柔軟性の高いコンピュータシステムを得ることができる。 As described above, according to the seventh embodiment, the time-out time of the timer can be dynamically changed by the processors 11 to 13 in accordance with the operation of the system. Therefore, compared with the interrupt control device according to the sixth embodiment. Thus, it is possible to obtain a more flexible computer system against a processor failure or the like.
実施の形態8.
また、通知済み割込要因記録部23を、プロセッサから参照できるように構成してもよい。実施の形態8の割込制御装置においては、プロセッサ11〜13は通知済み割込要因記録部23を参照する。
Embodiment 8 FIG.
Further, the notified interrupt
このように、実施の形態8によれば、他のプロセッサにより割込処理が行われている各周辺装置からの割込信号についても知ることができるので、実施の形態1の割込制御装置に比べて、プロセッサの障害等に対して、より柔軟性の高いコンピュータシステムを得ることができる。 As described above, according to the eighth embodiment, since it is possible to know the interrupt signal from each peripheral device that is being interrupted by another processor, the interrupt control device according to the first embodiment In comparison, it is possible to obtain a more flexible computer system against a processor failure or the like.
実施の形態9.
また、通知済み割込要因記録部23を、プロセッサ11〜13からクリアすることができるように構成してもよい。実施の形態9による割込制御装置は、プロセッサ11〜13が、何らかの手段により、他のプロセッサの障害等を検出した場合、通知済み割込要因記録部23をクリアする。割込選択部22は、プロセッサ11〜13による通知済み割込要因記録部23のクリアによって、改めて割込要因レジスタ24の値を設定し直す。プロセッサは更新された割込要因レジスタ24を参照することで、これまで通知済みとなっており参照できなかった割込要因を参照することができ、その割込処理を開始することができる。
Embodiment 9 FIG.
Moreover, you may comprise so that the notified interruption
このように、実施の形態9によれば、システムの動作に応じて、プロセッサ11〜13により動的に通知済み割込要因記録部23に記録される通知済み割込要因をクリアできるようにしたので、実施の形態1の割込制御装置に比べて、プロセッサ11〜13の障害等に対して、より柔軟性の高いコンピュータシステムを得ることができる。
As described above, according to the ninth embodiment, the notified interrupt factor recorded in the notified interrupt
実施の形態10.
実施の形態10の割込制御装置は、割込受付部21で受け付けている全ての周辺装置31〜35からの割込要因をプロセッサ11〜13から参照できるように構成されている。この場合、通知済み割込要因記録部23は更新してもよいし、更新しないようにしてもよい。
The interrupt control device according to the tenth embodiment is configured so that interrupt factors from all the
プロセッサ11〜13は、割込選択部22により選択された未通知の割込要因を割込要因レジスタ24から取得できると共に、割込受付部21で受け付けている周辺装置31〜35からの全ての割込要因を取得できることで、より多岐に渡る割込処理を実現しうる。
The processors 11 to 13 can acquire the unreported interrupt factor selected by the interrupt
例えば、ある用途においては、各プロセッサ11〜13で処理すべき割込要因を固定にすることも可能である。この場合は、各プロセッサ11〜13は直接割込受付部21で受け付けている全ての割込要因を取得し、自身で処理すべき割込要因が発生していないかを確認すればよい。
For example, in a certain application, it is possible to fix an interrupt factor to be processed by each of the processors 11 to 13. In this case, each of the processors 11 to 13 may acquire all the interrupt factors received by the direct interrupt receiving
例えば、ある一部の割込要因は特定のプロセッサで処理されるようにし、他の割込要因はいずれかのプロセッサで処理するように構成することも可能である。この場合は、各プロセッサ11〜13は、まず、割込受付部21で受け付けている全ての割込要因を取得し、自身で処理すべき割込要因が発生していないかを確認し、発生していればその割込要因に対する割込処理を行い、発生していなければ、割込要因レジスタ24を参照し、それで得られた割込要因に対する割込処理を行うようにすればよい。
For example, some interrupt factors may be processed by a specific processor, and other interrupt factors may be processed by any processor. In this case, each of the processors 11 to 13 first obtains all the interrupt factors accepted by the interrupt accepting
このように、実施の形態10によれば、割込受付部21で受け付けている全ての周辺装置31〜35からの割込要因をプロセッサ11〜13から参照できるように構成したので、実施の形態1による割込制御装置に比べて、システムの動作に応じた、より柔軟性の高いコンピュータシステムを得ることができる。
As described above, according to the tenth embodiment, since the interrupt factors from all the
1 プロセッサ部
2 割込制御装置
4 割込信号
11〜13 プロセッサ
21 割込受付部
22 割込選択部
23 通知済み割込要因記録部
24 割込要因レジスタ
25 優先度テーブル
26 タイマ
31〜35 周辺装置
100 コンピュータシステム
DESCRIPTION OF
Claims (10)
周辺装置からの割込信号を受付けて割込要因として保持する割込受付部と、
前記割込受付部が保持する割込要因の中からプロセッサに通知する割込要因を1つ選択する割込選択部と、
前記割込受付部が保持する割込要因のうちプロセッサに既に通知した割込要因を通知済み割込要因として記録する通知済み割込要因記録部と、
を備え、
プロセッサから割込要因の通知要求を受け取ったとき、前記割込選択部は、前記割込受付部が保持する割込要因で前記通知済み割込要因記録部に記録されていない割込要因を1つ選択して前記プロセッサに通知するとともに、該通知した割込要因を前記通知済み割込要因記録部に記録する、
ことを特徴とする割込制御装置。 Mounted in a computer system having one or more processors, accepts an interrupt signal generated from a peripheral device, generates an interrupt signal to the processor, and interrupts from which peripheral device in response to a notification request from the processor An interrupt control device that notifies an interrupt factor for identifying whether or not an error has occurred,
An interrupt reception unit that receives an interrupt signal from a peripheral device and holds it as an interrupt factor;
An interrupt selection unit for selecting one interrupt factor to be notified to the processor from the interrupt factors held by the interrupt reception unit;
Of the interrupt factors held by the interrupt reception unit, a notified interrupt factor recording unit that records an interrupt factor already notified to the processor as a notified interrupt factor;
With
When receiving the interrupt factor notification request from the processor, the interrupt selection unit sets the interrupt factor that is not recorded in the notified interrupt factor recording unit by the interrupt factor held by the interrupt reception unit. Selecting one and notifying the processor, and recording the notified interrupt factor in the notified interrupt factor recording unit,
An interrupt control device characterized by that.
プロセッサから割込要因の通知要求を受け取ったとき、前記割込選択部は、前記割込受付部が保持する割込要因で前記通知済み割込要因記録部に記録されていない割込要因の中から優先度の最も高い割込要因を1つ選択して前記プロセッサに通知するとともに、該通知した割込要因を通知済みとして前記通知済み割込要因記録部に記録させる、
ことを特徴とする請求項1に記載の割込制御装置。 When the interrupt acceptance unit accepts an interrupt factor, the interrupt factor is held in association with the priority,
When the interrupt factor notification request is received from the processor, the interrupt selection unit selects the interrupt factor that is not recorded in the notified interrupt factor recording unit by the interrupt factor held by the interrupt reception unit. Selecting one of the highest priority interrupt factors from the processor and notifying the processor, and causing the notified interrupt factor to be recorded as the notified interrupt factor recording unit,
The interrupt control apparatus according to claim 1.
プロセッサから割込要因の通知要求を受け取ったとき、前記割込選択部は、前記優先度テーブルを参照し、記割込受付部が保持する割込要因で前記通知済み割込要因記録部に記録されていない割込要因の中から優先度の最も高い割込要因を1つ選択して前記プロセッサに通知するとともに、該通知した割込要因を通知済みとして前記通知済み割込要因記録部に記録させる、
ことを特徴とする請求項1に記載の割込制御装置。 A priority table that holds a correspondence between the interrupt factor and the priority of the interrupt factor;
When receiving the interrupt factor notification request from the processor, the interrupt selection unit refers to the priority table and records it in the notified interrupt factor recording unit with the interrupt factor held by the recording interrupt reception unit. One interrupt factor with the highest priority is selected from the interrupt factors that have not been notified and notified to the processor, and the notified interrupt factor is recorded in the notified interrupt factor recording unit as notified Let
The interrupt control apparatus according to claim 1.
前記割込選択部は、プロセッサに割込要因を通知したとき、前記タイマを起動するとともに、該通知した割込要因を通知済みとして前記通知済み割込要因に記録し、前記タイマが前記所定の時間の計測を終了すると、前記通知済み割込要因記録部に記録されている通知済み割込要因を消去する、
ことを特徴とする請求項1〜4の何れか1つに記載の割込制御装置。 It further has a timer for measuring a predetermined time,
The interrupt selection unit, when notifying the interrupt factor to the processor, starts the timer and records the notified interrupt factor in the notified interrupt factor as being notified, and the timer When the time measurement ends, the notified interrupt factor recorded in the notified interrupt factor recording unit is deleted.
The interrupt control apparatus according to any one of claims 1 to 4, wherein
前記割込選択部は、プロセッサに割込要因を通知したとき、該通知した割込要因に対応する前記タイマを起動するとともに、該通知した割込要因を通知済みとして前記通知済み割込要因に記録させ、前記タイマが前記所定の時間の計測を終了すると、前記通知済み割込要因記録部に記録される情報のうち前記通知した割込要因に対応する情報を消去する、
ことを特徴とする請求項5に記載の割込制御装置。 There is a different timer for each interrupt factor,
The interrupt selection unit, when notifying the interrupt factor to the processor, activates the timer corresponding to the notified interrupt factor and sets the notified interrupt factor as notified to the notified interrupt factor. When the timer finishes measuring the predetermined time, the information corresponding to the notified interrupt factor is deleted from the information recorded in the notified interrupt factor recording unit,
The interrupt control apparatus according to claim 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008036242A JP2009193525A (en) | 2008-02-18 | 2008-02-18 | Interruption control device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008036242A JP2009193525A (en) | 2008-02-18 | 2008-02-18 | Interruption control device |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2009193525A true JP2009193525A (en) | 2009-08-27 |
Family
ID=41075455
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008036242A Pending JP2009193525A (en) | 2008-02-18 | 2008-02-18 | Interruption control device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2009193525A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2013545205A (en) * | 2010-12-07 | 2013-12-19 | アップル インコーポレイテッド | Interrupt distribution scheme |
-
2008
- 2008-02-18 JP JP2008036242A patent/JP2009193525A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2013545205A (en) * | 2010-12-07 | 2013-12-19 | アップル インコーポレイテッド | Interrupt distribution scheme |
US8959270B2 (en) | 2010-12-07 | 2015-02-17 | Apple Inc. | Interrupt distribution scheme |
US9262353B2 (en) | 2010-12-07 | 2016-02-16 | Apple Inc. | Interrupt distribution scheme |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP2007109238A (en) | System and method for logging recoverable error | |
US6594787B1 (en) | Input/output device managed timer process | |
US20100299470A1 (en) | Interrupt processing apparatus and method | |
JP2008176360A (en) | Multiprocessor system | |
JPWO2012001835A1 (en) | Multiprocessor system | |
JP5579935B2 (en) | Detection of abnormal operation caused by interrupt processing | |
JP5014179B2 (en) | OS priority changing device and OS priority changing program | |
JP4761229B2 (en) | Operation management apparatus, operation management method and program | |
JP2009193525A (en) | Interruption control device | |
JP4259390B2 (en) | Parallel processing unit | |
JP6123487B2 (en) | Control device, control method, and control program | |
JP2010009258A (en) | Fault detection device of software | |
US8151028B2 (en) | Information processing apparatus and control method thereof | |
JP2006227962A (en) | System and method for monitoring application task | |
JP4322606B2 (en) | Watchdog timer | |
JP2007193744A (en) | Information processing device, program and scheduling method | |
JP2009187474A (en) | Semiconductor device, portable electronic equipment, self-diagnosis method, and self-diagnosis program | |
JP4633553B2 (en) | Debug system, debugging method and program | |
JP2008217419A (en) | Interruption controller for automatically changing interruption level | |
US11068357B2 (en) | Uninterrupted restore operation using a time based approach | |
JP2008146148A (en) | Computer system | |
JP2011003052A (en) | Data processing apparatus, control method and program | |
WO2017037863A1 (en) | Computer device, control method, and control program | |
JP2010198165A (en) | Start control method, information processor and program | |
JP2007034864A (en) | Diagnostic method for i/o device |