In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces the differences between GPU and CPU in the operating system. It is very detailed and has a certain reference value. Friends who are interested must read it!
1. CPU is the central processing unit
CPU (Central Processing Unit) is not only the "brain" of the machine, but also the "commander-in-chief" of layout strategy, giving orders and controlling actions.
The structure of CPU mainly includes arithmetic unit (ALU, Arithmetic and Logic Unit), control unit (CU, Control Unit), register (Register), high-speed buffer (Cache) and the bus of data, control and state communication between them.
To put it simply: computing unit, control unit and storage unit
2. GPU is the graphics processor.
GPU, whose full name is Graphics Processing Unit and GPU in Chinese, was originally used as a microprocessor to run drawing operations on personal computers, workstations, game consoles and some mobile devices such as tablets and smartphones.
Why is GPU so good at processing image data? This is because every pixel in the image needs to be processed, and the process and way of processing each pixel are very similar, which becomes the natural hotbed of GPU.
The composition of GPU is relatively simple, with a large number of computing units and ultra-long pipeline, which is especially suitable for dealing with a large number of unified types of data. But GPU cannot work alone and must be controlled by CPU in order to work. CPU can act alone to deal with complex logical operations and different data types, but when a large number of data with uniform types are needed, GPU can be called for parallel computing.
The difference between the two:
Fundamentally speaking, CPU and GPU have different purposes, different priorities, and different performance characteristics. In some jobs, CPU performs faster, while in another, GPU may be better. GPU is more appropriate when you need to do the same thing with a large amount of data, and CPU is just right when you need to do a lot of things with the same data.
However, in practical application, there are more cases of the latter, that is, CPU is more flexible and competent for more tasks. What can GPU do? With regard to graphics and large matrix operations, such as machine learning algorithms, mining, brute force password cracking, etc., GPU will greatly improve the computational efficiency.
Cache, local memory: CPU > GPU
Threads (number of threads): GPU > CPU
Registers: GPU > CPU multi-registers can support a very large number of Thread,thread needs to use a large number of register,thread, register must also be followed by a large number.
SIMD Unit (single instruction multiple data stream, synchronously executing the same instruction at the same time): GPU > CPU.
To put it simply, CPU is good at complex operations such as branch prediction, while GPU is good at simple operations on large amounts of data. One is complex labor, and the other is a large number of parallel work.
In fact, GPU can be seen as a dedicated CPU, designed for single instruction to work on large chunks of data, which are all operated in the same way. It is important to know that processing a large chunk of data is more effective than processing a single chunk of data, and the overhead of executing instructions will be greatly reduced, because to deal with large chunks of data means more transistors are needed to work in parallel. Now flagship graphics cards are more than ten billion transistors.
CPU, on the other hand, aims to execute a single instruction on a single data as quickly as possible. Because it only needs to use a single instruction of single data, it requires much less transistors. At present, the mainstream desktop CPU transistors are all under 1 billion, which is more than 10 times different from the top GPU, but it requires a larger instruction set, more complex ALU (arithmetic logic unit), better branch prediction, better virtualization architecture, lower latency, and so on.
In addition, like our operating system Windows, which is written for x86 processors, the tasks it needs to do to execute the process must be more efficient on CPU, you want the tasks of each thread to be different, basically difficult to parallelize, completely unable to play the strengths of GPU.
These are all the contents of this article entitled "what are the differences between GPU and CPU in the operating system?" Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.