Abstract:
A smart memory (10) is provided that includes data storage (12 and 18) and a processing core (14 and 16) for executing instructions stored in the data storage area (12 and 18). Externally, smart memory (10) is directly accessible as a standard memory device. In a first mode of operation, the smart memory (10) is a data storage facility for an associated central processing unit (22). In a second mode of operation, the smart memory (10) is a storage facility for the processing core (14 and 16) and for central processing unit (22) for simultaneous execution of instructions. The central processing unit (22) controls the mode of operation and determines the instructions executed by the processing core (14 and 16). The wide data bus, available with an integrated processor/storage facility, permits certain processing operations to be off-loaded to the smart memory (10) where the processing operations can be performed more efficiently.

Description:
This application is a continuation of application Ser. No. 07/934,955, filed Aug. 25, 1992 now abandoned. 
    
    
     TECHNICAL FIELD OF THE INVENTION 
     This invention relates generally to processing, and more particularly to a method and apparatus for improved processing. 
     BACKGROUND OF THE INVENTION 
     Advances in processor technology have allowed for significant increases in processing speed. However, in applications that are intensive in off-processor chip memory accesses, such as speech, signal, and image processing applications, the gain in raw processing speed is often lost because of relatively slow access times to the off-chip memories. This problem is further aggravated since memory technology has focused on increased device density. With increased device density, the maximum bandwidth of a system decreases because multiple bus architectures are defeated. For example, a graphics application requiring storage of a 480×240 sixteen-bit image has four times the bandwidth if eight 256K memory chips are used, rather than two of the more dense 1 megabyte chips. 
     Several strategies have been proposed to overcome these difficulties. One such solution involves using an application specific integrated circuit (&#34;ASIC&#34;) to offload time-intensive tasks from the host CPU to increase overall system throughput. This alternative, however, requires one ASIC for each function to be offloaded, and requires dedicated memory for each ASIC. Consequently, a higher overall system cost is involved, and the system throughput is increased only for those tasks for which the ASIC was designed to handle, and not for tasks in general. 
     Another alternative involves the use of a co-processor. Such a solution allows for tasks to be offloaded from a host CPU and allows system memory to be shared by both the host CPU and the co-processor. With this system, however, total system bandwidth is decreased because of arbitration between the host processor and the co-processor. Furthermore, well-developed software is required to make full use and provide for &#34;seamless integration&#34; of the co-processor. 
     Another alternative involves the use of an application specific processor for offloading tasks from a host CPU. This alternative may require an expensive dedicated static RAM (&#34;SRAM&#34;) for use by the application specific processor. Thus, this alternative involves increased system cost. Furthermore, the SRAM is not available even when the attached application specific processor is idle, and well-developed software is needed for &#34;seamless integration&#34;. 
     As another solution to these difficulties, significant research and effort has been directed towards multiprocessing systems for increasing throughput as the limits of decreasing processor cycle times are approached. However, difficulties in designing multiprocessing systems, developing communication protocols for such systems, and designing software support routines have deterred proliferation of multiprocessing systems. Nonetheless, many applications in signal, speech and image processing are structured and lend themselves to partitioning and parallel processing. 
     Thus, a need has arisen for a device and method allowing for execution of several self-contained tasks in parallel within existing architectural frameworks. Furthermore, a need has arisen for improving processor to memory bandwidth without significant cost increases and without requiring customized, specific solutions for increasing system throughput. 
     SUMMARY OF THE INVENTION 
     In accordance with the present invention, an improved method and apparatus for processing is provided. In particular, data is stored in a data in the form of data logic signal groups storage of a smart memory. Within the smart memory, a processing core is operable to execute instructions in the form of instruction logic signal groups stored in the storage area and to read and write data stored in that storage. External connections to the smart memory are arranged such that the smart memory appears as a standard memory device to external devices. 
     An important technical advantage of the present invention is the fact that system throughput can be increased through use of the present invention, since it allows for parallel processing. 
     Another important technical advantage of the present invention is the fact that existing systems can be easily upgraded through use of the present invention because it appears externally as a standard memory device. Because the present invention appears externally as a standard memory device, parallel processing can be more easily implemented. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     For a more complete understanding of the present invention and the advantages thereof, reference is now made to the following description taken in conjunction with the accompanying drawings in which like reference numbers indicate like features and wherein: 
     FIG. 1a illustrates an external view of a device constructed according to the present invention; 
     FIG. 1b is a block diagram of an internal view of a device constructed according to the teachings of the present invention; 
     FIG. 2a is a block diagram of a typical uniprocessor system with standard memory devices; 
     FIG. 2b is a block diagram of a system including devices constructed according to the teachings of the present invention; 
     FIG. 3a is a block diagram illustrating bus traffic with a standard memory device; 
     FIG. 3b is a block diagram illustrating bus traffic in a system employing a device constructed according to the teachings of the present invention; 
     FIG. 4 is a block diagram of a memory map of a system including a device constructed according to the teachings of the present invention; 
     FIG. 5a is a block diagram illustrating processor control signals according to the present invention; and 
     FIG. 5b is a block diagram illustrating processor startup of a device constructed according to the teachings of the present invention. 
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     The problems discussed in the background of the invention are addressed with the present invention by integrating a processor into a large random access memory (&#34;RAM&#34;) in a single integrated circuit. Throughout this description, a device constructed according to the teachings of the present invention will be referred to, from time to time, as a smart memory or a smart DRAM (dynamic random access memory). These terms are used because a device constructed according to the teachings of the present invention appears externally as a random access memory chip and may have the pinout of a dynamic random access memory chip. 
     FIGS. 1a and 1b present external and internal views of a smart DRAM in accordance with the present invention. As shown in FIG. 1a, externally, a device 10 constructed according to the teachings of the present invention appears as a standard memory device with a memory-like pinout. Device 10 may have a pinout arrangement that is the same or substantially the same as standard memory pinouts, or Device 10 may have a pinout arrangement that includes a standard memory pinout plus additional pins, as will be discussed below. In either case the pins are to be arranged such that the Device 10 is directly accessible as a standard memory device by external devices. 
     Device 10 includes, by way of example, 42 pins which provide equivalent input and output signal groups of a typical DRAM. Device 10 may also include other pins in addition to those of a standard memory device, for additional functionality, as will be discussed below. It should be understood that the pinout illustrated in FIG. 1a is for example only, andthe pinout of Device 10 may be arranged to correspond to any standard memory pinout, such as, for example, a 48 pin DRAM, and as discussed, may include pins in addition to those of standard memories. A host CPU, such as an Intel 386 microprocessor, may access the device 10 as it would access a standard memory device. 
     In a particular embodiment, a smart DRAM constructed according to the teachings of the present invention may have a pinout as shown in FIG. 1a. The following table provides the pin, or lead, nomenclature for the pinoutas shown in FIG. 1a. 
     
         ______________________________________Pin Nomenclature    Standard Mode                 Smart Mode______________________________________A0-A11     Address inputs Address inputsD-DQ15     Data inputs/outputs                     Data inputs/outputsVcc        3.3-V power supply                     3.3-V power supplyVss        Ground         GroundW          WRite enable   WRite enableLCE        Lower CAS      Lower CASUCE        Upper CAS      Upper CASRE         RAS            RASM/RESET    No care        Mode/ResetTC         No care        Task completionIG         No care        Interrupt Generate______________________________________ 
    
     As shown in the table above, for a particular embodiment of the present invention, the device has 42 pins identical to a &#34;standard&#34; 16-Mbit DRAM device, with the three no-care pins used for special functions of the present invention, to be discussed. In a particular embodiment, the internal bus is 32 bits wide, and the memory space is byte addressable externally. The on-board processor has a 30-ns instruction cycle time, andthe chip operates on a 3.3-V power supply. The on-board processor can also be powered and grounded through additional pins, or the standard power andground pins. It should be understood that the above specifications are for a particular embodiment, and other specifications may be used without departing from the intended scope of the present invention. For example, awider bus than 32 bits, such as a 64 bit or 128 bit wide internal bus may be used. 
     As shown in the block diagram of FIG. 1b, internally device 10 appears likea processor with a large on-chip memory. In the illustrated embodiment, program and data reside in partitioned data storage, although program and data may reside in the same memory space of the data storage without departing from the intended scope of the present invention. A wide internal bus, inherently available inside memory devices, connects the processor with the memory. As shown in FIG. 1b, the internal bus may be 32bits wide. The program memory 12 is coupled to instruction decoder 14. Instruction decoder 14 decodes instructions residing within program memory12 and outputs control signals to a logic unit 16. Logic unit 16 is also coupled to program memory 12 and to data memory 18. 
     Instruction decoder 14 and logic unit 16 represent the processor core integrated into a memory according to the present invention. Processor cores to be integrated may range from fairly limited processor cores, suchas those including only an integer unit, to those including both fixed point and floating point multipliers. For example, a RISC-based integer unit (such as SPARC or MIPS) may be included as the processor core in the present invention. Typically, such integer units would occupy less than 10percent of the area of a 16-Mbit DRAM. Thus, RISC cores are attractive for integration because of their relatively small size compared to other processor cores. Processor cores using hardware multipliers in addition tothe integer unit may also be included. For example, a digital signal processor core, such as those used in the Texas Instruments TMS320C10-C50 digital signal processors may be integrated into smart memories according to the present invention. For example, use of a Texas Instruments TMS320C30 with its integer unit, floating point unit, 28 bit two-ported register file, and post control circuitry takes up only 22 percent of the area of a 16-Mbit DRAM. 
     As discussed above, program memory 12 and data memory 18 may occupy the same memory space or may be separately partitioned. A memory controller 20is also coupled to logic unit 16. Memory controller 20 is used to ensure that external accesses to the memory of device 10 have priority over internal accesses. Thus, memory controller 20 freezes logic unit 16 duringexternal accesses and then releases the logic unit 16 to resume processor execution after completion of the external access. External devices will have the highest memory access priority. Thus, for example, if a host processor tries to access the on-chip memory of a device constructed according to the teachings of the present invention while it is processing, then the on-chip processor will be halted. 
     FIG. 2a is a block diagram of a prior art uniprocessor system with four standard memory devices. As shown in FIG. 2a, the CPU 22 operates to storeand retrieve data from the memory devices 24, 26, 28, and 30 through the use of an address and data bus. As an example, CPU 22 may comprise a TMS 320 made by Texas Instruments Incorporated, while memory devices 24-30 maycomprise 32KX8 DRAMs. 
     FIG. 2b illustrates a system including two smart DRAMs 32 and 34 as shown in FIGS. 1a and 1b. As can be seen from FIGS. 2a and 2b, two of the standard memory devices shown in FIG. 2a have been replaced by devices constructed according to the teachings of the present invention without the need for additional hardware. Smart DRAMs 32 and 34 appear as typical memory devices, and thus are connected as if they were such memory devices. Thus, such smart memories can convert an existing uniprocessor system, such as a personal computer, into a powerful multiprocessor systemwithout major system redesign. As shown in FIG. 2b, the two smart memory devices may be used to execute tasks in parallel with operations performedby the CPU. 
     Because of the design of the present invention, significant advantages are realized to systems including smart memories. One such advantage is systemthroughput. System throughput increases because of the simultaneous execution of several self-contained tasks. For example, in a personal computer environment, one smart memory may be executing a graphics application downloaded by a host CPU and preparing that data for output toa graphics display, while another smart memory may be executing a downloaded speech recognition routine, and still another smart memory may be sending FAXes in the background. These tasks are performed through the control of a controlling CPU. With the tasks distributed among the smart memories as described above, the only task for the central CPU would be tomove the data from the smart memories to the appropriate outputs, without having to perform any processing on the data within those smart memories. 
     Another advantage of the present invention is improved CPU to memory bandwidth. Instead of fetching raw data from the memory, processing that data, and writing the processed results back to the memory, the host CPU now fetches only the processed data or information from the memory. Traffic on the system bus is therefore reduced. FIGS. 3a and 3b illustratean example of reduced traffic due to use of a smart DRAM constructed according to the teachings of the present invention. In certain applications, such as speech recognition, vectors must often be multipliedby various matrices. For example, a vector A may be multiplied by a matrix B to result in a vector C. As shown in FIG. 3a, in a conventional prior art system a host CPU fetches the elements of matrix B (raw data), multiplies them with the elements of vector A, and writes the products back to memory. With a system using a smart DRAM constructed according to the teachings of the present invention, the CPU moves the elements of vector A to the smart memory 36 containing matrix B, and the smart memory 36 then calculates C by multiplying A and B, thus freeing the host CPU from this vector multiplication. For a vector size of 100 and the above example, the traffic on the system bus is reduced by a factor of 100 when a smart DRAM constructed according to the teachings of the present invention is used. 
     Another advantage of the present invention is that it can serve two separate functions. In the default mode, devices according to the present invention serve as memory devices. However, as will be discussed below, they can also be switched into a &#34;smart&#34; mode and made to execute specifictasks by downloading appropriate software. In contrast, coprocessor cards in current computers physically occupy a slot. When idle, their dedicated memory is not available to the host CPU. 
     The present invention also allows ease of upgrading functionality in existing systems. Designing memory subsystems and adding them to existing processor systems is easier than designing and adding processor subsystems. Today&#39;s memories are standardized components, in stark contrast to processors, and thus devices constructed according to the teachings of the present invention, because they are pin-compatible with memory chips, may be easily integrated into existing systems. Furthermore,since the address space of a processor is typically populated with several memory devices, each time a smart DRAM is added to a system, not only is additional memory added, but also additional processing capability. Thus, as the computational needs of a system grow, the system can be easily and quickly scaled up by adding smart DRAMs constructed according to the teachings of the present invention. FIG. 4 illustrates a typical processorand memory system and its inherently parallel structure. Thus, smart memories designed according to the present invention provide for parallel processing with minimum design change, since they can be added to systems just as standard memory devices are. 
     Another advantage of the present invention is increased processing rates because of the locality of the memory and wide internal bus structure. Since all of the data needed for a program being executed on a smart DRAM are on-chip, the processing speed is faster than if the data were off-chip. Furthermore, wide internal busses are more feasible inside a memory chip than across chip boundaries because of size and electrical characteristic considerations. 
     In a preferred approach, the present invention has two modes, &#34;smart&#34; and &#34;standard&#34;. In the &#34;smart&#34; mode, the processor core is enabled to process data in the data memory 18, if instructed to begin processing. In the &#34;standard&#34; mode, the processing core is prevented from processing. The default operating mode is the &#34;standard&#34; mode. In the &#34;standard&#34; mode, thedevice operates as a memory device. As shown in FIG. 5a, the host processor38 of the system dynamically switches the operating mode by writing to a mode pin of the smart memory 10. The mode pin may comprise a no care pin on a typical memory device such as pin 11 in FIG. 1a. By using a mode pin,the operating mode of the device is guaranteed, and software bugs cannot inadvertently switch the mode. In another alternative, the mode pin could be used as an extra address pin. Thus, when addressed in one particular range, the smart memory would function in the standard mode. When addressed in another range, it would function in the smart mode. 
     In another embodiment, the mode of a smart memory device could be switched without the use of a mode pin. With this approach, a fixed memory locationis allocated as an operating mode switch. For example, a particular location within data memory 18 of FIG. 1b can be reserved as a mode switch. The host processor can switch operating modes by addressing and writing fixed patterns to this memory location across address and data busses as shown in FIG. 5a. The smart processor senses the pattern, or sequence of patterns, and switches modes accordingly. Other alternatives for selecting the mode of the device that do not require an extra pin likea mode pin include write-per-bit type functions or other design-for-test (&#34;DFT&#34;) functions. 
     The mode pin can also be used as a reset pin. Because a smart DRAM according to the present invention includes a processor, a reset function for the processor is needed. This reset can be accomplished through the mode pin--every time the mode is switched to &#34;smart,&#34; a reset takes place.As an alternative embodiment, an additional reset pin can be used. Furthermore, the reset function may be accomplished without the use of pinsignals, but by writing patterns to particular memory locations within the smart DRAM across address and data busses as shown in FIG. 5a, as discussed in connection with the mode switch. The reset function could be associated with the same memory location as the mode switch, or a separatememory location. FIG. 5a illustrates the reset pin in combination with the mode pin. 
     Once in the &#34;smart&#34; mode, the host processor may start and stop the processor on the smart DRAM by writing fixed patterns to a fixed &#34;go&#34; location as shown in FIG. 5b. If not in the &#34;smart&#34; mode, then the processor on the smart DRAM cannot begin processing, even if the &#34;go&#34; instruction has been received. A host CPU 38 addresses the go memory location 40 of smart DRAM 10 and writes the fixed &#34;go&#34; pattern to that location. The processor on the smart memory device will then begin to execute, provided the device is in the smart mode. After the smart memory has completed its task, it can signal the processor of its task completionthrough the TC pin. The TC pin, as shown in the above table and FIG. 5a, may comprise a no care pin of a standard memory device such as pin 12 in FIG. 1a. This TC pin may be connected to the interrupt line of a host CPU.It should be understood that the TC pin need not be used to signal task completion. For example, a particular memory location could be reserved asa status memory location within the smart DRAM. The host processor could poll this status memory location for a particular code indicating that a task has been completed by the smart DRAM through use of the address and data busses as shown in FIG. 5a. As another approach, the smart DRAM couldhave a reserved memory location for an estimate of the length of time required for completion of its task. The host CPU could read this memory location and then request the process data after the estimated length of time has elapsed. 
     As shown in the preceding table and FIG. 5a, an interrupt generate signal is also provided. This signal may be accomplished through a pin such as a no care pin or an additional pin, or, as discussed in connection with the mode switch, through a &#34;soft&#34; signal, by writing appropriate codes to particular memory locations across address and data busses shown in FIG. 5a. The interrupt generate signal causes the processor of the smart DRAM to interrupt its current task and process an interrupt task. Upon completion of the interrupt task, the initial task is resumed. The ID or address of the interrupt task can be passed by the host processor along with the interrupt generate signal. 
     For additional processing abilities, SMART DRAM 10 may include bus request and bus grant signals, for use in connection with a bus arbitrator 42 as shown in FIG. 5a. With this capability, SMART DRAM 10 can directly take control of the bus to perform, for example, I/O functions, to provide for more complete parallel processing. 
     The data read from and written to a smart DRAM by a host CPU is performed conventionally. The host CPU writes input data to the smart DRAM and readsdata to be output by the smart DRAM. If a 16 bit wide external bus is used with a 32 bit host CPU, for example, the processor will have to make two reads and writes to accomplish 32 bit data transfers. 
     Although the present invention has been described in detail, it should be understood the various changes, substitutions and alterations can be made without departing from the spirit and scope of the invention as defined solely by the appended claims.