DRAM controller

Abstract: A DRAM controller comprises an address output con­ troller (30) for transferring an address-designating signal to a dynamic RAM, a data output controller (32, 34, 36) for transferring data to be written into and read-out from that memory region of the dynamic RAM which is designated by the address-designating signal, and a control circuit responsive to a mode-designating signal for generating various control signals corre­ sponding to an access mode of the dynamic RAM designated by the mode-designating signal, and supplying the con­ trol signals to the dynamic RAM, address output control­ ler (30), and data output controller (32, 34, 36) in a predetermined sequence. In the DRAM controller, the con­ trol circuit includes a signal-generating unit (50B) for generating the control signals in a specific access mode which requires an access time longer than the machine cycle of a processor for generating the address-­ designating signal, the data to be written, and the mode-designating signal, and for delaying the generating of the control signals every time the designation of the specific access mode is repeated.

Description: The present invention relates to a DRAM controller for accessing a dynamic RAM (DRAM). Most computers have a dynamic RAM, a microprocessor, and a DRAM controller. A dynamic RAM has various access modes such as read mode, write mode, refresh mode, read-modify-mode, and the like. The DRAM controller is connected between the DRAM and the microprocessor. It generates various control signals in a predetermined sequence under the control of the microprocessor, and supplies these signals to the dynamic RAM, thereby controlling the dynamic RAM. More specifically, the DRAM controller receives an address signal A, an address strobe signal AS , a read/write control signal R/ W , data D, and a data strobe signal DS from the microprocessor, and generates a row-address strobe signal RAS , a column-address strobe signal CAS , a memory address signal MA, an output enable signal OE , and a write enable signal WE , which are supplied, as control signals, to the dynamic RAM. The operation of the conventional DRAM controller will be explained, with reference to Figs. 1(A) to 1(M) which form a timing chart. A clock signal CLK shown in Fig. 1(A) is supplied to the microprocessor and the DRAM controller, both incorporated in a computer. The DRAM controller sets the dynamic RAM used in the computer to the read-modify-write mode while it receives the first to fifth clock pulses. As long as the dynamic RAM is set to the read-modify-write mode, data RMD is read from the dynamic RAM. This data RMD and the data D supplied from the microprocessor are subjected to an operation such as AND operation or OR operation, and the results of this operation is written into the dynamic RAM. To be more specific, the microprocessor first outputs an address signal A as is illustrated in Fig. 1(B), and then outputs a address strobe signal AS and a read/write control signal R/ W , both at low level, as is shown in Figs. 1(C) and 1(D). Thereafter, the microprocessor generates data D, as can be seen from Fig. 1(E), and then outputs a data strobe signal DS at the low level as is shown in Fig. 1(F). After the address strobe signal AS has fallen to the low level, the DRAM controller supplies the dynamic RAM with a memory address signal MA which consists of the upper bits of the address signal A, as can be understood from Fig. 1(I). Further, it outputs a row-address strobe signal RAS at the low level. Thereafter, the DRAM controller supplies the dynamic RAM with a memory address signal MA which consists of the lower bits of the address signal A. Also, it outputs a column-address strobe signal CAS at the low level, at the trailing edge of the third clock pulse, as is shown in Fig. 1H. At the same time the DRAM controller outputs an output enable signal OE at the low level, as is shown in Fig. 1(J). Hence, when data RMD is read from that region of the dynamic RAM which is designated by the memory address signal MA, the DRAM controller performs an operation on this data RMD and the data D. The results of this operation, or write data WMD, are supplied to the dynamic RAM. Then, the DRAM controller outputs a write enable signal WE at the low level. The write enable signal WE is supplied to the dynamic RAM, whereby the write data WMD is stored in that region of the dynamic RAM which has been designated by the memory address signal MA. Assuming that the machine cycle of the microprocessor is a 4-clock pulse period, the read-modify-write operation is terminated at the leading edge of the fifth clock pulse. Therefore, the DRAM controller brings the microprocessor into the wait state at the leading edge of the fifth clock pulses, thereby causing the microprocessor to operate in synchronism with the dynamic RAM. The time during which the dynamic RAM is accessed can be shortened by, for example, operating the microprocessor at a higher speed. However, this method cannot eliminate the wait period of the microprocessor, and does not serve to increase the data-processing speed of the computer very much. Furthermore in EP 0 109 298 A3 from which proceeds the preamble of claim 1, a similar computer system is disclosed as described above; On this system, a memory controller is provided which responds to the recognition signal ANYRAS to provide an output strobe DOUTSTB DOUTLTCH to enter both read out words into latches. Either of the further signals from the controller DRVDOUTO, 1 (or both in sequence) cause one or both words to be read out in sequence to the data bus. The object of the present invention is to provide a DRAM controller capable of shortening the cycle time of a dynamic RAM which is repeatedly accessed in various modes. The object is attained by a computer system as described in claim 1. Due to the delay of generating the control signals, the processor need not be set in a waiting state, thus providing a time long enough to set up the dynamic RAM. In other words, the DRAM controller can shorten the cycle time of the dynamic RAM more than the conventional DRAM controller which sets the processor into the waiting state every time the read-modify-write mode is designated. This invention can be more fully understood from the following detailed description when taken in conjunction with the accompanying drawings, in which: Figs. 1(A) to 1(M) form a timing chart representing the operation of the conventional DRAM controller; Fig. 2 is a block diagram of a computer system comprising a microprocessor, a dynamic RAM, and a DRAM controller according to the present invention; Fig. 3 is a block diagram illustrating the DRAM controller shown in Fig. 2; Figs. 4(A) to 4(M) form a timing chart explaining when the DRAM controller (Fig. 3) generates signals in the case where the dynamic RAM is set to the read-modify-write mode twice continuously; and Figs. 5(A) to 5(M) form a timing chart explaining when the DRAM controller (Fig. 3) generates signals in the case where the dynamic RAM is set to the read-modify-write mode five times continuously. A DRAM controller according to an embodiment of the invention will now be described, with reference to Figs. 2 and 3. Fig. 2 is a block diagram showing a computer system comprising a DRAM controller 20, a microprocessor 22, and a dynamic RAM 24. The controller 20 is connected between the microprocessor 22 and the dynamic RAM 24. The microprocessor 22 is, for example, a general-purpose processor. It has address terminals A1 to A23, data terminals D0 to D15, a read/write control terminal R/ W , an address strobe terminal AS , an upper-data strobe terminal UDS , a lower-data strobe terminal LDS , a data acknowledge terminal DTACK , and a clock terminal CLK. The address terminals Al to A9 are connected to the row-address terminals RA0 to RA8 of the DRAM controller 20. The address terminals A10 to A18 are connected to the column-address terminals CA0 to CA8 of the DRAM controller 20. The address terminals A19 to A23, the read/write control terminal R/ W , and address strobe terminal AS are connected to the input terminals of a decoder 26. The output terminals of the decoder 26 are coupled to the chip select terminals CS1 to CS5 of the DRAM controller 20. The decoder 26 decodes the input signals supplied as a mode-designation signal, and supplying an enable signal to one of the chip select terminals CS1 to CS5. The enable signal is supplied to the terminal CS1 in the read-modify-write mode, to the terminal CS2 in the write mode, to the terminal CS3 in the read mode, to the terminal CS4 in the refresh mode, and to the terminal CS5 in the option mode. The data terminals D0 to D15 of the microprocessor 22 are connected to the data terminals D0 to D15 of the DRAM controller 20. The upper-data strobe terminal UDS and lower-data strobe terminal LDS of the DRAM controller 20 are connected to the input terminals of an AND circuit 28. The output terminal of the AND circuit 28 is connected to the data strobe terminal DS of the DRAM controller 20. The data acknowledge terminal DTACK of the microproces sor 22 is coupled to the ready terminal RDY of the DRAM controller 20. A clock signal CLK (25MHz) is supplied to the clock terminal CLK of the microprocessor 22, and also to the clock terminal CLK of the DRAM controller 20. The dynamic RAM 24 is a combination of two dynamic RAMs 24A and 24B, each being of 8-bit word configuration. Either dynamic RAM has memory address terminals MA0 to MA8, a row-address strobe terminal RAS , a column-address strobe terminal CAS , a write enable terminal WE , and an output enable terminal OE , which are connected to their equivalents of the DRAM controller 20. The RAMs 24A and 245B have a data terminal each. The data terminals of the dynamic RAM 24A are connected to the memory data terminals MD0 to MD7 of the DRAM controller 20. The data terminals of the dynamic RAM 24B are connected to the memory data terminals MD8 to MD15 of the DRAM controller 20. Fig. 3 illustrates the DRAM controller 20 in greater detail. As this figure shows clearly, the DRAM controller 20 comprises an address output controller 30, a data output controller 32, a modifying circuit 34, and a latching circuit 36. The address output controller 30 receives the row-address signal RA0 - RA8 and column-address signal CA0 - CA8 from the microprocessor 22, selects either the row-address signal or the column-address signal in accordance with an address select signal SL1 (later described in detail), and supplies the selected address signal, as a memory address signal MA0 - MA8, to the dynamic RAM 24. The latching circuit 36 latches the data MD0 - MD15 read-out from the dynamic RAM 24 under the control of a latch trigger signal TR, and supplies this data to the modifying circuit 34. The modifying circuit 34 performs a specific operation (an AND or an OR operation) on the data D0 - D15 supplied from the microprocessor 22 and the data MD0 - MD15 supplied from the latching circuit 36, and supplies the results of the operation to the data output controller 30. The data output controller 30 selects either the data D0 - D15 supplied from the microprocessor 22 or the data supplied from the modifying circuit 34, in accordance with a data select signal SL2 (later described), and supplies the selected data to the dynamic RAM. The DRAM controller 20 further comprises a first signal-generating unit 50A, a second signal-generating unit 50B, and a signal output controller 52. The first signal-generating unit 50A generates various control signals in a specific access mode which requires an access time equal to or shorter than the cycle time of the microprocessor 22. The unit 50A has four signal generators 50A-1 to 50A-4 connected to the respective chip select terminals CS2 to CS5, so as to receive an enable signal supplied from the decoder 26. In response to the enable signal, each of the signal generator 50A-1 to 50A-4 generates corresponding control signals, such as a row-address strobe signal RAS , a column-address strobe signal CAS , a write enable signal WE , an output enable signal OE , a latch trigger signal TR, an address select signal SL1 and a data select signal SL2 at a predetermined sequence. The data strobe signal DS and clock signal CLK are referred to in this signal generation. The second signal-generating unit 50B generates various control signals in a specific access mode which requires an access time longer than the cycle time (i.e., a period of four clock pulses) of the microprocessor 22. The unit 50B has a cycle condition circuit 50B-1 and three signal generators 50B-2 to 50B-4. The cycle condition circuit 50B-1 is connected to the chip select terminal CS1, so as to receive an enable signal supplied from decoder 26. In response to the enable signal, the circuit 50B-1 generates one of flag signals F1, F2, and F3. The signal generators 50B-2, 50B-3, and 50B-4 are connected to receive the flag signals F1, F2, and F3, respectively. In response to the flag signal F1, the signal generator 50B-2 generates a row-address strobe signal RAS , a column address strobe signal CAS , a write enable signal WE , an output enable signal OE , a latch trigger signal TR, an address select signal SL1, and a data select signal SL2 at a predetermined sequence. Similarly, the signal generators 50B-3 and 50B-4 generate these signals at the predetermined sequence, in response to the flag signals F2 and F3, respectively. The signals output by the signal generator 50B-3 are delayed by a predetermined period with respect to those output by the signal generator 50B-2, and the signals output by the signal generator 50B-4 are delayed by a predetermined period with respect to those of the signals output by the signal generator 50B-3. Suppose the dynamic RAM 24 is repeatedly set to the read-modify-write mode. Then, when the dynamic RAM 24 is set to the read-modify-write mode for the first time, the cycle condition circuit 50B-1 outputs the flag signal F1 to the signal generator 50B-2, then the flag signal F2 to the signal generator 50B-3, and finally the flag signal F3 to the signal generator 50B-4. Thereafter, every time the dynamic RAM 24 is set to the read-modify-write mode, the circuit 50B-1 first outputs the flag signal F2 to the signal generator 50B-3 and then the flag signal F3 to the signal generator 50B-4. In other words, the generators 50B-3 and 50B-4 are selected alternately as long as the dynamic RAM 24 is set to the read-modify-write mode repeatedly. When the dynamic RAM 24 is set to any other access mode and set to the read-modify-write mode again, the cycle condition circuit 50B-1 then output the flag signal F1, thereby selecting the signal generator 50B-2. Every time the signal generator 50B-4 is selected, the flag signal F3 is supplied to the signal output controller 52. The signal output controller 52 receives the control signals which any signal generator 50A-1, 50A-2, 50A-3, 50A-4, 50B-2, 50B-3, or 50B-4 generates while the dynamic RAM 24 is set to any access mode. More specifically, it receives the row-address strobe signal RAS , the column-address strobe signal CAS , a write enable signal WE , the output enable signal OE , the latch trigger signal TR, the address select signal SL1, and the data select signal SL2. The controller 52 supplies the signals RAS , CAS , WE , and OE to the dynamic RAM 24, the latch trigger signal TR to the latching circuit 36, the address select signal SL1 to the address output controller 30, and the data select signal SL2 to the data output controller 32. Further, the signal output controller 52 usually generates a ready signal RDY during the machine cycle of the microprocessor 22. If the generation of the control signals is delayed in excess, the dynamic RAM can no longer operate accurately. Therefore, the signal output controller 52 receives the flag signal f3 so as to detect that the sum of the period by which the control signals are delayed reaches the predetermined value. When the flag signal is supplied from the cycle condition circuit 50B-1 to the signal output controller 52, the controller 52 generates the ready signal RDY immediately after the machine cycle of the microprocessor 22, setting the microprocessor 22 into an wait state. The microprocessor 22 remains in the wait state for the duration of one clock pulse additionally generated in the read-modify-write mode. Figs. 4(A) to 4(M) form a timing chart explaining when the DRAM controller 20 generates signals in the case where the dynamic RAM 24 is set to the read-modify-write mode twice continuously. It should be noted that the dynamic RAM 24 is very often set to the read-modify write mode twice under the control of the microprocessor 22. When the dynamic RAM 24 is set to this specific access mode in the first memory access cycle, the flag signal F1 output from the cycle condition circuit 50B-1 to the signal generator 50B-2 is enabled. The signal generator 50B-2 therefore outputs DRAM control signals. Of these control signals, the row-address strobe signal RAS is disabled at time P1, after the machine cycle of the microprocessor 22. When the dynamic RAM 24 is set to the read-modify-write mode in the second memory access cycle, the flag signal F2 output from the circuit 50B-1 to the signal generator 50B-3 is enabled. As a result of this, the signal generator 50B-3 outputs DRAM control signals. Of these signals, the row-address strobe signal RAS is generated at time P2 in the second memory access cycle, that is, delayed with respect to the first row-address strobe signal RAS which has been generated at time P3 in the first memory access cycle. The second row-address strobe signal RAS is disabled at time P4, after the second machine cycle of the microprocessor 22. Even if the read-modify-write operation ends with a delay equivalent to one to two clock pulses, the dynamic RAM 24 can be refreshed in the next memory access cycle, i.e., the third memory access cycle. At the start of the fourth memory access cycle, during which the dynamic RAM 24 is set to be read-modify-write mode, the flag signal F1 supplied from the cycle condition circuit 50B-1 to the signal generator 50B-2 is enabled. Hence, the signal generator 50B-2 generates a row-address strobe signal RAS at time P5, with the same delay as the row-address strobe signal RAS generated in the first memory access cycle (i.e., the first read-modify-write operation). Thereafter, in the fifth memory access cycle et seq., the DRAM controller 20 performs the sequence of the same operations as is described above, without the necessity of setting the micro processor 22 into a wait state. In order to access the dynamic RAM 24 for a time shorter than the machine cycle of the microprocessor 22, it suffices to supply the dynamic RAM 24 with the DRAM control signals generated by the first signal-generating unit 50A. Figs. 5(A) to 5(M) are a timing chart explaining when the DRAM controller 20 generates signals in the case where the dynamic RAM is set to the read-modify-write mode five times continuously. With reference to these figures, it will be explained how the controller 20 operates in this case. The DRAM controller 20 operates exactly the same way as in the case where the dynamic RAM 24 is set to the read-modify-write mode twice continuously, during the first and second memory access cycles. At the start of the third memory access cycle, the flag signal F3 supplied from the cycle condition circuit 50B-1 to the signal generator 50B-4 is enabled. Hence, the signal generator 50B-4 generates a row-address strobe signal RAS at time P7 delayed with respect to the signal RAS generated by the signal generator 50B-3 in the second machine cycle. If the row-address strobe signal RAS generated from signal generator 50B-4 is disabled, without setting the microprocessor 22 into a wait state as in the first and second memory access cycles, a sufficiently refresh time cannot be acquired in the fourth memory access cycle. To provide a sufficient refresh time in the third machine cycle, the microprocessor 22 is set in the wait state for a time equivalent to one clock pulse during the third memory access cycle. As a result of this, the row-address strobe signal RAS is disabled at time P8. Therefore, the delay in the row-address strobe signal RAS is reduced. The dynamic RAM 24 does not fail to operate even if the dynamic RAM is set to the read-modify-write mode in the fourth memory access cycle. In this cycle, the flag signal F2 supplied from the cycle condition circuit 50B-1 to the signal generator 50B-3 is enabled, whereby the signal generator 50B-3 outputs a row-address strobe signal RAS , in the same way as in the second memory access cycle. In summary, even if the dynamic RAM 24 is set to the read-modify-write mode five times continuously, DRAM control signals are appropriately generated from one of the signal generators 50B-2 to 50B-4 in the first to fifth memory access cycles. Therefore, the microprocessor 22 is not set to a wait state in the first, second, and fourth memory access cycles though it is set to the wait state in the third and fifth memory access cycles. As has been described, to set the dynamic RAM 24 to the read-modify-write mode twice continuously, it is unnecessary to set the microprocessor 22 into a wait state. Further, even if the dynamic RAM 24 is to be set to the read-modify-write mode five times continuously, it suffices to set the microprocessor 22 at a wait state when the dynamic RAM 24 is set to this specific access mode for the third time and the fifth time. Hence, the cycle of the read-modify-write mode is shortened as compared to the case where the microprocessor 22 is set to a wait state every time the dynamic RAM 24 is set to the read-modify-write mode. Therefore, the DRAM controller 20 shortens the access time of the dynamic RAM 24, more particularly the cycle time thereof. Additional advantages and modifications will readily occur to those skilled in the art. Therefore, the invention in its broader aspects is not limited to the specific details, representative device, and illustrated example shown and described herein. Accordingly, various modifications may be made without departing from the invention as defined by the appended claims.

Claims: "A computer system comprising a processor with a given machine cycle length and a DRAM controller responsive to control signals from the processor, the DRAM controller comprising:" address output means (30) for transferring an address-designating signal to a dynamic RAM (24); data output means (32, 34, 36) for transferring data to be written into and read-out from that memory region of the dynamic RAM (24) which is designated by the address-designating signal; and control means (50A,50B,52) responsive to a mode-designating signal for generating various control signals corresponding to an access mode of the dynamic RAM (24) designated by the mode-designating signal, and supplying the control signals to said dynamic RAM (24), address output means (30), and data output means (32, 34, 36) in a predetermined sequence; characterized in that said control means (50A,50B,52) includes signal-generating means (50B) for generating the control signals in a specific access mode which requires an access time longer than the machine cycle of the processor (22) in which machine cycle the processor generates the address-designating signal, the data to be written, and the mode-designating signal, and for delaying the generating of the control signals with regard to this generating in a first machine cycle, in every consecutive machine cycle the designation of the specific access mode is repeated. A computer system according to claim 1, characterized in that said control means (50A,50B,52) includes wait control means (52) for setting the processor (22) in a waiting state when the sum of the period by which the control signals are delayed reaches a predetermined value. A computer system according to claim 2, characterized in that said signal generating means (50B) includes a plurality of signal generators (50B-2 to 50B-4) for generating said control signals and selecting means (50B-1) for selecting one of said signal generators (50B-2 to 50B-4) in response to the mode-designating signal designating said specific access mode. A computer system according to claim 3, characterized in that said plurality of signal generators includes a first signal generator (50B-2) for generating said control signals, a second signal generator (50B-3) for generating said control signals with a first predetermined delay, and a third signal generator (50B-4) for generating the control signals with a second predetermined delay larger than said first predetermined delay. A computer system according to claim 4, characterized in that said selecting means includes means (50B-1) for sequentially selecting said first to third signal generators (50B-2 to 50B-4). A computer system according to claim 5, characterized in that said wait control means includes means (52) for setting said processor (22) into a waiting state when it is detected that said third signal generator (50B-4) has been selected. A computer system according to claim 6, characterized by further comprising decoder means (26) for decoding signals supplied from an address strobe terminal ( AS ), read/write control terminal (R/ W ), and part of address terminals (A1 - A23) of said processor (22) as said mode-designation signal. A computer system according to claim 1, characterized in that said specific access mode is a read-modify-write mode. A computer system according to claim 1, characterized in that said control means (50A,50B,52) includes second signal-generating means (50A) for generating the control signals in an access mode which requires an access time equal to or shorter than the machine cycle of said processor (22).

Inventors: TAKAHASHI TOSHIYASU, TAKAHASHI, TOSHIYASU
Applicants: TOKYO ELECTRIC CO LTD, TOKYO ELECTRIC CO., LTD.
Application year: 1990
Main classification: G11C11
IPC codes: G11C11