I decided to submit this new post to discuss some of the subjects raised in regard to hyperthreading in the responses to my earlier question about CPU utilization in the Beginners section, since the topic is not very close to my original question.
In regard to Ryan's (RJP Computing) question whether hyperthreading really makes a difference: After some experimentation I am convinced the answer is YES! I was able to achieve performance increases up to 45% by splitting a PB application into two threads running simultaneously. More on this below for those interested.
(In response to Aszid) WinXP Home does not support multiple physical processors, but does support two logical processors (from Microsoft website and my experience) WinXP Pro supports 2 physical and 4 logical processors.
(In response to fsw) It is not so easy to disable HT, you can easily turn it off in BIOS, put unfortunately WinXP is aware of the presence of a HT processor during installation, and installs itself so as to use multiple processors, so you would have to reinstall WinXP after turning HT off in BIOS (from other discussion groups)
As to my own experiences:
I experimented with a CPU intensive simulation application that models a simple ecology. You can find the PB source code at
http://home.netspeed.com.au/dekool/RabbitWorld.pb
I split the code into two threads, one taking care of the actual calculations doing the evolution, and one for displaying the results on the screen.
If you adjust the frequency of displaying the results in such a way that these tasks take about an equal amount amount of time so that the threads are running simultaneously most of the time (about 30 timesteps per display), the code becomes 45% faster in the threaded mode as compared to the non-threaded mode
You can experiment with it for yourself if you want, there is a switch on the interface to enable /disable running in threaded mode. It is instructive to open Task Manager while the program is running to monitor the use of the two logical processors. In non-threaded mode it shows 50% usage distribited over the two logical CPUs, in threaded mode for optimum parameters both logical processors show up to 100%.
