JP2006309734A - Arithmetic processing unit and electronic device using arithmetic processing unit - Google Patents

Arithmetic processing unit and electronic device using arithmetic processing unit Download PDF

Info

Publication number
JP2006309734A
JP2006309734A JP2006085007A JP2006085007A JP2006309734A JP 2006309734 A JP2006309734 A JP 2006309734A JP 2006085007 A JP2006085007 A JP 2006085007A JP 2006085007 A JP2006085007 A JP 2006085007A JP 2006309734 A JP2006309734 A JP 2006309734A
Authority
JP
Japan
Prior art keywords
arithmetic processing
memory
cache
processing apparatus
hit rate
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.)
Granted
Application number
JP2006085007A
Other languages
Japanese (ja)
Other versions
JP4364878B2 (en
JP2006309734A5 (en
Inventor
Yoshimoto Kurokawa
義元 黒川
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Semiconductor Energy Laboratory Co Ltd
Original Assignee
Semiconductor Energy Laboratory Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Semiconductor Energy Laboratory Co Ltd filed Critical Semiconductor Energy Laboratory Co Ltd
Priority to JP2006085007A priority Critical patent/JP4364878B2/en
Publication of JP2006309734A publication Critical patent/JP2006309734A/en
Publication of JP2006309734A5 publication Critical patent/JP2006309734A5/ja
Application granted granted Critical
Publication of JP4364878B2 publication Critical patent/JP4364878B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • YGENERAL 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
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE 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/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a CPU which raises processing speed, and also realizes low power consumption simultaneously in a CPU mounted with a cache memory. <P>SOLUTION: In a CPU mounted with multiple sets of associative cache memory, the CPU is provided which has a means to monitor a cache memory area which does not contribute to improvement of processing performance of the CPU and can dynamically change it into an idle state according to the operating status. The CPU of high performance and low power consumption can be provided with such a configuration. <P>COPYRIGHT: (C)2007,JPO&INPIT

Description

本発明は、複数のセットからなる連想方式のキャッシュメモリを搭載した演算処理装置に関する。特に、動作状況に応じて、所定のセットを動作中に変更することのできる演算処理装置に関する。   The present invention relates to an arithmetic processing apparatus equipped with an associative cache memory composed of a plurality of sets. In particular, the present invention relates to an arithmetic processing device capable of changing a predetermined set during operation according to an operation state.

現在のCPU(Central Processing Unit:中央処理装置)に代表される演算処理装置では、ほぼ全てがストアドプログラム方式と呼ばれるアーキテクチャである。このストアドプログラム方式では、CPUが処理する命令及び処理に必要なデータは、メモリに格納されており、CPUの処理は、メモリのデータを順次読み出すことで進行する。そのため、CPUを搭載したシステムでは、メモリアクセス速度がシステム全体の性能を決定する上で非常に重要である。このような理由により、多くのCPUにおいて、キャッシュメモリが搭載されている。   Almost all arithmetic processing devices represented by the current CPU (Central Processing Unit) have an architecture called a stored program system. In this stored program method, instructions processed by the CPU and data necessary for the processing are stored in the memory, and the processing of the CPU proceeds by sequentially reading the data in the memory. Therefore, in a system equipped with a CPU, the memory access speed is very important for determining the performance of the entire system. For this reason, a cache memory is installed in many CPUs.

キャッシュメモリは、データの書き込みや読み出しが低速なメインメモリ(外部メモリ)の内容の一部をコピーして格納する高速なメモリである。なお、CPUが必要とするデータがキャッシュメモリに存在する場合をキャッシュヒットと言う。その反対、即ち、CPUが必要とするデータがキャッシュメモリに存在しない場合をキャッシュミスと言う。このようなキャッシュの性能については、非特許文献1を参照することができる。   The cache memory is a high-speed memory that copies and stores a part of the contents of the main memory (external memory) where data writing and reading are slow. A case where data required by the CPU exists in the cache memory is called a cache hit. On the contrary, the case where the data required by the CPU does not exist in the cache memory is called a cache miss. For such cache performance, Non-Patent Document 1 can be referred to.

キャッシュミス時には、低速なメインメモリへのアクセスが生じることになる。従って、キャッシュヒットの確率(キャッシュヒット率)が高い程、即ち、キャッシュミスの確率(キャッシュミス率)が低い程、CPUは高速に処理を行える。すなわち、CPUを搭載したシステムにおいて、システム全体の性能を高めることができる。
J.ヘネシー、D.パターソン共著、 コンピュータアーキテクチャ 日経BP社刊 第418、419頁
When a cache miss occurs, access to the low-speed main memory occurs. Therefore, the higher the cache hit probability (cache hit rate), that is, the lower the cache miss probability (cache miss rate), the faster the CPU can perform processing. That is, in a system equipped with a CPU, the performance of the entire system can be improved.
J. et al. Hennessy, D.C. Co-authored by Patterson, Computer Architecture, Nikkei Business Publications, 418, 419 pages

一般に、大容量のキャッシュメモリ程、キャッシュミスが少ない。そのため、キャッシュメモリ容量の増大によるCPUの処理速度向上が可能である。しかしながら、CPUにおいて、キャッシュメモリは最も消費電力が高いブロックの一つでもある。従って、容量を増大してCPUの処理速度を向上すると同時に、低消費電力も実現するキャッシュメモリが必要である。   Generally, a cache memory with a larger capacity has fewer cache misses. Therefore, the CPU processing speed can be improved by increasing the cache memory capacity. However, in the CPU, the cache memory is also one of the blocks with the highest power consumption. Therefore, there is a need for a cache memory that increases the capacity to improve the processing speed of the CPU and at the same time realizes low power consumption.

CPUのキャッシュメモリは、メインメモリからコピーする内容に対し、コピー元のアドレスもしくはその一部を格納するタグメモリと、当該アドレスに格納された内容をコピーするデータメモリと、から構成される。キャッシュメモリの読み出し動作時は、アドレスとタグメモリに格納されたデータ(タグデータ)との比較及びコピーしたデータ(コピーデータ)の読み出しが同時に行われる。ここで、アドレスとタグデータとが一致した場合がキャッシュヒットであり、読み出したコピーデータがCPUの処理に用いられる。一方、アドレスとタグデータとが不一致の場合がキャッシュミスであり、読み出したコピーデータは無効となり、メインメモリに再度アクセスしてCPUの処理に必要なデータを獲得することになる。   The cache memory of the CPU is composed of a tag memory for storing a copy source address or a part of the content copied from the main memory, and a data memory for copying the content stored at the address. During the read operation of the cache memory, the address is compared with the data (tag data) stored in the tag memory and the copied data (copy data) is read simultaneously. Here, the case where the address and the tag data match is a cache hit, and the read copy data is used for the processing of the CPU. On the other hand, when the address and the tag data do not match, a cache miss occurs, and the read copy data becomes invalid, and the main memory is accessed again to acquire data necessary for the CPU processing.

キャッシュメモリの代表的な構成としては、フルセット連想方式、ダイレクトマップ方式、nウェイセット連想方式などが挙げられる。以下、各々の方式について、簡単に説明する。   Typical configurations of the cache memory include a full set associative method, a direct map method, and an n-way set associative method. Each method will be briefly described below.

フルセット連想方式では、タグメモリにコピー元のアドレスの全ビットを格納しておく。キャッシュメモリの読み出し動作時には、タグメモリの全ての行(エントリ)のタグデータを読み出し、各々のタグデータとアドレスとを比較し、一致した場合に、該当するエントリのコピーデータを有効とする。メインメモリのどのアドレスからもデータをコピーできるが、キャッシュメモリの容量に応じて比較回路が複雑になるため、少数のエントリ、すなわち小容量のキャッシュメモリの場合に有効な方式である。   In the full set associative method, all bits of the copy source address are stored in the tag memory. During the read operation of the cache memory, the tag data of all the rows (entries) of the tag memory are read, and the respective tag data and addresses are compared. If they match, the copy data of the corresponding entry is validated. Although data can be copied from any address in the main memory, the comparison circuit becomes complicated depending on the capacity of the cache memory, so this is an effective system for a small number of entries, that is, a small capacity cache memory.

ダイレクトマップ方式では、タグメモリにメインメモリにおけるアドレスの一部のビットを格納する。通常はアドレスの上位ビットを格納する。また、格納できるタグメモリのエントリは、アドレスの下位ビットで指定される。キャッシュメモリの読み出し動作時には、アドレスの下位ビットで指定されるタグメモリのエントリからのみ読み出したタグデータと、アドレスの上位ビットとを比較し、一致した場合に、該当するエントリのコピーデータを有効とする。比較回路を簡単にできるが、下位ビットが同一となるアドレスへのアクセスが頻繁に行われる場合にはキャッシュヒット率が低下する。すなわち、CPUが必要とするデータに局所性がある場合に有効であり、大規模なプログラムを実行する場合には性能が低下する。   In the direct map method, some bits of the address in the main memory are stored in the tag memory. Normally, the upper bits of the address are stored. The tag memory entry that can be stored is specified by the lower bits of the address. When the cache memory is read, the tag data read only from the tag memory entry specified by the lower bit of the address is compared with the upper bit of the address, and if they match, the copy data of the corresponding entry is validated. To do. Although the comparison circuit can be simplified, the cache hit rate decreases when accesses to addresses having the same lower order bits are frequently performed. That is, it is effective when the data required by the CPU has locality, and the performance decreases when a large-scale program is executed.

nウェイセット連想方式は、タグメモリとデータメモリとを1組とするn(通常2、4、8)組のセットから構成される。いずれかのセットのタグメモリにメインメモリにおけるアドレスの一部のビットを格納する。通常はアドレスの上位ビットを格納する。また、格納できるタグメモリのエントリは、アドレスの下位ビットで指定される。キャッシュメモリの読み出し動作時には、全てのセットのタグメモリにおいて、アドレスの下位ビットで指定されるタグメモリのエントリからのみ読み出したタグデータと、アドレスの上位ビットとを各々比較し、一致した場合に、該当するセットにおけるエントリのコピーデータを有効とする。比較回路は若干複雑になるが、下位ビットが同一となるアドレスへのアクセスが頻繁に行われる場合にもキャッシュヒット率が低下しない。   The n-way set associative system is composed of a set of n (normally 2, 4, and 8) sets each including a tag memory and a data memory. Some bits of the address in the main memory are stored in either set of tag memories. Normally, the upper bits of the address are stored. The tag memory entry that can be stored is specified by the lower bits of the address. In the cache memory read operation, the tag data read only from the tag memory entry specified by the lower bit of the address is compared with the upper bits of the address in all sets of tag memories. Validate the copy data of the entry in the corresponding set. Although the comparison circuit is slightly complicated, the cache hit rate does not decrease even when accesses to addresses having the same low-order bits are frequently performed.

ここで、高性能なCPUのキャッシュメモリとして、一般に用いられている、nウェイセット連想方式のキャッシュメモリの詳細を示す。なお、簡単のため、2セットからなる連想方式のキャッシュメモリの概要を示す。   Here, details of an n-way set associative cache memory that is generally used as a cache memory of a high-performance CPU will be described. For the sake of simplicity, an outline of two sets of associative cache memories is shown.

キャッシュメモリの構成を図1に示す。ここで、キャッシュメモリ101は、第1のセット102、第2のセット103、タグ比較回路104及びデータ選択回路105から構成される。第1のセット102は、第1のタグメモリ106及び第1のデータメモリ107から構成される。第2のセット103は、第2のタグメモリ108及び第2のデータメモリ109から構成される。タグ比較回路104は、第1の比較回路110及び第2の比較回路111から構成される。   The configuration of the cache memory is shown in FIG. Here, the cache memory 101 includes a first set 102, a second set 103, a tag comparison circuit 104, and a data selection circuit 105. The first set 102 includes a first tag memory 106 and a first data memory 107. The second set 103 includes a second tag memory 108 and a second data memory 109. The tag comparison circuit 104 includes a first comparison circuit 110 and a second comparison circuit 111.

ここで、キャッシュメモリには、メインメモリにおける内容の一部のコピーが格納されているものとする。すなわち、メインメモリの特定のアドレスにおける内容に対し、アドレスの下位ビットで指定される第1のタグメモリ106または第2のタグメモリ108のいずれか一方のエントリに、アドレスの上位ビットが格納されている。   Here, it is assumed that a partial copy of the contents in the main memory is stored in the cache memory. That is, the upper bits of the address are stored in the entry of either the first tag memory 106 or the second tag memory 108 specified by the lower bits of the address for the contents at a specific address in the main memory. Yes.

さらに、アドレスの上位ビットが第1のタグメモリ106に格納されている場合には第1のデータメモリ107におけるアドレスの下位ビットで指定されるエントリに、また、第2のタグメモリ108に格納されている場合には第2のデータメモリ109におけるアドレスの下位ビットで指定されるエントリに、メインメモリの当該アドレスの内容(コピーデータ)が格納されているものとする。   Further, when the upper bit of the address is stored in the first tag memory 106, it is stored in the entry specified by the lower bit of the address in the first data memory 107 or in the second tag memory 108. In this case, it is assumed that the content (copy data) of the address in the main memory is stored in the entry specified by the lower bit of the address in the second data memory 109.

キャッシュメモリの動作を説明する。第1に、CPUが次に必要とするデータが格納されているメインメモリのアドレス112をキャッシュメモリが受け取る。   The operation of the cache memory will be described. First, the cache memory receives the address 112 of the main memory where the next data required by the CPU is stored.

第2に、アドレス112の上位ビット(アドレス上位ビット)113はタグ比較回路104に、アドレス112の下位ビット(アドレス下位ビット)114は第1のセット102及び第2のセット103に送られる。第1のセット102では、アドレス下位ビット114をデコードし、第1のタグメモリ106及び第1のデータメモリ107の各々該当するエントリに格納された第1のタグデータ115及び第1のコピーデータ116を出力する。同様に、第2のセット103から、第2のタグデータ117及び第2のコピーデータ118を出力する。   Secondly, the upper bit (address upper bit) 113 of the address 112 is sent to the tag comparison circuit 104, and the lower bit (address lower bit) 114 of the address 112 is sent to the first set 102 and the second set 103. In the first set 102, the lower address bits 114 are decoded, and the first tag data 115 and the first copy data 116 stored in the corresponding entries of the first tag memory 106 and the first data memory 107, respectively. Is output. Similarly, the second tag data 117 and the second copy data 118 are output from the second set 103.

第3に、第1の比較回路110において、アドレス上位ビット113と第1のタグデータ115とを比較し、第1のタグヒット信号119を出力する。ここで第1のタグヒット信号119は、一致の場合は”1”、不一致の場合は”0”とする。同様に、第2の比較回路111において、アドレス上位ビット113と第2のタグデータ117とを比較し、第2のタグヒット信号120を出力する。   Third, the first comparison circuit 110 compares the address upper bits 113 with the first tag data 115 and outputs a first tag hit signal 119. Here, the first tag hit signal 119 is “1” in the case of coincidence and “0” in the case of non-coincidence. Similarly, the second comparison circuit 111 compares the address upper bits 113 with the second tag data 117 and outputs a second tag hit signal 120.

最後に、データ選択回路105において、第1のタグヒット信号119が”1”の場合は第1のコピーデータ116を、第2のタグヒット信号120が”1”の場合は第2のコピーデータ118を、キャッシュデータ121として出力する。また、第1のタグヒット信号119または第2のタグヒット信号120のいずれかが”1”の場合に”1”となる、キャッシュヒット信号122を出力する。   Finally, in the data selection circuit 105, when the first tag hit signal 119 is “1”, the first copy data 116 is obtained. When the second tag hit signal 120 is “1”, the second copy data is obtained. 118 is output as the cache data 121. Further, a cache hit signal 122 that is “1” when either the first tag hit signal 119 or the second tag hit signal 120 is “1” is output.

CPUは、キャッシュヒット信号122が”1”の場合は、キャッシュデータ121を、メインメモリのアドレス112に格納されている内容と同一の有効データとして用いることができる。一方、キャッシュヒット信号122が”0”の場合は、キャッシュミスのため、メインメモリにアクセスし、必要なデータを取得する必要がある。   When the cache hit signal 122 is “1”, the CPU can use the cache data 121 as the same valid data as the contents stored at the address 112 of the main memory. On the other hand, when the cache hit signal 122 is “0”, it is necessary to access the main memory and acquire necessary data because of a cache miss.

このような2ウェイセット連想方式によるキャッシュメモリの場合、第1のコピーデータ116または第2のコピーデータ118の少なくとも一方は、常に使われないことになる。すなわち、読み出しに要した電流は常に無駄な消費電力として浪費されることになる。nウェイセット連想方式のキャッシュメモリでは、セット数が増加するにつれ、処理性能の向上と引き換えに、浪費される消費電力が増大することになる。   In the case of such a two-way set associative cache memory, at least one of the first copy data 116 and the second copy data 118 is not always used. That is, the current required for reading is always wasted as wasted power consumption. In an n-way set associative cache memory, as the number of sets increases, the consumed power increases in exchange for improved processing performance.

本発明は、上記の問題を鑑みなされたもので、nウェイセット連想方式のキャッシュメモリを搭載する演算処理装置において、動作状況に応じて、動作するセットを動的に変更することで、高性能且つ低消費電力の演算処理装置を提供する。本発明において、演算処理装置にはCPU及びDSP(Digital Signal Processor)が含まれる。   The present invention has been made in view of the above-described problems. In an arithmetic processing unit equipped with an n-way set associative cache memory, the operating set is dynamically changed in accordance with the operating state, thereby achieving high performance. An arithmetic processing unit with low power consumption is provided. In the present invention, the arithmetic processing device includes a CPU and a DSP (Digital Signal Processor).

本明細書で開示する本発明の構成は、連想方式のキャッシュメモリを搭載する演算処理装置であって、キャッシュメモリは、少なくとも1つのセットから構成され、セットは、各々データメモリと、タグメモリと、から構成され、各々動作状態及び停止状態の2つの状態間を遷移する手段を有し、演算処理装置は、キャッシュメモリへのアクセス回数と、キャッシュヒット回数と、各々のセットにおけるタグヒット回数と、アクセス回数でキャッシュヒット回数を除することで得られるキャッシュヒット率と、を任意の期間について計数する手段を有することを特徴とする。   The configuration of the present invention disclosed in the present specification is an arithmetic processing device equipped with an associative cache memory, and the cache memory is composed of at least one set, and each set includes a data memory, a tag memory, , Each having a means for transitioning between two states of an operation state and a stop state, and the arithmetic processing unit includes: the number of accesses to the cache memory; the number of cache hits; the number of tag hits in each set; And a means for counting the cache hit rate obtained by dividing the number of cache hits by the number of accesses for an arbitrary period.

上記構成において、演算処理装置は、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、動作状態にあるデータメモリとタグメモリの一方を停止状態に遷移させる手段を有しても良い。なお、本明細書中において、遷移とは可逆的な変化を含むものとする。具体的には、動作状態から停止状態への変化のみでなく、停止状態から動作状態への変化を含めて遷移というものとする。   In the above configuration, the arithmetic processing unit shifts one of the data memory and the tag memory in the operating state to the stopped state according to the result of comparing the cache hit rate and the reference value of the arbitrarily set hit rate. Means may be included. Note that in this specification, transition includes a reversible change. Specifically, the transition includes not only the change from the operating state to the stopped state but also the change from the stopped state to the operating state.

また、上記構成において、演算処理装置は、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、停止状態にあるデータメモリとタグメモリの一方を動作状態に遷移させる手段を有しても良い。   In the above configuration, the arithmetic processing unit sets one of the stopped data memory and the tag memory to the operating state according to the result of comparing the cache hit rate with the arbitrarily set hit rate reference value. Means for transition may be included.

また、上記構成において、演算処理装置は、任意に設定した時間の基準値で規定される時間毎に、動作状態にあるセットのうち少なくとも1つを停止状態に遷移させる手段を有しても良い。   In the above configuration, the arithmetic processing unit may include means for causing at least one of the sets in the operating state to transition to the stopped state for each time specified by an arbitrarily set time reference value. .

また、上記構成において、演算処理装置は、任意に設定した時間の基準値で規定される時間毎に、動作状態にあるセットのうちタグヒット回数が最も少ないセットを停止状態に遷移させる手段を有しても良い。   In the above configuration, the arithmetic processing unit has means for causing the set with the smallest number of tag hits among the sets in the operating state to transition to the stopped state for each time specified by the arbitrarily set time reference value. You may do it.

また、上記構成において、演算処理装置は、任意に設定した時間の基準値で規定される時間毎に、停止状態にあるセットのうち、少なくとも1つを動作状態に遷移させる手段を有しても良い。   Further, in the above configuration, the arithmetic processing unit may include means for causing at least one of the sets in the stopped state to transition to the operating state for each time defined by an arbitrarily set time reference value. good.

また、上記構成において、演算処理装置は、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、動作状態にあるセットのうち、タグヒット回数が最も少ないセットを停止状態に遷移させる手段を有しても良い。   In the above configuration, the arithmetic processing unit sets the smallest number of tag hits among the sets in the operating state according to the result of comparing the cache hit rate and the arbitrarily set hit rate reference value. There may be provided means for transitioning to a stop state.

上記構成において、演算処理装置は、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、動作状態にあるセットのうち、少なくとも1つを停止状態に遷移させる手段を有しても良い。   In the above configuration, the arithmetic processing unit causes at least one of the sets in the operating state to transition to the stopped state in accordance with the result of comparing the cache hit rate and the reference value of the arbitrarily set hit rate. Means may be included.

また、上記構成において、演算処理装置は、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、停止状態にあるセットのうち、少なくとも1つを動作状態に遷移させる手段を有しても良い。   In the above configuration, the arithmetic processing unit sets at least one of the sets in the stopped state to the operating state according to the result of comparing the cache hit rate and the arbitrarily set hit rate reference value. Means for transition may be included.

また、上記構成において、演算処理装置は、動作状態にあるセットを停止状態に遷移させる操作後に、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、操作において停止状態に遷移させたセットを再度動作状態に遷移させる手段を有することが望ましい。   Further, in the above configuration, the arithmetic processing unit performs an operation according to a result of comparing the cache hit rate with an arbitrarily set reference value of the hit rate after the operation of changing the set in the operating state to the stopped state. It is desirable to have means for transitioning the set that has been transitioned to the stop state in (1) to the operational state again.

また、上記構成において、演算処理装置は、停止状態にあるセットを動作状態に遷移させる操作後に、キャッシュヒット率と、任意に設定したヒット率の基準値と、を比較した結果に応じて、操作において動作状態に遷移させたセットを再度停止状態に遷移させる手段を有することが望ましい。   Further, in the above configuration, the arithmetic processing unit performs an operation according to a result of comparing the cache hit rate with an arbitrarily set reference value of the hit rate after the operation of changing the set in the stopped state to the operating state. It is desirable to have a means for transitioning the set that has been transitioned to the operating state in step 1 again to the stopped state.

また、上記構成において、演算処理装置は、動作状態にあるセットを停止状態に遷移させる操作、もしくは停止状態にあるセットを動作状態に遷移させる操作を、演算処理装置が実行する命令により制御する手段を有することが望ましい。   Further, in the above configuration, the arithmetic processing unit controls an operation for transitioning the set in the operating state to the stopped state, or an operation for transitioning the set in the stopped state to the operating state by an instruction executed by the arithmetic processing device. It is desirable to have

また、上記構成において、演算処理装置は、動作状態にあるセットを停止状態に遷移させる操作、もしくは停止状態にあるセットを動作状態に遷移させる操作を、演算処理装置に搭載された制御回路と、演算処理装置が実行する命令と、により制御する手段を有することが望ましい。   Further, in the above configuration, the arithmetic processing device performs an operation for transitioning the set in the operating state to the stopped state, or an operation for transitioning the set in the stopped state to the operating state, and a control circuit mounted on the arithmetic processing device; It is desirable to have a means for controlling by an instruction executed by the arithmetic processing unit.

また、上記構成において、演算処理装置は、時間の基準値や、ヒット率の基準値を、演算処理装置の動作中に変更する手段を有することが望ましい。   In the above configuration, it is desirable that the arithmetic processing device has means for changing the time reference value and the hit rate reference value during operation of the arithmetic processing device.

また、上記構成において、演算処理装置は、実行する各々のプログラムに適した時間の基準値や、ヒット率の基準値を決定する手段を有し、プログラムを次回以降実行する際には、基準値には、プログラムごとに適した値を用いることが望ましい。   In the above configuration, the arithmetic processing unit has means for determining a reference value for a time suitable for each program to be executed and a reference value for the hit rate. It is desirable to use a value suitable for each program.

本発明のより詳細な構成の一例は、データメモリとタグメモリを含む少なくとも1つのセットを有するキャッシュメモリと、計数回路と、レジスタと、を有し、計数回路は、任意の期間について、キャッシュメモリへのアクセス回数、キャッシュメモリのキャッシュヒット回数、タグメモリにおけるタグヒット回数、及びアクセス回数でキャッシュヒット回数を除することにより得られるキャッシュヒット率を計数し、レジスタによって、データメモリ又はタグメモリの一方を、動作状態または停止状態に遷移させることを特徴とする。
すなわち、キャッシュヒット率と、第1のヒット率の基準値との比較結果に応じて、前記データメモリ又は前記タグメモリの一方を、動作状態から停止状態に遷移させる。
レジスタによって、第1の時間の基準値毎に、データメモリ又はタグメモリの一方を、動作状態から停止状態に遷移させる構成としてもよい。
An example of a more detailed configuration of the present invention includes a cache memory having at least one set including a data memory and a tag memory, a counting circuit, and a register. The number of accesses to the cache, the number of cache hits in the cache memory, the number of tag hits in the tag memory, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses are counted. Is shifted to an operating state or a stopped state.
That is, one of the data memory and the tag memory is changed from the operating state to the stopped state according to the comparison result between the cache hit rate and the reference value of the first hit rate.
A configuration may be adopted in which one of the data memory and the tag memory is changed from the operating state to the stopped state for each first time reference value by the register.

本発明のより詳細な構成の他の例は、データメモリとタグメモリをそれぞれ含む複数のセットを有するキャッシュメモリと、計数回路と、レジスタと、を有し、計数回路は、任意の期間について、前記キャッシュメモリへのアクセス回数、キャッシュメモリのキャッシュヒット回数、複数のセットの少なくとも1つのセットのタグメモリにおけるタグヒット回数、及びアクセス回数でキャッシュヒット回数を除することにより得られるキャッシュヒット率を計数し、レジスタによって、少なくとも1つのセットを、動作状態または停止状態に遷移させることを特徴とする。
すなわち、キャッシュヒット率と、第1のヒット率の基準値との比較結果に応じて、少なくとも1つのセットを、動作状態から停止状態に遷移させる。
レジスタによって、第1の時間の基準値毎に、少なくとも1つのセットを、動作状態から停止状態に遷移させる構成としてもよい。また、第1の時間の基準値毎に、少なくとも1つのセットのうちタグヒット回数が最も少ないセットを、動作状態から停止状態に遷移させる構成としても良い。
Another example of a more detailed configuration of the present invention includes a cache memory having a plurality of sets each including a data memory and a tag memory, a counting circuit, and a register. Counts the number of accesses to the cache memory, the number of cache hits in the cache memory, the number of tag hits in the tag memory of at least one set of a plurality of sets, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses The at least one set is transited to an operating state or a stopped state by a register.
That is, at least one set is changed from the operating state to the stopped state according to the comparison result between the cache hit rate and the reference value of the first hit rate.
A configuration may be adopted in which at least one set is changed from the operating state to the stopped state for each reference value of the first time by the register. Further, for each reference value for the first time, a set with the smallest number of tag hits out of at least one set may be changed from the operating state to the stopped state.

なお、動作状態及び停止状態の2つの状態間を遷移する手段としては、例えば、計数回路や、条件判別回路、レジスタ等を有するセット制御回路が挙げられる。より具体的には、セット制御回路からのセット制御信号によって、動作状態及び停止状態を遷移させることができる。また、時間の基準値やヒット率の基準値の変更は、演算処理装置がレジスタの値を書き換えることにより行われる。実行するプログラムごとに適した基準値を用いることが好ましい。   Note that examples of means for transitioning between the two states of the operation state and the stop state include a set control circuit having a counting circuit, a condition determination circuit, a register, and the like. More specifically, the operation state and the stop state can be changed by a set control signal from the set control circuit. Further, the time reference value and the hit rate reference value are changed by rewriting the register value by the arithmetic processing unit. It is preferable to use a reference value suitable for each program to be executed.

また、上記構成において、停止状態とは、データメモリ及びタグメモリに格納されているデータを読み出す時に行うプリチャージ動作を行わない状態としても良い。また、上記構成において、停止状態とは、データメモリ及びタグメモリに電源電圧を供給しない状態としても良い。   In the above configuration, the stopped state may be a state in which the precharge operation that is performed when data stored in the data memory and the tag memory is read is not performed. In the above configuration, the stopped state may be a state in which the power supply voltage is not supplied to the data memory and the tag memory.

また、上記構成において、演算処理装置は、薄膜トランジスタにより構成されており、薄膜トランジスタは、絶縁表面を有する基板上に形成された半導体薄膜を活性層として用いており、絶縁表面を有する基板は、ガラス基板、石英基板、プラスチック基板、SOI基板のいずれかとしても良い。   In the above structure, the arithmetic processing unit includes a thin film transistor. The thin film transistor uses a semiconductor thin film formed over a substrate having an insulating surface as an active layer. The substrate having an insulating surface is a glass substrate. Further, any of a quartz substrate, a plastic substrate, and an SOI substrate may be used.

また、上記構成からなるCPUを電子機器に組み込む事が有効である。   It is also effective to incorporate the CPU having the above configuration into an electronic device.

本発明により、連想方式のキャッシュメモリにおいて、演算処理装置が実行するプログラムに応じて、演算処理装置の処理性能向上に寄与しないキャッシュメモリ領域を監視し、動的に適宜停止状態とすることができる。すなわち、演算処理装置の処理性能を保ったまま、キャッシュメモリからのデータ読み出しによる無駄な消費電力を低減することが可能である。このような、連想方式のキャッシュメモリを搭載することで、高性能且つ低消費電力のCPUを提供することができる。   According to the present invention, in an associative cache memory, it is possible to monitor a cache memory area that does not contribute to an improvement in processing performance of an arithmetic processing device and dynamically make it stop appropriately according to a program executed by the arithmetic processing device. . That is, it is possible to reduce wasteful power consumption due to data reading from the cache memory while maintaining the processing performance of the arithmetic processing unit. By mounting such an associative cache memory, a high performance and low power consumption CPU can be provided.

以下、本発明の実施の形態及び実施例について、図面を用いて説明する。但し、本発明は多くの異なる態様で実施することが可能であり、本発明の趣旨及びその範囲から逸脱することなくその形態及び詳細を様々に変更し得ることは当業者であれば容易に理解される。従って、本実施の形態及び実施例の記載内容に限定して解釈されるものではない。   Hereinafter, embodiments and examples of the present invention will be described with reference to the drawings. However, the present invention can be implemented in many different modes, and those skilled in the art can easily understand that the modes and details can be variously changed without departing from the spirit and scope of the present invention. Is done. Therefore, the present invention is not construed as being limited to the description of the embodiments and examples.

以下に、本発明の実施の形態について、図2及び図3を用いて説明する。   Hereinafter, embodiments of the present invention will be described with reference to FIGS.

なお、実施の形態及び実施例を説明するための全図において、同一部分又は同様な機能を有する部分には同一の符号を付し、その繰り返しの説明は省略する。   Note that the same portions or portions having similar functions are denoted by the same reference symbols throughout the drawings for describing the embodiments and examples, and the repetitive description thereof is omitted.

図2において、CPU201は、キャッシュメモリ202、制御部203及び演算部204から構成される。制御部203には、セット制御回路205が含まれている。セット制御回路205は、計数回路206、条件判別回路207、レジスタ208などから構成される。キャッシュメモリ202は、制御部203から発行されたアドレス112に対して、キャッシュデータ121を出力する。同時にヒット信号209も出力する。制御部203からの出力信号である、セット制御信号210により、キャッシュメモリ202における制御を行う。   In FIG. 2, the CPU 201 includes a cache memory 202, a control unit 203, and a calculation unit 204. The control unit 203 includes a set control circuit 205. The set control circuit 205 includes a counting circuit 206, a condition determination circuit 207, a register 208, and the like. The cache memory 202 outputs the cache data 121 to the address 112 issued from the control unit 203. At the same time, a hit signal 209 is output. The cache memory 202 is controlled by a set control signal 210 that is an output signal from the control unit 203.

キャッシュメモリ202は、例えば、図1のような構成を適用できる。但し、セット制御回路205からのセット制御信号210により、セット毎に動作状態または停止状態に遷移できる。すなわち図1の構成に、セット毎に動作状態または停止状態に遷移させる手段を追加した構成を図3に示す。   For example, the cache memory 202 can be configured as shown in FIG. However, a set control signal 210 from the set control circuit 205 can make a transition to an operating state or a stopped state for each set. That is, FIG. 3 shows a configuration in which means for changing to an operating state or a stopped state for each set is added to the configuration of FIG.

図3において、セット制御信号210により、停止状態に遷移するセット(停止セット)内のタグメモリ及びデータメモリの動作を停止する。具体的には、タグメモリ及びデータメモリへの書き込み信号及び読み出し信号を非有効化する。通常、メモリの読み出しには、データ信号線のプリチャージが必要である。メモリの消費電力の大部分はこのプリチャージによるものである。従って、読み出し信号を非有効化することで、各セットにおける消費電力は大幅に低減する。また、各セットに供給する電源電圧を遮断することで、更に消費電力を削減できる。   In FIG. 3, the operation of the tag memory and the data memory in the set (stop set) transitioning to the stop state is stopped by the set control signal 210. Specifically, the write signal and the read signal to the tag memory and the data memory are deactivated. Usually, the data signal line needs to be precharged for reading from the memory. Most of the power consumption of the memory is due to this precharge. Therefore, by disabling the read signal, the power consumption in each set is greatly reduced. Further, power consumption can be further reduced by cutting off the power supply voltage supplied to each set.

また、セット制御信号210により、停止セットに対するタグ比較回路104を非有効化することも有効である。具体的には、例えば、常にタグヒット信号を”0”とする。これにより、データ選択回路105では、停止セットのデータを誤って選択する心配が無くなる。なお、第1のタグヒット信号119、第2のタグヒット信号120及びキャッシュヒット信号122が、ヒット信号209に相当する。   It is also effective to deactivate the tag comparison circuit 104 for the stop set by the set control signal 210. Specifically, for example, the tag hit signal is always set to “0”. As a result, the data selection circuit 105 does not have to worry about erroneously selecting stop set data. Note that the first tag hit signal 119, the second tag hit signal 120, and the cache hit signal 122 correspond to the hit signal 209.

図2における、セット制御回路205は、キャッシュヒット率などを計数する計数回路206、条件判別回路207、レジスタ208から構成される。   The set control circuit 205 in FIG. 2 includes a counting circuit 206 that counts a cache hit rate and the like, a condition determination circuit 207, and a register 208.

計数回路206は、キャッシュメモリへのアクセス回数や、キャッシュヒット回数、セット毎のタグヒット回数などを計数できる。キャッシュヒット回数をアクセス回数で除することで、キャッシュヒット率を計数することができる。また、セット毎のタグヒット回数をアクセス回数で除することで、セット毎のタグヒット率を計数することができる。   The counting circuit 206 can count the number of accesses to the cache memory, the number of cache hits, the number of tag hits for each set, and the like. By dividing the number of cache hits by the number of accesses, the cache hit rate can be counted. Further, the tag hit rate for each set can be counted by dividing the number of tag hits for each set by the number of accesses.

条件判別回路207は、キャッシュヒット率などに応じて、所定のアルゴリズムにより、停止状態もしくは動作状態に遷移させるセットを決定する。キャッシュヒット率からセット毎の状態を決定するためのアルゴリズムは、本発明におけるキャッシュメモリを搭載したCPUの性能を決定するために非常に重要な項目である。本発明におけるCPUの具体的な用途に応じて、様々な方式が考え得る。   The condition determination circuit 207 determines a set to be changed to the stop state or the operation state by a predetermined algorithm according to the cache hit rate or the like. The algorithm for determining the state for each set from the cache hit rate is a very important item for determining the performance of the CPU equipped with the cache memory in the present invention. Various methods can be considered according to the specific application of the CPU in the present invention.

レジスタ208は、計数回路206における計数条件の設定や、条件判別回路207におけるパラメータ設定などの用途に利用する。   The register 208 is used for setting the counting condition in the counting circuit 206 and the parameter setting in the condition determining circuit 207.

以上のような形態とすることで、動作状況に応じて最適な性能及び消費電力を選択することができるキャッシュメモリを搭載した、高性能且つ低消費電力のCPUを提供することができる。   With the above configuration, it is possible to provide a high-performance and low-power-consumption CPU equipped with a cache memory that can select optimal performance and power consumption in accordance with the operation state.

また、本実施の形態におけるCPUを、ガラス基板、石英基板、プラスチック基板などの絶縁表面を有する基板上に形成された半導体薄膜を活性層として用いた薄膜トランジスタから構成することで、高性能且つ低消費電力のCPUを、より軽量で安価に提供することができる。   In addition, the CPU in this embodiment includes a thin film transistor that uses a semiconductor thin film formed over a substrate having an insulating surface such as a glass substrate, a quartz substrate, or a plastic substrate as an active layer, so that high performance and low consumption can be obtained. A power CPU can be provided at a lower weight and at a lower cost.

さらに、本実施の形態におけるCPUを用いて、電子機器を構成することで、高性能且つ低消費電力の電子機器を、より軽量で安価に提供することができる。   Furthermore, by configuring the electronic device using the CPU in this embodiment, a high-performance and low-power consumption electronic device can be provided at a lower weight and at a lower cost.

本実施例では、本発明に係る、キャッシュメモリを搭載したCPUについて、実施の形態では詳説を割愛した、キャッシュヒット率からセット毎の状態を決定するためのアルゴリズムについて説明する。   In this embodiment, an algorithm for determining a state for each set from a cache hit rate, which is not described in detail in the embodiment, for a CPU equipped with a cache memory according to the present invention will be described.

但し、本発明は多くの異なる態様で実施することが可能であり、本発明の趣旨及びその範囲から逸脱することなくその形態及び詳細を様々に変更し得ることは当業者であれば容易に理解される。従って、本実施例の記載内容に限定して解釈されるものではない。   However, the present invention can be implemented in many different modes, and those skilled in the art can easily understand that the modes and details can be variously changed without departing from the spirit and scope of the present invention. Is done. Therefore, the present invention is not construed as being limited to the description of this embodiment.

本実施例におけるアルゴリズムを、図5に示すフローチャートに従って説明する。任意の回数としてa回のアクセスにおけるキャッシュヒット率を計数(キャッシュヒット率計数501)する。このキャッシュヒット率と、予め設定される条件であるb%とを比較(条件判別502)し、その結果に応じて、任意のセットを動作状態から停止状態に遷移(セット停止処理503)させた後、任意の期間におけるキャッシュヒット率を計数(キャッシュヒット率計数504)し、これをc%とする。c%と予め設定される条件であるb%とを比較(条件判別505)し、その結果に応じて遷移前の状態に戻すか否かを決定する(セット復活処理506)。このアルゴリズムは、より少ないセット数でもキャッシュヒット率を維持できるか否かを検証しながらセット数を決定していくことに相当する。より少ないセット数にすることで、半導体装置における消費電力を低減できる。なお、ここで説明するアルゴリズムは、ソフトウェア(プログラム)またはハードウェアによって実行することができる。   The algorithm in the present embodiment will be described with reference to the flowchart shown in FIG. The cache hit rate in a access is counted as an arbitrary number (cache hit rate count 501). This cache hit rate is compared with b% which is a preset condition (condition determination 502), and an arbitrary set is changed from the operating state to the stopped state (set stop processing 503) according to the result. Thereafter, the cache hit rate in an arbitrary period is counted (cache hit rate count 504), and this is defined as c%. c% is compared with b% which is a preset condition (condition determination 505), and it is determined whether or not to return to the state before transition according to the result (set restoration processing 506). This algorithm corresponds to determining the number of sets while verifying whether the cache hit rate can be maintained even with a smaller number of sets. By reducing the number of sets, power consumption in the semiconductor device can be reduced. The algorithm described here can be executed by software (program) or hardware.

この操作をハードウェアで行う場合を以下に示す。計数回路でa回のアクセスにおけるキャッシュヒット率を計数し、レジスタに格納する。このキャッシュヒット率と、予め設定される条件であるb%とを条件判別回路によって比較し、その結果に応じて、セット制御信号を変化させることにより、任意のセットを動作状態から停止状態に遷移させる。その後、計数回路で任意の期間におけるキャッシュヒット率を計数し、これをc%とする。条件判別回路によってc%と予め設定される条件であるb%とを比較し、その結果に応じて遷移前の状態に戻すか否かを決定する。このようにして、半導体装置における消費電力を低減することができる。   The case where this operation is performed by hardware is shown below. The count circuit counts the cache hit rate in a accesses and stores it in a register. The cache hit rate and b% which is a preset condition are compared by a condition discriminating circuit, and a set control signal is changed according to the result, thereby changing an arbitrary set from an operating state to a stopped state. Let Thereafter, the cache hit rate in an arbitrary period is counted by a counting circuit, and this is set as c%. The condition discriminating circuit compares c% with b% which is a preset condition, and determines whether or not to return to the state before the transition according to the result. In this way, power consumption in the semiconductor device can be reduced.

ここで、任意のセットを停止状態に遷移させる条件として、キャッシュヒット率がb%以上とすることが有効である。これは、キャッシュメモリが非常に有効に機能している時に有効で、プログラムサイズが非常に小さく、メインメモリからキャッシュメモリにほぼ全てのプログラムをコピーできる場合に相当する。   Here, as a condition for transitioning an arbitrary set to the stopped state, it is effective that the cache hit rate is b% or more. This is effective when the cache memory is functioning very effectively, and corresponds to the case where the program size is very small and almost all programs can be copied from the main memory to the cache memory.

また、任意のセットを停止状態に遷移させる条件として、キャッシュヒット率がb%以下とすることも有効である。これは、キャッシュメモリがほとんど機能していない時に有効で、プログラムサイズは小さいものの、処理するデータがメインメモリ上で点在している場合に相当する。この場合、プログラムがキャッシュメモリにコピーされていれば、CPUの処理速度はほとんど変わらないと考えられる。   It is also effective to set the cache hit rate to b% or less as a condition for transitioning an arbitrary set to the stopped state. This is effective when the cache memory is hardly functioning, and corresponds to a case where data to be processed is scattered on the main memory although the program size is small. In this case, if the program is copied to the cache memory, it is considered that the CPU processing speed hardly changes.

なお、上記2種類の条件を組み合わせることも有効である。この場合、より緻密に停止状態に遷移させるか否かを決定できるため、消費電力の削減に有効である。   It is also effective to combine the above two types of conditions. In this case, since it can be determined whether or not to make a transition to the stop state more precisely, it is effective in reducing power consumption.

本実施例におけるアルゴリズムにおいて、パラメータa、b、cを固定値として設定することも可能であるが、キャッシュヒット率を観測しながら、適宜更新していくことが望ましい。これは最適な基準値は、実際にCPUで実行するプログラムに依存するためである。なお、これらの値の更新は、CPUがレジスタの値を書き換えることによって行われる。   In the algorithm in this embodiment, the parameters a, b, and c can be set as fixed values, but it is desirable to update them appropriately while observing the cache hit rate. This is because the optimum reference value depends on the program that is actually executed by the CPU. These values are updated by the CPU rewriting the register values.

さらに、一度実行したプログラムに対し、最適なa、b、cを保存しておき、次回の実行時にその値に設定することも有効である。これは、パーソナルコンピュータのように、様々なプログラムを実行する可能性があるシステムにCPUを用いる場合に、特に有効である。なお、これらのパラメータ、a、b、cを保存するために、図2におけるレジスタ208が有効である。   Furthermore, it is also effective to save optimal a, b, and c for a program that has been executed once, and set it to the value at the next execution. This is particularly effective when the CPU is used in a system that can execute various programs such as a personal computer. Note that the register 208 in FIG. 2 is effective in storing these parameters, a, b, and c.

また、任意の回数としてa’回のアクセスにおけるセット毎のタグヒット率を計数して(タグヒット率計数507)、停止状態に遷移させるセットを決定することで、より最適な制御が可能となる。タグヒット率が低いセットを停止することで、セット停止前後でキャッシュヒット率の低下は僅かであると考えられ、効果的に停止セットの制御を実施できる。従って、より緻密に消費電力の削減が可能である。   Further, by counting the tag hit rate for each set in a 'accesses as an arbitrary number of times (tag hit rate count 507) and determining a set to be shifted to the stopped state, more optimal control can be performed. . By stopping a set with a low tag hit rate, it is considered that the decrease in the cache hit rate is slight before and after the set stop, and the stop set can be controlled effectively. Therefore, power consumption can be more precisely reduced.

以上のような構成とすることで、動作状況に応じて最適な性能及び消費電力を選択することができるキャッシュメモリを搭載した、高性能且つ低消費電力のCPUを提供することができる。   With the above-described configuration, it is possible to provide a high-performance and low-power-consumption CPU equipped with a cache memory that can select optimal performance and power consumption according to the operation state.

なお、本実施例におけるCPUを、ガラス基板、石英基板、プラスチック基板などの絶縁表面を有する基板上に形成された半導体薄膜を活性層として用いた薄膜トランジスタから構成することで、高性能且つ低消費電力のCPUを、より軽量で安価に提供することができる。   Note that the CPU in this embodiment is composed of a thin film transistor using a semiconductor thin film formed on a substrate having an insulating surface such as a glass substrate, a quartz substrate, or a plastic substrate as an active layer, thereby achieving high performance and low power consumption. CPU can be provided at a lower weight and at a lower cost.

さらに、本実施例におけるCPUを用いて、電子機器を構成することで、高性能且つ低消費電力の電子機器を、より軽量で安価に提供することができる。   Furthermore, by configuring an electronic device using the CPU in this embodiment, a high-performance and low power consumption electronic device can be provided at a lower weight and at a lower cost.

本実施例は、発明を実施するための最良の形態と自由に組み合わせて実施することが可能である。   This embodiment can be implemented in combination with the best mode for carrying out the invention.

本実施例では、本発明に係る、キャッシュメモリを搭載したCPUについて、実施例1で説明した、キャッシュヒット率から停止セットを決定するためのアルゴリズムとは異なるアルゴリズムについて説明する。   In the present embodiment, an algorithm different from the algorithm for determining a stop set from the cache hit rate described in the first embodiment will be described for a CPU equipped with a cache memory according to the present invention.

但し、本発明は多くの異なる態様で実施することが可能であり、本発明の趣旨及びその範囲から逸脱することなくその形態及び詳細を様々に変更し得ることは当業者であれば容易に理解される。従って、本実施例の記載内容に限定して解釈されるものではない。   However, the present invention can be implemented in many different modes, and those skilled in the art can easily understand that the modes and details can be variously changed without departing from the spirit and scope of the present invention. Is done. Therefore, the present invention is not construed as being limited to the description of this embodiment.

本実施例におけるアルゴリズムを、フローチャートを図6に従って説明する。適当な時間間隔d秒を計数し(時間計数601)、任意のセットを動作状態から停止状態に遷移(セット停止処理602)させた後、キャッシュヒット率を計数(キャッシュヒット率計数603)する。このキャッシュヒット率を、あらかじめ設定される条件であるe%と比較(条件判別604)し、その結果に応じて遷移前の状態に戻すか否を決定する(セット復活処理605)。このアルゴリズムは、キャッシュメモリサイズとその有効性を定期的に調査し、より少ないセット数でも、キャッシュヒット率が維持できるか否かを検証することに相当する。より少ないセット数にすることで、半導体装置における消費電力を低減できる。なお、ここで説明するアルゴリズムは、ソフトウェア(プログラム)またはハードウェアによって実行することができる。   The algorithm in the present embodiment will be described with reference to a flowchart shown in FIG. An appropriate time interval d seconds is counted (time count 601), an arbitrary set is changed from the operating state to the stopped state (set stop processing 602), and then the cache hit rate is counted (cache hit rate count 603). This cache hit rate is compared with e%, which is a preset condition (condition determination 604), and it is determined whether or not to return to the state before transition according to the result (set restoration process 605). This algorithm corresponds to periodically checking the cache memory size and its effectiveness and verifying whether the cache hit rate can be maintained even with a smaller number of sets. By reducing the number of sets, power consumption in the semiconductor device can be reduced. The algorithm described here can be executed by software (program) or hardware.

この操作をハードウェアで行う場合を以下に示す。計数回路でd秒の時間を計数し、セット制御信号を変化させることにより任意のセットを動作状態から停止状態に遷移させる。その後、計数回路でキャッシュヒット率を計数し、レジスタに格納する。その後、キャッシュヒット率と、予め設定される条件であるe%とを条件判別回路によって比較し、その結果に応じて、遷移前の状態に戻すか否を決定する。   The case where this operation is performed by hardware is shown below. The counting circuit counts the time of d seconds, and changes the set control signal to change any set from the operating state to the stopped state. Thereafter, the cache hit rate is counted by a counting circuit and stored in a register. Thereafter, the cache hit rate and e% which is a preset condition are compared by the condition determination circuit, and it is determined whether or not to return to the state before the transition according to the result.

本実施例におけるアルゴリズムにおいても、パラメータd、eを固定値として設定することも可能であるが、キャッシュヒット率を観測しながら、適宜更新していくことが望ましい。これは最適な基準値は、実際にCPUで実行するプログラムに依存するためである。なお、これらの値の更新は、CPUがレジスタの値を書き換えることによって行われる。   Even in the algorithm in the present embodiment, the parameters d and e can be set as fixed values, but it is desirable to update appropriately while observing the cache hit rate. This is because the optimum reference value depends on the program that is actually executed by the CPU. These values are updated by the CPU rewriting the register values.

さらに、一度実行したプログラムに対し、最適なd、eを保存しておき、次回の実行時にその値に設定することも有効である。これは、パーソナルコンピュータのように、様々なプログラムを実行する可能性があるシステムにCPUを用いる場合に、特に有効である。なお、これらのパラメータ、d、eを保存するために、図2におけるレジスタ208が有効である。   Furthermore, it is also effective to store the optimum d and e for a program that has been executed once, and set it to the value at the next execution. This is particularly effective when the CPU is used in a system that can execute various programs such as a personal computer. In order to store these parameters, d and e, the register 208 in FIG. 2 is effective.

また、任意の時間としてd秒間のアクセスにおけるセット毎のタグヒット率を計数して(タグヒット率計数606)、停止状態に遷移させるセットを決定することで、より最適な制御が可能となる。タグヒット率が低いセットを停止することで、セット停止前後でキャッシュヒット率の低下は僅かであると考えられ、効果的に停止セットの制御を実施できる。従って、より緻密に消費電力の削減が可能である。   Further, by counting the tag hit rate for each set in the d-second access as an arbitrary time (tag hit rate count 606), and determining the set to be shifted to the stop state, more optimal control is possible. By stopping a set with a low tag hit rate, it is considered that the decrease in the cache hit rate is slight before and after the set stop, and the stop set can be controlled effectively. Therefore, power consumption can be more precisely reduced.

以上のような構成とすることで、動作状況に応じて最適な性能及び消費電力を選択することができるキャッシュメモリを搭載した、高性能且つ低消費電力のCPUを提供することができる。   With the above-described configuration, it is possible to provide a high-performance and low-power-consumption CPU equipped with a cache memory that can select optimal performance and power consumption according to the operation state.

なお、本実施例におけるCPUを、ガラス基板、石英基板、プラスチック基板などの絶縁表面を有する基板上に形成された半導体薄膜を活性層として用いた薄膜トランジスタから構成することで、高性能且つ低消費電力のCPUを、より軽量で安価に提供することができる。   Note that the CPU in this embodiment is composed of a thin film transistor using a semiconductor thin film formed on a substrate having an insulating surface such as a glass substrate, a quartz substrate, or a plastic substrate as an active layer, thereby achieving high performance and low power consumption. CPU can be provided at a lower weight and at a lower cost.

さらに、本実施例におけるCPUを用いて、電子機器を構成することで、高性能且つ低消費電力の電子機器を、より軽量で安価に提供することができる。   Furthermore, by configuring an electronic device using the CPU in this embodiment, a high-performance and low power consumption electronic device can be provided at a lower weight and at a lower cost.

本実施例は、発明を実施するための最良の形態及び実施例1と自由に組み合わせて実施することが可能である。   This embodiment can be carried out in any combination with the best mode for carrying out the invention and Embodiment 1.

本実施例では、本発明におけるCPUを用いたシステムとして、パーソナルコンピュータについて説明する。   In this embodiment, a personal computer will be described as a system using a CPU in the present invention.

図7に、パーソナルコンピュータの構成図を示す。図7において、マザーボード701の上に、CPU702、ノースブリッジ(NB)703、サウスブリッジ(SB)704、SDRAM705、画像処理回路706が搭載されている。SB704には、ハードディスクコントローラ707、フレキシブルディスクカートリッジコントローラ708、マウスコントローラ709、キーボードコントローラ710が搭載されている。画像処理回路706、ハードディスクコントローラ707、フレキシブルディスクカートリッジコントローラ708、マウスコントローラ709、キーボードコントローラ710は、各々ディスプレイ711、ハードディスク712、フレキシブルディスクカートリッジ713、マウス714、キーボード715を制御する。   FIG. 7 shows a configuration diagram of the personal computer. In FIG. 7, a CPU 702, a north bridge (NB) 703, a south bridge (SB) 704, an SDRAM 705, and an image processing circuit 706 are mounted on a motherboard 701. The SB 704 includes a hard disk controller 707, a flexible disk cartridge controller 708, a mouse controller 709, and a keyboard controller 710. An image processing circuit 706, a hard disk controller 707, a flexible disk cartridge controller 708, a mouse controller 709, and a keyboard controller 710 control the display 711, hard disk 712, flexible disk cartridge 713, mouse 714, and keyboard 715, respectively.

ここで、NB703は、SDRAM705、画像処理回路706など、CPUと高速なデータアクセスを行う必要がある半導体装置のコントローラ回路を集積した半導体装置である。また、SB704は、CPU702と低速なデータアクセスを行う半導体装置のコントローラ回路を集積した半導体装置である。   Here, the NB 703 is a semiconductor device in which a controller circuit of a semiconductor device that needs to perform high-speed data access with the CPU, such as an SDRAM 705 and an image processing circuit 706, is integrated. The SB 704 is a semiconductor device in which a controller circuit of a semiconductor device that performs low-speed data access with the CPU 702 is integrated.

本発明を、CPU702に用いることで、高性能且つ低消費電力のシステムを提供することができる。また、画像処理回路706内部のプロセッサに、本発明を用いることで、さらに高性能且つ低消費電力のシステムを提供することができる。 By using the present invention for the CPU 702, a high performance and low power consumption system can be provided. Further, by using the present invention for the processor in the image processing circuit 706, a system with higher performance and lower power consumption can be provided.

本実施例は、発明を実施するための最良の形態、実施例1及び実施例2と自由に組み合わせて実施することが可能である。   This embodiment can be carried out in any combination with the best mode for carrying out the invention, Embodiment 1 and Embodiment 2.

本実施例では、本発明におけるCPUを用いて作製される電子機器の例について図4を用いて説明する。   In this embodiment, an example of an electronic device manufactured using the CPU in the present invention will be described with reference to FIGS.

本発明を用いて作製した電子機器として、ビデオカメラやデジタルカメラ等のカメラ、ゴーグル型ディスプレイ(ヘッドマウントディスプレイ)、ナビゲーションシステム、音響再生装置(カーオーディオ、オーディオコンポ等)、パーソナルコンピュータ、ゲーム機器、携帯情報端末(モバイルコンピュータ、携帯電話、携帯型ゲーム機または電子書籍等)、記録媒体を備えた画像再生装置(具体的にはDigital Versatile Disc (DVD)等の記録媒体を再生し、その画像を表示しうるディスプレイを備えた装置)などが挙げられる。それらの電子機器の具体例を図4に示す。   As an electronic device manufactured using the present invention, a camera such as a video camera or a digital camera, a goggle type display (head mounted display), a navigation system, a sound reproduction device (car audio, audio component, etc.), a personal computer, a game device, Play back a recording medium such as a portable information terminal (mobile computer, mobile phone, portable game machine or electronic book), an image playback device (specifically, Digital Versatile Disc (DVD)) provided with a recording medium, A device having a display capable of displaying). Specific examples of these electronic devices are shown in FIGS.

図4(A)は表示装置であり、筐体1401、支持台1402、表示部1403を含む。本発明は表示部1403のコントローラに適用が可能である。本発明を用いることによって、表示装置の低消費電力化を実現できる。   FIG. 4A illustrates a display device, which includes a housing 1401, a support base 1402, and a display portion 1403. The present invention can be applied to the controller of the display unit 1403. By using the present invention, low power consumption of the display device can be realized.

図4(B)はビデオカメラであり、本体1411、表示部1412、音声入力部1413、操作スイッチ1414、バッテリー1415、受像部1416などによって構成されている。本発明は、本体1411内部のCPUや表示部1412のコントローラに適用が可能である。本発明を用いることによって、ビデオカメラの小型・軽量化を実現できる。   FIG. 4B illustrates a video camera, which includes a main body 1411, a display portion 1412, an audio input portion 1413, an operation switch 1414, a battery 1415, an image receiving portion 1416, and the like. The present invention can be applied to the CPU inside the main body 1411 and the controller of the display unit 1412. By using the present invention, the video camera can be reduced in size and weight.

図4(C)はパーソナルコンピュータであり、本体1421、筐体1422、表示部1423、キーボード1424などによって構成されている。本発明は表示部1423のコントローラに適用が可能である。また、本発明は本体1421内部のCPUに適用が可能である。本発明を用いることによって、パーソナルコンピュータの低消費電力化を実現できる。   FIG. 4C illustrates a personal computer, which includes a main body 1421, a housing 1422, a display portion 1423, a keyboard 1424, and the like. The present invention can be applied to the controller of the display portion 1423. Further, the present invention can be applied to the CPU inside the main body 1421. By using the present invention, low power consumption of a personal computer can be realized.

図4(D)は携帯情報端末であり、本体1431、スタイラス1432、表示部1433、操作ボタン1434、外部インターフェイス1435などによって構成されている。本発明は表示部1433のコントローラに適用が可能である。また、本発明は本体1431内部のCPUに適用が可能である。本発明を用いることによって、携帯情報端末の低消費電力化を実現できる。   FIG. 4D illustrates a portable information terminal which includes a main body 1431, a stylus 1432, a display portion 1433, operation buttons 1434, an external interface 1435, and the like. The present invention can be applied to the controller of the display portion 1433. Further, the present invention can be applied to the CPU inside the main body 1431. By using the present invention, low power consumption of the portable information terminal can be realized.

図4(E)は音響再生装置、具体的には車載用のオーディオ装置であり、本体1441、表示部1442、操作スイッチ1443、操作スイッチ1444などによって構成されている。本発明は表示部1442のコントローラに適用が可能である。また、本発明は本体1441内部のCPUに適用が可能である。また、今回は車載用オーディオ装置を例に上げたが、携帯型もしくは家庭用オーディオ装置に用いてもよい。本発明を用いることによって、音響再生装置の低消費電力化を実現できる。   FIG. 4E illustrates a sound reproducing device, specifically an in-vehicle audio device, which includes a main body 1441, a display portion 1442, an operation switch 1443, an operation switch 1444, and the like. The present invention can be applied to the controller of the display unit 1442. Further, the present invention can be applied to the CPU inside the main body 1441. In this example, the on-vehicle audio device is taken as an example, but it may be used for a portable or home audio device. By using the present invention, low power consumption of the sound reproducing device can be realized.

図4(F)はデジタルカメラであり、本体1451、表示部(A)1452、接眼部1453、操作スイッチ1454、表示部(B)1455、バッテリー1456などによって構成されている。本発明は表示部(A)1452および表示部(B)1455のコントローラに適用が可能である。また、本発明は本体1451内部のCPUに適用が可能である。本発明を用いることによって、デジタルカメラの低消費電力化を実現できる。   FIG. 4F illustrates a digital camera, which includes a main body 1451, a display portion (A) 1452, an eyepiece portion 1453, operation switches 1454, a display portion (B) 1455, a battery 1456, and the like. The present invention can be applied to the controllers of the display portion (A) 1452 and the display portion (B) 1455. Further, the present invention can be applied to the CPU inside the main body 1451. By using the present invention, low power consumption of a digital camera can be realized.

図4(G)は携帯電話であり、本体1461、音声出力部1462、音声入力部1463、表示部1464、操作スイッチ1465、アンテナ1466などによって構成されている。本発明は表示部1464のコントローラに適用が可能である。また、本発明は本体1461内部のCPUに適用が可能である。本発明を用いることによって、携帯電話の低消費電力化を実現できる。   FIG. 4G illustrates a cellular phone, which includes a main body 1461, an audio output portion 1462, an audio input portion 1463, a display portion 1464, operation switches 1465, an antenna 1466, and the like. The present invention can be applied to the controller of the display unit 1464. Further, the present invention can be applied to the CPU inside the main body 1461. By using the present invention, low power consumption of a mobile phone can be realized.

これらの電子機器に使われる半導体装置及び表示装置はガラス基板だけでなく耐熱性のプラスチック基板を用いることもできる。それにより軽量化を図ることができる。   A semiconductor device and a display device used in these electronic devices can use not only a glass substrate but also a heat-resistant plastic substrate. Thereby, weight reduction can be achieved.

本発明は、上記電子機器に限定されず、発明を実施するための最良の形態、及び、実施例1乃至実施例3で示した演算処理装置を用いた、様々な電子機器とすることができる。   The present invention is not limited to the above electronic devices, and can be various electronic devices using the best mode for carrying out the invention and the arithmetic processing units shown in the first to third embodiments. .

一般的な連想方式キャッシュメモリの概要図。1 is a schematic diagram of a general associative cache memory. 本発明における演算処理装置の概要図。The schematic diagram of the arithmetic processing unit in this invention. 本発明における演算処理装置に搭載される連想方式キャッシュメモリの概要図。1 is a schematic diagram of an associative cache memory installed in an arithmetic processing unit according to the present invention. 本発明における演算処理装置を応用した電子機器。The electronic device which applied the arithmetic processing unit in this invention. 本発明における演算処理装置に搭載される制御回路におけるアルゴリズムのフローチャート1。The flowchart 1 of the algorithm in the control circuit mounted in the arithmetic processing unit in this invention. 本発明における演算処理装置に搭載される制御回路におけるアルゴリズムのフローチャート2。The flowchart 2 of the algorithm in the control circuit mounted in the arithmetic processing unit in this invention. 本発明における演算処理装置を用いたシステム。The system using the arithmetic processing unit in this invention.

符号の説明Explanation of symbols

101 キャッシュメモリ
102 第1のセット
103 第2のセット
104 タグ比較回路
105 データ選択回路
106 第1のタグメモリ
107 第1のデータメモリ
108 第2のタグメモリ
109 第2のデータメモリ
110 第1の比較回路
111 第2の比較回路
112 アドレス
113 アドレス上位ビット
114 アドレス下位ビット
115 第1のタグデータ
116 第1のコピーデータ
117 第2のタグデータ
118 第2のコピーデータ
119 第1のタグヒット信号
120 第2のタグヒット信号
121 キャッシュデータ
122 キャッシュヒット信号
101 cache memory 102 first set 103 second set 104 tag comparison circuit 105 data selection circuit 106 first tag memory 107 first data memory 108 second tag memory 109 second data memory 110 first comparison Circuit 111 Second comparison circuit 112 Address 113 Address upper bit 114 Address lower bit 115 First tag data 116 First copy data 117 Second tag data 118 Second copy data 119 First tag hit signal 120 2 tag hit signal 121 Cache data 122 Cache hit signal

Claims (41)

キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとを有する少なくとも1つのセットと、
前記データメモリ又は前記タグメモリの一方の、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記タグメモリにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、
を有することを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
At least one set having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of one of the data memory or the tag memory;
Counting the number of accesses to the cache memory, the number of cache hits in the cache memory, the number of tag hits in the tag memory, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses for an arbitrary period Means to
An arithmetic processing apparatus comprising:
キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとを有する少なくとも1つのセットと、
前記データメモリ又は前記タグメモリの一方の、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記タグメモリにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、を有し、
前記遷移させる手段により、前記キャッシュヒット率と、第1のヒット率の基準値として任意に設定した値と、を比較した結果に応じて、動作状態にある前記データメモリ又は前記タグメモリの一方を停止状態に遷移させることを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
At least one set having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of one of the data memory or the tag memory;
Counting the number of accesses to the cache memory, the number of cache hits in the cache memory, the number of tag hits in the tag memory, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses for any period And means for
According to a result of comparing the cache hit rate and a value arbitrarily set as a reference value of the first hit rate by the means for making a transition, one of the data memory or the tag memory in an operating state is selected. An arithmetic processing apparatus characterized by causing a transition to a stopped state.
請求項2において、
前記演算処理装置の動作中に、前記第1のヒット率の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 2,
An arithmetic processing apparatus comprising: means for changing a reference value of the first hit rate to another value during the operation of the arithmetic processing apparatus.
請求項3において、
前記演算処理装置が実行するプログラムごとに前記第1のヒット率の基準値を変更することを特徴とする演算処理装置。
In claim 3,
The arithmetic processing device, wherein the reference value of the first hit rate is changed for each program executed by the arithmetic processing device.
請求項1乃至請求項4のいずれか一において、
前記遷移させる手段により、前記キャッシュヒット率と、第2のヒット率の基準値として任意に設定した値と、を比較した結果に応じて、停止状態にある前記データメモリ又は前記タグメモリの一方を動作状態に遷移させることを特徴とする演算処理装置。
In any one of Claims 1 thru | or 4,
According to a result of comparing the cache hit rate and a value arbitrarily set as a reference value of the second hit rate by the means for making a transition, one of the data memory or the tag memory in a stopped state is An arithmetic processing device characterized by causing transition to an operating state.
請求項5において、
前記演算処理装置の動作中に、前記第2のヒット率の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 5,
Means for changing the reference value of the second hit rate to another value during the operation of the arithmetic processing unit.
請求項6において、
前記演算処理装置が実行するプログラムごとに前記第2のヒット率の基準値を変更することを特徴とする演算処理装置。
In claim 6,
The arithmetic processing device, wherein the second hit rate reference value is changed for each program executed by the arithmetic processing device.
キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとを有する少なくとも1つのセットと、
前記データメモリ又は前記タグメモリの一方の、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記タグメモリにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、を有し、
前記遷移させる手段により、第1の時間の基準値として任意に設定した値毎に、動作状態にある前記データメモリ又は前記タグメモリの一方を停止状態に遷移させることを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
At least one set having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of one of the data memory or the tag memory;
Counting the number of accesses to the cache memory, the number of cache hits in the cache memory, the number of tag hits in the tag memory, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses for any period And means for
An arithmetic processing unit characterized in that the transition means causes one of the data memory or the tag memory in an operating state to transition to a stopped state for each value arbitrarily set as a reference value for the first time.
請求項8において、
前記演算処理装置の動作中に、前記第1の時間の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 8,
An arithmetic processing apparatus comprising: means for changing the reference value of the first time to another value during the operation of the arithmetic processing apparatus.
請求項9において、
前記演算処理装置が実行するプログラムごとに前記第1の時間の基準値を変更することを特徴とする演算処理装置。
In claim 9,
The arithmetic processing apparatus, wherein the first time reference value is changed for each program executed by the arithmetic processing apparatus.
請求項8乃至請求項10において、
前記遷移させる手段により、第2の時間の基準値として任意に設定した値毎に、停止状態にある前記データメモリ又は前記タグメモリの一方を動作状態に遷移させることを特徴とする演算処理装置。
In claims 8 to 10,
An arithmetic processing unit characterized in that, by means of the transition, one of the data memory or the tag memory in a stopped state is shifted to an operating state for each value arbitrarily set as a reference value for a second time.
請求項11において、
前記演算処理装置の動作中に、前記第2の時間の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 11,
An arithmetic processing apparatus comprising: means for changing the second time reference value to another value during operation of the arithmetic processing apparatus.
請求項12において、
前記演算処理装置が実行するプログラムごとに前記第2の時間の基準値を変更することを特徴とする演算処理装置。
In claim 12,
The arithmetic processing apparatus, wherein the second time reference value is changed for each program executed by the arithmetic processing apparatus.
請求項1乃至13のいずれか一において、
前記演算処理装置は、動作状態にある前記データメモリ又は前記タグメモリの一方を停止状態に遷移させる操作、または停止状態にある前記データメモリ又は前記タグメモリの一方を動作状態に遷移させる操作を、前記演算処理装置の命令により制御する手段、を有することを特徴とする演算処理装置。
In any one of Claims 1 thru | or 13,
The arithmetic processing unit performs an operation of transitioning one of the data memory or the tag memory in an operating state to a stopped state, or an operation of transitioning one of the data memory or the tag memory in a stopped state to an operating state, An arithmetic processing unit comprising means for controlling in accordance with an instruction from the arithmetic processing unit.
請求項1乃至請求項13のいずれか一において、
前記演算処理装置は、動作状態にある前記データメモリ又は前記タグメモリの一方を停止状態に遷移させる操作、または停止状態にある前記データメモリ又は前記タグメモリの一方を動作状態に遷移させる操作を、前記演算処理装置に実装された制御回路と、前記演算処理装置の命令と、により制御する手段、を有することを特徴とする演算処理装置。
In any one of Claims 1 thru | or 13,
The arithmetic processing unit performs an operation of transitioning one of the data memory or the tag memory in an operating state to a stopped state, or an operation of transitioning one of the data memory or the tag memory in a stopped state to an operating state, An arithmetic processing apparatus comprising: a control circuit mounted on the arithmetic processing apparatus; and a means for controlling the control circuit according to a command from the arithmetic processing apparatus.
キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとをそれぞれ有する複数のセットと、
前記複数のセットの、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記複数のセットのいずれかにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、
を有することを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
A plurality of sets each having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of the plurality of sets;
Any number of accesses to the cache memory, the number of cache hits of the cache memory, the number of tag hits in any of the plurality of sets, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses Means for counting the period of
An arithmetic processing apparatus comprising:
キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとをそれぞれ有する複数のセットと、
前記複数のセットの、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記複数のセットのいずれかにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、を有し、
前記遷移させる手段により、前記キャッシュヒット率と、第3のヒット率の基準値として任意に設定した値と、を比較した結果に応じて、動作状態にある前記複数のセットのいずれかを停止状態に遷移させることを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
A plurality of sets each having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of the plurality of sets;
Any number of accesses to the cache memory, cache hits of the cache memory, tag hits in any of the plurality of sets, and a cache hit rate obtained by dividing the cache hits by the number of accesses Means for counting for a period of
Depending on a result of comparing the cache hit rate and a value arbitrarily set as a reference value of the third hit rate by the means for making a transition, any one of the plurality of sets in the operating state is stopped. An arithmetic processing device characterized by making a transition to.
請求項17において、
前記演算処理装置の動作中に、前記第3のヒット率の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 17,
Means for changing the reference value of the third hit rate to another value during operation of the arithmetic processing unit.
請求項18において、
前記演算処理装置が実行するプログラムごとに前記第3のヒット率の基準値を変更することを特徴とする演算処理装置。
In claim 18,
The arithmetic processing device, wherein the third hit rate reference value is changed for each program executed by the arithmetic processing device.
請求項17乃至請求項19のいずれか一において、
前記遷移させる手段により、前記キャッシュヒット率と、第4のヒット率の基準値として任意に設定した値と、を比較した結果に応じて、停止状態にある前記複数のセットのいずれかを動作状態に遷移させることを特徴とする演算処理装置。
In any one of Claims 17-19,
According to a result of comparing the cache hit rate and a value arbitrarily set as a reference value of the fourth hit rate by the means for making a transition, any one of the plurality of sets in the stopped state is in an operating state. An arithmetic processing device characterized by making a transition to.
請求項20において、
前記演算処理装置の動作中に、前記第4のヒット率の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 20,
An arithmetic processing apparatus comprising: means for changing the reference value of the fourth hit rate to another value during operation of the arithmetic processing apparatus.
請求項21において、
前記演算処理装置が実行するプログラムごとに前記第4のヒット率の基準値を変更することを特徴とする演算処理装置。
In claim 21,
The arithmetic processing apparatus, wherein the fourth hit rate reference value is changed for each program executed by the arithmetic processing apparatus.
キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとをそれぞれ有する複数のセットと、
前記複数のセットの、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記セットにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、を有し、
前記遷移させる手段により、第3の時間の基準値として任意に設定した値毎に、動作状態にある前記複数のセットのいずれかを停止状態に遷移させることを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
A plurality of sets each having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of the plurality of sets;
Count the number of accesses to the cache memory, the number of cache hits in the cache memory, the number of tag hits in the set, and the cache hit rate obtained by dividing the number of cache hits by the number of accesses for any period. Means,
An arithmetic processing apparatus characterized in that, by means of the transition, any one of the plurality of sets in the operating state is transitioned to a stopped state for each value arbitrarily set as a third time reference value.
キャッシュメモリを有する演算処理装置であって、
データメモリと、タグメモリとをそれぞれ有する複数のセットと、
前記複数のセットの、動作状態と停止状態とを遷移させる手段と、
前記キャッシュメモリへのアクセス回数、前記キャッシュメモリのキャッシュヒット回数、前記複数のセットのいずれかにおけるタグヒット回数、及び前記アクセス回数で前記キャッシュヒット回数を除することにより得られるキャッシュヒット率、を任意の期間について計数する手段と、を有し、
前記遷移させる手段により、第3の時間の基準値として任意に設定した値毎に、動作状態にある前記複数のセットのうち前記タグヒット回数が最も少ないセットを停止状態に遷移させることを特徴とする演算処理装置。
An arithmetic processing unit having a cache memory,
A plurality of sets each having a data memory and a tag memory;
Means for transitioning between an operating state and a stopped state of the plurality of sets;
Any number of accesses to the cache memory, cache hits of the cache memory, tag hits in any of the plurality of sets, and a cache hit rate obtained by dividing the cache hits by the number of accesses Means for counting for a period of
For each value arbitrarily set as the reference value for the third time by the means for transition, the set having the smallest number of tag hits among the plurality of sets in the operating state is transitioned to the stopped state. Arithmetic processing unit to perform.
請求項23または請求項24において、
前記演算処理装置の動作中に、前記第3の時間の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 23 or claim 24,
An arithmetic processing apparatus comprising: means for changing the reference value of the third time to another value during operation of the arithmetic processing apparatus.
請求項25において、
前記演算処理装置が実行するプログラムごとに前記第3の時間の基準値を変更することを特徴とする演算処理装置。
In claim 25,
The arithmetic processing apparatus, wherein the third time reference value is changed for each program executed by the arithmetic processing apparatus.
請求項23乃至請求項26のいずれか一において、
前記遷移させる手段により、第4の時間の基準値として任意に設定した値毎に、前記停止状態にあるセットのうち少なくとも1つを動作状態に遷移させることを特徴とする演算処理装置。
In any one of claims 23 to 26,
The arithmetic processing apparatus, wherein the transition means causes at least one of the sets in the stopped state to transition to an operating state for each value arbitrarily set as a fourth time reference value.
請求項27において、
前記演算処理装置の動作中に、前記第4の時間の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 27,
An arithmetic processing apparatus comprising: means for changing the fourth time reference value to another value during the operation of the arithmetic processing apparatus.
請求項28において、
前記演算処理装置が実行するプログラムごとに前記第4の時間の基準値を変更することを特徴とする演算処理装置。
In claim 28,
The arithmetic processing unit, wherein the fourth time reference value is changed for each program executed by the arithmetic processing unit.
請求項23乃至請求項29のいずれか一において、
前記停止状態に遷移させる操作の後に、前記キャッシュヒット率と、第5のヒット率の基準値として任意に設定した値と、を比較した結果に応じて、前記操作において停止状態に遷移させたセットを、再度動作状態に遷移させる手段を有することを特徴とする演算処理装置。
In any one of claims 23 to 29,
After the operation for transitioning to the stopped state, the set that has been transitioned to the stopped state in the operation according to a result of comparing the cache hit rate and a value arbitrarily set as a reference value for the fifth hit rate An arithmetic processing unit characterized by having means for making a transition to the operating state again.
請求項30において、
前記演算処理装置の動作中に、前記第5のヒット率の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 30,
An arithmetic processing apparatus comprising: means for changing the reference value of the fifth hit rate to another value during the operation of the arithmetic processing apparatus.
請求項31において、
前記演算処理装置が実行するプログラムごとに前記第5のヒット率の基準値を変更することを特徴とする演算処理装置。
In claim 31,
The arithmetic processing device, wherein the reference value of the fifth hit rate is changed for each program executed by the arithmetic processing device.
請求項30乃至請求項32のいずれか一において、
前記動作状態に遷移させる操作の後に、前記キャッシュヒット率と、第6のヒット率の基準値として任意に設定した値と、を比較した結果に応じて、前記操作において動作状態に遷移させたセットを、再度停止状態に遷移させる手段を有することを特徴とする演算処理装置。
In any one of claims 30 to 32,
The set that is changed to the operation state in the operation according to the result of comparing the cache hit rate and the value arbitrarily set as the reference value of the sixth hit rate after the operation to change to the operation state An arithmetic processing unit characterized by having means for making a transition to a stopped state again.
請求項33において、
前記演算処理装置の動作中に、前記第6のヒット率の基準値を別の値へと変更する手段、を有することを特徴とする演算処理装置。
In claim 33,
An arithmetic processing apparatus comprising: means for changing the reference value of the sixth hit rate to another value during the operation of the arithmetic processing apparatus.
請求項34において、
前記演算処理装置が実行するプログラムごとに前記第6のヒット率の基準値を変更することを特徴とする演算処理装置。
In claim 34,
The arithmetic processing apparatus, wherein the sixth hit rate reference value is changed for each program executed by the arithmetic processing apparatus.
請求項16乃至請求項35のいずれか一において、
前記演算処理装置は、動作状態にある前記セットを停止状態に遷移させる操作、または停止状態にある前記セットを動作状態に遷移させる操作を、前記演算処理装置の命令により制御する手段、を有することを特徴とする演算処理装置。
In any one of claims 16 to 35,
The arithmetic processing unit has means for controlling an operation for transitioning the set in an operating state to a stopped state, or an operation for transitioning the set in a stopped state to an operating state by an instruction of the arithmetic processing unit. An arithmetic processing device characterized by the above.
請求項16乃至請求項35のいずれか一において、
前記演算処理装置は、動作状態にある前記セットを停止状態に遷移させる操作、または停止状態にある前記セットを動作状態に遷移させる操作を、前記演算処理装置に実装された制御回路と、前記演算処理装置の命令と、により制御する手段、を有することを特徴とする演算処理装置。
In any one of claims 16 to 35,
The arithmetic processing device performs an operation for transitioning the set in an operating state to a stopped state, or an operation for transitioning the set in a stopped state to an operating state, and a control circuit mounted on the arithmetic processing device; An arithmetic processing apparatus comprising: means for controlling according to an instruction of the processing apparatus.
請求項1乃至請求項37のいずれか一において、
前記停止状態とは、前記データメモリ及び前記タグメモリに格納されているデータを読み出す際に行うプリチャージ動作を行わない状態であることを特徴とする演算処理装置。
In any one of claims 1 to 37,
The arithmetic processing apparatus according to claim 1, wherein the stopped state is a state in which a precharge operation that is performed when reading data stored in the data memory and the tag memory is not performed.
請求項1乃至請求項37のいずれか一において、
前記停止状態とは、前記データメモリ及び前記タグメモリに電源電圧を供給しない状態であることを特徴とする演算処理装置。
In any one of claims 1 to 37,
The arithmetic processing apparatus according to claim 1, wherein the stopped state is a state in which a power supply voltage is not supplied to the data memory and the tag memory.
請求項1乃至請求項39のいずれか一において、
前記演算処理装置は、薄膜トランジスタを有し、
前記薄膜トランジスタは、絶縁表面を有する基板上に形成された半導体薄膜を用いたものであり、
前記絶縁表面を有する基板は、ガラス基板、石英基板、プラスチック基板、SOI基板のいずれかであることを特徴とする演算処理装置。
40. In any one of claims 1 to 39,
The arithmetic processing unit has a thin film transistor,
The thin film transistor is a semiconductor thin film formed on a substrate having an insulating surface,
The arithmetic processing apparatus, wherein the substrate having an insulating surface is any one of a glass substrate, a quartz substrate, a plastic substrate, and an SOI substrate.
請求項1乃至請求項40のいずれか一に記載の演算処理装置を用いた電子機器。   The electronic device using the arithmetic processing apparatus as described in any one of Claims 1 thru | or 40.
JP2006085007A 2005-03-31 2006-03-27 Arithmetic processing unit Expired - Fee Related JP4364878B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006085007A JP4364878B2 (en) 2005-03-31 2006-03-27 Arithmetic processing unit

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2005102105 2005-03-31
JP2006085007A JP4364878B2 (en) 2005-03-31 2006-03-27 Arithmetic processing unit

Publications (3)

Publication Number Publication Date
JP2006309734A true JP2006309734A (en) 2006-11-09
JP2006309734A5 JP2006309734A5 (en) 2009-02-12
JP4364878B2 JP4364878B2 (en) 2009-11-18

Family

ID=37476495

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006085007A Expired - Fee Related JP4364878B2 (en) 2005-03-31 2006-03-27 Arithmetic processing unit

Country Status (1)

Country Link
JP (1) JP4364878B2 (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008234320A (en) * 2007-03-20 2008-10-02 Fujitsu Ltd Cache control circuit
JP2009282880A (en) * 2008-05-26 2009-12-03 Fujitsu Ltd Cache memory system
WO2010137164A1 (en) * 2009-05-29 2010-12-02 富士通株式会社 Cache control device and method for controlling cache
JP2012068740A (en) * 2010-09-21 2012-04-05 Mitsubishi Electric Corp Information processing system
JP2013512529A (en) * 2010-03-08 2013-04-11 ヒューレット−パッカード デベロップメント カンパニー エル.ピー. Data storage device and method
JP2013250962A (en) * 2012-05-01 2013-12-12 Semiconductor Energy Lab Co Ltd Semiconductor device

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008234320A (en) * 2007-03-20 2008-10-02 Fujitsu Ltd Cache control circuit
JP4519151B2 (en) * 2007-03-20 2010-08-04 富士通株式会社 Cache control circuit
JP2009282880A (en) * 2008-05-26 2009-12-03 Fujitsu Ltd Cache memory system
WO2010137164A1 (en) * 2009-05-29 2010-12-02 富士通株式会社 Cache control device and method for controlling cache
JP5338905B2 (en) * 2009-05-29 2013-11-13 富士通株式会社 Cache control device and cache control method
JP2013512529A (en) * 2010-03-08 2013-04-11 ヒューレット−パッカード デベロップメント カンパニー エル.ピー. Data storage device and method
US8924645B2 (en) 2010-03-08 2014-12-30 Hewlett-Packard Development Company, L. P. Data storage apparatus and methods
JP2012068740A (en) * 2010-09-21 2012-04-05 Mitsubishi Electric Corp Information processing system
JP2013250962A (en) * 2012-05-01 2013-12-12 Semiconductor Energy Lab Co Ltd Semiconductor device
US9703704B2 (en) 2012-05-01 2017-07-11 Semiconductor Energy Laboratory Co., Ltd. Semiconductor device
JP2018088256A (en) * 2012-05-01 2018-06-07 株式会社半導体エネルギー研究所 Semiconductor device

Also Published As

Publication number Publication date
JP4364878B2 (en) 2009-11-18

Similar Documents

Publication Publication Date Title
US7818502B2 (en) Selectively powering down tag or data memories in a cache based on overall cache hit rate and per set tag hit rate
US20210056035A1 (en) Dynamic partial power down of memory-side cache in a 2-level memory hierarchy
US20180341588A1 (en) Apparatus and method for implementing a multi-level memory hierarchy having different operating modes
US10204039B2 (en) Host controlled hybrid storage device
JP4969805B2 (en) Adaptive memory system
US20140297919A1 (en) Apparatus and method for implementing a multi-level memory hierarchy
US9317448B2 (en) Methods and apparatus related to data processors and caches incorporated in data processors
JP2006012180A (en) Low power computer equipped with main and auxiliary processors
JP4364878B2 (en) Arithmetic processing unit
JP2012150815A (en) Coordination of performance parameters in multiple circuits
US9990293B2 (en) Energy-efficient dynamic dram cache sizing via selective refresh of a cache in a dram
US20210141555A1 (en) Method and apparatus for presearching stored data
US20170068304A1 (en) Low-power memory-access method and associated apparatus
US20220414009A1 (en) Data Pattern Based Cache Management
WO2005069148A2 (en) Memory management method and related system
KR101298171B1 (en) Memory system and management method therof
TWI526831B (en) A cache allocation scheme optimized for browsing applications
JP2001117817A (en) Control method for cache memory, computer system, hard disk drive, and hard disk controller
WO2015147868A1 (en) Magnetoresistive random-access memory cache write management
JP3935873B2 (en) Memory power management using prefetch buffer
JP2006209527A (en) Computer system
TW201732599A (en) Providing scalable dynamic random access memory (DRAM) cache management using DRAM cache indicator caches
JP2003248625A (en) Cache circuit, information processing unit, and electronic device
KR20140016405A (en) Memory system and management method therof
JP4664011B2 (en) Information processing apparatus and information processing method

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20081218

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20081218

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090414

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090605

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: 20090818

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090819

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120828

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Ref document number: 4364878

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120828

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120828

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130828

Year of fee payment: 4

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees