JP5505195B2 - Memory control device and control method - Google Patents
Memory control device and control method Download PDFInfo
- Publication number
- JP5505195B2 JP5505195B2 JP2010184823A JP2010184823A JP5505195B2 JP 5505195 B2 JP5505195 B2 JP 5505195B2 JP 2010184823 A JP2010184823 A JP 2010184823A JP 2010184823 A JP2010184823 A JP 2010184823A JP 5505195 B2 JP5505195 B2 JP 5505195B2
- Authority
- JP
- Japan
- Prior art keywords
- memory
- stack
- power
- memory block
- block
- 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
Classifications
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Description
本願は、メモリの制御装置、及び制御方法を開示する。 The present application discloses a memory control device and a control method.
近年、コンピュータが備えるプロセッサやメモリ等のデバイスには、消費電力を削減するための各種機能が備わっている(例えば、特許文献1〜2を参照)。
In recent years, devices such as a processor and a memory included in a computer have various functions for reducing power consumption (see, for example,
コンピュータがLIFO(Last In First Out)方式でデータを取り扱う場合、コンピ
ュータのメモリには次のような種類の領域が発生する。第1の領域は、例えば、直ちにアクセスされる可能性がある特定のデータが格納されている領域である。第2の領域は、例えば、上記第1の領域へのアクセスが行なわれない限りアクセスされ得ない他のデータが格納されている領域である。第3の領域は、例えば、当面の間、データが格納され得ない領域である。
When a computer handles data by the LIFO (Last In First Out) method, the following types of areas are generated in the memory of the computer. The first area is, for example, an area in which specific data that may be accessed immediately is stored. The second area is, for example, an area in which other data that cannot be accessed unless the first area is accessed is stored. The third area is, for example, an area where data cannot be stored for the time being.
ところで、メモリの大容量化に伴い、データの格納状態によっては電力供給を必要としない領域における消費電力が無視できなくなりつつある。しかし、データの格納状態はプロセッサにおける処理の進捗に応じて時々刻々と変化していくため、メモリ内の各領域に必要な電力を適切に配分して省電力を実現することは難しい。 By the way, with an increase in memory capacity, power consumption in an area where no power supply is required cannot be ignored depending on the data storage state. However, since the data storage state changes every moment according to the progress of processing in the processor, it is difficult to realize power saving by appropriately allocating necessary power to each area in the memory.
そこで、本願は、データの格納状態に応じた消費電力の抑制が可能なメモリの制御装置、及び制御方法を提供することを課題とする。 Therefore, an object of the present application is to provide a memory control device and a control method capable of suppressing power consumption in accordance with a data storage state.
本願は、次のような装置を開示する。
スタックポインタによってスタックの基点から空き領域へ向けて後入れ先出し処理されるスタック内のデータを格納する複数のメモリブロックと、前記メモリブロックにそれぞれ独立に電力を供給可能な電力供給部と、を有するメモリ装置の、各メモリブロックの境界のアドレス情報を保持するアドレス情報保持部と、
前記各メモリブロックのうち、前記スタックポインタが示すアドレスが存在する特定のメモリブロック以外のメモリブロックに供給する電力を、前記特定のメモリブロックに供給する電力よりも抑制する電源制御部と、を備える、
メモリの制御装置。
The present application discloses the following apparatus.
A plurality of memory blocks for storing data in the stack that is processed in a first-in first-out manner from the base point of the stack toward the empty area by the stack pointer, and a power supply unit capable of independently supplying power to the memory block An address information holding unit for holding address information at the boundary of each memory block of the memory device;
A power control unit that suppresses power supplied to a memory block other than the specific memory block in which the address indicated by the stack pointer exists among the memory blocks, compared to the power supplied to the specific memory block. ,
Memory control device.
また、本願は、次のような方法を開示する。
スタックポインタによってスタックの基点から空き領域へ向けて後入れ先出し処理されるスタック内のデータを格納する複数のメモリブロックと、前記メモリブロックにそれぞれ独立に電力を供給可能な電力供給部と、を有するメモリ装置の、各メモリブロックの境界のアドレス情報を保持するアドレス情報保持部にアクセスし、
前記各メモリブロックのうち、前記スタックポインタが示すアドレスが存在する特定のメモリブロック以外のメモリブロックに供給する電力を、前記特定のメモリブロックに供
給する電力よりも抑制する、
メモリの制御方法。
Moreover, this application discloses the following methods.
A plurality of memory blocks for storing data in the stack that is processed in a first-in first-out manner from the base point of the stack toward the empty area by the stack pointer, and a power supply unit capable of independently supplying power to the memory block Access the address information holding unit that holds the address information of the boundary of each memory block of the memory device,
Among the memory blocks, the power supplied to the memory blocks other than the specific memory block where the address indicated by the stack pointer exists is suppressed from the power supplied to the specific memory block.
Memory control method.
データの格納状態に応じた消費電力の抑制が可能となる。 It is possible to suppress power consumption according to the data storage state.
メモリ制御装置の構成を図1に示す。メモリ制御装置1は、図1に示すように、CPU(Central Processing Unit)2とメモリ3を備えるコンピュータ4に内蔵されている。
なお、メモリ制御装置1は、メモリ3に内蔵されていてもよい。
The configuration of the memory control device is shown in FIG. As shown in FIG. 1, the
Note that the
メモリ制御装置1は、CPU2のレジスタ10に格納されるスタックポインタが示すアドレス(以下、SP値という)を取得し、メモリ3の電源モードを制御するモード制御部5と、メモリ3の各ブロックのアドレスの情報を保持するテーブル6とを備える。
The
モード制御部5は、CPU2のレジスタ10から取得したSP値を取得する取得部5A、取得部5Aが取得したSP値とテーブル6とを比較する比較部5B、及び比較部5Bの比較結果に基づいてメモリ3の電源モードを決定する決定部5Cを備える。モード制御部5は、メモリ3の電源モードが、決定部5Cが決定した電源モードになるように、メモリ3のセレクタ7を制御する。
The mode control unit 5 is based on an acquisition unit 5A that acquires the SP value acquired from the
なお、取得部5Aは、CPU2のレジスタ10にクロックサイクル毎にアクセスを行なうことでSP値を取得するものであってもよいし、SP値の変化を契機にレジスタ10にアクセスを行ない、SP値を取得するものであってもよい。取得部5Aは、SP値の変化
を契機にして動作する場合、SP値が変化した場合にCPU2から通知される信号をトリガにしてもよいし、或いは、レジスタ10のSP値が変化したことを検知する回路を別途に設けておき、この回路から通知される信号をトリガにしてもよい。比較部5Bや決定部5Cについても、取得部5Aと同様、比較処理や決定処理をクロックサイクル毎に繰り返すものであってもよいし、SP値の変化を契機に処理を実行するものであってもよい。
The acquisition unit 5A may acquire the SP value by accessing the
CPU2は、各種の演算を行うハードウェアであり、ALU(Arithmetic Logic Unit
)8やLSU(Load/Store Unit)9、レジスタ10、プログラムカウンタ11を備える
。
The CPU 2 is hardware that performs various operations, and is an ALU (Arithmetic Logic Unit).
) 8, LSU (Load / Store Unit) 9, a
メモリ3は、記憶保持動作が必要な揮発性メモリである。メモリ3は、m×n個のメモリセルがアレイ状に配置されたメモリセルアレイ12、及び各メモリセルへ供給する電力を制御するセレクタ7を備える。セレクタ7は、メモリ制御装置1からの指令に応じてスイッチ群13を制御し、メモリセルアレイ12の各ブロック14A〜Dを、動作用の電力を供給する電力線L1やデータ保持用の電力を供給する電力線L2に接続する。すなわち、メモリセルアレイ12は、ブロック毎に電源モードを制御可能なようになっている。各ブロック14A〜Dは、スタック用領域として使われる。なお、メモリ3には、スタック用のメモリ領域の他に、汎用のメモリ領域を有していてもよい。
The
各ブロック14A〜Dは、電力線L1から電力が供給されるとデータを読み書き可能な通常の動作状態(On)になり、電力線L2から電力が供給されると読み書き不能なデータ保持状態(Retention)になり、電力の供給が遮断されるとデータの読み書きのみならず
データの保持も不能な停止状態(Off)になる。消費電力については、通常の動作状態(On)での消費電力が最も大きく、データ保持状態(Retention)での消費電力が次に大きく、停止状態(Off)での消費電力が最も小さい。
Each of the
テーブル6は、図2に示すように、メモリセルアレイ12の各ブロック14A〜Dのアドレスの範囲(ブロックの境界のアドレス)、例えば、各ブロックの先頭のアドレスと末端のアドレスの情報を保持している。なお、図2において、第1〜4ブロックは、図1の符号14A〜Dにそれぞれ対応している。また、図2では、説明の便宜上、「ブロック名」の列を示しているが、テーブル6は「アドレス」の列を有していればよい。
As shown in FIG. 2, the table 6 holds the address range (block boundary address) of each
メモリ制御装置1が実行する処理を、図3の処理フロー図に沿って説明する。なお、本実施形態では、ハードウェアとしてのメモリ制御装置1をCPU2とは別にコンピュータ4内に設けているが、メモリ制御装置1が実行する処理はソフトウェアによりCPU2で実現されるものであってもよい。
The processing executed by the
コンピュータ4が起動すると、メモリ3には、図4に示すように、データを格納するスタック用のメモリ領域が確保される。このとき、スタックには未だデータが格納されていないため、SP値は、スタックの基点(図4におけるスタックの下端)となるアドレスを指している。なお、本願では、スタックの基点と反対側(データが蓄積されていく方向側)を終点とする(図4におけるスタックの上端)。
When the computer 4 is activated, a memory area for stacking data is secured in the
CPU2による処理によりスタックにデータが格納されると、SP値は、図5に示すように、格納されたデータのサイズ分だけ変更される。 When data is stored in the stack by processing by the CPU 2, the SP value is changed by the size of the stored data as shown in FIG.
ここで、モード制御部5は、CPU2のレジスタ10からSP値を取得する(S101)。このステップS101の処理は、取得部5Aがクロックサイクル毎に動作する場合にはSP値の変化の有無に関わらず繰り返し実行され、取得部5AがCPU2から通知される信号を契機に動作する場合にはこの信号を契機に実行される。
Here, the mode control unit 5 acquires the SP value from the
モード制御部5は、取得したSP値と図2のテーブルとの相関から、スタックポインタが示すアドレスが属するブロックを特定する。モード制御部5は、スタックポインタが示すアドレスが属するブロックに変更が無ければ、再びステップS101の処理を繰り返す(S102)。また、モード制御部5は、ブロックに変更があれば、セレクタ7を制御して各ブロック14A〜Dの電源モードを切り替える(S103)。
The mode control unit 5 identifies the block to which the address indicated by the stack pointer belongs from the correlation between the acquired SP value and the table of FIG. If there is no change in the block to which the address indicated by the stack pointer belongs, the mode control unit 5 repeats the process of step S101 again (S102). Further, if there is a change in the block, the mode control unit 5 controls the selector 7 to switch the power mode of each of the
CPU2による処理によりスタックにデータが更に格納され、スタックポインタが示すアドレスが属するブロックが、図6に示すように第1ブロックから第2ブロックへ変化したとする。この場合、モード制御部5は、SP値と図2のテーブルとの相関から、スタックポインタが示すアドレスが属するブロックが変更されたことを検知し、セレクタ7を制御して各ブロック14A〜Dの電源モードを切り替える(S103)。
Assume that data is further stored in the stack by processing by the CPU 2 and the block to which the address indicated by the stack pointer belongs has changed from the first block to the second block as shown in FIG. In this case, the mode control unit 5 detects that the block to which the address indicated by the stack pointer belongs has been changed from the correlation between the SP value and the table of FIG. 2, and controls the selector 7 to control each of the
図6に示す例では、スタックポインタが示すアドレスが存在するブロックが、第1ブロックから第2ブロックへ変化しているため、セレクタ7は、第1ブロックに接続する電力線を電力線L1から電力線L2へ切り替え、第2ブロックに電力線L1を接続する。これにより、第1ブロックの電源モードは通常の動作状態(On)からデータ保持状態(Retention)へ切り替わり、第2ブロックの電源モードは停止状態(Off)から通常の動作状態(On)へ切り替わる。なお、セレクタ7によるブロックの切り替えを開始してから第2ブロックが通常の動作状態(On)へ遷移してデータの書き込みが可能になるまでの間、モード制御部5からLSU9へWait信号が送られ、CPU2からメモリ3へ書き込まれるデータは、LSU9に保留される。
In the example shown in FIG. 6, since the block in which the address indicated by the stack pointer exists has changed from the first block to the second block, the selector 7 changes the power line connected to the first block from the power line L1 to the power line L2. Switching, the power line L1 is connected to the second block. As a result, the power mode of the first block is switched from the normal operation state (On) to the data retention state (Retention), and the power mode of the second block is switched from the stop state (Off) to the normal operation state (On). Note that the Wait signal is sent from the mode control unit 5 to the LSU 9 after the selector 7 starts switching the block until the second block transitions to the normal operation state (On) and data can be written. The data written from the CPU 2 to the
一方、CPU2による処理によりスタックのデータが取り出され、スタックポインタが示すアドレスが属するブロックが、図7に示すように第2ブロックから第1ブロックへ変化したとする。この場合、セレクタ7は、第2ブロックに接続されていた電力線L1を切断し、第2ブロックに接続する電力線をL2から電力線L1へ切り替える。これにより、第2ブロックの電源モードは通常の動作状態(On)から停止状態(Off)へ切り替わり、
第1ブロックの電源モードはデータ保持状態(Retention)から動作状態(On)へ切り替
わる。
On the other hand, it is assumed that the data of the stack is extracted by the processing by the CPU 2 and the block to which the address indicated by the stack pointer belongs changes from the second block to the first block as shown in FIG. In this case, the selector 7 disconnects the power line L1 connected to the second block, and switches the power line connected to the second block from L2 to the power line L1. As a result, the power mode of the second block is switched from the normal operation state (On) to the stop state (Off).
The power mode of the first block is switched from the data retention state (Retention) to the operation state (On).
メモリ制御装置1が各ブロックの電源を適切に制御することにより、メモリ3の消費電力が削減される。また、各ブロックの電源がメモリ制御装置1によって自動的に制御されているため、アプリケーションの作成者がメモリ3の電源制御について配慮しなくても、メモリ3の誤作動を誘発することなくメモリ3の消費電力を自動的に削減できる。なお、上記実施形態では、メモリ領域が4つのブロック14A〜Dに分割されているが、4ブロックに限定されるものではない。すなわち、スタック用のメモリ領域が複数の電源領域に分割されていれば如何なるブロック数に分割されていてもよい。
When the
上記実施形態の第一変形例について説明する。セレクタ7による電源モードの切り替えには時間を要するため、上記実施形態では、データがLSU9に保留される場合があった。しかし、モード制御部5がセレクタ7を以下のように制御すれば、データをスタックへシームレスに格納できる。 A first modification of the above embodiment will be described. Since it takes time to switch the power mode by the selector 7, in the above embodiment, data may be held in the LSU 9. However, if the mode control unit 5 controls the selector 7 as follows, data can be seamlessly stored in the stack.
本変形例では、スタックポインタが示すアドレスがブロックの境界に近づくと、モード制御部5がセレクタ7の制御を実行する。本変形例でモード制御部5が実行する処理フローを図8に示す。 In this modification, when the address indicated by the stack pointer approaches the block boundary, the mode control unit 5 executes the control of the selector 7. A processing flow executed by the mode control unit 5 in this modification is shown in FIG.
本変形例では、図9に示すような境界領域が各ブロックの境界付近に予め設定されており、モード制御部5は、SP値が境界領域の範囲内に入ると(S202)、隣接するブロ
ックを電力線L1に接続する(S203)。境界領域は、例えば、図2に示したテーブルに付加された情報によって特定されてもよいし、図2のテーブルが示す各ブロックの境界のアドレス値から既定のオフセット量を加算あるいは減算して特定されるものであってもよい。
In this modification, a boundary area as shown in FIG. 9 is set in the vicinity of the boundary of each block, and when the SP value falls within the boundary area (S202), the mode control unit 5 Is connected to the power line L1 (S203). The boundary region may be specified by, for example, information added to the table shown in FIG. 2, or specified by adding or subtracting a predetermined offset amount from the boundary address value of each block shown in the table of FIG. It may be done.
境界領域は、その大きさが大きいほどデータをよりシームレスに格納できるが、消費電力とトレードオフの関係にある。よって、境界領域の大きさは、CPU2が処理するデータ量やセレクタ7の処理速度に応じて適宜決定すればよい。 The larger the boundary area, the more seamlessly the data can be stored, but there is a trade-off relationship with power consumption. Therefore, the size of the boundary area may be appropriately determined according to the amount of data processed by the CPU 2 and the processing speed of the selector 7.
CPU2による処理によりスタックにデータが更に格納され、SP値が図10に示すように第1ブロックと第2ブロックとの間の境界領域を示しているとする。この場合、モード制御部5は、セレクタ7を制御して第2ブロックに電力線L1を接続し、第2ブロックの電源モードを停止状態(Off)から通常の動作状態(On)へ切り替える。これにより、
第1ブロックと第2ブロックの両方が通常の動作状態(On)になる。
It is assumed that data is further stored in the stack by the processing by the CPU 2 and the SP value indicates a boundary area between the first block and the second block as shown in FIG. In this case, the mode control unit 5 controls the selector 7 to connect the power line L1 to the second block, and switches the power mode of the second block from the stop state (Off) to the normal operation state (On). This
Both the first block and the second block are in a normal operation state (On).
CPU2による処理によりスタックにデータが更に格納され、SP値が図11に示すように境界領域を外れて第2ブロックを示したとする(S204)。この場合、スタックポインタが第2ブロックを示しているので(S205)、モード制御部5は、第1ブロックに電力線L2を接続し、第1ブロックの電源モードを通常の動作状態(On)からデータ保持状態(Retention)へ切り替える。 It is assumed that data is further stored in the stack by the processing by the CPU 2, and the SP value indicates the second block outside the boundary area as shown in FIG. 11 (S204). In this case, since the stack pointer indicates the second block (S205), the mode control unit 5 connects the power line L2 to the first block and changes the power mode of the first block from the normal operation state (On) to the data. Switch to Retention state.
一方、図10に示す状態から、CPU2による処理によりスタック領域のデータが消去され、SP値が図12に示すように境界領域を外れて第1ブロックを示したとする。この場合、モード制御部5は、第2ブロックを電力線L2から切り離し、第2ブロックの電源モードを通常の動作状態(On)から停止状態(Off)へ切り替える。 On the other hand, it is assumed that the data in the stack area is erased by the processing by the CPU 2 from the state shown in FIG. 10, and the SP value is out of the boundary area as shown in FIG. In this case, the mode control unit 5 disconnects the second block from the power line L2, and switches the power mode of the second block from the normal operation state (On) to the stop state (Off).
モード制御部5がセレクタ7を上記のように制御することにより、SP値が増減して各ブロックの電源モードが切り替わる場合でも、データをスタックへシームレスに格納できる。 By controlling the selector 7 as described above, the mode control unit 5 can seamlessly store data in the stack even when the SP value increases or decreases and the power mode of each block is switched.
上記実施形態の第二変形例について説明する。仮想記憶システムでは、論理アドレスと物理アドレスとの相関関係は一意に定まらず、起動時の条件等に応じて変化する。このため、何ら対策を施さない場合、スタック領域が物理アドレス上で何れの位置に確保されるか特定できない。 A second modification of the above embodiment will be described. In the virtual storage system, the correlation between the logical address and the physical address is not uniquely determined, and changes according to the conditions at the time of activation. For this reason, if no measures are taken, it is impossible to specify at which position the stack area is secured on the physical address.
一方、メモリ3の各ブロックは、実在の回路構成によって区画されており、図2のテーブルも物理アドレスを示している。そこで、仮想記憶システムにおいて上記のようなSP値に基づく電源制御を行う場合、コンピュータ4を以下のように変形する。
On the other hand, each block of the
すなわち、アプリケーションのスタックが、コンピュータ4のOS(Operating System)が形成する仮想記憶空間のうち上記各ブロックに対応する特定の仮想記憶空間に確保されるように、OSを予め規定する。例えば、OSが形成する仮想記憶空間のうちスタック用の空間の仮想アドレスについては、ブロック14A〜Dの物理アドレスに対応してマッピングする。また、OSが形成する仮想記憶空間のうち汎用のデータを格納する空間の仮想アドレスについてはメモリ3のうちブロック14A〜D以外の任意の領域の物理アドレスに対応してマッピングする。
That is, the OS is defined in advance so that the application stack is secured in a specific virtual storage space corresponding to each block in the virtual storage space formed by the OS (Operating System) of the computer 4. For example, the virtual address of the stack space in the virtual storage space formed by the OS is mapped corresponding to the physical addresses of the
このOSでは、アプリケーションが取り扱うデータのうちスタックに格納するデータについては、上記各ブロック14A〜Dに対応する特定の仮想記憶空間に格納される一方、スタックに格納しないデータについては仮想記憶空間のうち前記特定の仮想記憶空間以外
の空間に格納される。
In this OS, data stored in the stack among data handled by the application is stored in a specific virtual storage space corresponding to each of the
このように、スタックに格納するデータについては、仮想記憶空間のうちブロック14A〜Dに対応する特定の仮想記憶空間に格納されることにより、図13に示すように、スタックに格納するデータについてはブロック14A〜Dの物理記憶空間へ格納され、スタックに格納しないデータについてはその他の物理記憶空間へ格納されることになる。
As described above, the data stored in the stack is stored in a specific virtual storage space corresponding to the
レジスタ10が示すSP値は、物理アドレスを示しているため、メモリ制御装置1は、図2のテーブルが示す物理アドレスとレジスタ10のSP値とに基づいて各ブロック14A〜Dの電源モードを制御すれば、メモリ3の誤作動を誘発することなくメモリ3の消費電力を自動的に削減できる。
Since the SP value indicated by the
なお、アプリケーションが図14のように複数実行される場合、スタックに格納したデータは以下のように処理する。 When a plurality of applications are executed as shown in FIG. 14, the data stored in the stack is processed as follows.
複数のアプリケーションをタスクの切り替えによって並列に実行する場合に、OSが実行すべきスタックのデータの処理フローを図15に示す。ユーザ操作や入出力待ち等によってタスクの切り替えが発生すると、OSは、スタックに格納されているブロック14A〜Dのデータを他のメモリ領域へ移動させる(S301)。ここで、他のメモリ領域とは、スタックのデータを退避するための領域であり、データを退避可能であれば如何なる記憶媒体であってもよい。ブロック14A〜Dのデータを他のメモリ領域へ移動させる場合、ブロック14A〜DのうちSP値が示すアドレスよりも下側の全ての領域に対してデータの読み出しが行なわれるため、メモリ制御装置1は、SP値のアドレスが存在するブロックのみならず、データが格納されている全てのブロックの電源モードを通常の動作状態(On)にする。
FIG. 15 shows a processing flow of stack data to be executed by the OS when a plurality of applications are executed in parallel by switching tasks. When task switching occurs due to a user operation, input / output waiting, or the like, the OS moves the data of the
OSは、切り替え前のタスクのスタックを退避させると、次に、切り替え後のタスクのスタックのデータを他のメモリ領域から読み出し、ブロック14A〜Dに格納する(S302)。メモリ制御装置1は、切り替え後のタスクのスタックのデータがブロック14A〜Dに格納されると、次に、SP値のアドレスが存在するブロックの電源モードを通常の動作状態(On)にしたまま、他のブロックの電源モードを停止状態(Off)あるいはデー
タ保持状態(Retention)にする。
When the OS saves the task stack before switching, the OS next reads the stack data of the task after switching from other memory areas and stores them in the
複数のアプリケーションをタスクの切り替えによって並列に実行する場合、ブロック14A〜Dに格納されるスタックのデータを上記のように処理すれば、メモリ3の消費電力を削減しながら複数のアプリケーションを実行できる。
When a plurality of applications are executed in parallel by switching tasks, the plurality of applications can be executed while reducing the power consumption of the
なお、ブロック14A〜Dのようなスタック用のメモリ領域が、図16に示すように、コンピュータ4内に複数用意されている場合、各アプリケーションのスタックに格納したデータは以下のように処理される。
When a plurality of stack memory areas such as
各ブロックの電源モードを独立して切り替え可能なスタック用のメモリ領域が複数あり、複数のアプリケーションをタスクの切り替えによって並列に実行する場合にOSが実行すべきスタックのデータの処理フローを図17に示す。ユーザ操作等によってタスクの切り替えが発生すると、OSは、当該アプリケーションに対応するスタックがスタック用のメモリ領域A〜Cにあるか否かを判定する(S401)。肯定判定の場合には、何ら処理を行うことなくタスクを切り替える。 FIG. 17 shows a stack data processing flow to be executed by the OS when there are a plurality of stack memory areas in which the power mode of each block can be switched independently, and a plurality of applications are executed in parallel by switching tasks. Show. When task switching occurs due to a user operation or the like, the OS determines whether or not the stack corresponding to the application is in the stack memory areas A to C (S401). If the determination is affirmative, the task is switched without performing any processing.
一方、ステップS401の判定処理が否定判定だった場合、OSは、何れかのスタック用のメモリ領域A〜Cが空いているか否かを、各メモリ領域A〜CのSP値に基づいて判
定する(S402)。肯定判定の場合、OSは、新たなタスクのアプリケーションのスタックのデータを空いているメモリ領域に移動させる(S405)。
On the other hand, if the determination process in step S401 is negative, the OS determines whether any of the stack memory areas A to C is free based on the SP values of the memory areas A to C. (S402). If the determination is affirmative, the OS moves the application stack data of the new task to a free memory area (S405).
一方、ステップS402の判定処理が否定判定だった場合、OSは、消去すべきスタックを選択する(S403)。消去するスタックの優先順位は、例えば、タスクを選択する頻度やスタックに格納されているデータの大きさ等に基づいて決定する。 On the other hand, if the determination process in step S402 is negative, the OS selects a stack to be erased (S403). The priority of the stack to be erased is determined based on, for example, the frequency of selecting a task, the size of data stored in the stack, and the like.
OSは、ステップS403で選択した消去すべきスタックに格納されているデータを、他のメモリ領域へ移動させる(S404)。この場合、既述したステップS301と同様、メモリ制御装置1は、SP値のアドレスが存在するブロックのみならず、データが格納されている全てのブロックの電源モードを通常の動作状態(On)にする。
The OS moves the data stored in the stack to be erased selected in step S403 to another memory area (S404). In this case, as in step S301 described above, the
OSは、切り替え前のタスクのスタックを退避すると、次に、切り替え後のタスクのスタックのデータを他のメモリ領域から読み出し、ブロック14A〜Dに格納する(S405)。メモリ制御装置1は、既述したステップS302と同様、切り替え後のタスクのスタックのデータがブロック14A〜Dに格納されると、次に、SP値のアドレスが存在するブロックの電源モードを通常の動作状態(On)にしたまま、他のブロックの電源モードを停止状態(Off)あるいはデータ保持状態(Retention)にする。
When the OS saves the stack of the task before switching, the OS reads the data of the stack of the task after switching from another memory area and stores it in the
スタック用のメモリ領域が複数ある場合、各アプリケーションのスタックのデータを上記のように取り扱えば、メモリ3の消費電力を削減しながら複数のアプリケーションを実行しつつ、タスクの切り替えもシームレスに行うことができる。
When there are a plurality of stack memory areas, if the stack data of each application is handled as described above, tasks can be switched seamlessly while executing a plurality of applications while reducing the power consumption of the
なお、上記メモリ制御装置1は、例えば、図18に示すように、ディスプレイやNIC(Network Interface Card)、無線LAN、ハードディスクドライブ、或いはブルーレイ(登録商標)ディスクドライブ、DVDドライブ等の周辺機器15を備えるコンピュータに内蔵されていてもよい。また、上記メモリ制御装置1は、コンピュータ1に代わり、携帯電話やPDA、車載機器、サーバ装置等に適用されてもよい。
The
1・・メモリ制御装置
2・・CPU
3・・メモリ
4・・コンピュータ
5・・モード制御部
6・・テーブル
7・・セレクタ
14A〜D・・ブロック
1 ... Memory control device 2 ... CPU
3, memory 4, computer 5, mode control unit 6, table 7,
Claims (4)
前記各メモリブロックのうち、前記スタックポインタが示すアドレスが存在する特定のメモリブロック以外のメモリブロックに供給する電力を、前記特定のメモリブロックに供給する電力よりも抑制する電源制御部と、を備え、
前記電源制御部は、前記各メモリブロックのうち、前記特定のメモリブロックよりも前記基点側のメモリブロックに、データ保持用の電力を供給する、
メモリの制御装置。 A plurality of memory blocks for storing data in the stack that is processed in a first-in first-out manner from the base point of the stack toward the empty area by the stack pointer, and a power supply unit capable of independently supplying power to the memory block An address information holding unit for holding address information at the boundary of each memory block of the memory device;
A power control unit that suppresses power supplied to a memory block other than the specific memory block in which the address indicated by the stack pointer exists among the memory blocks, compared to the power supplied to the specific memory block. ,
The power supply controller supplies power for data retention to a memory block closer to the base point than the specific memory block among the memory blocks.
Memory control device.
請求項1に記載のメモリの制御装置。 The power supply control unit cuts off the power supplied to the memory block on the free area side from the specific memory block among the memory blocks.
The memory control device according to claim 1 .
請求項1または2に記載のメモリの制御装置。 When the stack pointer indicates an address within a predetermined range from the boundary of the specific memory block, the power control unit supplies power for operation to a memory block adjacent to the specific memory block across the boundary To
The memory control device according to claim 1 or 2 .
前記各メモリブロックのうち、前記スタックポインタが示すアドレスが存在する特定のメモリブロック以外のメモリブロックに供給する電力を、前記特定のメモリブロックに供給する電力よりも抑制し、
前記抑制の際は、前記各メモリブロックのうち、前記特定のメモリブロックよりも前記基点側のメモリブロックに、データ保持用の電力を供給する、
メモリの制御方法。 A plurality of memory blocks for storing data in the stack that is processed in a first-in first-out manner from the base point of the stack toward the empty area by the stack pointer, and a power supply unit capable of independently supplying power to the memory block Access the address information holding unit that holds the address information of the boundary of each memory block of the memory device,
Among the memory blocks, the power supplied to the memory blocks other than the specific memory block where the address indicated by the stack pointer exists is suppressed from the power supplied to the specific memory block ,
At the time of suppression, power for holding data is supplied to the memory block on the base point side of the specific memory block among the memory blocks.
Memory control method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010184823A JP5505195B2 (en) | 2010-08-20 | 2010-08-20 | Memory control device and control method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010184823A JP5505195B2 (en) | 2010-08-20 | 2010-08-20 | Memory control device and control method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2012043249A JP2012043249A (en) | 2012-03-01 |
JP5505195B2 true JP5505195B2 (en) | 2014-05-28 |
Family
ID=45899457
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2010184823A Expired - Fee Related JP5505195B2 (en) | 2010-08-20 | 2010-08-20 | Memory control device and control method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5505195B2 (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6003420B2 (en) * | 2012-09-06 | 2016-10-05 | 富士通株式会社 | Circuit system and semiconductor device |
US20160011649A1 (en) * | 2013-03-04 | 2016-01-14 | Nec Corporation | Electronic apparatus, power supply control method, and program |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH07200295A (en) * | 1993-12-28 | 1995-08-04 | Matsushita Electric Ind Co Ltd | Microprocessor, memory controller and computer system |
US7647481B2 (en) * | 2005-02-25 | 2010-01-12 | Qualcomm Incorporated | Reducing power by shutting down portions of a stacked register file |
US20080109670A1 (en) * | 2006-11-06 | 2008-05-08 | Reino Johansson | Power control for memories |
-
2010
- 2010-08-20 JP JP2010184823A patent/JP5505195B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2012043249A (en) | 2012-03-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN100487632C (en) | Dual media storage device | |
KR101744126B1 (en) | Techniques for cooperative execution between asymmetric processor cores | |
JP4281421B2 (en) | Information processing system, control method therefor, and computer program | |
US11188262B2 (en) | Memory system including a nonvolatile memory and a volatile memory, and processing method using the memory system | |
JP5053552B2 (en) | Data storage device having heterogeneous non-volatile memory and driving method thereof | |
JP4902501B2 (en) | Power control method, computer system, and program | |
EP2665065A2 (en) | Electronic device employing flash memory | |
KR20120112965A (en) | Nonvolatile memory device, data processing device using the same, and swapping method using them | |
KR20100132244A (en) | Memory system and method of managing memory system | |
JP5716537B2 (en) | Storage medium control device, storage device, storage medium control method, and program | |
WO2012159394A1 (en) | Method and apparatus for managing mobile device memory | |
US8914571B2 (en) | Scheduler for memory | |
US8583890B2 (en) | Disposition instructions for extended access commands | |
JP2018022345A (en) | Information processing system | |
CN103914325B (en) | Based on the shutdown of the linux system of mixing internal memory, starting-up method and system | |
KR101996641B1 (en) | Apparatus and method for memory overlay | |
US20120017052A1 (en) | Information Handling System Universal Memory Wear Leveling System and Method | |
JP5505195B2 (en) | Memory control device and control method | |
JP2016085677A (en) | Memory management method, memory management program, and information processing device | |
JP2008262451A (en) | Memory power supply management device and memory power supply management method | |
CN102467557B (en) | Data de-duplication processing method | |
WO2010070529A2 (en) | A method, apparatus and computer program for moving data in memory | |
CN101441551A (en) | Computer, external memory and method for processing data information in external memory | |
KR20140065196A (en) | Memory system and method for operating the same | |
JP5334048B2 (en) | Memory device and computer |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20130604 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20131127 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20131203 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20131218 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20140130 |
|
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: 20140218 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20140303 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5505195 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
LAPS | Cancellation because of no payment of annual fees |