The main task of GPU is efficiently to draw pixels in screen - to be more preciously it calculates the positions of color in the screen and sends as an output. Because instead of CPU , GPU is very good at matrix arithmetic and floating point calculations. Here we should keep in mind that single floating point or vertex calculations can be faster solved in CPU, but if we have thousands or more of them, we will need another architecture can do it in parallel. GPU is designed to solve just same kind of calculations where CPU can do any calculations.
Other examples where GPU shines are cryptocurrency mining and flat image processing. Also programmers come up other ideas where you can use GPU instead of CPU, for example Stanford University used GPU to calculate protein folding to research diseases related to that.
Modern CPU's generally have 8 cores, now Intel developing i9 which will have 12 to 18 cores, but GPU's have 100th of cores, which is why they can handle multiple tasks simultaneously. Also there is 2 types of shaders that GPU had in the past - called vertex shader and pixel shader. As technology evolves now we have universal shaders that can handle both tasks, so that vertex is not sitting idle while pixels are being calculated.
Each GPU has it's own architecture, for example latest 900 series NVidia has 4 GPC (graphical processing cluster) also 4 memory controllers for each GPC and inside each GPC there is multiple SMM ( streaming multiprocessors). If we take a look at inside SMM's there is 4 blocks, each block consist of 32 cores - it means 128 cores per SMM. Also each block has it's own Instruction buffer and warp scheduler.