Modern GPUs seam increadibly flexible. THey are freely programmable using CUDA or OPENCL, they have loads of cores and completely overshadow any cpu in raw instructions per second.
They seam to have a complete instruction set and loads of ram.
So why can't we just run an OS on one of them?
What are GPUs missing that CPUs have?
Asked
Active
Viewed 3,313 times
2
user2741831
- 403
-
I suspect it's not that we can't, only that there are reasons why we don't... The question reminds me of the original Raspberry Pi, which does boot through the GPU first. – u1686_grawity Mar 31 '20 at 11:06
-
and what are those reasons? – user2741831 Mar 31 '20 at 11:23
-
Because it doesn’t have the required instructions required to run any modern OS that exists? A GPU is good for one thing math. What you are asking about is not possible – Ramhound Mar 31 '20 at 11:29
-
1Related: GPU cores vs. CPU cores They may be "incredibly flexible" by comparison to old GPUs, but they are nowhere near as flexible (and designed for near random branching instruction streams) as a CPU is. While there are a lot of cores on a GPU they are individually (when compared to a CPU) restricted in their capabilities, relatively slow, and heavily reliant on there being data ready and queued for processing. They are suited for different tasks and we use them as such. – Mokubai Mar 31 '20 at 11:59
1 Answers
1
An OS is in the middle of all processes running on it and is between all I/O devices and those processes. Processes have to "go through" the OS for any I/O.
So unless you are doing something that doesn't depend on I/O, like math (which is exactly what GPU cores are designed to do), you're waiting on a kernel to coordinate anyway. Having 1000+ GPU cores being able to do what they want, when they want to your Ethernet adapter or NVME storage would be a disaster.
LawrenceC
- 73,957
-
There is such an OS. DawnOS. http://gerigeri.uw.hu/DawnOS/index.html – Валерий Заподовников Mar 25 '21 at 15:23