Selectively operable cache memory

A cache memory in which the address of a required data item is compared with address data stored in a plurality of tag memory sections, a match indicating that the required data item is stored in a corresponding data memory section, is operable in at least a first and a second mode, whereby:(i) in the first mode, only that one of the data memory sections in which the required data word is stored is enabled for operation once the appropriate data memory section has been identified by an address match with the corresponding tag memory section; and(ii) in the second mode, two or more (and preferably all) of the data memory sections are enabled for operation substantially concurrently with the comparison of the required address and the addresses stored in the tag memory sections, an address match being used to select the output of one of the data memory sections.

Skip to:  ·  Claims  ·  References Cited  · Patent History  ·  Patent History

Claims

1. A data processing apparatus comprising:

(A) a cache memory having a plurality of data memory sections, each storing one or more data words, each said data memory section being operable to output a stored data word in response to an enable signal;
a plurality of tag memory sections, each corresponding to a respective data memory section, said tag memory sections storing address information indicative of a memory address of each data word stored in said corresponding data memory section; and
means for comparing a memory address of a required data word with said address information stored in said tag memory sections, said comparing means generating match signals indicating whether said required data word is stored in one of said data memory sections and, if so, identifying one of said data memory sections in which said required data word is stored;
said cache memory being selectively operable in at least a first mode and a second mode, in which:
(i) in said first mode, only that one of said data memory sections in which said required data word is stored is enabled for operation in response to said match signals; and
(ii) in said second mode, two or more of said data memory sections are enabled for operation substantially concurrently with operation of said comparing means, said match signals being used to select the output of one of said data memory sections;
(B) a prefetch unit for prefetching and buffering data processing instructions from said cache memory; and
(C) means responsive to said instructions stored in said prefetch unit for controlling said cache memory to operate in either said first mode or said second mode of operation.

2. A data processing apparatus according to claim 1, in which each data memory section is operable to store an array of data words, a position of each data word within said array being determined by selected bits of the memory address of said data word.

3. A data processing apparatus according to claim 1, comprising a multiplexer connected to receive data output by each of said data memory sections, said multiplexer being operable to select the output of one of said data memory sections in response to said match signals.

4. A data processing apparatus according to claim 1, comprising logic means for supplying said match signals to said data memory sections as respective enable signals in said first mode of operation, and for enabling all of said data memory sections in said second mode of operation.

5. A data processing apparatus according to claim 1, in which said prefetch unit is operable to select said first mode if at least a predetermined number of instructions are buffered in said prefetch unit.

6. A data processing apparatus according to claim 5, in which said prefetch unit is operable to select said first mode if a branch instruction is detected in said instructions buffered in said prefetch unit.

7. A data processing apparatus according to claim 1, in which said prefetch unit is operable to select said first mode if a branch instruction is detected in said instructions buffered in said prefetch unit.

8. A cache memory comprising:

a plurality of data memory sections, each storing one or more data words, each said data memory section being operable to output a stored data word in response to an enable signal;
a plurality of tag memory sections, each corresponding to a respective data memory section, said tag memory sections storing address information indicative of a memory address of each data word stored in said corresponding data memory section; and
means for comparing a memory address of a required data word with said address information stored in said tag memory sections, said comparing means generating match signals indicating whether said required data word is stored in one of said data memory sections and, if so, identifying one of said data memory sections in which said required data word is stored;
said cache memory being selectively operable in at least a first mode and a second mode, said first mode or said second mode being selected in response to instructions stored in a prefetch unit for prefetching and buffering data processing instructions from said cache memory, in which:
(i) in said first mode, only that one of said memory sections in which said required data word is stored is enabled for operation in response to said match signals; and
(ii) in said second mode, two or more of said data memory sections are enabled for operation substantially concurrently with operation of said comparing means, said match signals being used to select the output of one of said data memory sections.

9. A central processing unit for accessing data stored in a cache memory according to claim 8, said central processing unit comprising:

a prefetch unit for prefetching and buffering data processing instructions from said cache memory; and
means responsive to said instructions stored in said prefetch unit for controlling said cache memory to operate in either said first mode or said second mode of operation.
Referenced Cited
U.S. Patent Documents
4317181 February 23, 1982 Teza et al.
4862348 August 29, 1989 Nakamura
5018061 May 21, 1991 Kishigami et al.
5083266 January 21, 1992 Watanabe
5519667 May 21, 1996 Harston
Foreign Patent Documents
0 067 657 A2 December 1982 EPX
0 180 369 A2 May 1986 EPX
Patent History
Patent number: 5717892
Type: Grant
Filed: May 6, 1997
Date of Patent: Feb 10, 1998
Assignee: Advanced RISC Machines Limited (Cambridge)
Inventor: William Henry Oldfield (Ely)
Primary Examiner: Eddie P. Chan
Assistant Examiner: Hong C. Kim
Law Firm: Fenwick & West LLP
Application Number: 8/852,120
Classifications
Current U.S. Class: 395/455; 395/403; 395/405; 395/42103; 395/438; 395/464; 395/494
International Classification: G06F 1200;