JPH04235625A - Buffer control system - Google Patents

Buffer control system

Info

Publication number
JPH04235625A
JPH04235625A JP3012710A JP1271091A JPH04235625A JP H04235625 A JPH04235625 A JP H04235625A JP 3012710 A JP3012710 A JP 3012710A JP 1271091 A JP1271091 A JP 1271091A JP H04235625 A JPH04235625 A JP H04235625A
Authority
JP
Japan
Prior art keywords
output
load
buffer
input
database
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
JP3012710A
Other languages
Japanese (ja)
Inventor
Hirohiko Tanigawa
谷川 博彦
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 JP3012710A priority Critical patent/JPH04235625A/en
Publication of JPH04235625A publication Critical patent/JPH04235625A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PURPOSE:To attain the input/output of a block to a data base when a device control CPU has the load of 8 low level. CONSTITUTION:A data base 110 is provided together with a buffer 12 which holds the block to be inputted to end outputted from the data base 110. Then a CPU load measuring means 5 is ended to count the number of programs executed within a prescribed time together with a CPU load estimating means 16 which estimetes the load of a CPU based on the measuring result of the means 15, and a buffer control means 14 which performs the input/output of a block to the data base 110 when the CPU load obtained based on the results of both means 15 end 16 is lower then a reference level.

Description

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

【0001】0001

【技術分野】本発明はバッファ管理システムに関し、特
に二次記憶装置上に格納されたデータベースのデータの
ブロックの入出力管理システムに関する。
TECHNICAL FIELD The present invention relates to a buffer management system, and more particularly to an input/output management system for blocks of database data stored on a secondary storage device.

【0002】0002

【従来技術】従来、この種のシステムは、磁気ディスク
装置等の二次記憶装置上に設けられたデータベースにデ
ータを出力する場合、データベースのブロックと呼ばれ
る大きさのデータをシステム内のデータベースアクセス
用のバッファに格納し、その後データベースに出力する
。通常、そのバッファは、複数のブロックを格納し得る
容量を有し、プログラム実行体が出力を要求しても、入
出力回数が少なくなるように、実際にはすぐにデータベ
ースには出力されず、バッファが満杯になってしまった
ときや、静止点と呼ばれるプログラム上後戻り可能な状
態をつくるとき、データベースにバッファのデータが出
力されていた。
[Prior Art] Conventionally, when this type of system outputs data to a database provided on a secondary storage device such as a magnetic disk device, data of a size called a database block is used for database access within the system. buffer, and then output to the database. Normally, the buffer has a capacity that can store multiple blocks, and even if the program execution body requests output, the output is not actually output to the database immediately so as to reduce the number of input/outputs. When the buffer became full or when creating a state called a rest point in the program that allowed the program to backtrack, the data in the buffer was output to the database.

【0003】次に、その従来のシステムについて図面を
参照して説明する。
Next, the conventional system will be explained with reference to the drawings.

【0004】図5は従来のバッファ管理方式の構成を表
すブロック図である。図において、10は中央処理装置
等の処理装置、11はデータベース110 を格納する
磁気ディスク等の二次記憶装置、13は入出力手段であ
る。 処理装置10内には、複数のブロックを格納できるバッ
ファ12と、バッファ管理手段14とが設けられている
FIG. 5 is a block diagram showing the configuration of a conventional buffer management system. In the figure, 10 is a processing unit such as a central processing unit, 11 is a secondary storage device such as a magnetic disk that stores a database 110, and 13 is an input/output means. In the processing device 10, a buffer 12 capable of storing a plurality of blocks and a buffer management means 14 are provided.

【0005】かかる構成において、プログラム実行体1
aがバッファ管理手段14にブロックの出力を要求する
と、バッファ制御手段14はバッファ12上のブロック
の更新を行う。
In such a configuration, the program execution body 1
When a requests the buffer management means 14 to output a block, the buffer control means 14 updates the block on the buffer 12.

【0006】そして、バッファ12が満杯になってしま
ったときは、バッファ制御手段14が入出力手段13に
出力要求を行い、入出力手段13はデータベース110
 に出力を行ってバッファ12に空きをつくる。また、
プログラム実行体1aが静止点をつくる要求をすると、
バッファ管理手段14が入出力手段13にバッファ12
の内容全てを出力する要求を行い、入出力手段13はバ
ッファ12の内容全てをデータベース110 に出力す
る。
[0006] When the buffer 12 becomes full, the buffer control means 14 makes an output request to the input/output means 13, and the input/output means 13
to create space in the buffer 12. Also,
When the program execution body 1a requests to create a static point,
The buffer management means 14 sends the buffer 12 to the input/output means 13.
The input/output means 13 outputs all the contents of the buffer 12 to the database 110.

【0007】しかし、上述した従来のバッファ管理シス
テムでは、バッファ12が満杯になってしまったとき又
は、プログラム実行体1aが静止点をつくる要求をした
ときにしか、バッファ12の内容をデータベース110
 に出力しないため、その時、図示せぬCPUの負荷が
高くても、さらにCPUの負荷を増加させてしまいCP
Uの負荷の高い状態が一時に集中するという欠点があっ
た。
However, in the conventional buffer management system described above, the contents of the buffer 12 are transferred to the database 110 only when the buffer 12 becomes full or when the program execution unit 1a requests to create a quiet point.
Therefore, even if the load on the CPU (not shown in the figure) is high at that time, the load on the CPU will further increase and the CPU
There was a drawback that the high load state of U was concentrated at one time.

【0008】[0008]

【発明の目的】本発明は上述した従来の欠点を解決する
ためになされたものであり、その目的はCPUの負荷の
低いときにデータベースに対するブロックの入出力を行
うことができるバッファ管理システムを提供することで
ある。
OBJECTS OF THE INVENTION The present invention has been made to solve the above-mentioned conventional drawbacks, and its purpose is to provide a buffer management system that can input and output blocks to and from a database when the CPU load is low. It is to be.

【0009】[0009]

【発明の構成】本発明によるバッファ管理システムは、
データベースと、このデータベースに対して入出力すべ
きブロックを保持するバッファと、前記ブロックを前記
データベースに対して入出力する入出力手段とを有する
装置におけるバッファ管理システムであって、前記装置
の制御用CPUの負荷を予測する負荷予測手段と、この
負荷予測値が所定値以下のとき、前記入出力手段による
前記ブロックの前記データベースに対する入出力を実行
せしめる制御手段とを有することを特徴とする。
[Configuration of the Invention] A buffer management system according to the present invention includes:
A buffer management system for a device having a database, a buffer for holding blocks to be input/output to the database, and an input/output means for inputting/outputting the blocks to/from the database, the buffer management system being for controlling the device. The present invention is characterized by comprising a load prediction means for predicting the load on the CPU, and a control means for causing the input/output means to execute input/output of the block to the database when the predicted load value is less than a predetermined value.

【0010】0010

【実施例】次に、本発明について図面を参照して説明す
る。
DESCRIPTION OF THE PREFERRED EMBODIMENTS Next, the present invention will be explained with reference to the drawings.

【0011】図1は本発明によるバッファ管理システム
の一実施例の構成を示すブロック図であり、図5と同等
部分は同一符号により示されている。図において、11
0 は二次記憶装置11上のデータベース、12はバッ
ファ、13はデータベース110 とバッファ12との
入出力を行う入出力手段、14はバッファ管理手段、2
0はCPU負荷測定手段15及びCPU負荷予測手段1
6並びに基準値設定手段17からなる負荷予測手段、1
8は出力要求手段、19は出力ブロック数変更手段であ
る。
FIG. 1 is a block diagram showing the configuration of an embodiment of a buffer management system according to the present invention, and parts equivalent to those in FIG. 5 are designated by the same reference numerals. In the figure, 11
0 is a database on the secondary storage device 11, 12 is a buffer, 13 is an input/output means for performing input/output between the database 110 and the buffer 12, 14 is a buffer management means, 2
0 is CPU load measuring means 15 and CPU load predicting means 1
6 and a reference value setting means 17;
8 is an output requesting means, and 19 is an output block number changing means.

【0012】かかる構成とされた本実施例のバッファ管
理システムは、負荷予測手段20により、本システムが
搭載される装置のCPUの負荷を予測し、その負荷が低
いときに集中的にデータベース110 に対してブロッ
クの入出力を行うものである。
The buffer management system of this embodiment having such a configuration predicts the load on the CPU of the device in which this system is installed using the load prediction means 20, and intensively updates the database 110 when the load is low. It inputs and outputs blocks to and from the

【0013】次に、図2を用いて実際の入出力制御を行
う場合の動作を説明する。図2に示されているシステム
において、10は中央処理装置等の処理装置、11がデ
ータベース110 を格納する磁気ディスク等の二次記
憶装置、13は入出力手段である。処理装置10内には
、複数のブロックを格納できるバッファ12と、バッフ
ァ管理手段14とが設けられている。
Next, the operation of actual input/output control will be explained using FIG. 2. In the system shown in FIG. 2, 10 is a processing unit such as a central processing unit, 11 is a secondary storage device such as a magnetic disk that stores a database 110, and 13 is an input/output means. In the processing device 10, a buffer 12 capable of storing a plurality of blocks and a buffer management means 14 are provided.

【0014】プログラム実行体1aが、バッファ管理手
段14にブロックの出力を要求すると、バッファ管理手
段14はバッファ12上のブロックの更新を行う。
When the program execution body 1a requests the buffer management means 14 to output a block, the buffer management means 14 updates the block on the buffer 12.

【0015】CPU負荷測定手段15は、一定の周期で
図示せぬCPUの負荷を測定するものである。それは例
えば、ある時間から一定の周期の間に起動されたプログ
ラム実行体の数を数えるものである。
The CPU load measuring means 15 measures the load of a CPU (not shown) at regular intervals. For example, it counts the number of program executables activated during a certain period from a certain time.

【0016】CPU負荷予測手段16は、CPU負荷測
定手段15による測定値を元にCPUの負荷の予測値を
算出する。例えば、測定の周期をT、前々回の測定値を
L、前回の測定値をM、今回の測定値をNとすると、予
測値Kは、     K=L+(L−M)/T+{(L−M)/T−
(M−N)/T}/Tで求められる。
The CPU load predicting means 16 calculates a predicted value of the CPU load based on the measured value by the CPU load measuring means 15. For example, if the measurement period is T, the previous measurement value is L, the previous measurement value is M, and the current measurement value is N, the predicted value K is: K=L+(L-M)/T+{(L- M)/T-
(M-N)/T}/T.

【0017】基準値設定手段17は、それ以下のときに
は出力要求手段18がバッファ管理手段14にブロック
の出力を要求するというCPU負荷予測値の基準値を設
定する。
The reference value setting means 17 sets a reference value for the CPU load prediction value, at which the output requesting means 18 requests the buffer management means 14 to output a block when the value is less than the reference value.

【0018】出力ブロック数変更手段19は、CPU負
荷予測値又はCPU負荷測定値がそれ以下のときには出
力要求手段18がバッファ管理手段14に出力するブロ
ック数を変更するというCPU負荷の基準値を設定する
。CPU負荷がその基準値以下のときは、出力ブロック
数変更手段19は出力要求手段18に、出力要求をする
ブロック数を変更させる。すなわち、CPU負荷が低い
時にブロック数を多くして集中的に出力させれば良いの
である。
The output block number changing means 19 sets a reference value of the CPU load such that the number of blocks output by the output requesting means 18 to the buffer management means 14 is changed when the predicted CPU load value or the measured CPU load value is less than that value. do. When the CPU load is less than the reference value, the output block number changing means 19 causes the output requesting means 18 to change the number of blocks to be output requested. That is, when the CPU load is low, it is sufficient to increase the number of blocks and output them intensively.

【0019】CPU負荷として、CPU負荷予測値とC
PU負荷測定値とのどちらを使用するかは、CPU負荷
測定値の増加率によって決定する。例えば、測定の周期
をT、前々回の測定値をL、前回の測定値をM、今回の
測定値をNとすると、CPU負荷測定値の増加率Jは、
J={(L−M)/T−(M−N)/T}/Tで求めら
れる。CPU負荷測定値の増加率が正のときはCPU負
荷測定値をCPU負荷とし、CPU負荷測定値の増加率
が負のときはCPU負荷予測値をCPU負荷とするので
ある。
[0019] As the CPU load, the predicted CPU load value and C
Which of the CPU load measurement values to use is determined by the increase rate of the CPU load measurement values. For example, if the measurement period is T, the previous measurement value is L, the previous measurement value is M, and the current measurement value is N, then the increase rate J of the CPU load measurement value is:
It is determined by J={(LM)/T-(MN)/T}/T. When the increase rate of the CPU load measurement value is positive, the CPU load measurement value is used as the CPU load, and when the increase rate of the CPU load measurement value is negative, the CPU load predicted value is used as the CPU load.

【0020】かかる構成のシステムにおいて、基準値設
定手段17の設定した基準値がX、出力ブロック数変更
手段19の設定した基準値がYだったときの処理の流れ
について図3及び図4を参照して説明する。
Refer to FIGS. 3 and 4 for the processing flow when the reference value set by the reference value setting means 17 is X and the reference value set by the output block number changing means 19 is Y in the system configured as described above. and explain.

【0021】図3において、まず、CPU負荷測定手段
15が図示せぬCPUの負荷を測定する(ステップ31
)。そして、CPU負荷測定手段15は、測定値をCP
U負荷予測手段16に送る(ステップ32)。CPU負
荷予測手段16はこれをもとに予測値を算出する(ステ
ップ33)。そして、CPU負荷予測手段16は、予測
値を出力ブロック数変更手段19に送る(ステップ34
)。
In FIG. 3, first, the CPU load measuring means 15 measures the load of the CPU (not shown) (step 31).
). Then, the CPU load measuring means 15 converts the measured value into CPU
It is sent to the U load prediction means 16 (step 32). The CPU load prediction means 16 calculates a predicted value based on this (step 33). Then, the CPU load prediction means 16 sends the predicted value to the output block number changing means 19 (step 34
).

【0022】CPU負荷測定手段15も、測定値を出力
ブロック数変更手段19に送る。(ステップ35)。出
力ブロック数変更手段19は、CPU負荷測定値の増加
率が正か負かを判断する(ステップ36)。増加率が正
のときは、CPU負荷測定値をCPU負荷とし(ステッ
プ37)、CPU負荷測定値の増加率が負のときはCP
U負荷予測値をCPU負荷とする(ステップ38)。
The CPU load measuring means 15 also sends the measured value to the output block number changing means 19. (Step 35). The output block number changing means 19 determines whether the increase rate of the CPU load measurement value is positive or negative (step 36). When the increase rate is positive, the CPU load measurement value is set as the CPU load (step 37), and when the increase rate of the CPU load measurement value is negative, the CPU load measurement value is set as the CPU load (step 37).
The predicted U load value is set as the CPU load (step 38).

【0023】図4に移り、CPU負荷が基準値Y以下な
らば、出力要求手段18がバッファ管理手段14に出力
するブロック数を、例えばGに変更するよう指示する(
ステップ39→40)。
Turning to FIG. 4, if the CPU load is below the reference value Y, the output request means 18 instructs the buffer management means 14 to change the number of blocks to be output to, for example, G (
Step 39→40).

【0024】次に、基準値設定手段17は基準値Xを出
力要求手段18に送る(ステップ41)。CPU負荷予
測手段16も、予測値を出力要求手段18に送る(ステ
ップ42)。そして、CPU予測値負荷が基準値X以下
ならば、バッファ管理手段14にブロックの出力を要求
する(ステップ43→44)。
Next, the reference value setting means 17 sends the reference value X to the output requesting means 18 (step 41). The CPU load prediction means 16 also sends the predicted value to the output request means 18 (step 42). If the predicted CPU load is less than the reference value X, the buffer management means 14 is requested to output the block (steps 43→44).

【0025】これをうけて、バッファ管理手段14は入
出力手段13にブロック出力要求を行う(ステップ45
)。入出力手段13は、バッファ12からデータベース
110 へブロックを出力する(ステップ46)。
In response to this, the buffer management means 14 issues a block output request to the input/output means 13 (step 45).
). The input/output means 13 outputs the block from the buffer 12 to the database 110 (step 46).

【0026】バッファ12が満杯になってしまったとき
は、従来例と同様に、バッファ制御手段14が入出力手
段13に出力要求を行い、入出力手段13はデータベー
ス110 に出力を行ってバッファ13に空きをつくる
。また、プログラム実行体1aが静止点をつくる要求を
すると、同じく従来例と同様に、バッファ管理手段14
が入出力手段13にバッファ12の内容全てを出力する
要求を行い、入出力手段13はバッファ12の内容全て
をデータベース110 に出力する。
When the buffer 12 becomes full, the buffer control means 14 makes an output request to the input/output means 13, and the input/output means 13 outputs the data to the database 110 and fills the buffer 13. Create space in Further, when the program execution body 1a requests to create a static point, the buffer management means 14
requests the input/output means 13 to output all the contents of the buffer 12, and the input/output means 13 outputs all the contents of the buffer 12 to the database 110.

【0027】なお、以上はバッファ内のブロックをデー
タベースへ出力する場合の例であるが、逆にデータベー
ス内のブロックをバッファに出力する場合にも同様にC
PU負荷に応じて出力を行うことができる。
Note that the above is an example of outputting blocks in the buffer to the database, but conversely, when outputting blocks in the database to the buffer, C
Output can be performed according to the PU load.

【0028】[0028]

【発明の効果】以上説明したように本発明は、CPUの
負荷を予測することにより、バッファからデータベース
に対するブロックの入出力をCPUの負荷の低い時に集
中的に行うことができ、CPUに負荷が集中せず、CP
Uを効率的に運用できるという効果がある。
Effects of the Invention As explained above, the present invention enables block input/output from a buffer to a database to be performed intensively when the CPU load is low by predicting the CPU load, thereby reducing the load on the CPU. Don't concentrate, CP
This has the effect of allowing U to be operated efficiently.

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

【図1】本発明の実施例によるバッファ管理システムの
構成を示すブロック図である。
FIG. 1 is a block diagram showing the configuration of a buffer management system according to an embodiment of the present invention.

【図2】図1のバッファ管理システムにより入出力制御
を行う場合の概略構成図である。
FIG. 2 is a schematic configuration diagram when input/output control is performed by the buffer management system of FIG. 1;

【図3】図2のシステムにおける処理動作を示すフロー
チャートである。
FIG. 3 is a flowchart showing processing operations in the system of FIG. 2;

【図4】図2のシステムにおける処理動作を示すフロー
チャートである。
FIG. 4 is a flowchart showing processing operations in the system of FIG. 2;

【図5】従来のバッファ管理システムの構成を示すブロ
ック図である。
FIG. 5 is a block diagram showing the configuration of a conventional buffer management system.

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

12  バッファ 13  入出力手段 17  基準値設定手段 18  出力要求手段 20  負荷予測手段 12 Buffer 13 Input/output means 17 Standard value setting means 18 Output request means 20 Load prediction means

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】  データベースと、このデータベースに
対して入出力すべきブロックを保持するバッファと、前
記ブロックを前記データベースに対して入出力する入出
力手段とを有する装置におけるバッファ管理システムで
あって、前記装置の制御用CPUの負荷を予測する負荷
予測手段と、この負荷予測値が所定値以下のとき、前記
入出力手段による前記ブロックの前記データベースに対
する入出力を実行せしめる制御手段とを有することを特
徴とするバッファ管理システム。
1. A buffer management system for an apparatus having a database, a buffer for holding blocks to be input/output to the database, and input/output means for inputting/outputting the blocks to/from the database, comprising: The apparatus further comprises a load prediction means for predicting a load on a control CPU of the apparatus, and a control means for causing the input/output means to input/output the block to the database when the predicted load value is less than or equal to a predetermined value. Features a buffer management system.
【請求項2】  前記負荷予測手段は、前記装置の制御
用CPUの負荷を測定する手段と、前記負荷測定手段に
よる過去の測定結果をもとに前記CPUの負荷を予測す
る手段と、これら両手段からの値に応じて前記データベ
ースに対して入出力すべきブロック数を変更する手段と
からなることを特徴とする請求項1記載のバッファ管理
システム。
2. The load prediction means includes means for measuring a load on a control CPU of the apparatus, means for predicting a load on the CPU based on past measurement results by the load measurement means, and both of these. 2. The buffer management system according to claim 1, further comprising means for changing the number of blocks to be input/output to said database in accordance with a value from said means.
JP3012710A 1991-01-09 1991-01-09 Buffer control system Pending JPH04235625A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3012710A JPH04235625A (en) 1991-01-09 1991-01-09 Buffer control system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3012710A JPH04235625A (en) 1991-01-09 1991-01-09 Buffer control system

Publications (1)

Publication Number Publication Date
JPH04235625A true JPH04235625A (en) 1992-08-24

Family

ID=11812975

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3012710A Pending JPH04235625A (en) 1991-01-09 1991-01-09 Buffer control system

Country Status (1)

Country Link
JP (1) JPH04235625A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7421460B2 (en) 2002-11-20 2008-09-02 Hitachi, Ltd. Method for determining execution of backup on a database

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7421460B2 (en) 2002-11-20 2008-09-02 Hitachi, Ltd. Method for determining execution of backup on a database

Similar Documents

Publication Publication Date Title
US6553487B1 (en) Device and method for performing high-speed low overhead context switch
US7805709B2 (en) System and method for bypassing execution of an algorithm
JPH04235625A (en) Buffer control system
JPH06161837A (en) System for selecting volume on external storage device
JPH04257940A (en) Buffer managing system
JPH0588917A (en) Job scheduling system
JPH04195626A (en) Guidance display device
JPH07105022A (en) Microcomputer
JPH1063603A (en) Peripheral control device and its load state setting method
JPH10133997A (en) Dma controller
JPH03196345A (en) Data input/output system
JP2562515B2 (en) Direct access storage device selection processing method
JPH0454544A (en) Memory access controller
JPH05225020A (en) Buffer management system
JPH0644107A (en) File migration control system
JPH02166536A (en) Method and device for controlling main storage
JPH01121920A (en) Seek control method for storage device
JPH11219362A (en) Data processor, data processing method, data base system and recording medium
JPH0619796A (en) Automatic changing system for swapping use external storage device in virtual storage system
JP2000066903A (en) Interrupt processing system and interrupt processing method
JPH04355861A (en) Peripheral control processing device
JPH0612360A (en) Input/output control system for extended storage device
JPH01248257A (en) Load distribution control system for input output to auxiliary storage device
JPH0272435A (en) Central arithmetic processor
JPS63300350A (en) Task schedule system for multiprocessor system