JP6364827B2 - Information processing apparatus, resource access method thereof, and resource access program - Google Patents
Information processing apparatus, resource access method thereof, and resource access program Download PDFInfo
- Publication number
- JP6364827B2 JP6364827B2 JP2014046447A JP2014046447A JP6364827B2 JP 6364827 B2 JP6364827 B2 JP 6364827B2 JP 2014046447 A JP2014046447 A JP 2014046447A JP 2014046447 A JP2014046447 A JP 2014046447A JP 6364827 B2 JP6364827 B2 JP 6364827B2
- Authority
- JP
- Japan
- Prior art keywords
- memory area
- information
- dedicated memory
- task
- arithmetic processing
- 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.)
- Active
Links
Images
Landscapes
- Multi Processors (AREA)
Description
本発明は、複数のプロセッサコアを有する情報処理装置において、各プロセッサコアによって実行される多数のタスクが並行して特定のリソースにアクセスすることを可能とする技術に関する。 The present invention relates to a technology that enables a number of tasks executed by each processor core to access a specific resource in parallel in an information processing apparatus having a plurality of processor cores.
近年、演算処理装置であるプロセッサコア(以下、単に「コア」と称する場合がある)を複数有するコンピュータ等の情報処理装置(以下、「マルチコアシステム」と称する場合がある)が普及している。 2. Description of the Related Art In recent years, information processing apparatuses such as computers (hereinafter sometimes referred to as “multi-core systems”) having a plurality of processor cores (hereinafter simply referred to as “cores”), which are arithmetic processing devices, have become widespread.
このようなマルチコアシステムにおいて動作するプロセスやスレッド(以下これらをまとめて「タスク」と称する場合がある)は、当該タスクの処理に関連した各種情報を高速に出力するために、メモリ等の主記憶装置(以下「メモリ領域」と称する場合がある)を一時的な出力領域として使用することがある。この場合、例えば、係るタスクからメモリ領域に出力された各種データは、別のタスク等により、ハードディスク等の2次記憶装置に設けられたデータベースシステムやファイルシステム等に格納されることがある。 Processes and threads (hereinafter, sometimes collectively referred to as “tasks”) that operate in such a multi-core system have a main memory such as a memory in order to output various information related to the processing of the tasks at high speed. A device (hereinafter sometimes referred to as a “memory area”) may be used as a temporary output area. In this case, for example, various data output from the task to the memory area may be stored in a database system or a file system provided in a secondary storage device such as a hard disk by another task or the like.
係るマルチコアシステムにおいて、複数のタスクを並行して処理可能なマルチタスク・オペレーティングシステム(OS:Operating System)が稼働する場合、係るOSのスケジューラは、特定の瞬間において、1つのコアが1つのタスクのみを実行するよう制御する。即ち、1つのコアは、特定の瞬間において、同時に2つ以上のタスクを処理しないように制限される。 In such a multi-core system, when a multi-task operating system (OS) that can process a plurality of tasks in parallel operates, the scheduler of the OS has only one task per core at a specific moment. Control to execute. That is, one core is limited to not process more than one task at a particular moment.
上記したようなマルチコアシステムにおいては、複数のタスクが異なるコアにより同時に実行される場合がある。よって、それぞれのタスクが共有する各種資源(以下「リソース」と称する場合がある)にアクセスする際には、当該リソースに対する排他制御が必要となる場合がある。 In the multi-core system as described above, a plurality of tasks may be executed simultaneously by different cores. Therefore, when accessing various resources shared by each task (hereinafter sometimes referred to as “resources”), exclusive control may be required for the resources.
より具体的には、例えば、複数のタスクが特定のメモリ領域に各種情報を出力する場合には、それぞれのタスクの出力処理が競合する可能性を考慮した排他制御を、当該タスク自身に組み込む必要がある。 More specifically, for example, when multiple tasks output various types of information to a specific memory area, it is necessary to incorporate exclusive control into the task itself in consideration of the possibility of conflicting output processing of each task. There is.
共有リソースに対する排他制御を実装した場合、特定のタスクが係るリソースを占有している間、他のリソースか係るリソースにアクセスできないため、全体として処理性能(以下「スループット」と称する場合がある)が低下する場合がある。また、係る排他制御処理に関連して発生する処理のオーバーヘッドも、処理性能が低下する要因となる。 When exclusive control for shared resources is implemented, the resources related to other resources cannot be accessed while a specific task occupies the related resources, so the processing performance as a whole (hereinafter sometimes referred to as “throughput”) May decrease. In addition, processing overhead that occurs in connection with such exclusive control processing also causes a reduction in processing performance.
より具体的には、例えば、多数のタスクが並行して動作する際に、個々のタスクが動作ログを特定のメモリ領域に出力する場合など、複数のタスクが特定少数の共有領域に情報を出力する場合にはタスク間において排他制御が必要となる場合がある。これは、システム全体としての処理性能が低下する原因となる。 More specifically, for example, when a large number of tasks run in parallel, each task outputs its operation log to a specific memory area. For example, multiple tasks output information to a specific small number of shared areas. In some cases, exclusive control may be required between tasks. This causes a reduction in the processing performance of the entire system.
上記したような排他制御に伴う処理性能の低下を回避するため、例えば、個別のタスク毎に専用のメモリ領域を用意する方法が考えられる。しかし、この場合、各タスクが出力しうる情報の最大サイズを見積り、それらを合計したサイズを基準としてメモリ領域を用意しなければならず、膨大なサイズのメモリが必要となる場合がある。 In order to avoid the degradation of processing performance associated with exclusive control as described above, for example, a method of preparing a dedicated memory area for each individual task is conceivable. However, in this case, the maximum size of information that can be output by each task must be estimated, and a memory area must be prepared based on the total size, which may require a huge amount of memory.
また、用意可能なメモリ領域のサイズが限られている場合、係るメモリ領域をタスク毎に分割して各タスクに割り当てると、タスクによっては必要なサイズのメモリ領域を確保できないため、係るメモリ領域が有効活用されない場合がある。 In addition, when the size of the memory area that can be prepared is limited, if the memory area is divided for each task and allocated to each task, a memory area of a necessary size cannot be secured depending on the task. It may not be used effectively.
すなわち、複数のコアにおいて異なるタスクが並行して実行されるシステムにおいては、それぞれのタスクからリソースへのアクセスを効率的の処理可能な技術が求められている。 That is, in a system in which different tasks are executed in parallel in a plurality of cores, a technique capable of efficiently processing access from each task to a resource is required.
上記したような複数のタスクが実行される環境における、メモリ等の共有リソースへのアクセスに関する技術として、例えば、以下のような特許文献が開示されている。 For example, the following patent documents are disclosed as techniques related to access to a shared resource such as a memory in an environment where a plurality of tasks as described above are executed.
特許文献1は、複数のコアを有するマルチコアプロセッサにおいて、それぞれのコアに付随する専用メモリ領域を、他のコアから使用可能にする技術を開示する。 Patent Document 1 discloses a technique for enabling a dedicated memory area associated with each core to be used from another core in a multi-core processor having a plurality of cores.
特許文献1に開示された技術によれば、複数のコアを有するマルチコアプロセッサにおいて、それぞれのコアの状態を監視し、休止状態となっているコアに関連付けされた付随メモリを、他のコアから使用可能とする。係る付随メモリは、外部メモリに比して高速にアクセス可能であることから、特許文献1に開示された技術によれば、高速アクセス可能なメモリ領域を有効活用可能である。 According to the technology disclosed in Patent Document 1, in a multi-core processor having a plurality of cores, the state of each core is monitored, and the associated memory associated with the core in the dormant state is used from another core Make it possible. Since the associated memory can be accessed at a higher speed than the external memory, according to the technique disclosed in Patent Document 1, it is possible to effectively use a memory area accessible at a high speed.
特許文献2は、マルチコアプロセッサにおいて、複数のコアが異なるキャッシュメモリの領域に同時にアクセスする技術を開示する。 Patent Document 2 discloses a technique in which a plurality of cores simultaneously access different cache memory areas in a multi-core processor.
特許文献2に開示された技術は、セマフォア管理テーブルを用いて、排他制御対象に対する各コアからのアクセスを制御する。また、特許文献2に開示された技術は、係る排他制御の際に、各コアに割り当てられて優先度を考慮する。特許文献2に開示された技術によれば、排他制御対象へのアクセスをセマフォアに基づいて制御可能であると共に優先度が高い処理を短いオーバーヘッドで実行可能である。 The technique disclosed in Patent Document 2 controls access from each core to an exclusive control target using a semaphore management table. Further, the technique disclosed in Patent Document 2 considers the priority assigned to each core during such exclusive control. According to the technique disclosed in Patent Document 2, access to an exclusive control target can be controlled based on a semaphore, and high priority processing can be performed with a short overhead.
特許文献3は、共有メモリの排他制御装置等に関する技術を開示する。 Patent Document 3 discloses a technique related to an exclusive control device for a shared memory.
特許文献3に開示された技術によれば、複数のプロセッサと共有メモリを有するシステムにおいて、各プロセッサが、メモリバスのアドレス信号線に当該プロセッサの識別信号を設定することにより、当該メモリの排他使用権を獲得する。メモリアクセスコントローラは、アドレス信号線を監視することにより、排他使用権を獲得したプロセッサを認識し、他のプロセッサからのアクセス要求にリトライ応答を返す。これにより、特許文献3に開示された技術は、各プロセッサから共有メモリへのアクセスに関する排他制御を実現する。 According to the technique disclosed in Patent Document 3, in a system having a plurality of processors and a shared memory, each processor sets an identification signal of the processor on the address signal line of the memory bus, thereby exclusive use of the memory. Win the right. The memory access controller recognizes the processor that has acquired the exclusive use right by monitoring the address signal line, and returns a retry response to an access request from another processor. Thereby, the technique disclosed in Patent Document 3 realizes exclusive control related to access from each processor to the shared memory.
特許文献4は、複数のプロセッサを有し、プロセッサ毎に用意されたプライベートメモリと、全てのプロセッサからアクセス可能な共有メモリを有するマルチプロセッサシステムに関する技術を開示する。特許文献4に開示された技術は、プロセッサ毎に割り当てられたローカルメモリにマルチタスク・オペレーティングシステムを実装する。そして、係るオペレーティングシステムのカーネル部分をプロセッサ毎のプライベートメモリに配置し、タスク情報部分を共有メモリに配置する。特許文献4に開示された技術によれば、カーネル部分へのアクセスにはプロセッサ間でメモリアクセスバスの競合が発生しないため、システム全体のスループット(処理性能)を向上可能である。 Patent Document 4 discloses a technique related to a multiprocessor system having a plurality of processors, a private memory prepared for each processor, and a shared memory accessible from all the processors. The technique disclosed in Patent Literature 4 implements a multitasking operating system in a local memory allocated for each processor. Then, the kernel part of the operating system is arranged in the private memory for each processor, and the task information part is arranged in the shared memory. According to the technique disclosed in Patent Document 4, since access to the kernel portion does not cause a memory access bus contention between processors, the throughput (processing performance) of the entire system can be improved.
上記したように、複数のタスクが同時に実行されるマルチコアシステムにおいては、メモリ領域等の共有リソースにアクセスする際の排他制御に伴う、処理性能の低下を抑えることが可能な技術が求められている。また、係る技術は、複数のタスクから当該リソースへのアクセスを並行して処理可能であると共に、膨大なリソースを必要としないことが望ましい。 As described above, in a multi-core system in which a plurality of tasks are executed at the same time, there is a demand for a technique capable of suppressing a decrease in processing performance associated with exclusive control when accessing a shared resource such as a memory area. . In addition, it is desirable that such a technique can process access to the resource from a plurality of tasks in parallel and does not require a huge amount of resources.
ここで、上記特許文献1は、複数のコアにおいて同時に複数のタスク(プログラム)が実行された場合における、付随メモリにたいする排他制御については何ら考慮されていない。 Here, the above-mentioned Patent Document 1 does not consider any exclusive control for the associated memory when a plurality of tasks (programs) are simultaneously executed in a plurality of cores.
上記特許文献2は、各コアに対して1つのタスクのみが割り当てられることを前提としている。また、コア間で共有するリソースをアクセスする際には、通常の排他制御処理が必要となる。 The above Patent Document 2 is premised on that only one task is assigned to each core. Further, when accessing a resource shared between cores, a normal exclusive control process is required.
上記特許文献3は、回路規模の増大を抑え、バスの使用効率等を向上する実装技術であり、共有メモリにアクセスする際にはプロセッサ間の排他制御が必要となる。 The above-mentioned Patent Document 3 is a mounting technology that suppresses an increase in circuit scale and improves the use efficiency of a bus, and requires exclusive control between processors when accessing a shared memory.
また、上記特許文献4は、各プロセッサにおいて実行されるタスクが、例えばローカルメモリ上の特定の領域を共有する場合の排他制御に関して、具体的に言及していない。各プロセッサにおいてタスクは並列に実行されることから、ローカルメモリ上の特定の領域に同時にアクセスする際には、一般的な排他制御が必要となることが予想される。このため、上記各特許文献に開示された技術のみでは、上記した課題を十分に解決することができない。 Further, Patent Document 4 does not specifically mention the exclusive control in the case where a task executed in each processor shares a specific area on the local memory, for example. Since tasks are executed in parallel in each processor, it is expected that general exclusive control is required when simultaneously accessing a specific area on the local memory. For this reason, only the technique disclosed in each of the above-mentioned patent documents cannot sufficiently solve the above-described problem.
本発明は、上記の事情を鑑みてなされたものである。即ち、本発明は、複数のプロセッサコアを有するマルチコアシステムにおいて、複数のタスクがそれぞれ特定のリソースに並行してアクセスすることが可能な情報処理装置等を提供することを、主たる目的とする。 The present invention has been made in view of the above circumstances. That is, the main object of the present invention is to provide an information processing apparatus or the like that allows a plurality of tasks to access a specific resource in parallel in a multi-core system having a plurality of processor cores.
上記の目的を達成すべく、本発明に係る情報処理装置は、以下の構成を備えることを特徴とする。即ち、本発明に係る情報処理装置は、1以上のタスクを実行可能な複数の演算処理手段と、上記演算処理手段に関連付けされ、当該演算処理手段において実行される上記タスクから出力される情報を保持する第1の記憶手段である専用メモリ領域と、1以上の上記タスクを上記演算処理部に割り当てる演算処理割り当て管理手段と、1以上の上記タスクの内、特定の上記タスクに基づいて通知された上記専用メモリ領域に対するアクセス要求を受け付け、上記演算処理割り当て管理手段に対して当該特定の上記タスクを実行している上記演算処理手段の占有を要求すると共に、当該演算処理手段に関連付けされた上記専用メモリ領域に対する上記アクセス要求を処理する、リソースアクセス手段と、を有することを特徴とする。 In order to achieve the above object, an information processing apparatus according to the present invention has the following configuration. That is, the information processing apparatus according to the present invention includes a plurality of arithmetic processing means capable of executing one or more tasks, and information output from the task associated with the arithmetic processing means and executed by the arithmetic processing means. Notification is made based on the specific task among the one or more tasks, the dedicated memory area that is the first storage means to hold, the arithmetic processing assignment management means for assigning one or more of the tasks to the arithmetic processing unit, and The access request to the dedicated memory area is received, the occupancy of the arithmetic processing unit executing the specific task is requested to the arithmetic processing allocation management unit, and the processing unit associated with the arithmetic processing unit Resource access means for processing the access request to the dedicated memory area.
本発明に係る、情報処理装置におけるリソースアクセス方法は、以下の構成を備えることを特徴とする。即ち、本発明に係る、情報処理装置におけるリソースアクセス方法は、1以上のタスクを実行可能な複数の演算処理手段と、上記演算処理手段に関連付けされ、当該演算処理手段において実行される上記タスクから出力される情報を保持する第1の記憶手段である専用メモリ領域と、を有する情報処理装置が、1以上の上記タスクを上記演算処理部に割り当てる演算処理割り当て管理手段に対して、1以上の上記タスクの内、特定の上記タスクに基づいて通知された上記専用メモリ領域に対するアクセス要求を受け付けた場合に、当該特定の上記タスクを実行している上記演算処理手段の占有を要求し、当該演算処理手段に関連付けされた上記専用メモリ領域に対する上記アクセス要求を処理することを特徴とする。
A resource access method in an information processing apparatus according to the present invention has the following configuration. That is, the resource access method in the information processing apparatus according to the present invention includes a plurality of arithmetic processing means capable of executing one or more tasks, and the task associated with the arithmetic processing means and executed by the arithmetic processing means. An information processing apparatus having a dedicated memory area that is a first storage unit that holds information to be output, to an arithmetic processing assignment management unit that allocates one or more tasks to the arithmetic processing unit. When an access request to the dedicated memory area notified based on the specific task among the tasks is received, the occupation processing unit executing the specific task is requested to be occupied, and the calculation is performed. The access request for the dedicated memory area associated with the processing means is processed.
また、同目的は、上記構成を有する通信制御装置、並びに対応する通信制御方法を、コンピュータによって実現するコンピュータ・プログラム、及び、そのコンピュータ・プログラムが格納されている、コンピュータ読み取り可能な記憶媒体によっても達成される。 The object is also achieved by a computer program for realizing the communication control apparatus having the above-described configuration and the corresponding communication control method by a computer, and a computer-readable storage medium storing the computer program. Achieved.
本発明によれば、複数のプロセッサコアを有するマルチコアシステムにおいて、複数のタスクがそれぞれ特定のリソースに並行して任意の情報を出力することが可能である。より具体的には、複数のタスクが、係るプロセッサコア毎に用意されたリソースに対して並行してアクセスすることが可能な情報処理装置等を提供することが可能である。 According to the present invention, in a multi-core system having a plurality of processor cores, a plurality of tasks can output arbitrary information in parallel to specific resources. More specifically, it is possible to provide an information processing apparatus or the like in which a plurality of tasks can access resources prepared for each processor core in parallel.
次に、本発明を実施する形態について図面を参照して説明する。以下の実施の形態に記載されている構成は単なる例示であり、本願発明の技術範囲はそれらには限定されない。 Next, embodiments of the present invention will be described with reference to the drawings. The configurations described in the following embodiments are merely examples, and the technical scope of the present invention is not limited thereto.
<第1の実施形態>
以下、図1及び図2を参照して、本実施形態に係る情報処理装置であるマルチコアシステム100の構成にについて説明する。
<First Embodiment>
Hereinafter, the configuration of the
図1は本実施形態に係るマルチコアシステム100の構成を概念的に例示する図である。図1に例示するように、マルチコアシステム100は、コア101(図1に例示する「コア01」乃至「コア04」)と、係るコア101からアクセス可能な専用メモリ領域102(図1に例示する「専用メモリ領域01」乃至「専用メモリ領域04」)を有する。
FIG. 1 is a diagram conceptually illustrating the configuration of a
また、マルチコアシステム100は、上記コア101において実行される複数のタスク103と、上記タスク101等に対して上記専用メモリ領域102等へのアクセス機能を提供するライブラリ104と、上記専用メモリ領域102に保持(格納)された情報をファイル106に出力するファイル出力部105とを有する。
In addition, the
また、マルチコアシステム100は、上記タスク103の実行等を制御するOS(Operating System)を有する。係るOSは、各タスク103の実行順序や、各タスクのコア101への割り当てなどを制御するスケジューラ107を有し、係るスケジューラ107は、コア割り当て管理部108を有する。以下、それぞれの構成要素について説明する。
Further, the
コア101は、CPU(Central Processing Unit)等の演算装置であり、タスク103に実装された処理を実行する。本実施形態におけるコア101は、それ自体で単一のCPUであってもよく、あるいは、単一のCPUの一部を構成する演算処理ユニットであってもよい。図1に例示する具体例においては、コア101として「コア01」乃至「コア04」が例示されている。本実施形態におけるマルチコアシステム101はこれに限定されず、任意の個数のコア101を採用してよい。
The
なお、マルチコアシステム100においては、コア101を割り当てられたタスク103のみが実行状態とされ、コア101を割り当てられていないタスク103の実行は中断される。この場合、当該タスク103の処理は一時的に停止するが、タスク103自体は処理が停止していることを認識しない。
In the
専用メモリ領域102は、後述するタスク103から出力される各種情報を保持する領域である。専用メモリ領域102は、コア101毎に設けられ、1つの専用メモリ領域102は、一つのコア101に関連付けられる。本実施形態において、係る専用メモリ領域102にアクセス可能なのは、当該専用メモリ領域が関連付けられたコア101において実行されるタスク103に限定される。
The
即ち、特定のコア101に関連付けされた専用メモリ領域102に対しては、他のコア101において実行されるタスク103はアクセスすることができない。ただし、後述するファイル出力部105による専用メモリ領域初期化処理に限り、当該ファイル出力部105がどのコア101により実行されている場合でも、全ての専用メモリ領域102にアクセス可能とする。なお、上述したアクセス制限の具体的な方法は、例えば周知のOSや、周知のメモリコントローラ等の技術を採用してよいため、詳細な説明は省略する。
That is, the
本実施形態における専用メモリ領域102は、例えば、図2に例示するような管理情報領域201と、情報保持領域202とを有する。図2に例示する具体例においては、管理情報領域201は、専用メモリ領域102に関する管理情報として、全体領域サイズ201aと、ファイル出力中フラグ201bと、空き領域サイズ201cと、空き領域ポインタ201dと、を有する。
The
全体領域サイズ201aは、当該専用メモリ領域102において情報を保持可能な全体のサイズを保持する領域である。
The
ファイル出力中フラグ201bは、後述するファイル出力部105において、当該専用メモリ領域102に保持されている情報を、特定のファイル106に出力する処理を実行しているか否かを表す情報を保持する。
The
空き領域サイズ201cは、情報保持領域202における、空き領域202bのサイズを保持する。
The
空き領域ポインタ201dは、空き領域202bの先頭位置を表す情報を保持する。
The
情報保持領域202は、タスク103から出力される情報を保持する領域であり、係る情報が書き込まれた使用済み領域202aと、未使用の空き領域202bとを有する。
The information holding area 202 is an area for holding information output from the
使用済み領域202aは、当該専用メモリ102が関連付けされたコア101において実行されるタスク103から出力された各種情報が書き込まれた領域である。なお、係るタスク103の実行状況によっては、使用済み領域202aが存在しない場合(情報が出力されていない場合)もある。
The used
図3に例示するように、情報保持領域202は、ヘッダ情報301とタスクからの出力情報302とを保持する。本実施形態においては、ヘッダ情報301、及び、タスクからの出力情報302は、後述するライブラリ104によって情報保持領域202に書き込まれる。図3に例示する具体例においては、ヘッダ情報301は、出力時刻301a、タスクID301b、及び、サイズ301cを有する。
As illustrated in FIG. 3, the information holding area 202 holds header information 301 and
出力時刻301aは、特定のタスク103から出力された出力情報302が、専用メモリ領域102に書き込まれた時刻を表す情報を保持する。
The
タスクID301bは、出力情報302を書き込んだタスク103を一意に識別可能な識別情報を保持する。係る識別情報としては、例えば、後述するタスク103に関するプロセスID、スレッドID、あるいはこれらとプロセス名との組合せ等を採用してもよい。
The
サイズ301cは、タスクからの出力情報302のサイズを保持する。
The
上記ヘッダ情報301は、タスク103が指定した情報を専用メモリ領域102に書き込む際に、後述するライブラリ104によって付加される。なお、係るヘッダ情報301は、情報を出力したタスク103と、出力された情報の内容を特定するために用いられる。
The header information 301 is added by the
タスク103は、上記したように、マルチコアシステム100において実行されるプロセスやスレッド等である。各タスク103がどのような処理を実行するかは、タスク103を実装するソフトウェア・プログラム(コンピュータ・プログラム)等において任意に定めておよい。
As described above, the
なお、本実施形態におけるタスク103は、後述するライブラリ104を介して、上記専用メモリ領域102に対して各種情報を出力する。タスク103が出力する情報の内容は適宜定めてよく、例えば、当該タスク103の処理に関するログの情報等を含んでもよい。
Note that the
ライブラリ104は、上記タスク104や、後述するファイル出力部105等に対して、専用メモリ領域102にアクセスする機能を提供するソフトウェア・プログラムである。より具体的には、ライブラリ104は、上記専用メモリ領域102に対する書き込み・読み込み機能や、上記専用メモリ領域102における特定の領域を初期化する機能等を提供する。
The
本実施形態におけるライブラリ104は、タスク103からの情報出力要求に応じて、当該タスク103が割り当てられているコア101に関連付けされた専用メモリ領域104を特定し、当該専用メモリ領域104へ情報の書き込みを行う。また、当該書き込み処理の間、当該タスク103に割り当てられたコア101を、独占的に使用可能とすることを後述するコア割り当て管理部108に要求する。また、専用メモリ領域102の使用状況に応じて、後述するファイル出力部105に対して、メモリ領域内の情報をファイル106等に出力することを要求する。本実施形態におけるライブラリ104は、タスク103に対して、係るタスク103が出力する各種情報の内容と、出力サイズを指定可能なインターフェイスを提供してもよい。
In response to an information output request from the
本実施形態におけるライブラリ104は、例えば、当該ライブラリ104を利用するタスタスク103が実行されるコア101において、係るタスク103と共に実行されてもよい。即ち、本実施形態におけるライブラリ104は、例えば、当該ライブラリ104を利用するタスク103とリンクされることにより、係るタスクと一体として、コア101により実行されてもよい。
The
上記タスク103及び、ライブラリ104における各処理の具体的な内容については、後述する。
Specific contents of each process in the
ファイル出力部105は、専用メモリ領域102に書き込まれた各種情報を保存する処理、及び、専用メモリ領域102を再利用するための初期化処理等を実行するタスクである。ファイル出力部105は、上記ライブラリ104から適当な契機で呼び出され、専用メモリ領域102に書き込まれた各種情報をファイル106等に転送する。また、ファイル出力部は、当該専用メモリ領域102の管理情報を初期化する。これにより、当該専用メモリ領域102に新たな情報を書き込むことが可能となる。
The
本実施形態におけるファイル106は、図示しないハードディスク等の2次記憶装置に設けられたファイルシステム等によって提供される記憶領域である。本実施形態におけるファイル106は、上記ファイル出力部105により出力された各種情報を保持(記録)する。
The
なお、ファイル出力部105及びファイル106については、上記に限定されず、例えば、ファイル106を図示しないデータベースのレコードとして実現し、ファイル出力部105が係るデータベースのレコードを出力するよう構成してもよい。
The
スケジューラ107は、マルチコアシステム100を構成するマルチタスクOSの一部として設けられ、実行可能状態で待機しているタスク103に対して、所定の基準に基づいてコア101を割り当てるスケジューリングを行う。
The
ここで、コア101において実行するタスク103を選択する基準としては、例えば、優先度の高さや、処理完了までの推定残り時間の短さ等の基準を適宜選択してよい。また、係るタスク103を実行するコア101を選択する基準としては、例えば、各コアに対する使用率(各コアの稼働率)のバランスや、キャッシュヒットの可能性等の基準を適宜選択してよい。これらの基準は、例えば、マルチコアシステム100に対して定められた所定のポリシーに基づいて選択してもよい。
Here, as a criterion for selecting the
本実施形態におけるスケジューラ107は、後述するコア割り当て管理部108が管理する割り当て可能なコア101の情報(割り当て可能コア情報109)に基づいて、特定のタスク103に対してコア101を割り当てる。なお、本実施形態におけるスケジューラ107は、上記説明したコアの割り当て以外に、周知のマルチタスクOSに実装されたスケジューラと同様の機能を有してもよい。
The
コア割り当て管理部108は、タスク103に対して割り当て可能なコア101の情報(割り当て可能コア情報109)を管理し、係る情報を上記スケジューラ107に提供する。また、コア割り当て管理部108は、ライブラリ104から、特定のコア101を特定のタスク103に独占的に割り当てる(以下「占有」と称する場合がある)要求を受け付ける。コア割り当て管理部108は、係る占有要求に基づいて、各コア101を、タスク103に割り当て可能か否かを制御する。
The core
なお、本実施形態におけるマルチタスクOSは、周知のマルチタスクOSと同様に、ある特定の瞬間において、1つのコア101は1つのタスク103のみを実行するように制御する。即ち、1つのコアは、特定の瞬間において、同時に2つ以上のタスクを処理しないように制限される。
Note that the multitasking OS in the present embodiment controls so that one
なお、係るマルチタスクOSは、例えば、一定の時間毎に特定のコア101において実行されるタスク103を切り替えることにより(例えば、一つのコア101を時分割で複数のタスク103に割り当てることにより)、1つコアが一定期間内に複数のタスクを実行可能なように制御してもよい。なお、係るタスク103の切り替え動作は周知の技術を採用してよいため、詳細な説明は省略する。
Note that the multitasking OS switches, for example, a
上記説明したマルチコアシステム100を実現可能なハードウェア構成の具体例を、図4に例示する。
A specific example of a hardware configuration capable of realizing the
マルチコアプロセッサ401は、複数のコア101と、当該コア101に対する入出力を制御するIOコントローラとを有する。
The
1次記憶装置402は、上記コア101に関連付けされた複数の専用メモリ領域102と、各コアにおいて実行されるタスク103や、マルチタスクOSからアクセス可能な汎用メモリ領域と、1次記憶装置に入出力やデータの配置を制御するメモリコントローラとを有する。なお、係る1次記憶装置402は、例えば、揮発性のRAM(Random Access Memory)等により構成してもよい。
The
2次記憶装置403は、例えば、ハードディスク等により構成された不揮発性の記憶領域である。2次記憶装置403は、例えば、ファイルシステムにおいて提供される各種ファイルや、データベース等を記憶してもよい。例えば、本実施形態において、図1に例示するファイル106は、2次記憶装置403に記憶されてもよい。
The
プログラム記憶領域404は、本実施形態におけるマルチコアシステム100を構成するソフトウェア・プログラムを記憶する領域である。図4に例示する構成においては、プログラム記憶領域を2次記憶装置403とは別の要素として表記しているが、プログラム記憶領域404は2次記憶装置403に含まれてもよい。また、プログラム記憶領域404は、例えば、2次記憶装置403とは別にROM(Read Only Memory)等により構成してもよい。
The
図4のように構成されたマルチコアシステム100によれば、例えば、マルチタスクOSがプログラム領域404に格納されたタスク103及びライブラリ104を1次記憶装置402にロードし、係るロードされたタスク103をマルチコアプロセッサ401におけるコア101が実行することにより、タスク103に実装された各種処理が実行される。
According to the
次に、上記のように構成されたマルチコアシステムの動作について説明する。以下においては、図5乃至図7に例示するフローチャート参照して、上記タスク103から専用メモリ領域102に各種情報を出力する動作を説明する。
Next, the operation of the multi-core system configured as described above will be described. In the following, an operation for outputting various types of information from the
まず、図5に例示するフローチャートを参照して、タスク103及びライブラリ104の動作について説明する。
First, the operations of the
以下の説明においては、特定のタスク103(以下、仮に「タスク01」と称する)に対して、特定のコア01(以下、仮に「コア01」と称する)が割り当てられ、当該タスク01がコア01によって実行されている状態を仮定する。 In the following description, a specific core 01 (hereinafter referred to as “core 01”) is assigned to a specific task 103 (hereinafter referred to as “task 01”), and the task 01 is assigned to the core 01. Assume that the state is being executed by.
まず始めに、タスク01が、ライブラリ104が提供する機能を使用して、任意の情報の出力を要求する(ステップS501)。より具体的には、タスク01が、出力しようとする情報の内容とそのサイズとを指定して、ライブラリ104が提供する情報出力用のインターフェイスを呼び出す。以下、このようなタスク101から発せられる任意の情報を出力する要求を、「情報出力要求」と称する場合がある。
First, the task 01 requests the output of arbitrary information using the function provided by the library 104 (step S501). More specifically, the task 01 calls the information output interface provided by the
上記タスク01からの情報出力要求を受け付けたライブラリ104は、コア割り当て管理部108に対して、上記タスク01に対するコア01の割り当てを外さないよう、コア01の占有を要求する(ステップS502)。ステップS502の後、タスク01は、占有したコア01に関連付けされた専用メモリ領域102(以下、仮に「専用メモリ領域01」と称する)に各種情報を出力可能となる。
The
以下においては、ライブラリ104が、専用メモリ領域01における管理情報領域201に保持された各種情報を確認し、係る確認結果に応じて所定の処理を実行する(ステップS503乃至ステップS508)。以下、それぞれの処理内容について説明する。
In the following, the
まず、ライブラリ104は、専用メモリ領域01に保持された情報がファイル出力部105によりファイル106へ出力中か否かを確認する(ステップS503)。より具体的には、ライブラリ104は、専用メモリ領域01における管理情報領域201のファイル出力中フラグ201cを確認することにより、専用メモリ領域01に保持された情報がファイル106へ出力中か否かを判定する。この場合、ライブラリ104は、例えば、ファイル出力フラグ201cに「ON」が設定されている場合はファイルへ出力中であると判定し、ファイル出力フラグ201cに「OFF」が設定されている場合はファイルへ出力中ではないと判断してもよい。
First, the
係る判定の結果、ファイル出力中の場合(ステップS504においてYES)、専用メモリ領域01に保持された情報をファイルに出力する処理が実行されているため、専用メモリ用域01に対するアクセスを避ける必要がある。即ち、係る専用メモリ01に対しては、上記タスク01の情報出力要求に係る情報を書き込む(出力する)ことができない。 As a result of the determination, if the file is being output (YES in step S504), the process of outputting the information held in the dedicated memory area 01 to the file is being executed, so it is necessary to avoid access to the dedicated memory area 01. is there. That is, information related to the information output request of the task 01 cannot be written (output) to the dedicated memory 01.
このため、ライブラリ104は、専用メモリ領域01以外の専用メモリ用域102(コア01以外のコア101に関連付けされた専用メモリ領域102)に、タスク01から出力する情報を書き込む必要がある。
For this reason, the
よって、この場合、ライブラリ104は、コア割り当て管理部108に対して、コア01以外のコアのタスク01に対する割り当てと占有を要求する(ステップS505)。また、ライブラリ104は、コア割り当て管理部108に対して、タスク01を実行しているコア01の占有を解除することを通知してもよい。その後、コア01以外のコア101が、スケジューラ107によってタスク01に割り当てられた場合、ライブラリ104は、ステップS504から処理を続行する。
Therefore, in this case, the
次に、ステップS503における確認の結果、ファイル出力中ではない場合(ステップS504においてNO)、ライブラリ104は、専用メモリ領域102における空き領域202bのサイズを確認する(ステップS506)。より具体的には、ライブラリ104は、専用メモリ領域01における空き領域サイズ201cを確認することにより、空き領域202bのサイズを確認する。
Next, as a result of the confirmation in step S503, when the file is not being output (NO in step S504), the
ステップS506における確認の結果、専用メモリ領域01における空き領域202bのサイズが、タスク01が出力を要求する情報のサイズと、ヘッダ情報301のサイズとの合計よりも小さい場合(ステップS507においてNO)、当該専用メモリ領域01は、タスク01が出力する情報を保持するだけの空き領域を提供できない。この場合、タスク01は当該専用メモリ領域01に対して情報を書き込む(出力する)ことができない。
As a result of the confirmation in step S506, if the size of the
このため、ライブラリ104は、ファイル出力部106に対して、専用メモリ領域01が保持する情報をファイルに出力するよう、ファイル出力要求処理(ステップS508)を実行する。
For this reason, the
以下、ステップS508におけるファイル出力要求処理につて、図6に例示するフローチャートを参照して説明する。 Hereinafter, the file output request process in step S508 will be described with reference to the flowchart illustrated in FIG.
まず、ライブラリ104は、ファイル出力部106以外の他のタスク103が、専用メモリ領域01にアクセスしないように、専用メモリ領域01におけるファイル出力中フラグ201bを設定(「ON」に設定)する(ステップS601)。
First, the
次に、ライブラリ104は、ファイル出力部106に対して、専用メモリ領域01が保持する情報(より具体的には、情報保持領域202に保持された情報)を、特定のファイル106に出力するよう要求する(ステップS602)。
Next, the
ライブラリ104が上記ステップS602を実行した場合、ファイル出力部106が専用メモリ領域01における情報保持領域202が保持するデータを、ファイルに出力する処理を実行する。よって、タスク01は専用メモリ領域01に情報を書き込む(出力する)ことができない。このため、ステップS508の後、ライブラリ01はステップS505から処理を続行し、タスク01に対してコア01以外のコア101の割り当てと、割り当てたコアの占有を要求する。その後、コア01以外のコア101が、スケジューラ107によってタスク01に割り当てられた場合、ライブラリ104は、ステップS504から処理を再度実行する。
When the
次に、ステップS506における確認の結果、専用メモリ領域01における空き領域202bのサイズが充分大きい場合(ステップS507においてYES)、タスク01は、ライブラリ104を介して、当該専用メモリ領域01の情報保持領域202に、任意の情報を書き込む(出力する)(ステップS509)。
Next, as a result of the confirmation in step S506, if the size of the
より具体的には、タスク01は、ライブラリ104が提供するインターフェイスを介して、任意の情報の書き込みを要求する。係る要求を受け付けたライブラリ104が、専用メモリ領域01の情報保持領域202に、タスク01から渡された情報を書き込む。
More specifically, the task 01 requests writing of arbitrary information through an interface provided by the
この際、ライブラリ104は、タスク01が書き込みを要求した情報(以下「出力情報」と称する場合がある)に対して、ヘッダ情報301を付加する。そして、ライブラリ104は、係るヘッダ情報と、タスク01からの出力情報とを、空き領域ポインタ201dが指定する位置に書き込む。
At this time, the
次に、ライブラリ104は、専用メモリ領域01における管理情報領域201を更新する(ステップS510)。より具体的には、ライブラリ104は、空き領域サイズ201cの値を更新し、空き領域ポインタ201dの位置を変更する。
Next, the
次に、ライブラリ104は、更新後の専用メモリ領域01における空き領域サイズ201cの値を確認する(ステップS511)。即ち、ライブラリ104は、タスク01からの上記出力情報を書き込んだ結果、専用メモリ領域01においてどの程度の領域が空き領域202bとして残存しているかを確認する。
Next, the
上記ステップS511における確認の結果、ライブラリ104が、所定の基準に基づいて空き領域のサイズが小さい判断した場合には(ステップS512においてNO)、上記ステップS508と同様、ライブラリ104は、ファイル出力要求処理を実行する(ステップS514)。係るファイル出力要求処理により、専用メモリ領域01が保持する各種情報がファイル106に書き出されることから、専用メモリ領域01における空き領域202bのサイズが大きくなる。上記ステップS514の処理を実行した後、ライブラリ104は、下記ステップS513から処理を続行する。
As a result of the confirmation in step S511, if the
次に、上記ステップS511における確認の結果、ライブラリ104が、所定の基準に基づいて空き領域のサイズが充分大きいと判断した場合には(ステップS512においてYES)、ライブラリ104は、コア割り当て管理部108に対して、コア01の占有を解除することを通知する(ステップS513)。上記ステップS513における処理の実行後、タスク01以外の他のタスク103が、コア01を使用可能となる。
Next, as a result of the confirmation in step S511, if the
なお、ステップS511において、専用メモリ領域01における空き領域202bのサイズが十分か否かを判断する基準は、例えば、マルチコアシステム100の特性等に応じて、適宜選択してよい。
In step S511, the criterion for determining whether the size of the
次に、コア割り当て管理部108の動作について説明する。
Next, the operation of the core
コア割り当て管理部108は、各タスク103に対して割り当て可能なコア101の情報を割り当て可能コア情報109として保持し、係る情報をスケジューラ107に提供する。なお、コア割り当て管理部108が、割り当て可能なコア101に関する情報を具体的にどのように保持するかは、適宜選択してよい。
The core
コア割り当て管理部108は、特定のタスク101(ライブラリ104)からコア101に対する占有要求を受け付けていない場合、マルチタスクシステム100において利用可能な全てのコア101を、割り当て可能コア情報108に登録する。
The core
コア割り当て管理部108は、特定のタスク101からの情報出力要求等に基づいて、ライブラリ104から特定のコア101を占有する要求(占有要求)を受け付けた場合(例えば、上記ステップS502、S505等)、当該占有要求の対象であるコア101に関する情報を当て可能コア情報109から削除する。
When the core
スケジューラ107は、割り当て可能コア情報109に基づいて、利用可能なコア101を各タスク103に対して割り当てるため、割り当て可能コア情報109から削除されたコア101は、他のタスクに割り当てられない。即ち、コア割り当て管理部108、及び、スケジューラ107は、上記占有要求を受け付けた場合に、当該占有要求の対象であるコア101が、上記占有要求を行った特定のタスク101(ライブラリ104)以外のタスクに割り当てられないように制御する。
Since the
これにより、情報出力要求を行った特定のタスク101は、明示的な排他制御を必要とせず、上記占有要求の対象であるコア101と、当該コアに関連付けされた専用メモリ領域102を独占的に使用することが可能である。
As a result, the
また、コア割り当て管理部108は、ライブラリ104から特定のコア101に対する占有解除要求を受信すると(例えば、上記ステップS505、S513等)、当該占有解除の要求において指定された特定のコア101を、割り当て可能コア情報109に登録する。これにより、スケジューラ107は当該コア101を他のタスク103に割り当てることが可能となる。
When the core
次に、図7に例示するフローチャートを参照して、ファイル出力部105の処理について説明する。
Next, processing of the
ファイル出力部105は、例えば、ライブラリ104からのファイル出力要求(図5に例示するステップS508、S514等)を待機する(ステップS701)。より具体的には、ファイル出力部105は、例えば、マルチコアシステム100における常駐型のタスクとして、係るファイル出力要求を待ち受けてもよい。
For example, the
次に、ファイル出力部105は、ファイル出力要求を受け付けたか確認し(ステップS702)、ファイル出力要求を受け付けていない場合(ステップS702においてNO)、再度ステップS701の待機処理を実行する。
Next, the
一方、ファイル出力要求を受け付けた場合(ステップS702においてYES)、当該ファイル出力要求において指定された特定のコア101(以下、仮に「コア02」とする)に関連付けされた専用メモリ領域102(以下、仮に「専用メモリ領域02」とする)に保持された情報を読み出す(ステップS703)。より具体的には、ファイル出力要求において指定されて専用メモリ領域02の管理情報領域201及び情報保持領域202を順次読み出す。 On the other hand, when the file output request is received (YES in step S702), the dedicated memory area 102 (hereinafter referred to as “core 02”) associated with the specific core 101 (hereinafter referred to as “core 02”) designated in the file output request. The information held in “dedicated memory area 02” is read (step S703). More specifically, the management information area 201 and the information holding area 202 of the dedicated memory area 02 specified in the file output request are sequentially read.
次に、ファイル出力部105は、上記ステップS703において読み出した情報を、ファイル106に出力する(ステップS704)。ファイル106に対する具体的な出力(書き込み)処理の方法は、周知の技術を採用してよいため、詳細な説明を省略する。
Next, the
ここで、ファイル出力部105が上記ステップS703乃至ステップS704の処理を実行する際、当該ファイル出力要求を通知したライブラリ104によって、専用メモリ領域02のファイル出力中フラグがONに設定される(図6におけるステップS601)。このため、他のタスク101との間で専用メモリ領域02へのアクセスが競合することがない。即ち、ファイル出力部105は、明示的な排他制御を必要とせず、専用メモリ領域02にアクセスすることが可能である。
Here, when the
次に、ファイル出力部105は、専用メモリ領域02が保持する情報の出力が完了した後、専用メモリ領域02の管理情報を初期化する(ステップS705)。より具体的には、ファイル出力部105は、専用メモリ領域02における管理情報領域201を初期化し、ファイル出力中フラグ201bを「OFF」に設定する。また、ファイル出力部105は、管理情報領域201とともに、情報保持領域202を初期化してもよい。
Next, after the output of the information held in the dedicated memory area 02 is completed, the
ステップS705における処理の後、ファイル出力部105はステップS701に戻って処理を続行し、更なるファイル出力要求を待機する。
After the process in step S705, the
本実施形態におけるファイル出力部105はタスク101の一種として実現されるため、上記ステップS701乃至ステップS705の処理は、ファイル処理部105に割り当てられたコア101により実行される。スケジューラ107は、ファイル出力部105に対して任意の利用可能なコア101を割り当ててよい。
Since the
なお、本実施形態においては、複数のファイル出力部105を並行して実行してもよい。この場合、複数の専用メモリ領域102について、係る専用メモリ領域102に保持されている情報が並行して複数のファイル106に出力される。このため、複数の専用メモリ領域102の空き容量を並行して増やすことが可能となり、利用可能な専用メモリ領域102をより速やかに用意することが可能である。
In the present embodiment, a plurality of
以上説明したように、本実施形態に係るマルチコアシステム100においては、1つのコア101は、ある瞬間においては1つのタスク103のみ実行可能である。また、特定の専用メモリ領域102には、当該特定の専用メモリ領域に関連付けされた1つの特定のコア101において実行されるタスク103のみがアクセス可能である。
As described above, in the
例えば、あるタスク103が情報出力要求を実行した場合、特定のコア101を占有して係る情報出力要求を処理することにより、他のタスク101は、当該特定のコア101に関連付けされた専用メモリ領域102にアクセスすることができない。これにより、複数のタスク103間の競合状態を回避可能である。
For example, when a
このため、上記説明したマルチコアシステム100によれば、複数のタスク103間において明示的な排他制御を実行する必要がなく、特定の専用メモリ領域102に対して速やかに情報を出力可能である。
For this reason, according to the
また、それぞれのタスク103は、いずれの専用メモリ領域102に情報を出力するかを認識する必要がない。即ち、特定の専用メモリ領域102に対して情報を出力できない場合(例えば、図5に例示するステップS504においてYESの場合や、ステップS507においてNOの場合等)、係るタスク自体を異なるコア101に割り当てることにより、異なる専用メモリ領域102に対して情報を出力可能である。即ち、記説明したマルチコアシステム100によれば、各タスク103は、特定の専用メモリ領域102の使用状況等に影響を受けることなく、情報出力処理を速やかに実行可能である。
Also, each
また、上記説明したマルチコアシステム100によれば、専用メモリ領域102として用意する必要がある記憶容量(サイズ)の合計は、タスク103からの出力要求の最大サイズにコア101の総数を乗じた値としてよい。コア101の総数は、タスク103の総数よりも少ない場合が多いため、全てのタスク103に対して専用の出漁領域を設ける場合に比べて、用意すべきメモリのサイズを抑えることが可能である。
Further, according to the
また、例えば、マルチコアシステム100全体の性能向上のために、マルチコアプロセッサ401を増設した場合であっても、増加したコア数分のメモリ領域を用意することにより、各タスク103、ライブラリ104等を修正することなく、情報出力処理を実行可能である。また、この場合において、コア101が増加しても、各タスク103は情報出力処理において明示的な排他制御を必要としないため、係る情報出力処理がマルチコアシステム100全体のボトルネックとなることはない。
In addition, for example, in order to improve the performance of the entire
以上より、本実施形態におけるマルチコアシステム100によれば、複数のタスク103がそれぞれ専用メモリ領域102に並行して任意の情報を出力することが可能である。
As described above, according to the
より具体的には、コア101毎に専用メモリ領域102を用意することで、複数のタスク103が、係るコア101毎の専用メモリ領域102に並行して任意の情報を出力することが可能である。これにより、複数のタスク103が、コア101毎に用意されたリソース(専用メモリ領域102)に対して並行してアクセスすることが可能な情報処理装置(マルチコアシステム100)を提供することが可能である。
More specifically, by preparing a
<第2の実施形態>
次に、本願発明の第2の実施形態について説明する。
<Second Embodiment>
Next, a second embodiment of the present invention will be described.
図8は、本実施形態に係る情報処理装置800の構成を概念的に例示するブロック図である。
FIG. 8 is a block diagram conceptually illustrating the configuration of the
本実施形態における情報処理装置800は、複数の演算処理部801(図8に例示する「演算部01」乃至「演算部04」等)と、専用メモリ領域802(図8に例示する「専用メモリ領域01」乃至「専用メモリ領域04」等)とを有する。なお、本実施形態における演算処理部801の数は、情報処理装置800に求められる性能等に応じて、適宜選択してよい。
The
また、本実施形態における情報処理装置800は、複数のタスク803と、リソースアクセス部804と、演算処理割り当て管理部807と、を有する。
In addition, the
上記演算処理部801は、1以上のタスク803を実行する、演算処理装置である。
The
上記専用メモリ領域802は、特定の上記演算処理部801に関連付けられ、当該演算処理部801において実行される上記タスク803から出力される各種情報を保持可能な、第1の記憶部である。
The
上記タスク803は、例えば、上記演算処理部801において実行可能なように実装された各種ソフトウェア・プログラム(コンピュータ・プログラム)である。
The
上記演算処理割り当て管理部807は、1以上のタスク803を、特定の上記演算処理部801に割り当てる。特定の演算処理装置801を割り当てられたタスク803は、当該演算書士装置801において実行される。
The arithmetic processing
上記リソースアクセス部804は、特定のタスク803が通知した専用メモリ領域802に対するアクセス要求を受け付け、上記演算処理割り当て管理部807に対して当該特定のタスク803を実行している演算処理部801の占有を要求すると共に、当該演算処理部801に関連付けされた専用メモリ領域802に対する上記アクセス要求を処理する。
The
本実施形態において、上記アクセス要求は、例えば、特定のタスク803から専用メモリ領域802に対して任意の情報を出力することを要求する、情報出力要求であってもよい。
In the present embodiment, the access request may be, for example, an information output request that requests that specific information be output from the
また、本実施形態における情報処理装置800は、第2記憶出力部805と、第2の記憶部806とを有してもよい。
In addition, the
この場合、第2記憶出力部805は、上記リソースアクセス部804からの要求に応じて、特定の専用メモリ領域802に保持された各種情報を、第2の記憶部806に出力してもよい。本実施形態において、第2の記憶部806は、例えば、ファイルやデータベース等、専用メモリ領域802に保持された各種情報を保持可能な記憶装置であってもよい。
In this case, the second
また、この場合、上記専用メモリ領域802は、該専用メモリ領域802が関連付けされた演算処理部801において実行されるタスク803、または、上記第2記憶出力部805からのアクセスのみを受け付けてもよい。
In this case, the
上記説明したマルチコアシステム800においては、特定の専用メモリ領域102には、当該特定の専用メモリ領域102に関連付けされた1つの特定のコア801のみがアクセス可能である。
In the
例えば、あるタスク803が情報出力要求を実行した場合、当該タスク803が特定のコア801を占有することにより、他のタスク801は、当該特定のコア801に関連付けされた専用メモリ領域802にアクセスすることができない。これにより、複数のタスク803間の競合状態を回避可能である。
For example, when a
このため、上記説明したマルチコアシステム800によれば、複数のタスク803間において明示的な排他制御を実行する必要がなく、特定の専用メモリ領域802に対して速やかに情報を出力可能である。
For this reason, according to the
以上より、本実施形態における情報処理装置800によれば、各コア801に専用の情報出力領域(専用メモリ領域802)を用意することで、複数のタスク803が互いに排他制御を行うことなく、並行して任意の情報を出力することが可能である。これにより、複数のタスク803が、演算処理装置801毎に用意されたリソース(専用メモリ領域802)に対して並行してアクセスすることが可能な情報処理装置800を提供することが可能である。
As described above, according to the
<ハードウェア及びソフトウェア・プログラム(コンピュータ・プログラム)の構成>
以下、上記説明した各実施形態における情報処理装置を実現可能なハードウェア及びソフトウェア・プログラムについて説明する。
<Configuration of hardware and software program (computer program)>
Hereinafter, hardware and software programs capable of realizing the information processing apparatus in each of the above-described embodiments will be described.
なお、以下の説明において、上記各実施形態において説明したマルチコアシステム100及び、情報処理処装置800をまとめて「情報処理装置等」と称する場合がある。
In the following description, the
上記各実施形態において説明した情報処理装置等の各構成要素は、それぞれの機能を実現する専用のハードウェア装置により構成してもよい。この場合、係る情報処理装置等の構成要素は、全ての機能を統合したハードウェア(処理ロジックを実装した集積回路等)として実現してもよく、特定の機能を実現する個別のハードウェアの組合せにより構成してもよい。 Each component such as the information processing apparatus described in each of the above embodiments may be configured by a dedicated hardware device that realizes each function. In this case, the components such as the information processing apparatus may be realized as hardware integrating all functions (such as an integrated circuit in which processing logic is mounted), or a combination of individual hardware realizing specific functions. You may comprise by.
また、係る情報処理装置等の構成要素は、図9に例示するようなハードウェアと、係るハードウェアによって実行される各種ソフトウェア・プログラム(コンピュータ・プログラム)とによって構成されもよい。なお、以下の説明において、図9に例示するハードウェアを、単に情報処理ハードウェアと称する場合がある。 In addition, the components such as the information processing apparatus may be configured by hardware as illustrated in FIG. 9 and various software programs (computer programs) executed by the hardware. In the following description, the hardware illustrated in FIG. 9 may be simply referred to as information processing hardware.
図9における演算装置901は、汎用のCPU(Central Processing Unit)やマイクロプロセッサ等の演算処理装置である。演算装置901は、例えば後述する不揮発性記憶装置903に記憶された各種ソフトウェア・プログラムを記憶装置902に読み出し、係るソフトウェア・プログラムに従って処理を実行してもよい。
The
図9に例示する具体例において、演算装置901は例えばマルチコアプロセッサ401に相当し、複数の演算処理部であるコアを有してもよい。
In the specific example illustrated in FIG. 9, the
記憶装置902は、演算装置901から参照可能な、RAM(Random Access Memory)等のメモリ装置であり、ソフトウェア・プログラムや各種データ等を記憶する。なお、記憶装置902は、揮発性のメモリ装置であってもよい。
The
また、記憶装置902は、1次記憶装置402に相当し、専用メモリ用域(102,802)を提供してもよい。
The
不揮発性記憶装置903は、例えば磁気ディスクドライブや、フラッシュメモリによる半導体記憶装置のような、不揮発性の記憶装置であり、各種ソフトウェア・プログラムやデータ等を記録してもよい。
The
また、不揮発性記憶装置903は、2次記憶装置403に相当し、ファイルシステムによって提供されるファイルや、データベース等を記憶してもよい。なお、不揮発性記憶装置903は、プログラム記憶領域404として、各種ソフトウェア・プログラム(コンピュータ・プログラム)を記憶してもよい。
The
ネットワークインターフェイス906は、各種通信ネットワークに接続可能なインターフェイス装置である。係るネットワークインターフェイス906としては、例えば、有線及び無線式のLAN(Local Area Network)接続用インターフェイス装置等を採用してもよい。
The
上記説明した各実施形態においては、例えば、ファイル106あるいは第2の記憶部806が、何らかの通信ネットワークにより接続された外部装置により提供される場合、ネットワークインターフェイス906を介して、各タスク(103,803)からの出力情報を当該外部装置に送信してもよい。
In each of the embodiments described above, for example, when the
外部記憶装置904は、例えば、後述する外部記憶媒体905に対するデータの読み込みや書き込みを処理する装置である。
The
外部記録媒体905は、例えば光ディスク、光磁気ディスク、半導体フラッシュメモリ等、データを記録可能な任意の記録媒体である。
The
上述した各実施形態を例に説明した本発明は、例えば、図9に例示した情報処理ハードウェアにより上記情報処理装置等を構成し、係る情報処理ハードウェアに対して、上記各実施形態の説明において参照したフローチャートの機能を実現可能なソフトウェア・プログラムを供給した後、そのソフトウェア・プログラムを、演算装置901が実行することによって達成されてもよい。
The present invention described by taking the above-described embodiments as examples, for example, configures the information processing apparatus and the like by the information processing hardware illustrated in FIG. After the software program capable of realizing the function of the flowchart referred to in the above is supplied, the software program may be executed by the execution of the
上述した各実施形態において、上記各図に示した各部(例えば、コア割り当て管理部(108、807)、ファイル出力部105、第2記憶出力部805、ライブラリ104、リソースアクセス部804、タスク(103、803)等)は、上述したハードウェアにより実行されるソフトウェア・プログラムとして実現可能である。
In each embodiment described above, each unit (for example, core allocation management unit (108, 807),
また、これらは、上述したハードウェアにより実行されるソフトウェア・プログラムの機能(処理)単位である、ソフトウェア・モジュールとして実現することも可能である。ただし、これらの図面に示した各部の区分けは、説明の便宜上の構成であり、実装に際しては、様々な構成が想定され得る。 These can also be realized as a software module, which is a function (processing) unit of a software program executed by the hardware described above. However, the division of each part shown in these drawings is a configuration for convenience of explanation, and various configurations can be assumed for mounting.
例えば、上記情報処理装置等を構成する各部をソフトウェア・プログラムとして実現する場合、これらのソフトウェア・プログラムを不揮発性記憶装置903に記憶しておき、演算装置901がそれぞれの処理を実行する際に、これらのソフトウェア・プログラムを記憶装置902に読み出すよう構成してもよい。
For example, when each unit constituting the information processing apparatus or the like is realized as a software program, the software program is stored in the
また、これらのソフトウェア・プログラム間は、共有メモリやプロセス間通信等の適宜の方法により、相互に各種データを伝達できるように構成してもよい。このような構成により、これらのソフトウェア・プログラム間は、相互に通信可能に接続可能である。 In addition, various kinds of data may be transmitted between these software programs by an appropriate method such as shared memory or interprocess communication. With such a configuration, these software programs can be connected so as to communicate with each other.
更に、上記各ソフトウェア・プログラムを外部記憶媒体905に記録しておき、上記通信装置等の出荷段階、あるいは、運用段階等において、適宜外部記憶装置904を通じて当該ソフトウェア・プログラムを不揮発性メモリ903に格納するよう構成してもよい。
Further, each software program is recorded in the
また、上記各実施形態における情報処理装置等の構成要素をソフトウェア・プログラムとして実現する場合、上記各実施形態において説明したファイル106や第2の記憶部806に出力される情報は、適切なデータ構造等を用いて、不揮発性記憶装置903に記憶してもよい。また、これらの情報は、任意のデータベース等に格納することにより、不揮発性記憶装置903に記憶してもよい。
Further, when the constituent elements such as the information processing apparatus in each of the above embodiments are realized as a software program, the information output to the
なお、上記各情報処理装置等への各種ソフトウェア・プログラムの供給方法は、出荷前の製造段階、あるいは、出荷後のメンテナンス段階等において、適当な治具を利用して当該装置内にインストールする方法や、インターネット等の通信回線を介して外部よりダウンロードする方法等のように、現在では一般的な手順を採用することができる。そして、このような場合において、本発明は、係るソフトウェア・プログラムを構成するコード、あるいは、係るコードが記録されたところの、コンピュータ読み取り可能な記憶媒体によって構成されると捉えることができる。 The method of supplying various software programs to each information processing apparatus is a method of installing in the apparatus using an appropriate jig at the manufacturing stage before shipment or the maintenance stage after shipment. A general procedure can be adopted at present, such as a method of downloading from the outside via a communication line such as the Internet. In such a case, the present invention can be understood to be constituted by a code constituting the software program or a computer-readable storage medium in which the code is recorded.
以上、本発明を、上述した模範的な実施形態に適用した例として説明した。しかしながら、本発明の技術的範囲は、上述した各実施形態に記載した範囲には限定されない。当業者には、係る実施形態に対して多様な変更、または、改良を加えることが可能であることは明らかである。そのような場合、係る変更、または、改良を加えた新たな実施形態も、本発明の技術的範囲に含まれ得る。そしてこのことは、特許請求の範囲に記載した事項から明らかである。 In the above, this invention was demonstrated as an example applied to exemplary embodiment mentioned above. However, the technical scope of the present invention is not limited to the scope described in the above embodiments. It will be apparent to those skilled in the art that various modifications or improvements can be made to such embodiments. In such a case, a new embodiment to which such changes or improvements are added can also be included in the technical scope of the present invention. This is clear from the matters described in the claims.
本発明は、複数のタスクが並行して動作すると共に、各タスクがそれぞれの処理結果等の情報を並行して出力する情報処理システム等に適用可能である。 The present invention can be applied to an information processing system or the like in which a plurality of tasks operate in parallel and each task outputs information such as a processing result in parallel.
100 マルチコアシステム
101 コア
102 専用メモリ領域
103 タスク
104 ライブラリ
105 ファイル出力部
106 ファイル
107 スケジューラ
108 コア割り当て管理部
109 割り当て可能コア情報
401 マルチコアプロセッサ
402 1次記憶装置
403 2次記憶装置
404 プログラム記憶領域
800 情報処理装置
801 演算処理部
802 専用メモリ領域
803 タスク
804 リソースアクセス部
805 第2記憶出力部
806 第2の記憶部
807 演算処理割り当て管理部
901 演算装置
902 記憶装置
903 不揮発性記憶装置
904 外部記憶装置
905 外部記録媒体
906 ネットワークインターフェイス
DESCRIPTION OF
Claims (10)
前記演算処理手段に関連付けされ、当該演算処理手段において実行される前記タスクから出力される情報を保持する第1の記憶手段である専用メモリ領域と、
前記タスクを前記演算処理手段に割り当てる演算処理割り当て管理手段と、
1以上の前記タスクの内、特定タスクに基づいて通知された前記専用メモリ領域に対するアクセス要求を受け付け、前記演算処理割り当て管理手段に対して前記特定タスクを実行している前記演算処理手段の占有を要求すると共に、当該演算処理手段に関連付けされた前記専用メモリ領域に対する前記アクセス要求を処理する、リソースアクセス手段と、を有することを特徴とする、情報処理装置。 A plurality of arithmetic processing means capable of executing one or more tasks;
A dedicated memory area which is a first storage means associated with the arithmetic processing means and holds information output from the task executed in the arithmetic processing means;
Arithmetic processing assignment managing means for assigning the task to the arithmetic processing means;
An access request to the dedicated memory area notified based on a specific task among one or more of the tasks is received, and the calculation processing means that is executing the specific task is assigned to the calculation processing allocation management means. An information processing apparatus comprising: resource access means for making a request and processing the access request for the dedicated memory area associated with the arithmetic processing means.
ることを要求する要求であることを特徴とする、
請求項1に記載の情報処理装置。 The access request is a request for requesting output of arbitrary information from the task to the dedicated memory area.
The information processing apparatus according to claim 1.
セス要求に応じて、前記演算処理割り当て管理手段に対して前記特定タスクを実行してい
る特定の前記演算処理手段の占有を要求した場合に、
前記演算処理割り当て管理手段は、前記要求に応じて、当該特定の前記演算処理手段に
対して、前記特定タスクとは異なる他のタスクの処理を割り当てないことを特徴とする、
請求項1または請求項2に記載の情報処理装置。 In response to an access request from the specific task to the dedicated memory area, the resource access unit requests the arithmetic processing allocation management unit to occupy the specific arithmetic processing unit that is executing the specific task. In case,
The arithmetic processing allocation management unit, in response to the request for the specific said arithmetic processing means, characterized in that it does not assign a process different from the task and the specific task,
The information processing apparatus according to claim 1 or 2.
前記特定タスクからの前記専用メモリ領域に対するアクセス要求を受け付けた場合にお
いて、当該アクセス要求において要求されたサイズのメモリ領域を、当該前記専用メモリ
領域が提供できない場合に、
前記演算処理割り当て管理手段に対して、当該アクセス要求に関連付けられた前記特定タスクを、前記特定タスクを実行している前記演算処理手段とは異なる前記演算処理手段へ割り当てることを要求することを特徴とする
請求項1乃至請求項3のいずれかに記載の情報処理装置。 The resource access means is:
When an access request for the dedicated memory area from the specific task is received, if the dedicated memory area cannot provide a memory area of the size requested in the access request,
Requesting the arithmetic processing assignment management means to assign the specific task associated with the access request to the arithmetic processing means different from the arithmetic processing means executing the specific task. The information processing apparatus according to any one of claims 1 to 3.
前記リソースアクセス手段からの要求に応じて、前記専用メモリ領域に保持された情報
を前記第2の記憶手段に出力すると共に、前記専用メモリ領域において当該出力した情報
に関連する領域を初期化する第2記憶出力手段と、を更に有することを特徴とする、
請求項1乃至請求項4のいずれかに記載の情報処理装置。 Second storage means capable of holding information held in the dedicated memory area;
In response to a request from the resource access means, the information stored in the dedicated memory area is output to the second storage means, and an area related to the output information is initialized in the dedicated memory area. And 2 memory output means,
The information processing apparatus according to any one of claims 1 to 4.
前記特定タスクからの前記専用メモリ領域に対するアクセス要求を受け付けた場合にお
いて、前記第2記憶出力手段が、当該専用メモリ領域に保持された情報を前記第2の記憶
手段に出力する処理を実行している場合に、
前記演算処理割り当て管理手段に対して、当該アクセス要求に関連付けられた前記特定タスクを、前記特定タスクを実行している前記演算処理手段とは異なる前記演算処理手段に割り当てることを要求することを特徴とする、請求項5に記載の情報処理装置。 The resource access means is:
When the access request to the dedicated memory area from the specific task is received, the second storage output unit executes a process of outputting the information held in the dedicated memory area to the second storage unit If
Requesting the arithmetic processing assignment management means to assign the specific task associated with the access request to the arithmetic processing means different from the arithmetic processing means executing the specific task. The information processing apparatus according to claim 5.
特定の前記専用メモリ領域における空き領域のサイズを確認し、所定の基準に基づいて
当該確認した空き領域のサイズが小さいと判断した場合に、
前記第2記憶出力手段に対して、当該特定の前記専用メモリ領域が保持する情報を、前
記第2の記憶手段に出力することを要求することを特徴とする、
請求項5に記載の情報処理装置。 The resource access means is:
When the size of the free area in the specific dedicated memory area is confirmed and it is determined that the size of the confirmed free area is small based on a predetermined criterion,
The second storage output unit is requested to output the information held in the specific dedicated memory area to the second storage unit,
The information processing apparatus according to claim 5.
演算処理手段において実行される前記タスク、または、前記第2記憶出力手段のみがアク
セス可能であることを特徴とする、
請求項5乃至請求項7の何れかに記載の情報処理装置。 The dedicated memory area in the storage means is accessible only by the task executed in the arithmetic processing means associated with the dedicated memory area, or the second storage output means,
The information processing apparatus according to claim 5 .
記憶手段である専用メモリ領域と、を有する情報処理装置が、
1以上の前記タスクを前記演算処理手段に割り当てる演算処理割り当て管理手段に対して、1以上の前記タスクの内、特定の前記タスクに基づいて通知された前記専用メモリ領域に対するアクセス要求を受け付けた場合に、当該特定の前記タスクを実行している前記演算処理手段の占有を要求し、
当該演算処理手段に関連付けされた前記専用メモリ領域に対する前記アクセス要求を処理する、ことを特徴とする、
情報処理装置におけるリソースアクセス方法。 A plurality of arithmetic processing means capable of executing one or more tasks, and a first information associated with the arithmetic processing means and holding information output from the task executed in the arithmetic processing means
An information processing apparatus having a dedicated memory area as storage means,
When an access request to the dedicated memory area notified based on a specific task among the one or more tasks is received with respect to the arithmetic processing allocation management unit that allocates one or more tasks to the arithmetic processing unit Requesting the occupation of the arithmetic processing means executing the specific task,
Processing the access request for the dedicated memory area associated with the arithmetic processing means;
A resource access method in an information processing apparatus.
1以上の前記タスクを前記演算処理手段に割り当てる演算処理割り当て管理手段に対し
て、1以上の前記タスクの内、特定の前記タスクに基づいて通知された前記専用メモリ領域に対するアクセス要求を受け付けた場合に、当該特定の前記タスクを実行している前記演算処理手段の占有を要求する処理と、
当該演算処理手段に関連付けされた前記専用メモリ領域に対する前記アクセス要求を実
行する処理と、を実行させることを特徴とする、
情報処理装置におけるリソースアクセスプログラム。 A plurality of arithmetic processing means capable of executing one or more tasks, and a dedicated memory which is associated with the arithmetic processing means and is a first storage means for holding information output from the task executed in the arithmetic processing means A computer having a region,
When an access request to the dedicated memory area notified based on a specific task among the one or more tasks is received with respect to the arithmetic processing allocation management unit that allocates one or more tasks to the arithmetic processing unit And processing for requesting occupation of the arithmetic processing means executing the specific task,
Executing the access request to the dedicated memory area associated with the arithmetic processing means,
A resource access program in an information processing apparatus.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014046447A JP6364827B2 (en) | 2014-03-10 | 2014-03-10 | Information processing apparatus, resource access method thereof, and resource access program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014046447A JP6364827B2 (en) | 2014-03-10 | 2014-03-10 | Information processing apparatus, resource access method thereof, and resource access program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2015170270A JP2015170270A (en) | 2015-09-28 |
JP6364827B2 true JP6364827B2 (en) | 2018-08-01 |
Family
ID=54202911
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2014046447A Active JP6364827B2 (en) | 2014-03-10 | 2014-03-10 | Information processing apparatus, resource access method thereof, and resource access program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6364827B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6817827B2 (en) * | 2017-01-23 | 2021-01-20 | Necプラットフォームズ株式会社 | Accelerator processing management device, host device, accelerator processing execution system, method and program |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP4606142B2 (en) * | 2004-12-01 | 2011-01-05 | 株式会社ソニー・コンピュータエンタテインメント | Scheduling method, scheduling apparatus, and multiprocessor system |
-
2014
- 2014-03-10 JP JP2014046447A patent/JP6364827B2/en active Active
Also Published As
Publication number | Publication date |
---|---|
JP2015170270A (en) | 2015-09-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8413158B2 (en) | Processor thread load balancing manager | |
US9378069B2 (en) | Lock spin wait operation for multi-threaded applications in a multi-core computing environment | |
CN111104208B (en) | Process scheduling management method, device, computer equipment and storage medium | |
US9229765B2 (en) | Guarantee real time processing of soft real-time operating system by instructing core to enter a waiting period prior to transferring a high priority task | |
US10013264B2 (en) | Affinity of virtual processor dispatching | |
US20130097382A1 (en) | Multi-core processor system, computer product, and control method | |
US9507633B2 (en) | Scheduling method and system | |
CN114138422B (en) | Scalable NVMe storage virtualization method and system | |
JP2018022345A (en) | Information processing system | |
WO2022001303A1 (en) | Lock management method, apparatus, and device | |
US10198365B2 (en) | Information processing system, method and medium | |
US20190286582A1 (en) | Method for processing client requests in a cluster system, a method and an apparatus for processing i/o according to the client requests | |
CN114116155A (en) | Lock-free work stealing thread scheduler | |
US10545890B2 (en) | Information processing device, information processing method, and program | |
US20180129532A1 (en) | Thread interrupt offload re-prioritization | |
JP5158576B2 (en) | I / O control system, I / O control method, and I / O control program | |
JP6364827B2 (en) | Information processing apparatus, resource access method thereof, and resource access program | |
US20130247065A1 (en) | Apparatus and method for executing multi-operating systems | |
US20140281343A1 (en) | Information processing apparatus, program, and memory area allocation method | |
WO2007049543A1 (en) | Calculating apparatus | |
US8566829B1 (en) | Cooperative multi-level scheduler for virtual engines | |
JP5847313B2 (en) | Information processing device | |
JP2009193260A (en) | Storage system, storage device, priority control device, and priority control method | |
JP7147531B2 (en) | Information processing device, memory initialization control method and program | |
JP2009211604A (en) | Information processing apparatus, information processing method, program, and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20170215 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20180228 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20180320 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20180516 |
|
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: 20180605 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20180618 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6364827 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |