Interpretation of basic concepts cache

Interpretation of basic concepts cache

Cache (the Cache, referred to as a cache), the original sense to refer to the general access speed faster than a random access memory (RAM) one kind of RAM, it is not normally used as system main memory DRAM technology, the use of expensive but faster SRAM technology. Cache is located between the CPU and the DRAM, the access speed is generally a small-scale fast SRAM configuration memory.
At present, the cache concept has been expanded, not only between the CPU and main memory have Cache, and between memory and hard drive are also Cache (disk cache), and even between the hard disk and the network also has a sense of Cache── called temporary Internet files folder or web content caching. Any of the velocity difference between the two hardware larger, both the structure for coordinating data transfer speed difference, may be referred to as Cache.

working principle

1, pre-read: When the hard disk controlled by the CPU instruction starts reading the data, the control chip to control the head will be on the hard disk data in the cluster being read one or several clusters in the read buffer when it is desired to read remove one or several data cluster when the hard disk is not required to read data again, transmitting the data directly to the cache memory on it, due to the much higher rate than the rate of the cache read and write heads, it is possible to achieve significant improvement in performance.
2, is written: when an instruction to write data to the hard disk, not immediately write data to the disk, but is temporarily stored in the cache, then sends a "Data write" signal to the system , then the system will think the data has been written, and continue with the following work, while the hard disk is idle (read or write when not) when then write data onto the disk cache.
3, temporary storage: Some data will often need to access, like the internal hard disk cache (a kind of scratchpad) will frequently read some of the data stored in the cache, it can directly read again from cache direct transmission.
Interpretation of basic concepts cache

The role of significance

Temporary data processing results, and provides access to the next use. In many cases, data processing or data acquisition can be very time-consuming, when the request for the amount of data is large, frequent data processing will consume a lot of resources. The effect is to cache data stored in the hard-won, when a request this data again, directly from the cache data processing flow is omitted, thus reducing the consumption of resources to improve the response speed.

Want to know more? Please move on to CD-speed cloud passed official website (raysync, cloud), or public attention] [CD-speed No. Oh ~

Guess you like

Origin blog.51cto.com/13609234/2436903