Home> System Tutorial> LINUX> body text

A brief discussion on the relationship between CPU, memory, virtual memory and hard disk

WBOY
Release: 2024-06-20 13:43:28
Original
381 people have browsed it

Everyone knows that assembling a computer requires CPU hard disk, memory and other hardware. The system also contains virtual memory. However, you may not understand the relationship between them! Below, I will introduce the relationship to you in the most concise and easy-to-understand language!

A brief discussion on the relationship between CPU, memory, virtual memory and hard disk

CPU

CPU is the central processing unit, which is the abbreviation of "Central Processing Unit" in English. The CPU fetches instructions from memory or cache, puts them into the instruction register, decodes and decomposes the instructions into a series of micro-operations, and then issues various control commands to execute the micro-operation series to complete the execution of system instructions.

Memory

However, the CPU cannot directly call the system, programs and data stored on the hard disk. The relevant contents of the hard disk must first be stored in the memory so that it can be read and run by the CPU. Therefore, memory (that is, physical memory, as opposed to the "external memory" of the hard disk), as a "transfer station" between the hard disk and the CPU, has a great impact on the running speed of the computer.

Virtual Memory

When the running data exceeds the capacity of the physical memory, part of the data will "overflow" on its own. At this time, the system will simulate part of the space on the hard disk as memory - virtual memory, and will temporarily not run programs or Unused data is stored in this part of the space for easy and timely recall when needed.

Since the memory is stored live (the data will disappear once the power is turned off), and the capacity is limited, a hard disk (external memory) is required to store programs or data for a long time. The hard disk also affects system speed, because the speed at which the system reads data from the hard disk and stores it into memory through the bus also affects how fast the system runs.

——As for the metaphor of some online articles: "CPU is a factory, hard disk is a large warehouse, memory is a regular transfer center, and virtual memory is a temporary transfer center", it is roughly close to reality, but not completely accurate.

The above is the detailed content of A brief discussion on the relationship between CPU, memory, virtual memory and hard disk. For more information, please follow other related articles on the PHP Chinese website!

source:linuxprobe.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!