How more than one thread runs on a processor core
I wanted to know how a multi-threaded multiprocessor program executes on the processor core. For example, my program has 12 threads and I am running it on an intel core-i5 machine. It has four processors. Will there be 3 threads in each core? I got confused because I saw programs with 30 threads running on a 4 core computer.
thank
source to share
The kernel is responsible for looping threads. The more cores you have, the more threads you can run simultaneously. Each core can only execute one command at a time, however its so fast it seems like you are using multiple threads at the same time.
Intel Processors
supports Hyper Threading , allowing a single core to support multiple threads by operating system
doubling the number of logical cores per physical core. For example, a Core i3 that is only dual-core can actually serve two threads per core, i.e. A total of four threads can run simultaneously. However, even ifCore i5 processors
are four cores, since they do not support Hyper-Threading (with the exception of the i5-661), the number of threads they can serve simultaneously is approximately equal to their number Core i3
. p>
source to share