JP5103954B2 - Memory management device, memory management method and program - Google Patents
Memory management device, memory management method and program Download PDFInfo
- Publication number
- JP5103954B2 JP5103954B2 JP2007060521A JP2007060521A JP5103954B2 JP 5103954 B2 JP5103954 B2 JP 5103954B2 JP 2007060521 A JP2007060521 A JP 2007060521A JP 2007060521 A JP2007060521 A JP 2007060521A JP 5103954 B2 JP5103954 B2 JP 5103954B2
- Authority
- JP
- Japan
- Prior art keywords
- memory
- identification information
- unit
- application program
- amount
- 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 - Fee Related
Links
Images
Description
本発明は、メモリの空き領域を管理するメモリ管理装置、メモリ管理方法およびプログラムに関する。 The present invention relates to a memory management device, a memory management method, and a program for managing a free area of a memory.
通常、アプリケーションプログラムの起動では、メモリが使用される。この起動中にメモリの空き領域が不足した場合、オペレーティングシステム(OSと略す)が、メモリの空き領域を確保するための領域確保処理を行なう。領域確保処理は、例えば、スワップ処理である。 Normally, a memory is used for starting an application program. If there is a shortage of memory space during the start-up, the operating system (abbreviated as OS) performs an area securing process for securing the memory space. The area securing process is, for example, a swap process.
アプリケーションプログラムの起動中に領域確保処理が行なわれると、そのアプリケーションプログラムの起動が完了するまでに非常に時間がかかるという問題があった。 If the area securing process is performed during the activation of the application program, there is a problem that it takes a very long time to complete the activation of the application program.
従来、この問題を改善するために、メモリ管理装置が用いられている。 Conventionally, in order to improve this problem, a memory management device is used.
メモリ管理装置は、先ず、アプリケーションプログラムの起動が要求されると、その起動が要求されたアプリケーションプログラムのメモリの使用量を予測する。続いて、メモリ管理装置では、OSが、その予測された使用量の空きメモリ領域を確保し、その後、そのアプリケーションプログラムを起動する。 First, when activation of an application program is requested, the memory management device predicts the memory usage of the application program requested to be activated. Subsequently, in the memory management device, the OS secures a free memory area of the predicted usage amount, and then starts the application program.
これにより、アプリケーションプログラムの起動の速度を向上させることが可能になる。 As a result, it is possible to improve the startup speed of the application program.
このようなメモリ管理装置として、例えば、特許文献1(特開2001−256111号公報)に記載のシステム監視装置がある。 As such a memory management device, for example, there is a system monitoring device described in Japanese Patent Application Laid-Open No. 2001-256111.
このシステム監視装置では、システムリソース監視手段が設けられている。システムリソース監視手段は、アプリケーションプログラムにて使用されるメモリサイズを予測する予測手段と、その予測されたメモリサイズに基づいて、そのアプリケーションプログラムで使用されるメモリの領域を確保する確保手段とを備える。 In this system monitoring apparatus, system resource monitoring means is provided. The system resource monitoring means includes a prediction means for predicting a memory size used in the application program, and a securing means for securing a memory area used in the application program based on the predicted memory size. .
予測手段は、アプリケーションプログラムが起動されるたびに、そのアプリケーションプログラムで使用されるメモリサイズを取得する。 Each time the application program is activated, the prediction means acquires the memory size used by the application program.
確保手段は、予測手段が過去に取得したメモリサイズの平均値を算出し、その算出した平均値分だけメモリの領域を確保する。
特許文献1に記載のシステム監視装置は、アプリケーションプログラムの起動の要求の後、その起動が要求されたアプリケーションプログラムによって使用される分のメモリサイズを過去の使用量から算出し、そのメモリサイズ分のメモリの領域を確保している。
The system monitoring device described in
このため、アプリケーションの起動が要求されてから、そのアプリケーションの起動が終了するまでの時間が長くなる。 For this reason, it takes a long time from the start of the application to the end of the start of the application.
本発明の目的は、アプリケーションプログラムの起動を迅速に行なうことが可能なメモリ管理装置、メモリ管理方法およびプログラムを提供することである。 An object of the present invention is to provide a memory management device, a memory management method, and a program capable of quickly starting an application program.
上記の目的を達成するために、本発明のメモリ管理装置は、予め起動手順が定められたアプリケーションプログラムの起動に必要なメモリ量を確保するメモリ管理装置であって、メモリと、アプリケーションプログラムと該アプリケーションプログラムの識別情報とを対応付けて記憶する特定記憶部と、前記アプリケーションプログラムの識別情報と、該アプリケーションプログラムから起動される別のアプリケーションプログラムの識別情報とを対応付けて記憶する起動手順記憶部と、前記別のアプリケーションプログラムの識別情報を、該別のアプリケーションプログラムの起動に必要なメモリ量と対応付けて記憶する需要記憶部と、前記アプリケーションプログラムを起動する旨の起動要求を受け付け、該起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を前記特定記憶部から選択する選択部と、前記選択部が選択した識別情報と対応付けられた前記別のアプリケーションプログラムの識別情報を前記起動手順記憶部から選択する監視部と、前記監視部が選択した識別情報と対応付けられたメモリ量を前記需要記憶部から選択し、かつ、前記メモリの空き領域を調べ、該空き領域が前記選択したメモリ量より大きいか否かを判定する推測部と、前記推測部にて前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで前記メモリの空き領域を確保する管理部と、を含む。 In order to achieve the above object, a memory management device of the present invention is a memory management device that secures an amount of memory necessary for starting an application program for which a startup procedure is predetermined, and includes a memory, an application program, A specific storage unit that stores the identification information of the application program in association with each other, and an activation procedure storage unit that associates and stores the identification information of the application program and the identification information of another application program activated from the application program A demand storage unit that stores the identification information of the other application program in association with the amount of memory required to start the other application program, and a startup request for starting the application program, App requested in request A selection unit that selects identification information associated with an application program from the specific storage unit, and identification information of the other application program that is associated with the identification information selected by the selection unit from the startup procedure storage unit And a memory amount associated with the identification information selected by the monitoring unit is selected from the demand storage unit, and a free area of the memory is checked, and the free area is larger than the selected memory amount. And when the estimation unit determines that the free area is smaller than the memory amount, the free area of the memory is secured until the free area of the memory becomes the memory amount. And a management unit.
また、本発明のメモリ管理方法は、アプリケーションプログラムと該アプリケーションプログラムの識別情報とを対応付けた情報と、前記アプリケーションプログラムの識別情報と該アプリケーションプログラムから起動される別のアプリケーションプログラムの識別情報とを対応付けた情報と、前記別のアプリケーションプログラムの識別情報を該別のアプリケーションプログラムの起動に必要なメモリ量と対応付けた情報とを活用し、予め起動手順が定められたアプリケーションプログラムの起動に必要なメモリ量を確保するためのメモリ管理方法であって、前記アプリケーションプログラムを起動する旨の起動要求を受け付ける受付ステップと、前記受け付けられた起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を選択する第一選択ステップと、前記選択された識別情報と対応付けられた前記別のアプリケーションプログラムの識別情報を選択する第二選択ステップと、前記選択された別のアプリケーションプログラムの識別情報と対応付けられたメモリ量を選択する第三選択ステップと、メモリの空き領域を調べる調査ステップと、前記調べられた空き領域が前記選択されたメモリ量より大きいか否かを判定する判定する判定ステップと、前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで前記メモリの領域を確保する確保ステップと、を含む。 Also, the memory management method of the present invention includes information associating an application program with identification information of the application program, identification information of the application program, and identification information of another application program started from the application program. Necessary for launching an application program whose launch procedure is determined in advance by utilizing the associated information and the information that associates the identification information of the other application program with the amount of memory necessary for launching the other application program A memory management method for securing a sufficient amount of memory, which is associated with a reception step for receiving a start request for starting the application program, and an application program requested by the received start request A first selection step of selecting identification information; a second selection step of selecting identification information of the other application program associated with the selected identification information; and identification information of the selected other application program A third selection step for selecting a memory amount associated with the memory, an investigation step for examining a free area of the memory, and a determination for determining whether or not the examined free area is larger than the selected memory amount And, when it is determined that the free area is smaller than the memory amount, a securing step of securing the memory area until the free area of the memory reaches the memory amount.
上記の発明によれば、メモリの空き領域が、アプリケーションプログラムから起動される別のアプリケーションプログラムの起動に必要なメモリ量になるまで確保される。 According to the above invention, the free space of the memory is secured until the memory amount necessary for starting another application program started from the application program is reached.
このため、別のアプリケーションプログラムの起動が要求される前に、その別のアプリケーションプログラムの起動に必要なメモリ量を確保することが可能になる。したがって、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 For this reason, it is possible to secure an amount of memory necessary for starting another application program before the start of another application program is requested. Therefore, the application program can be activated quickly.
また、本発明のメモリ管理装置は、プロセスを起動するためのシステムコールの生成パターンを、該プロセスの識別情報と対応付けて記憶する動作記憶部と、前記プロセスの識別情報を、該プロセスから起動される別のプロセスの識別情報と対応付けて記憶するプロセス起動手順記憶部と、前記別のプロセスの識別情報を、該別のプロセスの動作に必要なメモリ量と対応付けて記憶するプロセス需要記憶部と、前記システムコールを生成する実行部と、前記実行部が生成したシステムコールの生成パターンを解析し、該生成パターンと対応付けられたプロセスの識別情報を前記動作記憶部から選択し、その後、該プロセスの識別情報と対応付けられた前記別のプロセスの識別情報を前記プロセス起動手順記憶部から選択するプロセス監視部と、を含み、前記推測部は、前記プロセス監視部が選択したプロセスの識別情報と対応付けられたメモリ量を前記プロセス需要記憶部から選択し、かつ、前記メモリの空き領域を調べ、該空き領域が前記選択したメモリ量より大きいか否かを判定することが望ましい。 In addition, the memory management device of the present invention activates, from the process, an operation storage unit that stores a generation pattern of a system call for starting a process in association with the identification information of the process, and the identification information of the process. A process startup procedure storage unit that stores the identification information of the other process in association with the identification information of the other process, and the process demand storage that stores the identification information of the other process in association with the amount of memory necessary for the operation of the other process. Analyzing the system call generation pattern generated by the execution unit, selecting process identification information associated with the generation pattern from the operation storage unit, A process monitoring unit that selects, from the process activation procedure storage unit, identification information of the other process associated with the identification information of the process; The estimation unit selects a memory amount associated with the process identification information selected by the process monitoring unit from the process demand storage unit, checks a free area of the memory, and It is desirable to determine whether or not the selected memory amount is larger.
また、本発明のメモリ管理方法は、プロセスを起動するためのシステムコールの生成パターンを該プロセスの識別情報と対応付けた情報と、前記プロセスの識別情報を該プロセスから起動される別のプロセスの識別情報と対応付けた情報と、前記別のプロセスの識別情報を該別のプロセスの動作に必要なメモリ量と対応付けた情報とを活用し、前記システムコールを生成する生成ステップと、前記システムコールの生成パターンを解析する解析ステップと、前記解析された生成パターンと対応付けられたプロセスの識別情報を選択する第一プロセス選択ステップと、前記選択されたプロセスの識別情報と対応付けられた別のプロセスの識別情報を選択する第二プロセス選択ステップと、前記選択された別のプロセスの識別情報と対応付けられたメモリ量を選択する第三プロセス選択ステップと、を含むことが望ましい。 The memory management method of the present invention also includes information that associates a generation pattern of a system call for starting a process with identification information of the process, and identification information of the process of another process that is started from the process. A generation step for generating the system call by utilizing information associated with identification information and information associated with identification information of the another process and an amount of memory necessary for the operation of the other process; and the system An analysis step for analyzing a call generation pattern; a first process selection step for selecting identification information of a process associated with the analyzed generation pattern; and a separate step associated with the identification information of the selected process. A second process selection step for selecting the identification information of the other process and the identification information of the selected another process. It is desirable to include a third process selecting step of selecting the memory amount.
上記の発明によれば、メモリの空き領域が、プロセスから起動される別のプロセスの動作に必要なメモリ量になるまで確保される。 According to the above invention, the free area of the memory is secured until the memory amount necessary for the operation of another process started from the process is reached.
このため、別のプロセスが生成される前に、その別のプロセスの動作に必要なメモリ量を確保することが可能になる。よって、アプリケーションプログラムのプロセスの起動のときに、そのアプリケーションプログラムのプロセスの動作に必要な空きメモリ領域が予め確保されるので、容易にメモリの空き領域が確保され、その別のプロセスの生成を迅速に行うことが可能となる。したがって、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 For this reason, it is possible to secure an amount of memory necessary for the operation of another process before another process is generated. Therefore, when an application program process is started, a free memory area necessary for the operation of the application program process is secured in advance, so that a free memory area is easily secured, and another process can be quickly generated. Can be performed. Therefore, the application program can be activated quickly.
また、本発明のメモリ管理装置は、プロセスの識別情報を、該プロセスから起動される別のプロセスの識別情報と対応付けて記憶するプロセス起動手順記憶部と、前記別のプロセスの識別情報を、該別のプロセスの動作に必要なメモリ量と対応付けて記憶するプロセス需要記憶部と、機能を実行する旨の実行要求を受け付けると、該機能に応じたプロセスの識別情報を送る実行部と、前記実行部から受け付けたプロセスの識別情報と対応付けられた別のプロセスの識別情報を、前記プロセス起動手順記憶部から選択するプロセス監視部と、を含み、前記推測部は、前記プロセス監視部が選択したプロセスの識別情報と対応付けられたメモリ量を前記プロセス需要記憶部から選択し、かつ、前記メモリの空き領域を調べ、該空き領域が前記選択したメモリ量より大きいか否かを判定することが望ましい。 The memory management device of the present invention includes a process activation procedure storage unit that stores process identification information in association with identification information of another process activated from the process, and identification information of the other process, A process demand storage unit that stores the amount of memory necessary for the operation of the other process in association with it, an execution unit that sends process identification information corresponding to the function when receiving an execution request to execute the function; A process monitoring unit that selects, from the process activation procedure storage unit, identification information of another process associated with the process identification information received from the execution unit, and the estimation unit includes the process monitoring unit A memory amount associated with the identification information of the selected process is selected from the process demand storage unit, and a free area of the memory is checked, and the free area is the selected It was it is desirable to determine greater or not than the memory capacity.
また、本発明のメモリ管理方法は、プロセスの識別情報を該プロセスから起動される別のプロセスの識別情報と対応付けた情報と、前記別のプロセスの識別情報を該別のプロセスの動作に必要なメモリ量と対応付けた情報と、を活用し、機能を実行する旨の実行要求を受け付ける入力ステップと、前記機能に応じたプロセスの識別情報を送る送信ステップと、前記送られたプロセスの識別情報と対応付けられた別のプロセスの識別情報を選択する第四プロセス選択ステップと、前記選択された別のプロセスの識別情報と対応付けられたメモリ量を選択する第五プロセス選択ステップと、を含むことが望ましい。 Also, the memory management method of the present invention requires information for associating process identification information with identification information of another process started from the process and the identification information of the other process for the operation of the other process. An input step for accepting an execution request to execute a function by utilizing information associated with a sufficient amount of memory, a transmission step for sending process identification information corresponding to the function, and an identification of the sent process A fourth process selection step for selecting identification information of another process associated with the information, and a fifth process selection step for selecting an amount of memory associated with the identification information of the selected other process. It is desirable to include.
上記の発明によれば、実行を要求された機能に応じたプロセスの識別情報が送られる。また、そのプロセスの識別情報と対応付けられた別のプロセスの識別情報が選択される。 According to the above invention, the process identification information corresponding to the function requested to be executed is sent. Further, identification information of another process associated with the identification information of the process is selected.
このため、システムコールの生成パターンが解析されなくても、アプリケーションプログラムの起動のときに確保するメモリの領域を軽減することが可能になる。したがって、アプリケーションプログラムの起動をさらに迅速に行なうことが可能になる。 For this reason, even if the system call generation pattern is not analyzed, it is possible to reduce the memory area secured when the application program is activated. Therefore, the application program can be activated more quickly.
また、本発明のメモリ管理装置では、前記管理部は、前記推測部にて前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで、前記メモリ内のデータをスワップアウトするスワップ処理部を含むことが望ましい。 Further, in the memory management device of the present invention, when the estimation unit determines that the free area is smaller than the memory amount, the management unit continues until the free area of the memory reaches the memory amount. It is desirable to include a swap processing unit for swapping out the data in the inside.
また、本発明のメモリ管理方法では、前記管理ステップは、前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで、前記メモリ内のデータをスワップアウトするスワップアウトステップを含むことが望ましい。 In the memory management method of the present invention, when it is determined that the free area is smaller than the memory amount, the management step swaps data in the memory until the free area of the memory becomes the memory amount. It is desirable to include a swap-out step to out.
上記の発明によれば、メモリの空き領域が必要なメモリ量になるまで、メモリ内のデータが、スワップアウトされる。このため、容易にメモリの空き領域が確保され、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 According to the above invention, the data in the memory is swapped out until the free space of the memory reaches the required memory amount. For this reason, an empty area of the memory is easily secured, and the application program can be started up quickly.
また、本発明のメモリ管理装置では、前記推測部は、前記メモリにおいてアドレスが連続した空き領域を調べ、該空き領域が前記推測部にて選択されたメモリ量より大きいか否かを判定し、前記管理部は、前記アドレスが連続した空き領域が前記メモリ量より小さいと判定されると、前記アドレスが連続した空き領域が前記メモリ量になるまで、前記メモリをデフラグする整理部を含むことが望ましい。 Further, in the memory management device of the present invention, the estimation unit examines a free area having consecutive addresses in the memory and determines whether or not the free area is larger than a memory amount selected by the estimation unit. The management unit may include an organizing unit that defragments the memory until the free area where the addresses are continuous is smaller than the memory amount, until the free area where the addresses are continuous reaches the memory amount. desirable.
また、本発明のメモリ管理方法では、前記調査ステップでは、前記メモリにおいてアドレスが連続した空き領域を調べ、前記管理ステップは、前記アドレスが連続した空き領域が前記メモリ量より小さいと判定されると、前記アドレスが連続した空き領域が前記メモリ量になるまで、前記メモリをデフラグするデフラグステップを含むことが望ましい。 Further, in the memory management method of the present invention, in the investigating step, a free area having consecutive addresses is examined in the memory, and the managing step determines that the free area having consecutive addresses is smaller than the memory amount. Preferably, the method further includes a defragmentation step of defragmenting the memory until a free area where the addresses are continuous reaches the memory amount.
上記の発明によれば、メモリにおいてアドレスが連続した空き領域が必要なメモリ量になるまでデフラグされる。このため、アドレスが連続したメモリの空き領域が必要な場合に、スワップデバイスがなくても、そのアドレスが連続したメモリの空き領域が確保されるので、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 According to the above-described invention, defragmentation is performed until a free area having consecutive addresses in the memory reaches a necessary memory amount. For this reason, when there is a need for free memory space with consecutive addresses, even if there is no swap device, free memory space with consecutive addresses is secured, so application programs can be started up quickly. become.
また、本発明のプログラムは、前記メモリ管理方法をコンピュータに実行させる。 The program of the present invention causes a computer to execute the memory management method.
本発明によれば、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 According to the present invention, it is possible to quickly start an application program.
以下、本発明の実施形態について図面を参照して説明する。 Embodiments of the present invention will be described below with reference to the drawings.
図1は、本発明の第一の実施形態のメモリ管理装置の構成を示したブロック図である。メモリ管理装置は、アプリケーションプログラムを起動する機能を有し、アプリケーションプログラムの起動手順は、予め定められている。なお、メモリ管理装置は、コンピュータシステムに組み込まれる。 FIG. 1 is a block diagram showing the configuration of the memory management device according to the first embodiment of the present invention. The memory management device has a function of starting an application program, and the starting procedure of the application program is predetermined. The memory management device is incorporated in the computer system.
図1において、メモリ管理装置は、情報処理部10と、記憶部20と、メモリ30とを含む。
In FIG. 1, the memory management device includes an information processing unit 10, a storage unit 20, and a
情報処理部10は、アプリケーション選択部1と、アプリケーション制御部2と、アプリケーション監視部3と、メモリ推測部4と、メモリ管理部51とを含む。
The information processing unit 10 includes an
記憶部20は、アプリケーション起動手順記憶部21と、アプリケーションメモリ需要記憶部22と、アプリケーション特定記憶部23とを含む。
The storage unit 20 includes an application startup
アプリケーション起動手順記憶部(起動手順記憶部と略す)21は、あるアプリケーションプログラムから別のアプリケーションプログラムを起動する際のアプリケーションプログラムを対応付ける起動手順を記憶する。このとき、あるアプリケーションプログラムから別のアプリケーションプログラムへの対応付けが複数あってもよい。なお、これらの対応付けは、各アプリケーションプログラムの識別情報を用いて設定される。以下、あるアプリケーションプログラムから起動される別のアプリケーションプログラムを後続アプリケーションプログラムと称する。 The application startup procedure storage unit (abbreviated as startup procedure storage unit) 21 stores a startup procedure for associating an application program when starting another application program from a certain application program. At this time, there may be a plurality of associations from one application program to another application program. These associations are set using identification information of each application program. Hereinafter, another application program started from a certain application program is referred to as a subsequent application program.
起動手順は、アプリケーションプログラムの階層構造を示すツリーで表すことができる。図2は、アプリケーションプログラムの起動手順の一例を示した説明図である。 The activation procedure can be represented by a tree indicating the hierarchical structure of the application program. FIG. 2 is an explanatory diagram showing an example of a procedure for starting an application program.
図2では、ノード201から208までは、それぞれアプリケーションプログラムを示している。ノード202、206、207および208以外が示すアプリケーションプログラムは、次に後続アプリケーションプログラムを起動させるメニューとしても動作する。ノード201は、アプリケーション選択部1から最初に起動されるアプリケーションプログラムである。
In FIG. 2,
アプリケーションメモリ需要記憶部(需要記憶部と略す)22は、アプリケーションプログラムごとに(アプリケーションプログラムの識別情報ごとに)、アプリケーションプログラムの起動に必要なメモリ量を対応付ける需要情報を記憶する。 The application memory demand storage unit (abbreviated as demand storage unit) 22 stores demand information for each application program (for each identification information of the application program) that associates an amount of memory necessary for starting the application program.
必要なメモリ量は、過去に起動されたアプリケーションプログラムが起動に使用したメモリ量から求められてもよいし、アプリケーションプログラムの設計者または利用者にて予め設定されてもよい。 The required amount of memory may be obtained from the amount of memory used for activation by an application program activated in the past, or may be set in advance by a designer or user of the application program.
アプリケーション特定記憶部(特定記憶部と略す)23は、コンピュータシステムにインストールされたアプリケーションプログラムと、そのアプリケーションプログラムの識別情報を対応付ける特定情報を記憶する。 The application specific storage unit (abbreviated as a specific storage unit) 23 stores specific information that associates an application program installed in the computer system with identification information of the application program.
アプリケーション選択部(選択部と略す)1は、アプリケーションプログラムを起動する旨の起動要求を受け付ける。選択部1は、その起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を特定記憶部23から選択し、そのアプリケーションプログラムの起動をアプリケーション制御部(制御部と略す)2に対して要求する。
An application selection unit (abbreviated as a selection unit) 1 accepts an activation request to activate an application program. The
ここで、選択部1は、起動要求を、コンピュータシステムの入力デバイスから受け付けてもよいし、コンピュータシステムにインストールされた他のアプリケーションプログラムまたはOSに従って動作するCPUから受け付けてもよい。なお、OSは、コンピュータシステムにインストールされたソフトウェアである。
Here, the
制御部2は、選択部1が要求したアプリケーションプログラムを構成するプロセスの起動および実行をOSに従って動作するCPUに対して要求し、同時に管理部51に対して空きメモリの確保を要求する。
The
アプリケーション監視部(監視部と略す)3は、選択部1が選択したアプリケーションプログラムの識別情報に対応付けられた後続アプリケーションプログラムの識別情報を起動手順記憶部21から選択する。なお、選択部1が選択したアプリケーションプログラムの識別情報に、複数の後続アプリケーションプログラムの識別情報が対応付けられている場合、監視部3は、その複数の後続アプリケーションプログラムの識別情報を選択する。
The application monitoring unit (abbreviated as monitoring unit) 3 selects the identification information of the subsequent application program associated with the identification information of the application program selected by the
メモリ推測部(推測部と略す)4は、監視部3が選択した後続アプリケーションプログラムの識別情報と対応付けられた必要なメモリ量を選択する。なお、監視部3が複数の後続アプリケーションの識別情報を選択した場合、推測部4は、その複数の後続アプリケーションプログラムの識別情報のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量を需要記憶部22から選択する。
The memory estimation unit (abbreviated as estimation unit) 4 selects a necessary memory amount associated with the identification information of the subsequent application program selected by the
また、推測部4は、現在のメモリ30の空き領域を調べ、その空き領域がその必要なメモリ量より大きいか否かを判定する。
Further, the
管理部51は、メモリ30の空き領域の確保および解放など、メモリ30を管理する。
The
管理部51は、推測部4にて空き領域が必要なメモリ量より小さいと判定された場合、その空き領域が必要なメモリ量になるまでメモリ30の空き領域を確保する。
When the
管理部51では、スワップ処理部511は、空き領域がその必要なメモリ量になるまで、メモリ30内のデータをスワップデバイス(不図示)にスワップアウトする。このとき、管理部51は、スワップ処理部511がスワップアウトする前に、メモリ30内の不要である可能性が高い不要候補メモリ領域の解放を試みてもよい。この場合、不要候補メモリ領域の解放で、必要なメモリ量が確保されなかった場合に、スワップアウトが実行される。
In the
スワップ処理部511は、メモリ30内の不要である可能性が高い不要候補メモリ領域内のデータをスワップアウトする。スワップ処理部511による不要候補メモリ領域の選択方法は、例えば、一定期間内でアクセス回数が少ないメモリ領域から順に、そのメモリ領域を不要候補メモリ領域として選択する方法などである。なお、不要候補メモリ領域の選択方法は、この方法に限らず適宜変更可能である。また、この選択方法は、当業者にとって自明なため、詳細な説明は省略する。
The
次に動作を説明する。 Next, the operation will be described.
図3は、メモリ管理装置の動作を説明するためのフローチャートである。 FIG. 3 is a flowchart for explaining the operation of the memory management device.
ステップA1では、選択部1は、起動要求を受け付け、その起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を特定記憶部23から選択する。選択部1は、その識別情報を制御部2および監視部3に送る。
In step A <b> 1, the
制御部2は、その識別情報を受け付けると、その識別情報にて特定されるアプリケーションプログラムを構成するプロセスの起動および実行を行なう旨のプロセス実行要求をOSに従って動作するCPUに送る。
Upon receipt of the identification information,
監視部3は、その識別情報を受け付けると、ステップA2を実行する。
When the
ステップA2では、監視部3は、起動が要求されたアプリケーションプログラムの識別情報と対応付けられた後続アプリケーションプログラムの識別情報を起動手順記憶部21から選択し、その後続アプリケーションプログラムの識別情報を推測部4に送る。なお、監視部3は、そのアプリケーションプログラムの識別情報に、複数の後続アプリケーションプログラムの識別情報が対応付けられている場合、その複数の後続アプリケーションプログラムの識別情報を起動手順記憶部21から選択し、その選択した複数の後続アプリケーションプログラムの識別情報を推測部4に送る。
In step A2, the
推測部4は、その後続アプリケーションプログラムの識別情報を受け付けると、ステップA3を実行する。
When the
ステップA3では、推測部4は、その後続アプリケーションプログラムの識別情報と対応付けられた必要なメモリ量を需要記憶部22から選択する。なお、推測部4は、監視部3から複数の後続アプリケーションの識別情報を受け付けた場合、その複数の後続アプリケーションプログラムの識別情報のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量を需要記憶部22から選択する。推測部4は、必要なメモリ量を選択すると、ステップA4を実行する。
In step A <b> 3, the
ステップA4では、推測部4は、メモリ30の空き領域を調べ、その空き領域がその必要なメモリ量より大きいか否かを判定する。推測部4は、その空き領域がその必要なメモリ領域より小さいと、ステップA5を実行し、その空き領域がその必要なメモリ量より大きいと、動作を終了する。
In step A4, the
ステップA5では、推測部4は、空き領域を確保する旨の確保要求を生成し、その確保要求を管理部51に送る。なお、確保要求は、空き領域および必要なメモリ量を含む。
In step A <b> 5, the
管理部51は、確保要求を受け付けると、スワップ処理部511にスワップアウトの要求を送る。なお、スワップアウトの要求は、空き領域および必要なメモリ量を含む。
Upon receipt of the securing request, the
このとき、管理部51は、スワップアウトの要求を送る前に、メモリ30内の不要候補メモリ領域の解放を試みてもよい。この場合、不要候補メモリ領域の解放で、必要なメモリ量が確保されなかった場合に、スワップアウトの要求が送られる。
At this time, the
スワップ処理部511は、そのスワップアウトの要求を受け付けると、例えば、その必要なメモリ量と空き領域との差を確保量として求め、その確保量だけの不要候補メモリ領域を選択することで、その選択した不要候補メモリ領域内のデータをスワップデバイスにスワップアウトする。
When the
また、スワップ処理部511は、不要候補メモリ領域の不要を示す度合いの高い順に、例えば、アクセス回数が少ない順に、スワップアウトし、その結果、必要なメモリ量が確保されていれば、スワップアウトを終了するなどしてもよい。なお、スワップアウトの方法は、これらの方法に限らず適宜変更可能である。
In addition, the
スワップ処理部511は、不要候補メモリ領域内のデータをスワップアウトすると、スワップアウトが完了した旨を推測部4に送る。推測部4は、その旨を受け付けると、ステップA4を実行する。これは、実際に空き領域が必要量より大きくなったか否かを確認するためである。
When the
次に効果を説明する。 Next, the effect will be described.
本実施形態によれば、起動手順記憶部21は、あるアプリケーションプログラムの識別情報を、そのアプリケーションプログラムから起動される後続アプリケーションプログラムの識別情報と対応付けて記憶する。需要記憶部22は、アプリケーションプログラムの識別情報を、そのアプリケーションプログラムの起動に必要なメモリ量と対応付けて記憶する。特定記憶部23は、アプリケーションプログラムを、そのアプリケーションプログラムの識別情報と対応付けて記憶する。
According to the present embodiment, the activation
選択部1は、起動要求を受け付け、その起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を特定記憶部23から選択する。監視部3は、選択部1が選択した識別情報と対応付けられた後続アプリケーションプログラムの識別情報を起動手順記憶部21から選択する。推測部4は、監視部3が選択した識別情報と対応付けられた必要なメモリ量を需要記憶部22から選択する。推測部4は、空き領域がその選択した必要なメモリ量より大きいか否かを判定する。推測部4がその空き領域がその必要なメモリ量より小さいと判定すると、管理部51は、その空き領域がその必要なメモリ量になるまでメモリ30の領域を確保する。
The
このため、後続アプリケーションプログラムの起動が要求される前に、その後続アプリケーションプログラムの起動に必要なメモリ量を確保することが可能になる。したがって、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 For this reason, it is possible to secure an amount of memory necessary for starting the subsequent application program before the start of the subsequent application program is requested. Therefore, the application program can be activated quickly.
また、本実施形態では、管理部51は、その空き領域がその必要なメモリ量になるまで、メモリ30内のデータをスワップアウトすることで、メモリ30の領域を確保する。
Further, in the present embodiment, the
このため、容易にメモリの空き領域が確保され、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 For this reason, an empty area of the memory is easily secured, and the application program can be started up quickly.
次に、第二の実施形態のメモリ管理装置について説明する。 Next, a memory management device according to the second embodiment will be described.
図4は、第二の実施形態のメモリ管理装置の構成を示したブロック図である。以下では、図1と異なる構成および動作について主に説明する。なお、図4において、図1と同じものには、同じ符号が付してある。 FIG. 4 is a block diagram illustrating a configuration of the memory management device according to the second embodiment. In the following, the configuration and operation different from those in FIG. 1 will be mainly described. In FIG. 4, the same components as those in FIG.
図4において、管理部51は、スワップ処理部511の代わりにメモリ整理回収部512を含む。メモリ管理装置の他の構成は、図1で示した構成と同じである。
In FIG. 4, the
一般的に、メモリについて領域の確保および解放が繰り返されると、メモリ30内のデータが断片化し、メモリ30の空き領域も断片化する。小さな空き領域の断片が増加すると、アプリケーションプログラムの起動に必要なメモリ量の、メモリアドレスが連続した空き領域を確保することができない場合がある。この場合、アプリケーションプログラムの起動に時間がかかる可能性がある。
In general, when the securing and releasing of the area of the memory are repeated, the data in the
推測部4は、メモリ30においてメモリアドレスが連続した空き領域を調べ、その空き領域が需要記憶部22から選択した必要なメモリ量より大きいか否かを判定する。
The
管理部51は、推測部4にてメモリアドレスが連続した空き領域が必要なメモリ量より小さいと判定されると、メモリアドレスが連続した空き領域がその必要なメモリ量になるまで、メモリ30内の断片化したデータが連続するように再配置し、メモリ30の領域を確保する。
If it is determined by the
具体的には、管理部51のメモリ整理回収部(整理部と略す)512は、そのメモリアドレスが連続した空き領域がその必要なメモリ量になるまで、メモリ30をデフラグする。これにより、アプリケーションプログラムの起動に必要なメモリ量の、メモリアドレスが連続した領域を確保することができる。
Specifically, the memory organizing / collecting unit (abbreviated as organizing unit) 512 of the managing
図5は、整理部512がデフラグする前とデフラグした後のメモリ領域の一例を示した模式図である。図5において、「空」は、空き領域を示し、「使用中」は、使用領域を示す。図5において、デフラグされる前(処理前)では断面化されていた空き領域が、デフラグされた後(処理後)では連続化されている。
FIG. 5 is a schematic diagram showing an example of a memory area before and after the
例えば、「4MB」の連続した空き領域が必要な場合、処理前では、「4MB」の連続した空き領域がないとき、整理部512は、メモリアドレスが連続した空き領域が「4MB」になるまでメモリ30をデフラグする。
For example, if a continuous free area of “4 MB” is required, and there is no continuous free area of “4 MB” before processing, the
次に動作を説明する。 Next, the operation will be described.
図6は、第二の実施形態のメモリ管理装置の動作を説明するためのフローチャートである。図6において、図3で説明した処理と同じ処理には、同じ符号が付してある。 FIG. 6 is a flowchart for explaining the operation of the memory management device according to the second embodiment. In FIG. 6, the same processes as those described in FIG.
ステップA3で推測部4は、必要なメモリ量を選択すると、ステップA6を実行する。
In step A3, when the
ステップA6では、推測部4は、メモリアドレスが連続したメモリ30の空き領域を調べ、その空き領域がその必要なメモリ量より大きいか否かを判定する。推測部4は、その空き領域がその必要なメモリ量より小さいと、ステップA7を実行し、その空き領域がその必要なメモリ量より大きいと、動作を終了する。
In step A6, the
ステップA7では、推測部4は、確保要求を生成し、その確保要求を管理部51に送る。
In step A <b> 7, the
管理部51は、その確保要求を受け付けると、デフラグの要求を整理部512に送る。なお、デフラグの要求は、空き領域および必要なメモリ量を含む。
When accepting the securing request, the
このとき、管理部51が、デフラグの要求を送る前に、メモリ30内の不要候補メモリ領域の解放を試みてもよい。この場合、不要候補メモリ領域の解放で、必要なメモリ量が確保されなかった場合に、デフラグの要求を送る。
At this time, the
整理部512は、そのデフラグの要求を受け付けると、メモリアドレスが連続したメモリ30の空き領域が必要なメモリ量になるまで、メモリ30をデフラグする。整理部512は、メモリ30をデフラグすると、デフラグが完了した旨を推測部4に通知する。推測部4は、その旨を受け付けると、ステップA6を実行する。
When the
次に効果を説明する。 Next, the effect will be described.
本実施形態によれば、推測部4は、メモリ30においてアドレスが連続した空き領域を調べ、その空き領域が必要なメモリ量より大きいか否かを判定する。管理部51は、その空き領域がその必要なメモリ量より小さいと、メモリアドレスが連続したメモリの空き領域が必要なメモリ量になるまで、メモリ30をデフラグする。
According to the present embodiment, the
この場合、アドレスが連続した空き領域が必要なメモリ量になるまで、メモリ30がデフラグされる。
In this case, the
このため、アドレスが連続した空き領域が必要な場合に、スワップデバイスがなくても、そのアドレスが連続したメモリの空き領域が確保されるので、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 For this reason, when an empty area with consecutive addresses is required, an empty area of a memory with consecutive addresses is secured even if there is no swap device, so that the application program can be started up quickly. .
次に、第三の実施形態のメモリ管理装置について説明する。 Next, a memory management device according to the third embodiment will be described.
図7は、第三の実施形態のメモリ管理装置の構成を示したブロック図である。以下、主に図1と異なる構成について説明する。なお、図7において、図1と同じものには同じ符号が付してある。 FIG. 7 is a block diagram showing the configuration of the memory management device according to the third embodiment. Hereinafter, a configuration different from FIG. 1 will be mainly described. In FIG. 7, the same components as those in FIG.
図7において、情報処理部10は、図1で示した構成に加えて、アプリケーションプログラム実行部6と、プロセス監視部7とを含む。記憶部20は、図1で示した構成に加えて、プロセス起動手順記憶部24と、プロセス動作パターン記憶部25と、プロセスメモリ需要記憶部26とを含む。
7, the information processing unit 10 includes an application
プロセス起動手順記憶部24は、プロセスの起動手順を記憶する。
The process activation
プロセスの起動手順は、あるプロセスから別のプロセスを起動する際のプロセスを対応付ける情報である。このとき、あるプロセスから別のプロセスへの対応付けが複数あってもよい。なお、これらの対応付けは、各プロセスの識別情報を用いて設定される。以下、あるプロセスから起動される別のプロセスを後続プロセスと称する。 The process activation procedure is information for associating a process when another process is activated from a certain process. At this time, there may be a plurality of associations from one process to another. These associations are set using the identification information of each process. Hereinafter, another process started from a certain process is referred to as a subsequent process.
プロセス動作パターン記憶部(動作記憶部と略す)25は、システムコールの生成パターンとプロセスとを対応付けるパターン情報を記憶する。パターン情報は、具体的には、アプリケーションプログラムのプロセスを起動するためのシステムコールの生成パターンと、そのプロセスの識別情報と、をアプリケーションプログラムの識別情報ごとに対応付ける。生成パターンは、例えば、システムコールが生成される順番を示す。 The process operation pattern storage unit (abbreviated as operation storage unit) 25 stores pattern information that associates a generation pattern of a system call with a process. Specifically, the pattern information associates a generation pattern of a system call for starting a process of an application program with the identification information of the process for each identification information of the application program. The generation pattern indicates, for example, the order in which system calls are generated.
プロセスメモリ需要記憶部(プロセス需要記憶部と略す)26は、プロセスごとに(プロセスの識別情報ごとに)、プロセスの動作に必要なメモリ量を対応付ける需要情報として記憶されている。 The process memory demand storage unit (abbreviated as process demand storage unit) 26 is stored as demand information for each process (for each process identification information) that associates an amount of memory necessary for the operation of the process.
このプロセスの動作に必要なメモリ量は、過去に起動されたプロセスの動作に使用されたメモリ量から求められてもよいし、アプリケーションプログラムの設計者または利用者にて予め設定されてもよい。 The amount of memory necessary for the operation of this process may be obtained from the amount of memory used for the operation of the process activated in the past, or may be set in advance by the designer or user of the application program.
アプリケーションプログラム実行部(実行部と略す)6は、コンピュータシステムにインストールされたアプリケーションプログラムが実行されることで実現される。 The application program execution unit (abbreviated as execution unit) 6 is realized by executing an application program installed in a computer system.
実行部6は、ある機能を実行する旨の実行要求を受け付けると、その実行要求にて要求された機能に応じたシステムコールを生成する。ここで、実行部6は、実行要求を、コンピュータシステムの入力デバイスから受け付けてもよいし、コンピュータシステムにインストールされた他のアプリケーションプログラムまたはOSに従って動作するCPUから受け付けてもよい。
When the
プロセス監視部7は、実行部6が生成したシステムコールの生成パターンを解析する。例えば、プロセス監視部7は、実行部6が生成したシステムコールの順序を解析する。
The
プロセス監視部7は、選択部1が選択したアプリケーションプログラムの識別情報と対応付けられ、かつ、その解析したシステムコールの生成パターンと対応付けられた、プロセスの識別情報を動作記憶部25から選択する。
The
プロセス監視部7は、プロセスの識別情報を選択すると、そのプロセスの識別情報と対応付けられた後続プロセスの識別情報を、プロセス起動手順記憶部24から選択する。なお、プロセス監視部7は、動作記憶部25から選択したプロセスの識別情報に、複数の後続プロセスの識別情報が対応付けられている場合、その複数の後続プロセスの識別情報を選択する。
When selecting the process identification information, the
推測部4は、プロセス監視部7が選択した後続プロセスの識別情報と対応付けられた必要なメモリ量をプロセス需要記憶部26から選択する。なお、プロセス監視部7が複数の後続プロセスの識別情報を選択した場合、推測部4は、その複数の後続プロセスの識別情報のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量をプロセス需要記憶部26から選択する。
The
次に動作を説明する。 Next, the operation will be described.
先ず、第一の実施形態(図3)で説明した後続アプリケーションプログラムの起動に必要なメモリ量の空き領域を確保する動作の変更点を説明する。 First, a description will be given of a change in the operation of securing a free area having a memory amount necessary for starting the subsequent application program described in the first embodiment (FIG. 3).
図3のステップA2では、監視部3は、アプリケーションプログラムの識別情報を推測部4に送っていたが、本実施の形態では、そのアプリケーションプログラムの識別情報をプロセス監視部7に送る。
In step A2 in FIG. 3, the
プロセス監視部7は、そのアプリケーションプログラムの識別情報を受け付けると、そのアプリケーションプログラムの識別情報を推測部4に送る。このとき、プロセス監視部7は、そのアプリケーションプログラムの識別情報を保持する。
When the
推測部4は、その後続アプリケーションプログラムの識別情報を受け付けると、ステップA3を実行する。以降、図3のステップA3からA5までが実行される。
When the
次に、後続プロセスの空き領域を確保する動作を説明する。 Next, an operation for securing a free area in the subsequent process will be described.
図8は、後続プロセスの動作に必要なメモリ量の空き領域を確保する動作を説明するためのフローチャートである。なお、図8において、図3と同じ処理には同じ符号が付してある。 FIG. 8 is a flowchart for explaining an operation of securing a free area having a memory amount necessary for the operation of the subsequent process. In FIG. 8, the same processes as those in FIG. 3 are denoted by the same reference numerals.
実行部6は、実行要求を受け付けると、ステップC1を実行する。
The
ステップC1では、実行部6は、その実行要求にて要求された機能に応じたシステムコールを生成し、そのシステムコールをプロセス監視部7と、OSに従って動作するCPUに送る。
In Step C1, the
そのCPUは、そのシステムコールを受け付けると、そのシステムコールに応じた処理を行う。 When the CPU receives the system call, the CPU performs processing according to the system call.
プロセス監視部7は、そのシステムコールを受け付けると、ステップC2を実行する。
When receiving the system call, the
ステップC2では、プロセス監視部7は、そのシステムコールの生成パターンを解析する。プロセス監視部7は、生成パターンを解析すると、ステップC3を実行する。
In step C2, the
ステップC3では、プロセス監視部7は、保持しているアプリケーションプログラムの識別情報と対応付けられ、かつ、その解析したシステムコールの生成パターンと対応付けられた、プロセスの識別情報を動作記憶部25から選択する。プロセス監視部7は、プロセスの識別情報を選択すると、ステップC4を実行する。
In step C3, the
ステップC4では、プロセス監視部7は、そのプロセスの識別情報と対応付けられた後続プロセスの識別情報をプロセス起動手順記憶部24から選択し、その選択した後続プロセスの識別情報を推測部4に送る。
In step C4, the
なお、プロセス監視部7は、そのプロセスの識別情報に、複数の後続プロセスの識別情報が対応付けられている場合、その複数の後続プロセスの識別情報を選択し、その選択した複数の後続プロセスの識別情報を推定部4に送る。
The
推測部4は、その後続プロセスの識別情報を受け付けると、ステップC5を実行する。
When the
ステップC5では、推測部4は、その後続プロセスの識別情報と対応付けられた必要なメモリ量をプロセス需要記憶部26から選択する。なお、推定部4は、プロセス監視部7から複数の後続プロセスの識別情報を受け付けた場合、その複数の後続プロセスのそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量をプロセス需要記憶部26から選択する。推測部4は、必要なメモリ量を選択すると、ステップA4を実行する。その後、ステップA4およびA5が実行される。
In step C <b> 5, the
次に効果を説明する。 Next, the effect will be described.
本実施形態によれば、動作記憶部25は、プロセスを生成するためのシステムコールの生成パターンを、そのプロセスの識別情報と対応付けて記憶する。プロセス起動手順記憶部24は、プロセスの識別情報を、そのプロセスから起動される後続プロセスの識別情報と対応付けて記憶する。プロセス需要記憶部26は、その後続プロセスの識別情報を、その後続プロセスの動作に必要なメモリ量と対応付けて記憶する。
According to the present embodiment, the
実行部6は、システムコールを生成する。プロセス監視部7は、実行部6が生成したシステムコールの生成パターンを解析し、その解析した生成パターンと対応付けられたプロセスの識別情報を動作記憶部25から選択する。推測部4は、プロセス監視部7が選択したプロセスの識別情報と対応付けられた必要なメモリ量をプロセス需要記憶部26から選択する。推測部4は、空き領域がその選択した必要なメモリ量より大きいか否かを判定する。管理部51は、推測部4にてその空き領域がその必要なメモリ量になるまでメモリ30の領域を確保する。
The
このため、後続プロセスが生成される前に、その後続プロセスの動作に必要なメモリ量を確保することが可能になる。よって、アプリケーションプログラムのプロセスの起動のときに、そのアプリケーションプログラムのプロセスの動作に必要な空きメモリ領域が予め確保されるので、容易にメモリの空き領域が確保され、後続プロセスの生成を迅速に行うことが可能となる。したがって、アプリケーションプログラムの起動を迅速に行なうことが可能になる。 For this reason, before the subsequent process is generated, it is possible to secure an amount of memory necessary for the operation of the subsequent process. Therefore, when an application program process is started, a free memory area necessary for the operation of the application program process is secured in advance, so that a free memory area is easily secured, and subsequent processes are generated quickly. It becomes possible. Therefore, the application program can be activated quickly.
次に、第四の実施形態のメモリ管理装置について説明する。 Next, a memory management device according to a fourth embodiment will be described.
図9は、第四の実施形態のメモリ管理装置の構成を示したブロック図である。以下、主に図1および図7と異なる構成について説明する。なお、図9において、図7と同じものには同じ符号が付してある。 FIG. 9 is a block diagram showing the configuration of the memory management device according to the fourth embodiment. Hereinafter, a configuration different from FIGS. 1 and 7 will be mainly described. In FIG. 9, the same components as those in FIG.
図9において、情報処理部10は、図7で示した構成と同じ構成を有する。記憶部20は、図7で示した構成から動作記憶部25を除いた構成を有する。
In FIG. 9, the information processing unit 10 has the same configuration as that shown in FIG. The storage unit 20 has a configuration in which the
実行部6は、コンピュータシステムの入力デバイスから実行要求を受け付けると、その実行要求にて要求された機能に応じたプロセスの識別情報を、プロセス監視部7に送る。
When the
プロセス監視部7は、実行部6からプロセスの識別情報を受け付けると、そのプロセスの識別情報と対応付けられた後続プロセスの識別情報をプロセス起動手順記憶部24から選択する。
When receiving the process identification information from the
次に動作を説明する。 Next, the operation will be described.
図10は、第四の実施形態のメモリ管理装置の動作を説明するためのフローチャートである。なお、図10において、図8と同じ処理には同じ符号が付してある。 FIG. 10 is a flowchart for explaining the operation of the memory management device according to the fourth embodiment. In FIG. 10, the same processes as those in FIG. 8 are denoted by the same reference numerals.
実行部6は、実行要求を受け付けると、ステップC7を実行する。
The
ステップC7では、実行部6は、実行要求にて要求された機能に応じたプロセスの識別情報をプロセス監視部7に送る。
In step C <b> 7, the
また、プロセス監視部7は、そのプロセスの識別情報を受け付けると、ステップC4を実行する。その後、ステップC4、C5、A4およびA5が実行される。
When the
次に効果を説明する。 Next, the effect will be described.
実行部6は、機能を実行する旨の実行要求を受け付けると、その機能に応じたプロセスの識別情報をプロセス監視部7に送る。プロセス監視部7は、その送られたプロセスの識別情報と対応付けられた後続プロセスの識別情報を、プロセス起動手順記憶部24から選択する。推測部4は、プロセス監視部7が選択したプロセスの識別情報と対応付けられた必要なメモリ量をプロセス需要記憶部26から選択する。
When receiving an execution request for executing a function, the
この場合、実行を要求された機能に応じたプロセスの識別情報が実行部6から送られる。また、そのプロセスの識別情報と対応付けられた後続プロセスの識別情報が選択される。
In this case, process identification information corresponding to the function requested to be executed is sent from the
このため、システムコールの生成パターンが解析されなくても、アプリケーションプログラムの起動のときに確保するメモリの領域を軽減することが可能になる。したがって、アプリケーションプログラムの起動をさらに迅速に行なうことが可能になる。 For this reason, even if the system call generation pattern is not analyzed, it is possible to reduce the memory area secured when the application program is activated. Therefore, the application program can be activated more quickly.
第一の実施例として、第一の実施形態のメモリ管理装置を組み込んだコンピュータシステムについて説明する。以下、コンピュータシステムを携帯電話機として説明するが、コンピュータシステムは、携帯電話機に限らず適宜変更可能である。 As a first example, a computer system incorporating the memory management device of the first embodiment will be described. Hereinafter, the computer system will be described as a mobile phone, but the computer system is not limited to the mobile phone and can be changed as appropriate.
図11は、第一の実施例の携帯電話機の構成の一例を示したブロック図である。 FIG. 11 is a block diagram showing an example of the configuration of the mobile phone according to the first embodiment.
図11において、携帯電話機は、通信処理部41と、ディスプレイ42と、キーボード43と、ハードディスクドライブ(HDDと略す)44と、メモリ45と、CPU46とを含む。
In FIG. 11, the mobile phone includes a
通信処理部41は、電話通信など無線通信を行なう。ディスプレイ42は、種々の情報を表示する。キーボード43は、利用者から種々の情報を受け付ける。例えば、キーボード43は、利用者から起動要求を受け付ける。
The
HDD44は、種々の情報を記憶する。また、HDD44は、スワップアウトされたデータを記憶するスワップデバイスとして用いられる。
The
メモリ45およびCPU46は、メモリ管理装置を構成する。メモリ45は、図1で示した記憶部20に対応し、CPU46は、図1で示した情報処理部10に対応する。
The
図12は、メモリ45およびCPU46の構成の一例を示したブロック図である。
FIG. 12 is a block diagram showing an example of the configuration of the
メモリ45は、CPU46にて読み取り可能な記録媒体であり、CPU46の動作を規定するプログラムを記録する。
The
また、メモリ45は、起動手順記憶部1021と、需要記憶部1022と、特定記憶部1023を含む。
The
起動手順記憶部1021、需要記憶部1022および特定記憶部1023のそれぞれは、図1で示した起動手順記憶部21、需要記憶部22および特定記憶部23のそれぞれと同等な機能を有するため、説明は省略する。
Each of the startup
なお、起動手順、需要情報および特定情報は、HDD44に記憶され、携帯電話機が立ち上がると、CPU46は、その起動手順、需要情報および特定情報をHDD44から取得し、その起動手順を起動手順記憶部1021に記憶し、その需要情報を需要記憶部1022に記憶し、その特定情報を特定記憶部1023に記憶するものとする。また、需要情報の各アプリケーションプログラムの起動に必要なメモリ量は、アプリケーションプログラムの開発者が定め、そのアプリケーションプログラムが携帯電話機に導入される際に、識別情報と対応付けられてHDD44に記憶される。
The startup procedure, demand information, and specific information are stored in the
CPU46は、メモリ45に記録されたプログラムを読み取り、読み取ったプログラムを実行して、図1の情報処理部10と同等な機能を実現する。具体的には、CPU46は、アプリケーションランチャー部1001と、制御部1002と、監視部1003と、推測部1004と、OS実行部1005とを実現する。
The
アプリケーションランチャー部(ランチャー部と略す)1001、制御部1002、監視部1003および推測部1004は、ミドルウェアが実行されることで実現されることが望ましい。また、ランチャー部1001、制御部1002、監視部1003および推測部1004は、ユーザモードで動作する。
The application launcher unit (abbreviated as launcher unit) 1001, the
なお、ランチャー部1001、制御部1002、監視部1003および推測部1004のそれぞれは、図1で示した選択部1、制御部2、監視部3および推測部4のそれぞれと同等な機能を有するため、詳細な説明は省略する。
Note that each of the
OS実行部1005は、OSが実行されることで実現される。OSは、Linux系統またはUnix系統であることが望ましいが、Linux系統またはUnix系統に限らず適宜変更可能である。
The
OS実行部1005は、メモリマネージャ1051と、制御モジュール1052とを含む。メモリマネージャ1051は、スワップ処理部1511を含む。
The
制御モジュール1052は、推測部1004から確保要求を受け付け、その確保要求をメモリマネージャ1051にて認識可能な形式に変換する。制御モジュール1052は、その形式を変換した確保要求をメモリマネージャ1051に送る。
The
メモリマネージャ1051およびスワップ処理部1511のそれぞれは、図1で示した管理部51およびスワップ処理部511のそれぞれと同等な機能を有するため、説明は省略する。
Since each of the
次に携帯電話機のアプリケーションプルグラムの起動手順の例を説明する
図13は、携帯電話機のアプリケーションプルグラムの起動手順の一例を説明するための説明図である。図13では、アプリケーションプログラムの起動手順を示すツリーが示されている。ノード601から608までは、アプリケーションプログラムを示す。なお、ノード601から608までのそれぞれの下部には、そのノードが示すアプリケーションプログラムの起動に必要なメモリ量が示されている。
Next, an example of a procedure for starting an application program for a mobile phone will be described. FIG. 13 is an explanatory diagram for explaining an example of a procedure for starting an application program for a mobile phone. FIG. 13 shows a tree showing the startup procedure of the application program.
図14は、アプリケーションプログラムと、そのアプリケーションプログラムの起動に必要なメモリ量の関係の一例を示した説明図である。 FIG. 14 is an explanatory diagram showing an example of the relationship between an application program and the amount of memory required to start the application program.
図14では、アプリケーション名と、IDと、消費メモリ量とが示されている。アプリケーション名は、アプリケーションプログラムの名前を示す。IDは、そのアプリケーションプログラムの識別情報を示す。消費メモリ量は、そのアプリケーションプログラムの起動に必要なメモリ量を示す。 FIG. 14 shows the application name, ID, and consumed memory amount. The application name indicates the name of the application program. ID indicates identification information of the application program. The consumed memory amount indicates the amount of memory required for starting the application program.
OS実行部1005は、携帯電話機が立ち上がると、「メニュー1」を起動する旨の起動要求をランチャー部1001に送るように設定されているものとする。
It is assumed that the
ランチャー部1001は、その起動要求を受け付けると、その起動要求にて要求されたアプリケーションプログラムと対応付けられたアプリケーションプログラムの識別情報「ID1」を特定記憶部1023から選択する。
Upon receiving the activation request, the
監視部1003は、その選択したアプリケーションプログラムの識別情報「ID1」と対応付けられた、「メール」の識別情報「ID2」と、「メニュー2」の識別情報「ID3」と、「ブラウザ」の識別情報「ID4」とを選択する。
The
推測部1004は、その選択された識別情報「ID2」「ID3」および「ID4」のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量を需要記憶部1022から選択する。この場合、「ブラウザ」の起動に必要なメモリ量「4MB」が最も大きいので、推測部1004は、必要なメモリ量「4MB」を選択する。
The
メモリマネージャ1051は、その必要なメモリ量「4MB」になるまで、メモリ45の空き領域を確保する。
The
その後、利用者がキーボード43を用いて「メール」を選択した場合、キーボード43は、「メール」を起動する旨の起動要求をランチャー部1001に送る。
Thereafter, when the user selects “mail” using the
ランチャー部1001は、その起動要求を受け付けると、その起動要求にて要求された「メール」と対応付けられた識別情報「ID2」を特定記憶部1023から選択する。
When the
この場合、監視部1003は、「メール」から起動される後続アプリケーションプログラムがないと判定して、動作を終了する。
In this case, the
また、利用者がキーボード43を用いて「メニュー2」を選択した場合、キーボード43は、「メニュー2」を起動する旨の起動要求をランチャー部1001に送る。
When the user selects “
ランチャー部1001は、その起動要求を受け付けると、その起動要求にて要求された「メニュー2」と対応付けられた識別情報「ID3」を特定記憶部1023から選択する。
Upon receiving the activation request, the
監視部1003は、その識別情報「ID3」と対応付けられた、「メニュー3」の識別情報「ID5」と、「ゲーム」の識別情報「ID6」とを起動手順記憶部1021から選択する。
The
推測部1004は、その識別情報「ID5」および「ID6」のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量を需要記憶部1022から選択する。この場合、「ゲーム」の起動に必要なメモリ量「10MB」が最も大きいので、推測部1004は、必要なメモリ量「10MB」を選択する。
The
メモリマネージャ1051は、その必要なメモリ量「10MB」になるまで、メモリ45の空き領域を確保する。
The
その後、利用者がキーボード43を用いて「メニュー3」を選択した場合、キーボード43は、「メニュー3」を起動する旨の起動要求をランチャー部1001に送る。
Thereafter, when the user selects “
ランチャー部1001は、その起動要求にて要求された「メニュー3」と対応付けられた識別情報「ID5」を特定記憶部1023から選択する。
The
監視部1003は、その識別情報「ID5」と対応付けられた、「音声メモ」の識別情報「ID7」と、「音楽再生」の識別情報「ID8」とを起動手順記憶部1021から選択する。
The
推測部1004は、その識別情報「ID7」および「ID8」のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量を需要記憶部1022から選択する。この場合、「音楽再生」の起動に必要なメモリ量「4MB」が最も大きいので、推測部1004は、必要なメモリ量「4MB」を選択する。
The
次に動作を説明する。 Next, the operation will be described.
図15は、携帯電話機の動作の一例を説明するためにフローチャートである。以下、「メニュー1」が起動された状態で、利用者がアプリケーションプログラム「ブラウザ」を選択した場合を例に説明する。
FIG. 15 is a flowchart for explaining an example of the operation of the mobile phone. Hereinafter, a case where the user selects the application program “browser” while “
ステップB1では、ランチャー部1001は、「ブラウザ」を起動する旨の起動要求を受け付け、その「ブラウザ」と対応付けられた識別情報「ID4」を特定記憶部1023から選択する。選択部1は、その識別情報「ID4」を制御部1002および監視部1003に送る。
In step B <b> 1, the
制御部1002は、その識別情報「ID4」を受け付けると、その識別情報「ID4」にて特定される「ブラウザ」を構成するプロセスの起動および実行を行なう旨のプロセス実行要求を生成し、そのプロセス実行要求をOS実行部1005に送る。
Upon receipt of the identification information “ID4”, the
なお、制御部1002は、「ブラウザ」の識別情報「ID4」を受け付ける前に受け付けた「メニュー1」の識別情報「ID1」を保持するものとする。これは、「ブラウザ」が終了された場合に「メニュー1」が起動されるように、制御部1002が、「メニュー1」を構成するプロセスの起動および実行を行なう旨のプロセス実行要求をOS実行部1005に送るためである。
Note that the
OS実行部1005は、そのプロセス実行要求を受け付けると、そのプロセス実行要求に応じてプロセスの起動および実行を行なう。
When the
監視部1003は、その識別情報を受け付けると、ステップB2を実行する。
Upon receiving the identification information,
ステップB2では、監視部1003は、その「ブラウザ」の識別情報「ID4」と対応付けられた「音楽再生」の識別情報「ID8」を起動手順記憶部1021から選択し、その後続アプリケーションプログラムの識別情報「ID8」を推測部1004に送る。推測部1004は、その後続アプリケーションプログラムの識別情報「ID8」を受け付けると、ステップB3を実行する。
In step B2, the
ステップB3では、推測部1004は、その後続アプリケーションプログラムの識別情報「ID8」と対応付けられた必要なメモリ量「4MB」を、需要記憶部1022から選択する。
In step B <b> 3, the
ステップB4では、推測部1004は、メモリ45の空き領域を調べる。例えば、推測部1004は、「/procファイルシステム」を用いて、メモリ45の空き領域を調べる。
In step B <b> 4, the
推測部1004は、メモリ45の空き領域を調べると、その空き領域がその必要なメモリ量より大きいか否かを判定する。推測部1004は、その空き領域がその必要なメモリ量より小さいと、ステップB5を実行し、その空き領域がその必要なメモリ量より大きいと、動作を終了する。
When the
ステップB5では、推測部1004は、空き領域を確保する旨の確保要求を生成し、その確保要求を制御モジュール1052に送る。
In step B <b> 5, the
制御モジュール1052は、その確保要求を受け付け、その確保要求をメモリマネージャ1051にて認識可能な形式に変換する。制御モジュール1052は、その形式を変換した確保要求をメモリマネージャ1051に送る。
The
メモリマネージャ1051は、その確保要求を受け付けると、スワップ処理部1511にスワップの要求を送る。
When accepting the reservation request, the
このとき、メモリマネージャ1051は、スワップアウトの要求を送る前に、メモリ45内の不要候補メモリ領域の解放を試みてもよい。この場合、メモリマネージャ1051は、不要候補メモリ領域の解放で、必要なメモリ量が確保されなかった場合に、スワップアウトの要求を送る。
At this time, the
スワップ処理部1511は、そのスワップアウトの要求を受け付けると、必要なメモリ量が確保されるまで、メモリ45の不要候補メモリ領域内のデータをHDD44にスワップアウトする。
When the
スワップ処理部1511は、不要候補データをスワップアウトすると、スワップアウトが完了した旨を推測部1004に送る。推測部1004は、その旨を受け付けると、ステップB4を実行する。
After swapping out unnecessary candidate data, the
次に、第二の実施例として、第二の実施形態のメモリ管理装置を組み込んだ携帯電話機を説明する。 Next, a mobile phone incorporating the memory management device of the second embodiment will be described as a second example.
図16は、第二の実施例の携帯電話機の構成の一例を示したブロック図である。以下、図11と異なる構成について主に説明する。なお、図16において、図11と同じものには同じ符号が付してある。 FIG. 16 is a block diagram showing an example of the configuration of the mobile phone according to the second embodiment. Hereinafter, a configuration different from that in FIG. 11 will be mainly described. In FIG. 16, the same components as those in FIG. 11 are denoted by the same reference numerals.
図16において、携帯電話機は、HDD44の代わりにフラッシュメモリ47を含む。なお、携帯電話機のその他の構成は、図11と同じである。
In FIG. 16, the mobile phone includes a
フラッシュメモリ47は、一般的に、HDD44に比べて、小型であり、読み書き速度が速く、かつ、耐衝撃性が高い。このため、フラッシュメモリ47は、携帯電話機におけるデータの格納手段として好適である。しかしながら、フラッシュメモリ47は、書き換え耐性が低いため、スワップデバイスには適さない。
The
図17は、この携帯電話機のメモリ45およびCPU46の構成の一例を示したブロック図である。以下、図12と異なる構成について主に説明する。なお、図17において、図12と同じものには同じ符号が付してある。
FIG. 17 is a block diagram showing an example of the configuration of the
図17において、メモリ45は、図12で示した構成と同じ構成を有する。CPU46では、メモリマネージャ1051が、スワップ処理部1511の代わりにガベージコレクタ1512を含む。CPU46のその他の構成は、図12で示した構成と同じである。
In FIG. 17, the
ガベージコレクタ1512は、整理部512と同等な機能を有するため、ガベージコレクタ1512の説明は省略する。
Since the
次に、第三の実施例として、第三の実施形態のメモリ管理装置を組み込んだ携帯電話機を説明する。 Next, a mobile phone incorporating the memory management device of the third embodiment will be described as a third example.
第三の実施例の携帯電話機は、図11で示した携帯電話機と同じ構成を有する。 The mobile phone of the third embodiment has the same configuration as the mobile phone shown in FIG.
図18は、第三の実施例の携帯電話機のメモリ45およびCPU46の構成の一例を示したブロック図である。以下、主に図12と異なる構成について説明する。なお、図18において、図12と同じものには同じ符号が付してある。
FIG. 18 is a block diagram showing an example of the configuration of the
図18において、メモリ45は、図12で示した構成に加え、プロセス起動手順記憶部1024と、動作記憶部1025と、プロセス需要記憶部1026とを含む。CPU46は、図12で示した構成に加え、アプリケーション実行部1006と、プロセス監視部1007とを含む。
18, the
なお、プロセスの起動手順、パターン情報およびプロセス需要情報は、HDD44に記憶され、携帯電話機が立ち上がると、CPU46は、プロセスの起動手順、パターン情報およびプロセス需要情報をHDD44から取得し、そのプロセスの起動手順をプロセス起動手順記憶部1024に記憶し、そのパターン情報を動作記憶部1025に記憶し、そのプロセス需要情報をプロセス需要記憶部1026に記憶するものとする。また、プロセス需要情報の各プロセスの動作に必要なメモリ量は、そのプロセスのアプリケーションプログラムの開発者が定め、そのアプリケーションプログラムが携帯電話機に導入される際に、プロセスの識別情報と対応付けられてHDD44に記憶される。
The process startup procedure, pattern information, and process demand information are stored in the
プロセス起動手順記憶部1024と、動作記憶部1025と、プロセス需要記憶部1026は、図7で示したプロセス起動手順記憶部24と、動作記憶部25と、プロセス需要記憶部26と同等な機能を有するため、説明は省略する。また、アプリケーション実行部(実行部)1006と、プロセス監視部1007とは、図7で示した実行部6と、プロセス監視部7と同等な機能を有するため、説明は省略する。
The process activation
次に携帯電話機のプロセスの起動手順の例を説明する
図19は、携帯電話機のプロセスの起動手順の一例を説明するための説明図である。なお、図19において、図13と同じものには同じ符号が付してある。また、アプリケーションプログラム「メール」を示すノード602の中に、「メール」で実行されるプロセスの起動手順を示すツリーが示されている。ノード611から615までは、プロセスを示す。なお、ノード611から615までのそれぞれの下部には、そのノードが示すプロセスの動作に必要なメモリ量が示されている。
Next, an example of a procedure for starting a cellular phone process will be described. FIG. 19 is an explanatory diagram for explaining an example of a procedure for starting a cellular phone process. In FIG. 19, the same components as those in FIG. 13 are denoted by the same reference numerals. In addition, in the
図20は、プロセスと、そのプロセスの動作に必要なメモリ量の関係の一例を示した説明図である。 FIG. 20 is an explanatory diagram showing an example of the relationship between a process and the amount of memory necessary for the operation of the process.
図20では、機能名と、機能IDと、消費メモリ量とが示されている。機能名は、機能の名前を示す。機能IDは、その機能の識別情報を示す。消費メモリ量は、その機能の動作に必要なメモリ量を示す。 FIG. 20 shows a function name, a function ID, and a memory consumption amount. The function name indicates the name of the function. The function ID indicates identification information of the function. The consumed memory amount indicates the amount of memory necessary for the operation of the function.
本実施例では、一つのプロセスが一つの機能に対応されているとする。この場合、機能IDは、プロセスの識別情報であり、消費メモリ量は、その機能に応じたプロセスの動作に必要なメモリ量を示す。 In this embodiment, it is assumed that one process corresponds to one function. In this case, the function ID is process identification information, and the consumed memory amount indicates a memory amount necessary for the operation of the process corresponding to the function.
アプリケーションプログラム「メール」が起動中に、利用者がキーボード43を用いて「機能メニュー1」を選択した場合、キーボード43は、「機能メニュー1」を実行する旨の実行要求を実行部1006に送る。
If the user selects “
実行部1006は、その実行要求を受け付けると、「機能メニュー1」に応じたシステムコールを生成する。
When the
プロセス監視部1007は、実行部1006が生成したシステムコールの生成パターンを解析する。プロセス監視部1007は、アプリケーションプログラム「メール」の識別情報と対応付けられ、かつ、その解析したシステムコールの生成パターンと対応付けられた、「機能メニュー1」の識別情報「機能ID1」を動作記憶部1025から選択する。
The
プロセス監視部1007は、その「機能メニュー1」の識別情報「機能ID1」と対応付けられた、「返信」の識別情報「機能ID2」と、「機能メニュー2」の識別情報「機能ID3」をプロセス起動手順記憶部24から選択する。
The
推測部1004は、その識別情報「機能ID2」および「機能ID3」のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量をプロセス需要記憶部1026から選択する。この場合、「返信」の動作に必要なメモリ量「100kB」が最も大きいので、推測部1004は、必要なメモリ量「100kB」を選択する。
The
メモリマネージャ1051は、その選択されたメモリ量「100kB」になるまで、メモリ45の空き領域を確保する。
The
その後、利用者がキーボード43を用いて「返信」を選択した場合、キーボード43は、「返信」を実行する旨の実行要求を実行部1006に送る。
Thereafter, when the user selects “Reply” using the
実行部1006は、その実行要求を受け付けると、その「返信」に応じたシステムコールを生成する。
When the
プロセス監視部1007は、実行部1006が生成したシステムコールの生成パターンを解析する。プロセス監視部1007は、アプリケーションプログラム「メール」の識別情報と対応付けられ、かつ、その解析したシステムコールの生成パターンと対応付けられた、プロセスの識別情報「機能ID2」を選択する。
The
この場合、プロセス監視部1007は、「返信」から起動される後続プロセスがないと判定して、動作を終了する。
In this case, the
一方、利用者がキーボード43を用いて「機能メニュー2」を選択した場合、キーボード43は、「機能メニュー2」を実行する旨の実行要求を実行部1006に送る。
On the other hand, when the user selects “
実行部1006は、その実行要求を受け付けると、「機能メニュー2」に応じたシステムコールを生成する。
When the
プロセス監視部1007は、実行部1006が生成したシステムコールの生成パターンを解析する。プロセス監視部1007は、アプリケーションプログラム「メール」の識別情報と対応付けられ、かつ、実行部1006にて生成されたシステムコールの生成パターンと対応付けられた、プロセスの識別情報「機能ID3」を動作記憶部1025から選択する。
The
プロセス監視部1007は、その識別情報「機能ID3」と対応付けられた、「引用返信」の識別情報「機能ID4」と、「画像付き返信」の識別情報「機能ID5」とをプロセス起動手順記憶部1024から選択する。
The
推測部1004は、その識別情報「機能ID4」および「機能ID5」のそれぞれと対応付けられた複数の必要なメモリ量の中から、最も大きいメモリ量をプロセス需要記憶部1026から選択する。この場合、「画像付き返信」の起動に必要なメモリ量「200kB」が最も大きいので、推測部1004は、必要なメモリ量「200kB」を選択する。
The
メモリマネージャ1051は、その選択されたメモリ量「200kB」になるまで、メモリ45の空き領域を確保する。
The
次に、動作を説明する。 Next, the operation will be described.
図21は、携帯電話機の動作の一例を説明するためのフローチャートである。以下、「機能メニュー2」が起動された状態で、利用者がキーボード43を用いてアプリケーションプログラム「引用返信」を選択した場合を例に説明する。
FIG. 21 is a flowchart for explaining an example of the operation of the mobile phone. Hereinafter, a case where the user selects the application program “quote reply” using the
利用者がキーボード43を用いて「引用返信」を選択した場合、キーボード43は、「引用返信」を実行する旨の実行要求を実行部1006に送る。実行部1006は、その実行要求を受け付けると、ステップD1を実行する。
When the user selects “quote reply” using the
ステップD1では、実行部1006は、その「引用返信」に応じたシステムコールを生成し、そのシステムコールをプロセス監視部1007と、OS実行部1005とに送る。
In step D1, the
OS実行部1005は、そのシステムコールを受け付けると、そのシステムコールに応じた処理を行う。
When the
プロセス監視部1007は、そのシステムコールを受け付けると、ステップD2を実行する。
When the
ステップD2では、プロセス監視部1007は、そのシステムコールの生成パターンを解析する。プロセス監視部1007は、生成パターンを解析すると、ステップD3を実行する。
In step D2, the
ステップD3では、プロセス監視部1007は、保持しているアプリケーションプログラムの識別情報と対応付けられ、かつ、その解析したシステムコールの生成パターンと対応付けられた、プロセスの識別情報を動作記憶部1025から選択する。プロセス監視部1007は、プロセスの識別情報を選択すると、ステップD4を実行する。
In step D3, the
ステップD4では、プロセス監視部1007は、そのプロセスの識別情報と対応付けられた後続プロセスの識別情報をプロセス起動手順記憶部1024から選択し、その選択したプロセスの識別情報を推測部1004に送る。推測部1004は、そのプロセスの識別情報を受け付けると、ステップD5を実行する。
In step D4, the
ステップD5では、推測部1004は、そのプロセスの識別情報と対応付けられた必要なメモリ量をプロセス需要記憶部1026から選択する。推測部1004は、必要はメモリ量を選択すると、ステップB4を実行する。その後、ステップB4およびB5が実行される。
In step D5, the
次に、第四の実施例として、第四の実施形態のメモリ管理装置を組み込んだ携帯電話機を説明する。 Next, a mobile phone incorporating the memory management device of the fourth embodiment will be described as a fourth example.
第四の実施例の携帯電話機は、図11で示した携帯電話機と同じ構成を有する。 The mobile phone of the fourth embodiment has the same configuration as the mobile phone shown in FIG.
図22は、第四の実施例の携帯電話機のメモリ45およびCPU46の構成の一例を示したブロック図である。以下、主に図18と異なる構成について説明する。なお、図22において、図18と同じものには同じ符号が付してある。
FIG. 22 is a block diagram showing an example of the configuration of the
図22において、メモリ45は、図18で示した構成から、動作記憶部1025を除いた構成を有する。CPU46は、図18と同じ構成を有する。
22, the
次に動作を説明する。 Next, the operation will be described.
図23は、第四の実施例の携帯電話機の動作の一例を説明するためのフローチャートである。なお、図23において、図21と同じ処理には同じ符号が付してある。 FIG. 23 is a flowchart for explaining an example of the operation of the mobile phone according to the fourth embodiment. In FIG. 23, the same processes as those in FIG. 21 are denoted by the same reference numerals.
利用者がキーボード43を用いて機能を選択した場合、キーボード43は、その機能を実行する旨の実行要求を実行部1006に送る。実行部1006は、その実行要求を受け付けると、ステップD7を実行する。
When the user selects a function using the
ステップD7では、実行部1006は、実行要求にて要求された機能に応じたプロセスの識別情報をプロセス監視部1007および制御部1002に送る。
In step D7, the
制御部1002は、そのプロセスの識別情報を受け付けると、そのプロセスの起動および実行を行う旨のプロセス実行要求を生成し、そのプロセス実行要求をOS実行部1005に送る。
Upon receiving the process identification information, the
OS実行部1005は、そのプロセス実行要求を受け付けると、そのプロセス実行要求に応じてプロセスの起動および実行を行う。
When the
また、プロセス監視部1007は、その識別情報を受け付けると、ステップD4を実行する。その後、ステップD4、D6、B4およびB5が実行される。
In addition, when receiving the identification information, the
以上説明した各実施形態および各実施例において、図示した構成は単なる一例であって、本発明はその構成に限定されるものではない。 In each embodiment and each example described above, the illustrated configuration is merely an example, and the present invention is not limited to the configuration.
例えば、アプリケーションプログラムの起動手順が定められた組込システムに適用できる。 For example, the present invention can be applied to an embedded system in which an application program startup procedure is defined.
1 アプリケーション選択部
2 アプリケーション制御部
3 アプリケーション監視部
4 メモリ推測部
6 アプリケーションプログラム実行部
7 プロセス監視部
10 情報処理部
21 アプリケーション起動手順記憶部
22 アプリケーションメモリ需要記憶部
23 アプリケーション特定記憶部
24 プロセス起動手順記憶部
25 プロセス動作パターン記憶部
26 プロセスメモリ需要記憶部
30 メモリ
41 通信処理部
42 ディスプレイ
43 キーボード
44 HDD
45 メモリ
46 CPU
47 フラッシュメモリ
51 管理部
511 スワップ処理部
512 メモリ整理回収部
DESCRIPTION OF
45
47
Claims (11)
メモリと、
アプリケーションプログラムと、該アプリケーションプログラムの識別情報とを対応付けて記憶する特定記憶部と、
前記アプリケーションプログラムの識別情報と、該アプリケーションプログラムから起動される別のアプリケーションプログラムの識別情報とを対応付けて記憶する起動手順記憶部と、
前記別のアプリケーションプログラムの識別情報を、該別のアプリケーションプログラムの起動に必要なメモリ量と対応付けて記憶する需要記憶部と、
前記アプリケーションプログラムを起動する旨の起動要求を受け付け、該起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を前記特定記憶部から選択する選択部と、
前記選択部が選択した識別情報と対応付けられた前記別のアプリケーションプログラムの識別情報を前記起動手順記憶部から選択する監視部と、
前記監視部が選択した識別情報と対応付けられたメモリ量の中から、最も大きいメモリ量を前記需要記憶部から選択し、かつ、前記メモリの空き領域を調べ、該空き領域が前記選択したメモリ量より大きいか否かを判定する推測部と、
前記推測部にて前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで前記メモリの空き領域を確保する管理部と、を含むメモリ管理装置。 A memory management unit to ensure the amount of memory required to start the application program,
Memory,
A specific storage unit that stores an application program and identification information of the application program in association with each other;
An activation procedure storage unit that stores the identification information of the application program and the identification information of another application program activated from the application program in association with each other;
A demand storage unit that stores the identification information of the other application program in association with the amount of memory required to start the other application program;
A selection unit that accepts an activation request to activate the application program, and selects identification information associated with the application program requested in the activation request from the specific storage unit;
A monitoring unit that selects identification information of the another application program associated with the identification information selected by the selection unit from the startup procedure storage unit;
From the memory amount associated with the identification information selected by the monitoring unit , the largest memory amount is selected from the demand storage unit, and the free area of the memory is checked, and the free area is the selected memory. An estimation unit for determining whether or not the amount is greater than the amount;
And a management unit that reserves a free area in the memory until the free area in the memory reaches the memory amount when the estimation unit determines that the free area is smaller than the memory amount.
プロセスを起動するためのシステムコールの生成パターンを、該プロセスの識別情報と対応付けて記憶する動作記憶部と、
前記プロセスの識別情報を、該プロセスから起動される別のプロセスの識別情報と対応付けて記憶するプロセス起動手順記憶部と、
前記別のプロセスの識別情報を、該別のプロセスの動作に必要なメモリ量と対応付けて記憶するプロセス需要記憶部と、
前記システムコールを生成する実行部と、
前記実行部が生成したシステムコールの生成パターンを解析し、該生成パターンと対応付けられたプロセスの識別情報を前記動作記憶部から選択し、その後、該プロセスの識別情報と対応付けられた前記別のプロセスの識別情報を前記プロセス起動手順記憶部から選択するプロセス監視部と、を含み、
前記推測部は、前記プロセス監視部が選択したプロセスの識別情報と対応付けられたメモリ量を前記プロセス需要記憶部から選択し、かつ、前記メモリの空き領域を調べ、該空き領域が前記選択したメモリ量より大きいか否かを判定する、メモリ管理装置。 The memory management device according to claim 1,
An operation storage unit that stores a generation pattern of a system call for starting a process in association with identification information of the process;
A process activation procedure storage unit that stores the identification information of the process in association with identification information of another process activated from the process;
A process demand storage unit that stores the identification information of the another process in association with the amount of memory necessary for the operation of the other process;
An execution unit for generating the system call;
Analyzing the generation pattern of the system call generated by the execution unit, selecting process identification information associated with the generation pattern from the operation storage unit, and then selecting the process call identification information associated with the process identification information. A process monitoring unit that selects identification information of the process from the process activation procedure storage unit,
The estimation unit selects, from the process demand storage unit, a memory amount associated with the process identification information selected by the process monitoring unit, checks a free area of the memory, and the free area is selected. A memory management device for determining whether or not the amount of memory is larger.
プロセスの識別情報を、該プロセスから起動される別のプロセスの識別情報と対応付けて記憶するプロセス起動手順記憶部と、
前記別のプロセスの識別情報を、該別のプロセスの動作に必要なメモリ量と対応付けて記憶するプロセス需要記憶部と、
機能を実行する旨の実行要求を受け付けると、該機能に応じたプロセスの識別情報を送る実行部と、
前記実行部から受け付けたプロセスの識別情報と対応付けられた別のプロセスの識別情報を、前記プロセス起動手順記憶部から選択するプロセス監視部と、を含み、
前記推測部は、前記プロセス監視部が選択したプロセスの識別情報と対応付けられたメモリ量を前記プロセス需要記憶部から選択し、かつ、前記メモリの空き領域を調べ、該空き領域が前記選択したメモリ量より大きいか否かを判定する、メモリ管理装置。 The memory management device according to claim 1,
A process activation procedure storage unit for storing identification information of a process in association with identification information of another process activated from the process;
A process demand storage unit that stores the identification information of the another process in association with the amount of memory necessary for the operation of the other process;
When an execution request for executing a function is received, an execution unit that sends process identification information corresponding to the function;
A process monitoring unit that selects, from the process startup procedure storage unit, identification information of another process associated with the identification information of the process received from the execution unit,
The estimation unit selects, from the process demand storage unit, a memory amount associated with the process identification information selected by the process monitoring unit, checks a free area of the memory, and the free area is selected. A memory management device for determining whether or not the amount of memory is larger.
前記管理部は、前記推測部にて前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで、前記メモリ内のデータをスワップアウトするスワップ処理部を含む、メモリ管理装置。 In the memory management device according to any one of claims 1 to 3,
When the estimation unit determines that the free area is smaller than the memory amount, the management unit swaps out data in the memory until the free area of the memory reaches the memory amount. A memory management device.
前記推測部は、前記メモリにおいてアドレスが連続した空き領域を調べ、該空き領域が前記推測部にて選択されたメモリ量より大きいか否かを判定し、
前記管理部は、前記アドレスが連続した空き領域が前記メモリ量より小さいと判定されると、前記アドレスが連続した空き領域が前記メモリ量になるまで、前記メモリをデフラグする整理部を含む、メモリ管理装置。 In the memory management device according to any one of claims 1 to 3,
The estimation unit examines an empty area with consecutive addresses in the memory, determines whether the empty area is larger than the memory amount selected by the estimation unit,
The management unit includes a organizing unit that defragments the memory until the free area where the addresses are continuous is smaller than the memory amount, until the free area where the addresses are continuous reaches the memory amount. Management device.
前記アプリケーションプログラムを起動する旨の起動要求を受け付ける受付ステップと、
前記受け付けられた起動要求にて要求されたアプリケーションプログラムと対応付けられた識別情報を選択する第一選択ステップと、
前記選択された識別情報と対応付けられた前記別のアプリケーションプログラムの識別情報を選択する第二選択ステップと、
前記選択された別のアプリケーションプログラムの識別情報と対応付けられたメモリ量の中から、最も大きいメモリ量を選択する第三選択ステップと、
メモリの空き領域を調べる調査ステップと、
前記調べられた空き領域が前記選択されたメモリ量より大きいか否かを判定する判定する判定ステップと、
前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで前記メモリの領域を確保する確保ステップと、を含むメモリ管理方法。 Information associating an application program with identification information of the application program, information associating identification information of the application program with identification information of another application program started from the application program, and the other application the identity of the program to take advantage of the information associated with the amount of memory needed to run the application program the another, a memory management method for ensuring the amount of memory required to start the application program ,
An accepting step of accepting an activation request to activate the application program;
A first selection step of selecting identification information associated with the application program requested in the accepted activation request;
A second selection step of selecting identification information of the another application program associated with the selected identification information;
A third selection step of selecting the largest memory amount from among the memory amounts associated with the identification information of the selected other application programs;
A survey step to examine the free space in the memory;
A determination step of determining whether the examined free area is larger than the selected memory amount;
And a securing step of securing the memory area until the free area of the memory reaches the memory capacity when it is determined that the free area is smaller than the memory capacity.
プロセスを起動するためのシステムコールの生成パターンを該プロセスの識別情報と対応付けた情報と、前記プロセスの識別情報を該プロセスから起動される別のプロセスの識別情報と対応付けた情報と、前記別のプロセスの識別情報を該別のプロセスの動作に必要なメモリ量と対応付けた情報とを活用し、
前記システムコールを生成する生成ステップと、
前記システムコールの生成パターンを解析する解析ステップと、
前記解析された生成パターンと対応付けられたプロセスの識別情報を選択する第一プロセス選択ステップと、
前記選択されたプロセスの識別情報と対応付けられた別のプロセスの識別情報を選択する第二プロセス選択ステップと、
前記選択された別のプロセスの識別情報と対応付けられたメモリ量を選択する第三プロセス選択ステップと、を含むメモリ管理方法。 The memory management method according to claim 6.
Information in which a generation pattern of a system call for starting a process is associated with identification information of the process, information in which the identification information of the process is associated with identification information of another process started from the process, Utilizing information that associates the identification information of another process with the amount of memory necessary for the operation of the other process,
A generating step for generating the system call;
An analysis step of analyzing a generation pattern of the system call;
A first process selection step of selecting identification information of a process associated with the analyzed generation pattern;
A second process selection step of selecting identification information of another process associated with the identification information of the selected process;
And a third process selection step of selecting a memory amount associated with the identification information of the selected another process.
プロセスの識別情報を該プロセスから起動される別のプロセスの識別情報と対応付けた情報と、前記別のプロセスの識別情報を該別のプロセスの動作に必要なメモリ量と対応付けた情報と、を活用し、
機能を実行する旨の実行要求を受け付ける入力ステップと、
前記機能に応じたプロセスの識別情報を送る送信ステップと、
前記送られたプロセスの識別情報と対応付けられた別のプロセスの識別情報を選択する第四プロセス選択ステップと、
前記選択された別のプロセスの識別情報と対応付けられたメモリ量を選択する第五プロセス選択ステップと、を含むメモリ管理方法。 The memory management method according to claim 6.
Information associating process identification information with identification information of another process started from the process, information associating identification information of the other process with the amount of memory necessary for the operation of the other process, Use
An input step for receiving an execution request to execute the function;
Sending the process identification information according to the function;
A fourth process selection step of selecting identification information of another process associated with the identification information of the sent process;
And a fifth process selection step of selecting a memory amount associated with the identification information of the selected other process.
前記確保ステップは、前記空き領域が前記メモリ量より小さいと判定されると、前記メモリの空き領域が前記メモリ量になるまで、前記メモリ内のデータをスワップアウトするスワップアウトステップを含む、メモリ管理方法。 The memory management method according to any one of claims 6 to 8,
The securing step includes a swap-out step of swapping out data in the memory until it is determined that the free area is smaller than the memory amount until the free area of the memory reaches the memory amount. Method.
前記調査ステップでは、前記メモリにおいてアドレスが連続した空き領域を調べ、
前記確保ステップは、前記アドレスが連続した空き領域が前記メモリ量より小さいと判定されると、前記アドレスが連続した空き領域が前記メモリ量になるまで、前記メモリをデフラグするデフラグステップを含む、メモリ管理方法。 The memory management method according to any one of claims 6 to 8,
In the investigating step, an empty area having continuous addresses in the memory is examined,
The securing step includes a defragmenting step of defragmenting the memory until it is determined that a free area in which the addresses are continuous is smaller than the memory amount, and a free area in which the addresses are continuous becomes the memory amount. Management method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007060521A JP5103954B2 (en) | 2007-03-09 | 2007-03-09 | Memory management device, memory management method and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007060521A JP5103954B2 (en) | 2007-03-09 | 2007-03-09 | Memory management device, memory management method and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2008225669A JP2008225669A (en) | 2008-09-25 |
JP5103954B2 true JP5103954B2 (en) | 2012-12-19 |
Family
ID=39844245
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2007060521A Expired - Fee Related JP5103954B2 (en) | 2007-03-09 | 2007-03-09 | Memory management device, memory management method and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5103954B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5936458B2 (en) * | 2012-06-18 | 2016-06-22 | シャープ株式会社 | Information processing apparatus, application execution control method, application execution control program, and recording medium |
JP7202684B2 (en) * | 2020-09-25 | 2023-01-12 | 株式会社ユニバーサルエンターテインメント | game machine |
JP7202683B2 (en) * | 2020-09-25 | 2023-01-12 | 株式会社ユニバーサルエンターテインメント | game machine |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2000298591A (en) * | 1999-04-14 | 2000-10-24 | Nec Corp | Program starting device and method and recording medium |
JP2001256111A (en) * | 2000-03-14 | 2001-09-21 | Toshiba Corp | System monitoring device |
JP2002041285A (en) * | 2000-07-28 | 2002-02-08 | Toshiba Corp | Data processing equipment and data processing method |
JP2005301801A (en) * | 2004-04-14 | 2005-10-27 | Nec Corp | Information processing apparatus, memory management apparatus and program |
JP2006048422A (en) * | 2004-08-05 | 2006-02-16 | Matsushita Electric Ind Co Ltd | Loading apparatus, loading method, loading program, and computer readable recording medium for recording loading program |
-
2007
- 2007-03-09 JP JP2007060521A patent/JP5103954B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2008225669A (en) | 2008-09-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP2715535B1 (en) | Application notifications | |
US6910210B1 (en) | System and method for terminating applications | |
JP3942941B2 (en) | COMMUNICATION DEVICE, PLUG-IN MODULE CONTROL METHOD, PROGRAM FOR EXECUTING COMPUTER, AND COMPUTER-READABLE RECORDING MEDIUM CONTAINING PROGRAM FOR EXECUTING COMPUTER | |
US20150212919A1 (en) | Policy Based Application Suspension and Termination | |
CN100468345C (en) | Competition solving device | |
JP2007026094A (en) | Execution device and application program | |
US20070266231A1 (en) | Portable Electronic Device and Method for Loading Resource Data of the Portable Electronic Device | |
JP2006351004A (en) | Memory management method of mobile terminal | |
US11080143B2 (en) | Systems and processes for data backup and recovery | |
JP6037320B2 (en) | Program, computer-readable recording medium, computer-implemented method for predicting computing device action candidates, and apparatus for predicting application activity | |
MXPA06013666A (en) | Method, software and apparatus for using application state history information when re-launching applications. | |
WO2007136021A1 (en) | Virtual machine management device, method for managing virtual machine and program | |
JP2016508268A (en) | Personal real-time recommendation system | |
WO2019196878A1 (en) | Method for memory management and related device | |
EP3588287B1 (en) | Performance of predicted actions | |
KR20140034246A (en) | Memory management model and interface for new applications | |
JPH09128276A (en) | Computer system and file managing method used by the same | |
KR20140033448A (en) | Memory management model and interface for unmodified applications | |
CN112612417B (en) | Data migration method, device, equipment and storage medium | |
JP5103954B2 (en) | Memory management device, memory management method and program | |
CN107977275B (en) | Task processing method based on message queue and related equipment | |
CN111026331A (en) | Request response method, device, equipment and computer readable storage medium | |
JPH1091498A (en) | Smart lru method for re-using directory location handle | |
KR100493893B1 (en) | System and method of shortening class loading process in java program | |
CN111078587B (en) | Memory allocation method and device, storage medium and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20100218 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120508 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20120620 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120731 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20120815 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20120904 |
|
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20120917 |
|
R150 | Certificate of patent or registration of utility model |
Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20151012 Year of fee payment: 3 |
|
LAPS | Cancellation because of no payment of annual fees |