Why is Having More Threads than Cores Faster?

后端 未结 2 1769
一整个雨季
一整个雨季 2020-12-06 03:11

I\'ve implemented a version of PageRank in a multithreaded version. I\'m running it on a 4-core Q6600. When I run it set to create 4 threads, I get:

real             


        
2条回答
  •  臣服心动
    2020-12-06 03:21

    You probably have spare CPU cycles while the thread blocks for some resources like memory. These CPU cycles can be used by other threads. The data I'd look at is... Does the 4 thread version show 100% utilization of each core? If not the you've found your spare CPU cycles.

提交回复
热议问题