JP2007102399A - Data processor - Google Patents
Data processor Download PDFInfo
- Publication number
- JP2007102399A JP2007102399A JP2005289679A JP2005289679A JP2007102399A JP 2007102399 A JP2007102399 A JP 2007102399A JP 2005289679 A JP2005289679 A JP 2005289679A JP 2005289679 A JP2005289679 A JP 2005289679A JP 2007102399 A JP2007102399 A JP 2007102399A
- Authority
- JP
- Japan
- Prior art keywords
- data processing
- task
- progress
- progress information
- execution
- 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.)
- Withdrawn
Links
Images
Landscapes
- Executing Machine-Instructions (AREA)
Abstract
Description
本発明は、電子データを汎用的に処理するデータ処理装置に係り、特にハードウェアとプロセッサ上で動作するソフトウェアとが共同してデータを処理するデータ処理装置に関する。 The present invention relates to a data processing apparatus that processes electronic data for general use, and more particularly, to a data processing apparatus in which hardware and software operating on a processor jointly process data.
現在、特定の処理を実行するハードウェア装置をプロセッサ等の制御装置によって制御する構成のデータ処理装置が広く使用されている。このようなデータ処理装置では、1つのプロセッサが複数のタスクを優先順位にしたがって実行し、この過程でタスクのうち比較的負荷が大きい処理をハードウェアに依頼する。
ハードウェアに処理を依頼した場合、このプロセッサは、この処理に係るタスクを中断して次に実行すべきタスクを実行する。ハードウェアは、依頼された処理の実行が終了すると、処理の終了をプロセッサに通知する。このとき、プロセッサは、実行中であった処理がハードウェアに依頼した処理よりも優先度が低い場合、実行中であった処理を中断する。そして、ハードウェアに依頼して処理が終了したタスクを必要に応じて引き続き実行する。
Currently, a data processing device having a configuration in which a hardware device that executes a specific process is controlled by a control device such as a processor is widely used. In such a data processing apparatus, one processor executes a plurality of tasks in accordance with the priority order, and requests a process having a relatively large load among the tasks in this process.
When processing is requested to the hardware, this processor interrupts the task related to this processing and executes the task to be executed next. When the execution of the requested process ends, the hardware notifies the processor of the end of the process. At this time, if the process being executed has a lower priority than the process requested to the hardware, the processor interrupts the process being executed. Then, the task that has been requested by the hardware and completed processing is continuously executed as necessary.
以上のプロセッサ及びハードウェアの動作において、ハードウェアからプロセッサに対して行われる処理終了の通知は、一般的に割込みが用いられる。従来のデータ処理装置の多くは、プロセッサに対する割込みをトリガとしてタスクを切替えている。このような従来技術としては、例えば、特許文献1が挙げられる。
しかしながら、特許文献1に記載された発明は、プロセッサがタスクを割込みのみをトリガとして切替えるため、実行中のタスクを中断するための処理を割込みがなされてから開始することになる。なお、タスクを中断するための処理とは、中断直前の処理内容を処理再開に備えて保存しておく処理をいうものとする。
また、特許文献1に記載された発明は、割込みがなされない限りタスクを順次実行するため、プロセッサに依頼した優先順位のよりタスクの処理が終了する直前であっても、優先順位のより低いタスクの実行が開始される。このような場合、特許文献1に記載された発明では、優先順位のより低いタスクの実行開始のために優先順位がより高いタスクの実行開始が遅れる可能性が生じる。
However, in the invention described in
In the invention described in
このような特許文献1は、タスク切替によるオーバーヘッドが大きく、タスク切替の処理効率をより高めることが望まれている。
本発明は、上記した点に鑑みてなされたものであり、プロセッサ上で実行されるソフトウェアと特定の処理に専用のハードウェアとが共同してタスクを実行するデータ処理装置のタスク切替の処理効率をより高めることを目的とする。
The present invention has been made in view of the above points, and the task switching processing efficiency of a data processing apparatus in which software executed on a processor and hardware dedicated to a specific process execute a task jointly The purpose is to further increase.
以上の課題を解決するため、本発明のデータ処理装置は、複数のタスクを、当該タスクの優先順位にしたがって順次実行する制御手段と、前記制御手段の指示によって電子データを処理するデータ処理実行手段と、を備えるデータ処理装置であって、前記データ処理実行手段は、実行される電子データの処理の進捗状況を示す進捗情報を記録する進捗情報記録手段を備え、前記制御手段は、前記進捗情報記録手段によって記録された進捗情報を認識する進捗状況認識手段を備え、前記進捗状況認識手段によって認識された進捗情報を含む情報に基づいてタスクを切替え、順次実行することを特徴とする。 In order to solve the above problems, a data processing apparatus according to the present invention includes a control unit that sequentially executes a plurality of tasks in accordance with the priority order of the tasks, and a data processing execution unit that processes electronic data in accordance with instructions from the control unit The data processing execution means includes progress information recording means for recording progress information indicating a progress status of processing of electronic data to be executed, and the control means includes the progress information. Progress status recognition means for recognizing the progress information recorded by the recording means is provided, and tasks are switched based on information including the progress information recognized by the progress status recognition means, and executed sequentially.
このような発明によれば、複数のタスクを優先順位にしたがって順次実行し、この過程でデータ処理実行手段にタスクの一部の処理を実行させることができる。また、データ処理実行手段によって実行される電子データの処理の進捗状況を示す進捗情報を記録し、制御手段に進捗情報を認識させることができるので、本実施形態のデータ処理装置は、制御手段がデータ処理実行手段の処理の進捗状況を把握し、状況に応じてタスクを切替えることができる。 According to such an invention, a plurality of tasks can be sequentially executed according to the priority order, and in this process, the data processing execution means can execute a part of the tasks. In addition, since the progress information indicating the progress status of the processing of the electronic data executed by the data processing execution means can be recorded and the control means can recognize the progress information, the data processing apparatus of the present embodiment has the control means The processing progress of the data processing execution means can be grasped, and tasks can be switched according to the situation.
このような本発明は、プロセッサ上で実行されるソフトウェアと特定の処理に専用のハードウェアとが共同してタスクを実行するデータ処理装置のタスク切替の処理効率をより高めることができる。
また、本発明のデータ処理装置は、前記制御手段が、タスクの実行順序を設定する実行順序設定手段を備え、前記実行順序設定手段は、前記進捗状況認識手段によって認識された進捗状況によって前記実行順序設定手段によって設定された実行順序を変更することを特徴とする。
Such an embodiment of the present invention can further improve the task switching processing efficiency of a data processing apparatus in which software executed on a processor and hardware dedicated to a specific process execute a task.
In the data processing apparatus of the present invention, the control means includes execution order setting means for setting an execution order of tasks, and the execution order setting means executes the execution according to the progress situation recognized by the progress situation recognition means. The execution order set by the order setting means is changed.
このような発明によれば、制御手段がタスクの実行順序を設定し、設定された実行順書を進捗状況認識手段によって認識された進捗状況によって変更することができる。
このような発明によれば、いったん設定されたタスクの実行順序をデータ処理装置における処理の進捗状況に応じて変更することが可能になり、処理の進捗状況に柔軟に対応してより処理効率の高い順序を設定することができる。
According to such an invention, the control means can set the task execution order, and the set execution order can be changed according to the progress situation recognized by the progress situation recognition means.
According to such an invention, it is possible to change the execution order of tasks once set according to the progress of processing in the data processing apparatus, and flexibly respond to the progress of processing, thereby improving the processing efficiency. High order can be set.
また、本発明のデータ処理装置は、前記進捗情報記録手段が前記データ処理実行手段内のレジスタに進捗情報を記録すると共に、前記進捗状況認識手段は、前記進捗情報記録手段に割り当てられたメモリマップ上の対応するアドレスを参照して進捗情報を認識することを特徴とする。
このような発明によれば、レジスタに進捗情報を記録し、記録された進捗情報を、レジスタに予め割り当てられたアドレスを参照することによって認識することができる。このため、進捗情報参照にかかる手順や時間を軽減し、変化する進捗情報をリアルタイムで参照しやすくすることができる。
In the data processing apparatus of the present invention, the progress information recording means records progress information in a register in the data processing execution means, and the progress status recognition means is a memory map assigned to the progress information recording means. The progress information is recognized by referring to the corresponding address above.
According to such an invention, the progress information can be recorded in the register, and the recorded progress information can be recognized by referring to the address previously assigned to the register. For this reason, it is possible to reduce the procedure and time for referring to the progress information, and to easily refer to the changing progress information in real time.
また、本発明のデータ処理装置は、前記進捗情報記録手段が、前記データ処理実行手段におけるデータ処理のうち残りのデータ処理にかかるサイクル数を進捗情報として記録することを特徴とする。
このような発明によれば、データ処理実行手段におけるデータ処理にかかる残り時間によってデータ処理の進捗状況を把握することができる。このため、設定された実行順序にしたがってタスクを実行するべきか、データ処理実行手段の処理を待ってタスクの実行を再開すべきかの判断を容易にすることができる。
In the data processing apparatus of the present invention, the progress information recording means records the number of cycles for the remaining data processing among the data processing in the data processing execution means as progress information.
According to such an invention, the progress status of the data processing can be grasped by the remaining time required for the data processing in the data processing execution means. For this reason, it is possible to easily determine whether the task should be executed according to the set execution order or whether the execution of the task should be resumed after waiting for the processing of the data processing execution means.
また、本発明のデータ処理装置は、前記進捗情報記録手段が、前記データ処理実行手段におけるデータ処理の残りが所定のデータ処理量であるしきい値以下であるか否かを判定し、しきい値以下であった場合、データ処理の残りがしきい値以下であることを示すフラグを進捗情報として記録することを特徴とする。
このような発明によれば、データ処理の残り量に基づいて判断する処理を省き、設定された実行順序にしたがってタスクを実行するべきか、データ処理実行手段の処理を待ってタスクの実行を再開すべきかの判断をいっそう容易にすることができる。
In the data processing apparatus of the present invention, the progress information recording unit determines whether or not the remaining data processing in the data processing execution unit is equal to or less than a threshold value that is a predetermined data processing amount, and a threshold value. When the value is less than or equal to the value, a flag indicating that the remaining data processing is less than or equal to the threshold value is recorded as progress information.
According to such an invention, it is possible to omit the determination based on the remaining amount of data processing and execute the task according to the set execution order, or wait for the processing of the data processing execution means to resume the execution of the task Judgment of what to do can be made easier.
また、本発明のデータ処理装置は、前記しきい値を記録すると共に、記録されたしきい値を変更することが可能なしきい値記録手段を備えることを特徴とする。
このような発明によれば、設定された実行順序にしたがってタスクを実行するべきか、データ処理実行手段の処理を待ってタスクの実行を再開すべきかを判断する基準をユーザのニーズやデータ処理の内容等に応じて変更することが可能になる。
The data processing apparatus of the present invention is characterized by comprising threshold recording means capable of recording the threshold and changing the recorded threshold.
According to such an invention, the criteria for determining whether the task should be executed according to the set execution order or whether the execution of the task should be resumed after waiting for the processing of the data processing execution means is determined based on the user needs and the data processing. It can be changed according to the contents.
以下、図を参照して本発明に係るデータ処理装置の一実施の形態を説明する。
図1は、本実施形態のデータ処理装置の構成を説明するための図である。本実施形態のデータ処理装置は、複数のタスクを、このタスクの優先順位にしたがって順次実行するCPU(Central Processing Unit)101と、CPU101の指示によって電子データ(以降単にデータ)を処理するハードウェア(HW)アクセラレータ103と、を備えるデータ処理装置である。図1中に示したメモリ102は、データ処理装置のタスクの実行に使用される命令や命令の実行に使用されるテーブルやデータ等を保存するための構成である。
Hereinafter, an embodiment of a data processing apparatus according to the present invention will be described with reference to the drawings.
FIG. 1 is a diagram for explaining the configuration of the data processing apparatus according to the present embodiment. The data processing apparatus according to the present embodiment includes a CPU (Central Processing Unit) 101 that sequentially executes a plurality of tasks according to the priority order of the tasks, and hardware (hereinafter simply referred to as data) that processes electronic data according to instructions from the
CPU101、メモリ102、HWアクセラレータ103は、互いにバスによって接続されている。また、本実施形態は、図1に示したように、HWアクセラレータ103を一つ備えるものに限定されるものではなく、複数のHWアクセラレータ103を備えるものであってもよい。このような場合、CPU101は、1つで複数のHWアクセラレータ103を制御するものであってもよいし、複数あってもよい。
The
CPU101は、複数のタスクを適正に順次実行するため、タスク管理テーブル108を備えている。タスク管理テーブル108の一例を、図2に示す。
図2に示したタスク管理テーブル108は、タスクA、タスクB、タスクCを含むタスクを管理するためのタスク管理テーブルである。タスク管理テーブル108は、各タスクのタスク名と、各タスクの進行状況を示すプログラムカウンタ(PC)、タスク実行時のプロセッサの状態や条件等を記録するプロセッサステートレジスタ(PSR)、スタックの位置を示すスタックポインタ(SP)、タスクの状態を示すスティト(State)、優先順位(priority)、実行中のタスクの処理内容(register file)、HWアクセラレータが複数ある場合の使用されているHWアクセラレータ、または唯一のHWアクセラレータの使用、不使用(HW)を管理する。
The
The task management table 108 illustrated in FIG. 2 is a task management table for managing tasks including task A, task B, and task C. The task management table 108 includes a task name of each task, a program counter (PC) indicating the progress of each task, a processor state register (PSR) that records a processor state and condition at the time of task execution, and a stack position. A stack pointer (SP) indicating a state of a task, a state indicating a state of the task, a priority (priority), a processing content of a task being executed (register file), an HW accelerator being used when there are a plurality of HW accelerators, or Manage the use and non-use (HW) of the only HW accelerator.
CPU101は、このようなタスク管理テーブル108を用い、複数のタスクの実行順序を設定する。CPU101とタスク管理テーブル108とは、本実施形態の実行順序設定手段として機能する。本実施形態でいう実行順序は、実行可能なタスクのタスク名をより早期に実行されるものから一列に列記して表される。また、この列を、以降レディキューとも記すものとする。
The
一方、HWアクセラレータ103は、タスクの実行にあたって比較的負荷の大きいデータの処理をするためのハードウェアである。このため、データ処理に使用される演算部106、CPU101の指示にしたがって演算部106を制御する制御部104を備えている。
制御部104は、カウンタあるいはステートマシンから成る。本実施形態のカウンタは、処理のサイクルをカウントする。ステートマシンは、処理のパラメータや設定等によって演算部106での処理を制御する。制御部104によれば、現在演算部106が実行している処理のサイクル数や状態を示すことができる。
On the other hand, the
The
また、HWアクセラレータ103は、ステータス信号生成部105及びステータスレジスタ107を備えている。ステータス信号生成部105は、HWアクセラレータ103によって得られる処理の残りサイクル数を示すステータス信号を生成する。ステータス信号は、HWステータス(progress_val)として残りのサイクル数を含む情報をステータスレジスタ107に書き込む信号である。図1に示した例では、HWアクセラレータ103によって実行されている処理の残りのサイクル数が30であることを示している。
The
このような制御部104、ステータス信号生成部105、ステータスレジスタ107は、実行される電子データの処理の進捗状況を示すHWステータス(進捗情報)を記録する進捗情報記録手段として機能する。
CPU101は、ステータスレジスタ107に書き込まれたHWステータスを認識し、認識されたHWステータスを含む情報に基づいてタスクを切替え、順次実行する。本実施形態のデータ処理装置は、HWステータスによってタスク管理テーブル108で設定された実行順序を変更することによってタスク切替えを実行する。なお、実行順序を変更する具体的な動作については後述する。また、本実施形態でいうHWステータスを含む情報とは、HWステータス及び各タスクの優先順位の情報である。
The
The
以上述べた構成において、CPU101は、HWアクセラレータ103をキックしてタスクに含まれる一の処理(HW依頼処理)の実行を指示する。HWアクセラレータ103は、指示されたHW依頼処理を実行する。この際、本実施形態では、制御部104がHW依頼処理の内容に基づいて処理の開始から終了までに必要なサイクル数を算出する。ステータス信号生成部105は、設定されたサイクル数をステータス信号によってステータスレジスタ107に書き込む。また、CPU101は、HWアクセラレータ103は、書き込まれたサイクル数を演算部106の処理の進捗に応じて更新する。
In the configuration described above, the
また、CPU101は、ステータスレジスタ107に記録されたHWステータスを認識することができる(矢線Aで示す)。本実施形態では、ステータスレジスタ107にHWステータスを書き込み、CPU101がメモリマップに割り当てられているステータスレジスタ107を参照することによってHWステータスの認識を可能にしている。
図3は、CPU101によって参照されるメモリマップの一例を示した図である。本実施形態では、メモリマップのうちHWステータスが書き込まれるアドレスの範囲を予め設定しておく。そして、CPU101が、タスクを終了するごとにメモリマップの設定された範囲のアドレスに書き込まれたデータを参照することによって処理の残りサイクル数を認識する。
Further, the
FIG. 3 is a diagram illustrating an example of a memory map referred to by the
このような構成により、CPU101は、比較的簡易にHWステータスを参照し、HWアクセラレータ103によって実行されている処理の状況を随時判定することができる。
一方、HWアクセラレータ103は、矢線Bで示すアクセスラインを有し、指示された処理の完了をCPU101に割込みとして通知することが可能である。
次に、以上述べた本実施形態のデータ処理装置の動作を説明する。この説明では、データ処理装置がタスクA、タスクB、タスクCの3つのタスクを実行するものとする。タスクA、タスクB、タスクCの優先順位は、タスクA>タスクB>タスクCである。
With such a configuration, the
On the other hand, the
Next, the operation of the data processing apparatus of this embodiment described above will be described. In this description, it is assumed that the data processing apparatus executes three tasks, task A, task B, and task C. The priority order of task A, task B, and task C is task A> task B> task C.
図4は、本実施形態のデータ処理装置の動作を説明するための図であって、実線は本実施形態のデータ処理装置の動作を、破線は比較のため記した従来技術の動作を示している。図4において、タスクA、タスクB、タスクCの文字の下に記した縦方向の矢線は、各タスクが実行されているタイミングを示している。また、OSの文字の下に記した縦方向の矢線は、CPU101においてOSが動作しているタイミングを、INTの文字の下に記した縦方向の矢線は、割込み及び割込みにかかる処理のタイミング示している。また、横方向の矢線は、各処理の遷移を示すものである。
FIG. 4 is a diagram for explaining the operation of the data processing apparatus according to the present embodiment. The solid line indicates the operation of the data processing apparatus according to the present embodiment, and the broken line indicates the operation of the prior art described for comparison. Yes. In FIG. 4, vertical arrows indicated below the characters of task A, task B, and task C indicate the timing at which each task is executed. The vertical arrow line below the OS character indicates the timing at which the OS is operating in the
なお、図4に示した縦方向の矢線の実線と破線とのずれは、両者を識別して認識しやすくするためのものであって、特に記載する箇所以外に両者に実質的な相違はない。
以下、本実施形態のデータ処理装置の動作と、従来の構成の動作とを対比して説明する。
Note that the deviation between the solid line and the broken line in the vertical direction of the arrow shown in FIG. 4 is for identifying and recognizing both, and there is no substantial difference between the two except for the parts described in particular. Absent.
Hereinafter, the operation of the data processing apparatus of the present embodiment will be described in comparison with the operation of the conventional configuration.
(本実施形態のデータ処理装置)
本実施形態のデータ処理装置は、先ず、CPU101が、最も優先順位の高いタスクAの実行を開始する。タスクAの実行中、CPU101は、HW依頼処理の実行をHWアクセラレータ103に指示する(S401)。このため、CPU101においては、実行されているタスクがOS(Operating System)に切替えられてディスパッチャが起動する。
(Data processing apparatus of this embodiment)
In the data processing apparatus of the present embodiment, first, the
図5は、上記したタスクAの実行中にHW依頼処理をするタスクプログラムを示した図である。HW依頼処理は、タスクAの実行中にCPU101がHWアクセラレータ103をコールする。そして、HW依頼処理に必要なパラメータを渡して処理の実行を指示するものである。
CPU101は、図2に示したタスク管理テーブルを参照し、HWアクセラレータ103の使用状況を確認する(S402)。そして、HWアクセラレータ103が使用可能な状態であった場合、CPU101上で動作するOSは、HWアクセラレータ103にHW依頼処理の実行を指示する(S403)。タスクAは、HW依頼処理の完了まで実行できない状態になる。このため、CPU101は、タスクAをレディキューから外す(S404)。
FIG. 5 is a diagram showing a task program that performs HW request processing during the execution of task A described above. In the HW request process, the
The
タスクAが実行できなくなったことにより、CPU101では、次のタスクを実行するためにディスパッチャが起動する(S405)。ここで、本実施形態のデータ処理装置は、OSがステータスレジスタ107に書き込まれているHWステータスを確認する(S406)。
本実施形態のHWステータスは、HW依頼処理に必要な残りのサイクル数で表されている。CPU101は、HWステータスを確認した結果、HWステータスが所定の数以上のサイクル数を示している場合、レディキューにおける次のタスクBを実行する(S407)。
Since the task A cannot be executed, the
The HW status of this embodiment is represented by the number of remaining cycles necessary for the HW request process. As a result of checking the HW status, the
CPU101においてタスクBの実行が終了すると、ディスパッチャが起動し(S408)、CPU101上でOSが動作する。OSは、ステータスレジスタ107に書き込まれているHWステータスを確認する(S409)。確認の結果、HWステータスが示すサイクル数が所定の数に満たない場合、タスクAが所定の時間以下の時間内に終了する。
HWステータスが示すサイクル数が所定の数に満たない場合、CPU101は、レディキューにおいてタスクBの次に実行すべきタスクCの優先度とタスクAの優先度とを比較する。タスクAの優先度は、タスクCの優先度よりも高い。このため、CPU101は、レディキューので設定された実行順序を変更し、タスクCを実行することなくタスクAをレディキューの先頭に追加する(S410)。
When the execution of task B is completed in the
When the number of cycles indicated by the HW status is less than the predetermined number, the
HW依頼処理が終了すると、HWアクセラレータ103は、割込みによってCPU101に処理の終了を通知する(S411)。本実施形態のデータ処理装置では、割込みがあったときタスクがすでにレディキューに追加されていて、しかもCPU101が他のタスクを実行していない。このため、速やかに割込みに伴う処理をしてタスクAの実行を開始することができる。
割込みに伴う処理が終了すると、CPU101上でOSが動作してディスパッチャが起動する(S412)。次に、CPU101は、レディキューにおいて先頭にあるタスクAを実行する(S413:図中に実行開始のタイミングをt1として記す)。
When the HW request process ends, the
When the process associated with the interrupt is completed, the OS operates on the
(従来の構成)
従来のデータ処理装置は、タスクAの処理の一部の実行をHWアクセラレータ103に依頼したことによってタスクAをレディキューから外した後にディスパッチャを起動する。そして、HWアクセラレータ103の処理状況によらず、レディキューにそってタスクB、タスクCを順次実行する。
(Conventional configuration)
The conventional data processing apparatus starts the dispatcher after removing the task A from the ready queue by requesting the
HWアクセラレータ103は、HW依頼処理を終了すると、割込みによってCPU101に処理の終了を通知する。このとき、CPU101は、タスクCの実行中であって、タスクCよりも優先度が高いタスクA実行することを決定する。このため、タスクAをレディキューの先頭に追加してディスパッチャを起動する。ディスパッチャにより、CPU101は、タスクCに替えてタスクAを実行する(図中に実行開始のタイミングをt2として記す)。
When completing the HW request process, the
このように、本実施形態のデータ処理装置は、タスクが終了した時点でHWアクセラレータ103におけるHW依頼処理の残りサイクル数を確認する点で従来の構成と相違する。また、HW依頼処理を含むタスクAの優先度がタスクCよりも高いことから、タスクCを実行することなくタスクAをレディキューに追加する。
このような処理によれば、本実施形態のデータ処理装置は、タスクの実行順序を変更し、HWアクセラレータ103による割込みに先んじてタスクAをレディキューに追加しておくことができる。また、割込みがなされた後にも、タスクCの実行を中断するためタスクCの処理中のデータをレジスタファイルに退避させる等の処理をすることなく、速やかにタスクAの実行の準備をすることができる。
As described above, the data processing apparatus according to the present embodiment is different from the conventional configuration in that the number of remaining cycles of the HW request processing in the
According to such processing, the data processing apparatus of the present embodiment can change the task execution order and add task A to the ready queue prior to the interruption by the
このため、本実施形態は、処理の一部の実行をHWアクセラレータ103に依頼したことによって中断されたタスクAの実行を、従来の構成よりも図中に示す差分d(タイミングt1とタイミングt2との差分)の時間だけ早く開始することができる。
なお、本実施形態のデータ処理装置は、以上述べた構成に限定されるものではない。すなわち、以上述べた実施形態では、HWアクセラレータ103によって実行されている処理の残りサイクル数を進捗情報として書き込んでいる。しかしながら、進捗情報は、残りサイクル数に限定されるものでなく、例えば、残りサイクル数に基づいてフラグ等を立てるものであってもよい。
For this reason, in the present embodiment, the execution of the task A interrupted by requesting the
Note that the data processing apparatus of the present embodiment is not limited to the configuration described above. That is, in the embodiment described above, the remaining number of cycles of the process executed by the
図6は、フラグを進捗情報としてHWステータスに使用したデータ処理装置の例を説明するための図であって、図6中に示した構成のうち、図1に示した構成と同一のものには同一の符号を付し、説明を一部省くものとする。
図示したデータ処理装置は、処理の残りサイクル数が記録されるステータスレジスタ107に代えて、フラグを立てる際のしきい値となるサイクル数(しきい値サイクル数:pre_done_cfg)が設定されるパラメータレジスタ608、残り処理数がしきい値サイクル数以下になった場合に立てられるフラグが書き込まれるステータスレジスタ607を備えている。
FIG. 6 is a diagram for explaining an example of a data processing apparatus that uses a flag as progress information for the HW status. Of the configurations shown in FIG. 6, the same configurations as those shown in FIG. Are given the same reference numerals, and a part of the explanation is omitted.
In the illustrated data processing apparatus, a parameter register in which a cycle number (threshold cycle number: pre_done_cfg) serving as a threshold for setting a flag is set instead of the
図6に示したデータ処理装置は、制御部104が、現在実行中のHW依頼処理のサイクル数をカウントすると共に残りサイクル数を算出する。さらに、制御部104は、算出された残りサイクル数をパラメータレジスタ608に書き込まれたしきい値サイクル数と比較する。そして、残りサイクル数がしきい値サイクル数以下になった場合ステータス信号生成部105に指示してステータスレジスタ607に「1」のフラグ(pre_done_flag)を書き込ませる。
In the data processing apparatus shown in FIG. 6, the
CPU101は、タスクが終了するとステータスレジスタ607を参照し、「1」のフラグが立ったことによってHWアクセラレータ103におけるHW依頼処理の終了が近いことを検出する。そして、HW依頼処理を含むタスクと、レディキューに設定されたタスクとの優先順位に応じてタスクの実行順序を変更する。
また、図6に示したデータ処理装置にあっても、CPU101は、メモリマップを参照することによってしきい値サイクル数やフラグといったHWステータスを認識する。
When the task is completed, the
Also in the data processing apparatus shown in FIG. 6, the
図7は、CPU101によって参照されるメモリマップの一例である。本実施形態では、メモリマップのうちHWステータスが書き込まれるアドレスの範囲を予め設定しておく。そして、CPU101が、タスクが終了するごとにメモリマップの設定された範囲のアドレスに書き込まれたデータを参照することによって処理の残りサイクル数を認識する。
また、本実施形態のデータ処理装置は、しきい値サイクル数を任意に設定可能に構成することも可能である。このような構成は、例えば、ユーザの要望やデータ処理装置が扱うデータの種別、HWアクセラレータの処理内容に応じてデータ処理装置が含まれる機器の出荷時に所望の設定値をパラメータレジスタ608に書き込むことによって実現できる。
FIG. 7 is an example of a memory map referred to by the
Further, the data processing apparatus of the present embodiment can be configured such that the number of threshold cycles can be arbitrarily set. In such a configuration, for example, a desired setting value is written in the
また、予め所定のしきい値を複数設定しておき、タスクのパラメータ等に応じてCPU101が設定を変更するものであってもよい。
なお、以上の構成では、しきい値サイクルの値を書き替え可能なパラメータレジスタ608がしきい値記録手段となる。
Alternatively, a plurality of predetermined threshold values may be set in advance, and the
In the above configuration, the
101 CPU、102 メモリ、103 HWアクセラレータ、104 制御部
105 ステータス信号生成部、106 演算部、107 ステータスレジスタ、108 タスク管理テーブル、607 ステータスレジスタ、608 パラメータレジスタ
101 CPU, 102 memory, 103 HW accelerator, 104
Claims (6)
前記制御手段の指示によって電子データを処理するデータ処理実行手段と、を備えるデータ処理装置であって、
前記データ処理実行手段は、
実行される電子データの処理の進捗状況を示す進捗情報を記録する進捗情報記録手段を備え、
前記制御手段は、
前記進捗情報記録手段によって記録された進捗情報を認識する進捗状況認識手段を備え、
前記進捗状況認識手段によって認識された進捗情報を含む情報に基づいてタスクを切替え、順次実行することを特徴とするデータ処理装置。 Control means for sequentially executing a plurality of tasks according to the priority order of the tasks;
A data processing device comprising: data processing execution means for processing electronic data according to an instruction from the control means;
The data processing execution means includes
A progress information recording means for recording progress information indicating a progress status of processing of electronic data to be executed;
The control means includes
Progress status recognition means for recognizing progress information recorded by the progress information recording means,
A data processing apparatus, wherein tasks are switched and executed sequentially based on information including progress information recognized by the progress status recognition means.
前記実行順序設定手段は、前記進捗状況認識手段によって認識された進捗状況によって前記実行順序設定手段によって設定された実行順序を変更することを特徴とする請求項1に記載のデータ処理装置。 The control means includes an execution order setting means for setting an execution order of tasks,
The data processing apparatus according to claim 1, wherein the execution order setting unit changes the execution order set by the execution order setting unit according to a progress situation recognized by the progress situation recognition unit.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005289679A JP2007102399A (en) | 2005-10-03 | 2005-10-03 | Data processor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005289679A JP2007102399A (en) | 2005-10-03 | 2005-10-03 | Data processor |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2007102399A true JP2007102399A (en) | 2007-04-19 |
Family
ID=38029298
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2005289679A Withdrawn JP2007102399A (en) | 2005-10-03 | 2005-10-03 | Data processor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2007102399A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2010205046A (en) * | 2009-03-04 | 2010-09-16 | Toyota Motor Corp | Information processing apparatus |
JP2014178801A (en) * | 2013-03-14 | 2014-09-25 | Juki Corp | Image processing apparatus and image processing method |
-
2005
- 2005-10-03 JP JP2005289679A patent/JP2007102399A/en not_active Withdrawn
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2010205046A (en) * | 2009-03-04 | 2010-09-16 | Toyota Motor Corp | Information processing apparatus |
JP2014178801A (en) * | 2013-03-14 | 2014-09-25 | Juki Corp | Image processing apparatus and image processing method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9727343B2 (en) | Apparatus and method for handling exception events | |
US7992042B2 (en) | Debug support device, and program for directing computer to perform debugging method | |
US6553487B1 (en) | Device and method for performing high-speed low overhead context switch | |
EP3754492A1 (en) | Interrupt system for risc-v architecture | |
US10824467B2 (en) | Data processing system with protected mode of operation for processing protected content | |
US9092255B2 (en) | Multi-core processor system, computer product, and control method for interrupt execution | |
JPH02267634A (en) | Interrupt system | |
JP2005276097A (en) | Interruption request program and microcomputer | |
JP4965638B2 (en) | System and method for controlling task switching | |
JP2007102399A (en) | Data processor | |
JP2006146758A (en) | Computer system | |
JP2004078683A (en) | Computer system and shared memory controlling method | |
JPH0916409A (en) | Microcomputer | |
JP2011108140A (en) | Data processor | |
JP2005258509A (en) | Storage device | |
JP2007109038A (en) | Data processor | |
JP2007109037A (en) | Data processor | |
JP2008140124A (en) | Data processor | |
JP2007241629A (en) | Information processor and program for making computer execute information processing method | |
JPH05313916A (en) | Electronic computer and its interruption processing method | |
JPH05233525A (en) | Input/otuput processor | |
JPH0486923A (en) | Task management controlling system | |
JPS61184644A (en) | Control system of virtual computer system | |
JP2003223334A (en) | Interruption processing method, os supporting system, information processor, and recording medium | |
JP2006146641A (en) | Multi-thread processor and multi-thread processor interruption method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20070405 |
|
A300 | Withdrawal of application because of no request for examination |
Free format text: JAPANESE INTERMEDIATE CODE: A300 Effective date: 20090106 |