Multiple threads and performance on a single CPU

后端 未结 6 1993
清酒与你
清酒与你 2020-12-15 07:17

Is here any performance benefit to using multiple threads on a computer with a single CPU that does not having hyperthreading?

6条回答
  •  旧巷少年郎
    2020-12-15 07:32

    In terms of speed of computation, No. In fact things will slow down due to the overhead of managing the threads.

    In terms of responsiveness, yes. You can for example have one thread wait on an IO operation and have another run a GUI at the same time.

提交回复
热议问题