Every day we take care of manipulating images with our PC, not in vain our monitor sends us a minimum of 60 of them per second. But, which component processes them faster? The GPU that is specialized in it or the CPU with its great speed. Many of you already know the answer, but we explain why.
Image manipulation is one of the professional disciplines most related to the PC today and for decades. From photo manipulation to computer art creation, through prepress and editorial design. Day after day millions of images are manipulated by the hardware of our PC.
What is an image?
We all know what an image is, but the question is more directed to what an image is when we talk about computing and it is that it is nothing more than a mesh of pixels, each pixel storing the information of the RGB color components.
When it comes to manipulating an image, what the processor, be it a CPU or a GPU, does is manipulate all those pixels individually and in parallel, manipulating each and every one of the color components that make up each of the pixels of the picture.
CPU vs. GPU in imaging
The CPUs are designed to work seriously and not in parallel, this is due to how the Von Neumann architecture on which all CPUs are based works, this means that when manipulating images they usually do it taking pixel by pixel, and in certain cases even component by component, individually.
Due to space issues, there are no different ALUs with different precisions, but to operate with a lower precision data, higher precision ALUs are used. This means that if the CPU has to manage a pixel with 3 or 4 components, RGB or RGBA, then it will manage all one by one each of these when calculating them, which will require many more cycles.
Shifting GPUs are meant for graphics processing and their pixel manipulation instructions are meant to manipulate all 3 or 4 components of a pixel. In addition, the way in which they use memory means that, despite the fact that the access is serial as a CPU, it can process several pixels at the same time that it will process making use of its high level of parallelism.
Graphics processors can process images at a high speed, which can be several orders of magnitude faster than that of a CPU, but this requires that the programs are ready for use. The vast majority of image processing companies hardly use the graphics card and if they do, it is at specific moments. So it is possible that the image that you are processing in your image editor is not affected by having a very powerful GPU.
Image decryption via CPU and GPU
Because storage space is important, compressed image formats were developed in which the image information is not given as is, but is encrypted to take up less space and requires decryption to obtain it.
The graphic processors in their beginnings were a cluster of fixed function units that could not be programmed, this led to the fact that when using certain image formats, the CPU had to do the decryption, which caused the image already decoded was in the memory space of the CPU.
With the arrival of shader units in GPUs, graphics card hardware began to be used to decode images, but it was a momentary solution, since although it frees the CPU from the task, it was not entirely elegant, that is why Fixed function units and / or accelerators began to be used to decrypt certain image formats much faster and without affecting CPU and GPU performance.
The post What processes images faster, CPU or graphics card? appeared first on HardZone.