When computers didn't have operating systems yet, they executed only one program at the time. The program would run from the beginning to the end. Running only one program was the only way back then, and this is now seen as very inefficient. Because the program had access to all the resources in the computer at any time, programming was a lot simpler. But because the machine (computer) was only running once program at the time, the machine's resources where not used efficiently, resulting in an inefficient use of the computers capabilities. Nowadays, machines are able to run multiple programs. The OS (operating system) can even run multiple programs simultaneously, and one single program can even be divided into multiple concurrent threads. All these threads together do all the work that used to be done by just one program. Threads can also communicate with each other, with for instance; message passing and shared memory concurrency.
The last few years, multicore processors have become less expensive. Most desktop computers and laptops are using multicore chips and developers are programming more and more with multiple concurrent threads. A downside is that the bug reports related to threading are also increasing every day; this shows that multicore programming is not the easiest thing to do. In
Source by Corwin Smith
Post a Comment