Sign in with
Sign up | Sign in
Your question

Processor threads

Last response: in CPUs
Share
February 15, 2013 3:34:49 PM

Hello guys! I have a question! We have multicores processors. But processors also have threads ( i7 - 4 cores 8 threads i think) How does this threads help CPU to do work faster? How do they work? Can somebody please explain me in "simple" English. Tnx :D  :??: 

More about : processor threads

a b à CPUs
February 15, 2013 3:53:08 PM

In Simple english lets say that the threads act like virtual cores.
And 2 threads = 1 virtual core so in reality an i7 has 4 real cores and 4 virtual ones and when software is coded to makes use of these virtual cores then the work is done faster. Its as simple as that.

Also the term for having more threads than cores is "hyperthreading"
a c 190 à CPUs
February 15, 2013 4:13:51 PM

The extra threads on the Intel® Core™ i7 comes from hyper-threading and the best way to easly understand hyper-threading is to think of leftovers.

Rarely will an application use 100% of the resources of a processor. What hyper-threading does simply put is allow second pathway to come in and take advantage of the extra resources. This can give a small performance boost for multi-threading or heavy multi-tasking. Since hyper-threading doesnt run on 100% of the resources of the processor it will never have the full performance of a core but it can help on applications that can take advantage of it.
Related resources
a c 135 à CPUs
February 15, 2013 4:53:45 PM

+1 mr.intel man

February 15, 2013 5:20:57 PM

tnx guys! that's what i need!
a c 135 à CPUs
February 15, 2013 5:21:41 PM

excellent :) 

February 13, 2014 2:11:04 AM

Dear jagdtiger12cm,

About if threats may accelerate work faster, it also depends on your software architecture and configuration.

For example, when you use apache with prefork mpm, it may handle one session with one logical threat. You won't feel noticeable faster within one login session because only one logical threat is serving you.

If you want to explore if the multi-core helps, use htop to see the logical threat utilization. If all of them are running busy, I think you should feel faster. But if only one of them is serving you, you might need to fine tune your software architecture.

More detail about htop, please read Linux Processor Viewer with Thread Support.

Wish it helps!

Best regards,

Amigo
February 23, 2014 5:02:43 PM

jagdtiger12cm said:
Hello guys! I have a question! We have multicores processors. But processors also have threads ( i7 - 4 cores 8 threads i think) How does this threads help CPU to do work faster? How do they work? Can somebody please explain me in "simple" English. Tnx :D  :??: 


Dear jagdtiger12cm,

I write a post How Multi-Core Processors Accelerate your LAMP Applications to explain how modern multi-core processor with hyper-thread technology to serve your LAMP application with different Apache MPM in different scenario.

With HT, the processor may serve more threads than the number of its core(s). It is called "logical" core. And using tools like htop, top, or task manager will take "logical" cores as cores in the graph.

Even with multiple cores, you need the right program, configuration, and scenario to see the different. For thread-safe programs with Apache Worker MPM, requests may be served with more than one thread. You will see performance improvements.

But with preform MPM, a request is served with one thread. You probably won't see different or even worse degradation with HT. Because even the processor may serve more than one threads by a core, it is actually execute by quickly switching among them. There is still one core who really execute the program. The extra switch still need time. If what it saves is less than what it consumes, you see degradation.

That's why you need the right programs and configurations to utilize multi-core with HT processors.

Wish it helps!

Amigo
!