JPH0363768B2 - - Google Patents

Info

Publication number
JPH0363768B2
JPH0363768B2 JP16901482A JP16901482A JPH0363768B2 JP H0363768 B2 JPH0363768 B2 JP H0363768B2 JP 16901482 A JP16901482 A JP 16901482A JP 16901482 A JP16901482 A JP 16901482A JP H0363768 B2 JPH0363768 B2 JP H0363768B2
Authority
JP
Japan
Prior art keywords
virtual machine
priority
virtual
host
dispatch
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
JP16901482A
Other languages
Japanese (ja)
Other versions
JPS5958553A (en
Inventor
Hideo Kubo
Shinji Nanba
Naoya Oono
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
Nippon Electric Co 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 Nippon Electric Co Ltd filed Critical Nippon Electric Co Ltd
Priority to JP16901482A priority Critical patent/JPS5958553A/en
Publication of JPS5958553A publication Critical patent/JPS5958553A/en
Publication of JPH0363768B2 publication Critical patent/JPH0363768B2/ja
Granted legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)

Description

【発明の詳細な説明】 この発明は統合型仮想計算機システムにおける
ホストシステムおよび仮想計算機へのデイスパツ
チ方式に関する。仮想計算機とは実計算機上に一
般に複数個仮想的に作り出される計算機であつて
各々が独立に異るオペレーテイングシステムを同
時に実行させうる。すなわち、仮想計算機システ
ムでは、一台の実計算機上に複数台の仮想計算機
を実現できる。これは次のような目的に有効に利
用される。
DETAILED DESCRIPTION OF THE INVENTION The present invention relates to a dispatch method to a host system and a virtual machine in an integrated virtual machine system. A virtual computer is generally a plurality of virtual computers created on a real computer, each of which can independently run a different operating system at the same time. That is, in a virtual computer system, multiple virtual computers can be realized on one real computer. This is effectively used for the following purposes.

1 オペレーテイングシステム開発の効率化 2 システム移行のサポート 3 システム運用管理の容易化 仮想計算機を実現するには、実ハードウエアの
仮想化を行う制御プログラム(VMC)の組込み
と、実計算機の方式によつてはハードウエアの一
部改造とが必要とされる。VMCの実現方法とし
ては、実計算機上に直接実現する形(第1図)と
汎用オペレーテイングシステムの下に実現する形
(第2図)とがある。
1. Improving the efficiency of operating system development 2. Supporting system migration 3. Easier system operation management In some cases, it may be necessary to partially modify the hardware. There are two ways to implement VMC: directly on a real computer (Figure 1) and under a general-purpose operating system (Figure 2).

第1図のような仮想計算機システムをIBMの
VM/370に従つてCP型仮想計算機システムと呼
び、第2図のような仮想計算機システムを統合型
仮想計算機システムと呼ぶ。統合型においては第
2図に示すように実計算機上で実行する汎用オペ
レーテイングシステムをホストOS、その制御下
で直接実行されるプロセスをホストプロセスこれ
ら全体をホストシステムと呼ぶ。
IBM's virtual computer system as shown in Figure 1
According to VM/370, it is called a CP type virtual computer system, and a virtual computer system like the one shown in Figure 2 is called an integrated virtual computer system. In the integrated type, as shown in Figure 2, the general-purpose operating system that runs on the actual computer is called the host OS, the processes that are directly executed under its control are called the host processes, and the entire system is called the host system.

従来、仮想計算機システムは広く利用されてい
る前記VM/370を初め大部分がCP型として開発
されてきた。しかし、統合型仮想計算機システム
も、ハードウエア仮想化の完全性に問題はあるも
のの実用上は、ほとんど支障はなく、CP型に比
較して次のような利点を有している。
Conventionally, most virtual computer systems have been developed as CP types, including the widely used VM/370. However, although integrated virtual computer systems also have problems with the integrity of hardware virtualization, they have virtually no problems in practice, and have the following advantages over CP systems.

1 ホストOSとホストプロセスは実ハードウエ
ア上で実行されるので、ホストシステムに担当
させた業務処理は仮想計算機化のオーバヘツド
なしに実行可能である。
1. Since the host OS and host processes are executed on real hardware, business processes assigned to the host system can be executed without the overhead of virtualization.

2 VMCの開発及び改造に際して、ホストOSの
もつ様々なプログラム開発フアシリテイの恩恵
を受け得、また、VMC自身がホストOSの機能
を利用しうるので実現が容易であり、大幅な開
発保守の省力化が期待できる。
2. When developing and modifying the VMC, you can benefit from the various program development facilities of the host OS, and since the VMC itself can use the functions of the host OS, it is easy to implement, resulting in significant labor savings in development and maintenance. can be expected.

特に仮想計算機化による実行時のオーバーヘツ
ドはCP型で大きな問題となつており、様々な改
良の手が打たれてきたが、CP型では本質的に除
くことは無理であつた点である。例えば、システ
ム移行時に、旧システムでオンラインサービスを
続行しつつ、同一ハードウエア上で新システムの
開発を行うような場合に、現在サービス中のシス
テムについては最大限の性能を提供することが望
まれる。この場合CP型では余分なオーバヘツド
を免かれないが、統合型でホストシステムとして
実行させれば、このシステムについては仮想計算
機化のオーバヘツドを免れうる。
In particular, runtime overhead due to virtualization is a major problem with the CP type, and various improvements have been made, but it is essentially impossible to eliminate with the CP type. For example, when migrating a system, if a new system is being developed on the same hardware while continuing online service on the old system, it is desirable to provide maximum performance for the system currently in service. . In this case, the CP type cannot avoid extra overhead, but if the integrated type is executed as a host system, this system can avoid the overhead of virtualization.

統合型仮想計算機システムは以上のような利点
を有しているが、従来はホストシステムと仮想計
算機との間の処理能力の配分に問題があつた。す
なわち、従来は実CPU資源の仮想計算機への割
当てであるデイスパツチは、個々のホストプロセ
スと仮想計算機とを同列に扱つて行われていた。
具体的には、仮想計算機対応にそれを代表するホ
ストプロセスを用意しておき、このプロセスへデ
イスパツチされた時にその延長として対応する仮
想計算機が動くようになつているか。VMCとす
べての仮想計算機とを全体として一つのプロセス
で代表させ、そのプロセスにデイスパツチされた
時にその中で個々の仮想計算機へデイスパツチす
る方式がとられていた。このため本来は同格であ
るはずの個々の仮想計算機とホストプロセス群全
体とを同列に扱つて処理能力の配分を行うことが
できなかつた。タイムスライスを用いてホストプ
ロセス群全体と個々の仮想計算機に平等な処理能
力配分を行おうとしても、従来のタイムスライス
機構だけでは実現は困難であつた。ホストシステ
ム仮想計算機との間の処理能力配分を自由に制御
に制御できないことは、統合型仮想計算機システ
ムの適用範囲を狭めていた。
Although integrated virtual computer systems have the above-mentioned advantages, conventionally there has been a problem in the distribution of processing power between the host system and the virtual computers. That is, conventionally, dispatch, which is the allocation of real CPU resources to virtual machines, has been performed by treating individual host processes and virtual machines in the same way.
Specifically, is a host process representative of the virtual machine prepared, and when this process is dispatched, the corresponding virtual machine runs as an extension of that process? A method was used in which the VMC and all virtual machines were represented as a whole by one process, and when a dispatch was made to that process, the dispatch was dispatched to an individual virtual machine within that process. For this reason, it was not possible to allocate processing power by treating individual virtual machines and the entire host process group, which should originally be on the same level, on the same level. Even if an attempt was made to use time slicing to equally distribute processing power to the entire host process group and to individual virtual machines, it was difficult to achieve this using only the conventional time slicing mechanism. The inability to freely control the distribution of processing power between the host system and the virtual machine has narrowed the scope of application of the integrated virtual machine system.

本発明の目的は、前記のような利点を有する統
合型仮想計算機システムの実現に当つて、ホスト
プロセスを優先度の高い群と低い群とに分割する
ことを可能にし、これによつてホスト内で実行さ
れる一般のジヨブは、全体として他の仮想計算機
と同じレベルのサービスを受け、ホスト内で制御
上必要とされるようなプロセス特にホストオペレ
ーテイングシステムの一部であるようなプロセス
は絶対優先でサービスを受けることを可能にする
方式を提供することにある。この方式を実装する
ことによつて統合型仮想計算機システムは、ホス
トをいわば最優先で、かつ低オーバヘツドの仮想
計算機として使用することも、オーバヘツドは低
いが他の仮想計算機と同列の一つの仮想計算機と
して使用することも可能にすることができ、望み
の処理能力配分を実現しうるようになる。
An object of the present invention is to make it possible to divide host processes into a high-priority group and a low-priority group in realizing an integrated virtual computer system having the above-mentioned advantages. A typical job running on a virtual machine receives the same level of service as any other virtual machine as a whole, and only processes that are required for control within the host, especially those that are part of the host operating system, receive the same level of service as any other virtual machine. The goal is to provide a method that allows you to receive priority services. By implementing this method, an integrated virtual computer system can either use the host as a low-overhead virtual computer with top priority, or use a single virtual computer with low overhead but on the same level as other virtual computers. It can also be used as a server, making it possible to realize the desired distribution of processing power.

本発明ではホストプロセスのデイスパツチング
プライオリテイに境界値を設け、これより高いプ
ライオリテイをもつホストプロセスを特権プロセ
スと呼び、それ以外のホストプロセスを一般プロ
セスと呼び、また、一般プロセスのみを実行させ
る仮想的な計算機を考え、これをホスト仮想計算
機と呼ぶ。そして、特権プロセスにはすべての仮
想計算機より優先的に実CPU資源を与え、特権
プロセスが実CPU資源を要求していない時にの
みホスト仮想計算機または一般の仮想計算機へ、
その仮想計算機プライオリテイに従つて実CPU
資源を与えるようなデイスパツチ機構を提供する
ことにより上記の目的を達成可能にする。
In this invention, a boundary value is set for the dispatching priority of a host process, and a host process with a higher priority is called a privileged process, other host processes are called a general process, and only the general process is executed. Consider a virtual computer that can be used to host computers, and this is called a host virtual computer. Then, the privileged process is given real CPU resources with priority over all virtual machines, and only when the privileged process is not requesting real CPU resources, it is given to the host virtual machine or a general virtual machine.
Real CPU according to its virtual machine priority
The above objectives can be achieved by providing a dispatch mechanism that provides resources.

以下本発明の第一および第二の実施例について
図面を参照しつつ説明する。第一の実施例はプロ
セスに関するデイスパツチを行うプロセスデイス
パツチヤがマイクロプログラム制御によつて実計
算機能の一部として実現されているような実計算
機上に、これと全く同じアーキテクチヤをもつ仮
想計算機を実現する場合の実施例である。
First and second embodiments of the present invention will be described below with reference to the drawings. In the first embodiment, a virtual computer having exactly the same architecture is installed on a real computer in which a process dispatcher that dispatches processes is realized as part of the real calculation function by microprogram control. This is an example of implementation.

ここでは、ホストシステムだけでなく仮想計算
機のプロセスデイスパツチヤとしても、実計算機
機能の一部であるプロセスデイスパツチヤを使用
する。このアーキテクチヤにおいては、すべての
ソフトウエアはプロセスとして実行されるので、
割込み等の生起時におけるシステム状態の退避
は、ハードウエアによつて、その時走行中であつ
たプロセスに対応するプロセス制御ブロツクへな
される。従つてある仮想計算機へ実CPUを与え
たすなわちデイスパツチしたら、その仮想計算機
は必ずプロセスデイスパツチヤから動き始めて、
まずプロセスデイスパツチを実行する必要があ
る。
Here, a process dispatcher, which is part of the real computer functions, is used not only for the host system but also for the virtual machine. In this architecture, all software runs as processes, so
When an interrupt or the like occurs, the system state is saved by hardware to the process control block corresponding to the process that was running at the time. Therefore, if you assign a real CPU to a virtual machine, that is, dispatch it, that virtual machine will always start running from the process dispatcher.
First you need to run a process dispatch.

第3図は第一の実施例を示すブロツク図であ
る。CPU2には実行中の仮想計算機番号を記憶
するレジスタ21、実行中のプロセスのIDを保
持するレジスタ22、ホストプロセスに関するデ
イスパツチングプライオリテイの境界値を保持す
るレジスタ23が設けられている。仮想計算機機
構を活性化する命令のオペランドとして境界値が
指定でき、この命令がホストシステムによつて実
行されると、レジスタ23に指定された値がセツ
トされる。レジスタ23の保持する値より高い
(小さい)プライオリテイを与えられているホス
トプロセスは特権プロセスとして扱われ、等しい
か低い(大きい)プライオリテイを与えられてい
るホストプロセスは一般プロセスとして扱われる
ことになる。記憶装置1には、ホストシステム専
用領域および各仮想計算機用の領域がとられてい
る。ホストシステム専用領域にはCPU2で実行
可能な仮想計算機を管理するレデイ仮想計算機リ
ストRVMLが用意される。このリストには仮想
計算機1〜nを代表する仮想計算機制御ブロツク
VMCB1〜nの他にホスト仮想計算機を代表す
るVMCB0を登録しうる。レデイ仮想計算機リ
ストには、VMCB0〜nのうち、対応する仮想
計算機が実計算機を割当てられれば実行可能な状
態、すなわちレデイ状態にあるもののみが、
VMCB上に記されているプライオクテイ値の高
い小さい順にリンクされている。先頭のVMCB
(一般には実行中の仮想計算機に対応)は、レデ
イ仮想計算機トツプポインタRVTから指されて
いる。ホスト仮想計算機は、一般にプロセスに一
つでもレデイ状態のものがあれば、レデイ状態に
あるとして扱われる。また、ホストシステム専用
領域にはホストシステムのレデイプロセスリスト
RPLhも保持されている。これはホストシステム
間のプロセスであつて実計算機が割当てられれば
実行可能なものに対応するプロセス制御ブロツク
PCBをプロセスプライオリテイの高い(小さい)
順序にリンクして管理しているリストである。先
頭のPCBはレデイプロセストツプポインタRPT
から指されている。同様のレデイプロセスリスト
RPLiが、各仮想計算機ごとに各々の記憶領域中
に保持されている。各PCBには対応するプロセ
スのデイスパツチングプライオリテイ、最後に
CPUを取上げられた時のレジスタ等の値が記憶
されている。
FIG. 3 is a block diagram showing the first embodiment. The CPU 2 is provided with a register 21 for storing the number of the virtual machine under execution, a register 22 for holding the ID of the process under execution, and a register 23 for holding the boundary value of the dispatching priority for the host process. A boundary value can be specified as an operand of an instruction to activate the virtual machine mechanism, and when this instruction is executed by the host system, the specified value is set in the register 23. A host process that is given a higher (lower) priority than the value held by the register 23 is treated as a privileged process, and a host process that is given a priority that is equal to or lower (larger) than the value held in the register 23 is treated as a general process. Become. The storage device 1 has a dedicated area for the host system and an area for each virtual machine. A ready virtual machine list RVML for managing virtual machines executable by the CPU 2 is prepared in the host system exclusive area. This list includes virtual machine control blocks representing virtual machines 1 to n.
In addition to VMCB1 to VMCBn, VMCB0 representing the host virtual machine can be registered. In the ready virtual machine list, among VMCB0 to n, only those that are in a state where the corresponding virtual machine can be executed if a real machine is allocated, that is, in a ready state, are listed.
They are linked in descending order of priority value listed on the VMCB. First VMCB
(which generally corresponds to a running virtual machine) is pointed to by the ready virtual machine top pointer RVT. Generally, a host virtual machine is treated as being in a ready state if at least one process is in a ready state. In addition, the host system dedicated area contains the host system ready process list.
RPL h is also retained. This is a process control block that corresponds to a process between host systems that can be executed if a real computer is allocated.
PCB with high (small) process priority
This is a list that is managed by linking in order. The first PCB is the ready process top pointer RPT.
It is pointed from. Similar ready process list
RPL i is held in each storage area for each virtual machine. Each PCB has a dispatching priority for the corresponding process, and finally
The values of registers, etc. at the time the CPU was taken away are stored.

仮想計算機制御ブロツクVMCBには、対応す
る仮想計算機のプライオリテイを示す数値仮想計
算機用の記憶領域の所在を示す情報等が保持され
ている。このプライオリテイ値は仮想計算機を最
初に動かし始める命令である仮想計算機起動命令
のオペランドとして与えられ、上記命令の実行に
伴つてセツトされる。アイドル状態にあつた仮想
計算機が入出力終了割込み等に伴つて実行可能な
状態になつた時には、その仮想計算機に対応する
VMCBi(i≠0)が、また一般プロセスが一つも
実行可能状態になかつた時に特権プロセスからの
Vオペレーシヨン等により実行可能な一般プロセ
スが生じた場合はVMCB0が、その上に保持さ
れているプライオリテイ値に従つて、レデイ仮想
計算機リストRVML上に登録される。
The virtual machine control block VMCB holds information such as the location of the storage area for the numerical virtual machine, which indicates the priority of the corresponding virtual machine. This priority value is given as an operand of a virtual machine startup instruction, which is an instruction for starting the virtual machine for the first time, and is set as the above instruction is executed. When a virtual machine that was in an idle state becomes executable due to an input/output end interrupt, etc., it responds to that virtual machine.
VMCB i (i≠0) is held on top of VMCB i (i≠0), and if an executable general process is generated by a V operation from a privileged process when no general process is in an executable state, VMCB0 is held above it. The virtual machines are registered on the ready virtual machine list RVML according to their priority values.

そして仮想計算機デイスパツチヤが起動され
る。仮想計算機デイスパツチヤは実行中であつた
仮想計算機が入出力終了待ち等によりアイドル状
態になつた時、タイムスライスを使い切つた時に
も起動される。仮想計算機デイスパツチヤが起動
された時には、アドレス空間はホストシステムに
切換えられている。
Then, the virtual machine dispatcher is activated. The virtual machine dispatcher is also activated when the virtual machine that was being executed becomes idle due to waiting for input/output to complete, or when the time slice is used up. When the virtual machine dispatcher is activated, the address space has been switched to the host system.

なお、上記の仮想計算機プライオリテイは、仮
想計算機開始後、任意の時点で変更できるように
することも可能である。これによつて各仮想計算
機の動作状況に応じて仮想計算機間の処理能力配
分を動的に制御すること、特定の仮想計算機を一
時的に優先させて、その間だけ処理速度を上げさ
せることなどが可能になる。仮想計算機プライオ
リテイ変更機能は命令として提供され、オペラン
ドとしては対象仮想計算機番号、新プライオリテ
イが指定される。この命令の実行は次の通りに行
う。まず、指定された仮想計算機に対応する
VMCB内の仮想計算機プライオリテイを指定さ
れた値に変更する。対象VMCBが仮想計算機レ
デイリストRVMLから外されている。すなわち
アイドル状態であつたならば、これで終了する。
アイドルでなければ、実行中の仮想計算機が存在
したらこれの状態をレデイ状態に戻した後に、仮
想計算機レデイリストRVMLから対象VMCBを
外して新しいプライオリテイに該当する場所へ挿
入する。次に仮想計算機デイスパツチヤへ制御を
移す。
Note that the virtual machine priority described above can be changed at any time after starting the virtual machine. This makes it possible to dynamically control the distribution of processing power between virtual machines according to the operating status of each virtual machine, and to temporarily give priority to a particular virtual machine to increase its processing speed only during that time. It becomes possible. The virtual machine priority changing function is provided as a command, and the target virtual machine number and new priority are specified as operands. This command is executed as follows. First, correspond to the specified virtual machine.
Change the virtual machine priority in VMCB to the specified value. The target VMCB has been removed from the virtual machine ready list RVML. In other words, if it was in an idle state, it ends now.
If it is not idle, if there is a running virtual machine, it is returned to the ready state, and then the target VMCB is removed from the virtual machine ready list RVML and inserted into the location corresponding to the new priority. Next, control is transferred to the virtual machine dispatcher.

次に仮想計算機デイスパツチヤ(VMデイスパ
ツチヤ)の動作を第4図のフローチヤートを参照
しつつ説明する。仮想計算機デイスパツチヤが起
動されるとホストシステムのレデイリストRPLh
を参照し、リスト上にPCBが存在するなら先頭
に登録されているプロセスのプライオリテイを得
る。この値がレジスタ23の保持する値より小さ
かつたならば、レジスタ21に−1をセツトして
プロセスデイスパツチヤの先頭へ制御を移す(ホ
ストシステムへVMデイスパツチしたことにな
る)。先頭プロセスのプライオリテイがレジスタ
23の保持する値と等しいか大きかつた場合もし
くは、RPLhが空であつた場合はレデイVMリス
トRVMLの先頭に登録されているVMCBを得
る。得られたVMCBの指している仮想計算機の
番号(0〜nのいずれか)をレジスタ21にセツ
トしVMCBの内容に従つてアドレス空間を切換
えてプロセスデイスパツチヤの先頭へ制御を移
す。これにより仮想計算機へのデイスパツチがな
されたことになる。RVML上にVMCBが一つも
登録されていなかつたならば、制御を仮想計算機
デイスパツチヤの先頭へ戻し、ループしながら
VMCBが登録されるのを待つ。
Next, the operation of the virtual machine dispatcher (VM dispatcher) will be explained with reference to the flowchart shown in FIG. When the virtual machine dispatcher is started, the host system's ready list RPL h
If there is a PCB on the list, get the priority of the first registered process. If this value is smaller than the value held in the register 23, -1 is set in the register 21 and control is transferred to the beginning of the process dispatcher (this means that the VM has been dispatched to the host system). If the priority of the head process is equal to or greater than the value held in the register 23, or if RPL h is empty, the VMCB registered at the head of the ready VM list RVML is obtained. The number (any one of 0 to n) of the virtual machine pointed to by the obtained VMCB is set in the register 21, the address space is switched according to the contents of the VMCB, and control is transferred to the beginning of the process dispatcher. This means that the virtual machine has been dispatched. If no VMCB is registered on RVML, control is returned to the beginning of the virtual machine dispatcher, and while looping,
Wait for VMCB to be registered.

本実施例ではプロセスデイスパツチヤは仮想化
される計算機機能の一部であるので、仮想計算機
環境においても、その中で実行されるプログラム
から見ると実計算機の従来のデイスパツチヤと同
等の機能を果さなければならない。実計算機の従
来のデイスパツチヤは、第4図の点線内に示すよ
うな機能をもつていたとする。本実施例では、こ
れに第4図に示す機能追加を行つて仮想計算機環
境におけるデイスパツチヤとしている。従来のプ
ロセスデイスパツチヤは、プロセスレデイリスト
をサーチし、もしプロセスが一つも登録されてい
なかつたならば、サーチを繰返して登録されるの
を待つ。登録されたプロセスが存在したら、その
先頭のものを取出してそのプロセスにデイスパツ
チする。すなわちレジスタ22にプロセスIDを
セツトし、対応するプロセス制御ブロツクPDB
から退避されていたレジスタ類の値を復帰してそ
のプロセスの実行を再開させる。
In this example, the process dispatcher is a part of the virtualized computer function, so even in a virtual computer environment, it can perform the same function as a conventional dispatcher on a real computer from the perspective of the program executed within it. Must do. It is assumed that the conventional dispatcher of the actual computer has the function shown within the dotted line in FIG. In this embodiment, the functions shown in FIG. 4 are added to this system to provide a dispatcher in a virtual computer environment. A conventional process dispatcher searches the process ready list and, if no process is registered, repeats the search and waits for one to be registered. If there are registered processes, the first one is extracted and dispatched to that process. In other words, set the process ID in the register 22, and write the corresponding process control block PDB.
The values of the registers that were saved are restored and the execution of the process is resumed.

本実施例のプロセスデイスパツチすべきレデイ
プロセスが選択された時にレジスタ21の内容が
−1(特権プロセス実行中)で、このプロセスの
プライオリテイがレジスタ23の保持する値より
小さくなかつた(特権プロセスでない)ならば、
プロセスデイスパツチは実行せずに仮想計算機デ
イスパツチヤへ制御を移す。また、レジスタ21
の内容が0(一般プロセス実行中)で選択された
プロセスのプライオリテイがレジスタ23の保持
する値より小さい(特権プロセス)ならば、レジ
スタ21に−1をセツトして、そのまま選択され
たプロセスへデイスパツチする。
In this embodiment, when the ready process to be dispatched is selected, the contents of register 21 is -1 (privileged process running), and the priority of this process is not smaller than the value held in register 23 (privileged process ), then
Control is transferred to the virtual machine dispatcher without executing the process dispatch. Also, register 21
If the content of is 0 (general process in progress) and the priority of the selected process is lower than the value held in register 23 (privileged process), register 21 is set to -1 and the process is transferred directly to the selected process. Dispatch.

以上のようなケースはホストシステム実行中に
おけるプロセス切換えの場合に起りうる。
The above case may occur when a process is switched while the host system is running.

これ以外の場合には従来通りのプロセスデイス
パツチヤとして動作させる。上記のプロセスデイ
スパツチヤからVMデイスパツチヤへ制御が渡つ
た場合その中でホストシステム(仮想計算機0)
がデイスパツチ対象として選ばれた時は、レジス
タ21に0がセツトされた後に再度プロセスデイ
スパツチヤへ入つてくるので、今度はホストシス
テムのレデイプロセスリストの先頭のもの(一般
プロセス)デイスパツチされることになる。ま
た、プロセスレデイリストが空であつた時にレデ
イプロセスのサーチを繰返さずに、実行中の仮想
計算機をRVMLから外しアドレス空間をホスト
に切換えて、直ちに仮想計算機デイスパツチヤへ
制御を移す(第4図に一点鎖線で表示)ようにす
ることによつて仮想計算機がアイドルになつたら
実計算機時間を空費せず、直ちに他の仮想計算機
を実行させるように切換えることが可能となる。
In other cases, it operates as a conventional process dispatcher. When control is passed from the above process dispatcher to the VM dispatcher, the host system (virtual machine 0)
When a process is selected as a dispatch target, the register 21 is set to 0 and then it enters the process dispatcher again, so this time the first process (general process) on the host system's ready process list is dispatched. Become. Also, when the process ready list is empty, instead of repeating the search for ready processes, the running virtual machine is removed from RVML, the address space is switched to the host, and control is immediately transferred to the virtual machine dispatcher (Figure 4). By doing so, when a virtual computer becomes idle, it is possible to immediately switch to running another virtual computer without wasting real computer time.

次に第二の実施例について説明する。本実施例
はプロセスデイスパツチヤがソフトウエアとして
作られている場合のように各仮想計算機が各々プ
ロセスデイスパツチヤを備えている場合に適用で
きる。ここではホストOSのプロセスデイスパツ
チヤを改造して、仮想計算機デイスパツチヤの機
能を追加している。一般の仮想計算機内のプロセ
スデイスパツチヤには手を加えなくてよいので、
任意のプロセスデイスパツチヤをもつOSで制御
される仮想計算機を動作させうる。
Next, a second embodiment will be described. This embodiment can be applied to a case where each virtual machine is provided with a process dispatcher, such as a case where the process dispatcher is created as software. Here, the process dispatcher of the host OS is modified to add virtual machine dispatcher functionality. Since there is no need to modify the process dispatcher in a general virtual machine,
It is possible to operate a virtual machine controlled by an OS with an arbitrary process dispatcher.

第3図に示したブロツク図に関しては基本的に
は第一の実施例と同じ構成であるが、一般の仮想
計算機のレデイプロセスリストRPLiの構成方法、
プロセス制御ブロツクPCBの形式、内容等はホ
ストのレデイプロセスリストRPLhやPCBと異つ
ていてもよい。また、仮想計算機制御ブロツク
VMCBは仮想計算機の状態の退避領域をもつて
いる。ホスト仮想計算機を除く仮想計算機から制
御が取上げられる時はその時点の仮想計算機の状
態がVMCBに退避される。
The block diagram shown in FIG. 3 basically has the same configuration as the first embodiment, but the method for configuring the ready process list RPL i of a general virtual machine,
The format, contents, etc. of the process control block PCB may be different from the host's ready process list RPL h and the PCB. In addition, the virtual machine control block
VMCB has a save area for the state of the virtual machine. When control is taken away from a virtual machine other than the host virtual machine, the state of the virtual machine at that time is saved to the VMCB.

本実施例における仮想計算機デイスパツチは、
VMCB内に退避されていた状態を実計算機のレ
ジスタ等へ復帰することによつて実現される。第
一の実施例と異り、仮想計算機の実行の再開を仮
想計算機内のプロセスデイスパツチヤの起動によ
り行わせることは不要である。ただし、ホスト仮
想計算機については、仮想計算機の実行の再開は
ホストシステムのプロセスデイスパツチヤの実行
から行われる。
The virtual machine dispatch in this embodiment is as follows:
This is achieved by restoring the state saved in the VMCB to the registers of the actual computer. Unlike the first embodiment, it is not necessary to restart execution of the virtual machine by activating a process dispatcher within the virtual machine. However, for the host virtual machine, the execution of the virtual machine is restarted by executing the process dispatcher of the host system.

本実施例は第5図のフローチヤートに示すデイ
スパツチヤ機能(HVPデイスパツチヤと呼ぶ)
により特徴づけられる。以下第5図を参照しつつ
説明する。HVPデイスパツチヤへは、従来ホス
トシステムにおいてプロセスデイスパツチヤへ制
御が渡つたのと同じ契機(ホストシステムで実行
中のプロセスが待ち状態になつた割込処理を終了
した等)で入つてくる。まず、ホストシステムの
レデイプロセスリストRPLhを参照し、リスト上
にPCBが存在するならその先頭のプロセスを見
て、これのプライオリテイがレジスタ23の保持
する値より小さい(特権プロセス)ならば、この
プロセスデイスパツチする。
This embodiment uses the dispatcher function (referred to as HVP dispatcher) shown in the flowchart of FIG.
Characterized by. This will be explained below with reference to FIG. The HVP dispatcher is accessed at the same trigger as when control is passed to the process dispatcher in a conventional host system (such as when a process being executed in the host system completes an interrupt process that is in a wait state). First, refer to the ready process list RPL h of the host system, and if there is a PCB on the list, look at the first process, and if the priority of this is smaller than the value held in register 23 (privileged process), Dispatch this process.

先頭プロセスのプライオリテイがレジスタ23
の保持する値に等しいか大きい(一般プロセス)
かまたはホストのレデイプロセスリストが空であ
つたならば、レデイ仮想計算機リストRVML上
に仮想計算機制御ブロツクVMCBが登録されて
いるかどうか見る。もし、一つも登録されていな
かつたならば、HVPデイスパツチヤの入口に戻
り割込みがかかるまでループする。VMCBが存
在したら先頭のものを得て、このVMCBが
VMCB0でなかつたならば、対応する仮想計算
機にデイスパツチする。VMCB0であつたなら
ば、ホストレデイプロセスリストRPLhにプロセ
スが登録されているか否か見る。登録されていた
ら先頭のプロセスにデイスパツチする。RPLh
空であつたならば、VMCB0をレデイ仮想計算
機リストRVMLから外し、他の仮想計算機へデ
イスパツチするようにRVMLのサーチへ戻る。
The priority of the head process is in register 23
equal to or greater than the value held by (general process)
Or, if the host's ready process list is empty, check whether the virtual machine control block VMCB is registered on the ready virtual machine list RVML. If none are registered, the process returns to the HVP dispatcher entrance and loops until an interrupt occurs. If VMCB exists, get the first one and this VMCB
If it is not VMCB0, dispatch to the corresponding virtual machine. If it is VMCB0, check whether the process is registered in the host ready process list RPL h . If it is registered, dispatch to the first process. If RPL h is empty, remove VMCB0 from the ready virtual machine list RVML and return to the RVML search to dispatch to another virtual machine.

以上説明したように、本発明によればオーバヘ
ツドの少い統合型仮想計算機システムに関してホ
ストシステムと一般の仮想計算機との間の処理能
力の配分を自由に制御可能な仮想計算機システム
を実現することが可能となる。
As explained above, according to the present invention, it is possible to realize a virtual computer system that can freely control the distribution of processing power between a host system and a general virtual computer in an integrated virtual computer system with low overhead. It becomes possible.

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

第1図はCP型の仮想計算機システムの概念的
な構成を示すブロツク図、第2図は本発明で対象
としている統合型仮想計算機システムの概念的な
構成を示すブロツク図、第3図は本発明の実施例
における構成を示すブロツク図、第4図は第一の
実施例における仮想計算機デイスパツチヤおよび
プロセスデイスパツチヤの動作を示すフローチヤ
ート、第5図は第二の実施例におけるホストシス
テムの仮想計算機およびプロセスデイスパツチヤ
の動作を示すフローチヤートである。 図において、1は記憶装置、2はCPU、21
は実行中仮想計算機番号の保持レジスタ、22は
実行中プロセスID保持レジスタ、23は境界プ
ライオリテイ保持レジスタを示す。
Fig. 1 is a block diagram showing the conceptual configuration of a CP type virtual computer system, Fig. 2 is a block diagram showing the conceptual configuration of the integrated virtual computer system targeted by the present invention, and Fig. 3 is a block diagram showing the conceptual configuration of the integrated virtual computer system targeted by the present invention. FIG. 4 is a block diagram showing the configuration of an embodiment of the invention, FIG. 4 is a flowchart showing the operation of the virtual machine dispatcher and process dispatcher in the first embodiment, and FIG. 5 is a virtual diagram of the host system in the second embodiment. 3 is a flowchart showing the operation of a computer and a process dispatcher. In the figure, 1 is a storage device, 2 is a CPU, 21
22 is an executing process ID holding register, and 23 is a boundary priority holding register.

Claims (1)

【特許請求の範囲】 1 実計算機上で実行されるホスト・オペレーテ
イングシステムの制御の下で複数のプロセス(ホ
ストプロセス)と複数の仮想計算機とを実行させ
る統合型仮想計算機システムにおいて、前記ホス
トプロセスのデイスパツチングプライオリテイに
関する境界値を設定および前記境界値を保持する
手段、および前記境界値より低いデイスパツチン
グプライオリテイをもつホストプロセス全体をも
デイスパツチ対象としては、一つの仮想計算機
(ホスト仮想計算機)として扱い、これも含めて
各仮想計算機対応に仮想計算機ブライオリテイを
設定および前記ブライオリテイを保持する手段
と、上記境界値より高いデイスパツチングプライ
オリテイをもつホストプロセスがデイスパツチ待
ちならばすべての仮想計算機よりも優先的にホス
トシステムにデイスパツチし、前記境界値より高
いデイスパツチングプライオリテイをもつホスト
プロセスが存在しなかつた場合にはホスト仮想計
算機を含むデイスパツチ待ちのすべての仮想計算
機を対象に仮想計算機プライオリテイに基づいて
デイスパツチする仮想計算機デイスパツチ機構と
を備えることを特徴とする統合型仮想計算機シス
テムにおけるデイスパツチ制御方式。 2 前記仮想計算機デイスパツチ機構として実行
中の仮想計算機がアイドル状態になつたことを検
出し、直ちに仮想計算機デイスパツチヤを起動す
る機能をももつ特許請求の範囲第1項記載の統合
型仮想計算機システムにおけるデイスパツチ制御
方式。 3 前記仮想計算機プライオリテイ設定および前
記プライオリテイを保持する手段として仮想計算
機プライオリテイ変更命令と、その実行機能をも
備えた特許請求の範囲第1項記載の統合型仮想計
算システムにおけるデイスパツチ制御方式。
[Scope of Claims] 1. In an integrated virtual computer system in which a plurality of processes (host processes) and a plurality of virtual machines are executed under the control of a host operating system executed on a real computer, the host process means for setting and maintaining a boundary value regarding the dispatching priority of a single virtual computer (host virtual A means for setting a virtual machine priority for each virtual machine including this virtual machine and maintaining said priority, and a means for maintaining said priority for each virtual machine, and if a host process with a dispatch priority higher than the above boundary value is waiting for dispatch, all virtual machines are Dispatch is given to the host system with priority over the computer, and if there is no host process with a dispatch priority higher than the above-mentioned boundary value, all virtual machines waiting for dispatch, including the host virtual machine, are dispatched to the host system. 1. A dispatch control method in an integrated virtual computer system, comprising a virtual machine dispatch mechanism that dispatches based on computer priority. 2. In the integrated virtual machine system according to claim 1, the virtual machine dispatch mechanism has a function of detecting that a virtual machine running becomes idle and immediately starting a virtual machine dispatcher. Dispatch control method. 3. A dispatch control method in an integrated virtual computing system according to claim 1, further comprising a virtual machine priority change command and its execution function as means for setting the virtual machine priority and holding the priority.
JP16901482A 1982-09-28 1982-09-28 Dispatch control system of integrated type virtual computer Granted JPS5958553A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP16901482A JPS5958553A (en) 1982-09-28 1982-09-28 Dispatch control system of integrated type virtual computer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP16901482A JPS5958553A (en) 1982-09-28 1982-09-28 Dispatch control system of integrated type virtual computer

Publications (2)

Publication Number Publication Date
JPS5958553A JPS5958553A (en) 1984-04-04
JPH0363768B2 true JPH0363768B2 (en) 1991-10-02

Family

ID=15878726

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16901482A Granted JPS5958553A (en) 1982-09-28 1982-09-28 Dispatch control system of integrated type virtual computer

Country Status (1)

Country Link
JP (1) JPS5958553A (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4916608A (en) * 1986-05-30 1990-04-10 International Business Machines Corporation Provision of virtual storage resources to an operating system control program
US6986137B1 (en) 1999-09-28 2006-01-10 International Business Machines Corporation Method, system and program products for managing logical processors of a computing environment
US7007276B1 (en) 1999-09-28 2006-02-28 International Business Machines Corporation Method, system and program products for managing groups of partitions of a computing environment
JP5648544B2 (en) 2011-03-15 2015-01-07 富士通株式会社 Scheduling program and information processing apparatus

Also Published As

Publication number Publication date
JPS5958553A (en) 1984-04-04

Similar Documents

Publication Publication Date Title
JP3546678B2 (en) Multi-OS configuration method
US6711605B2 (en) Multi OS configuration method and computer system
EP1467282B1 (en) Operating systems
US9304794B2 (en) Virtual machine control method and virtual machine system using prefetch information
US7657888B2 (en) Method for forking or migrating a virtual machine
JP5106036B2 (en) Method, computer system and computer program for providing policy-based operating system services within a hypervisor on a computer system
US8635615B2 (en) Apparatus and method for managing hypercalls in a hypervisor and the hypervisor thereof
JPS62163149A (en) Dispatching control system for virtual computer
JPH0695898A (en) Control method for virtual computer and virtual computer system
JPH0754471B2 (en) Data processing device
US20090241112A1 (en) Recording medium recording virtual machine control program and virtual machine system
JPH06243112A (en) Multiprocessor device
JP2000259434A (en) Logical interval type computer system
JPH0363768B2 (en)
EP0223463B1 (en) Multiprocessor data processing system
JP2001216172A (en) Multi-os constituting method
JP2902746B2 (en) Virtual computer control method
JP2006522971A (en) operating system
JPS59167756A (en) Dispatch control system of virtual computer
Walters et al. Enabling interactive jobs in virtualized data centers
Tsai et al. On the architectural support for logical machine systems
Hatch Jr et al. Hardware/software interaction on the Honeywell model 8200
JP2556018B2 (en) Channel path group management method
JP2932547B2 (en) Communication register virtualization method
JPS62221041A (en) Dispatch controller in virtual computer system