Page 1 of 1

Do you really have n usable processors?

Posted: Mon Oct 15, 2007 10:53 am
by hines
Performance measurements are more accurate on multiprocessor desktops when there is not a background process using up a large percentage of one of the processors. You can see if this is the case on a linux machine by running "top". The bottom line, though, is that if you have 4 cores then the following, call it nproc.hoc, should take the same amount of time with 1 and 4 processes:

Code: Select all

objref pc
pc = new ParallelContext()
x = startsw()
for i=1, 1000 {
        for j = 1, 50000 {
                y += 1
//      pc.barrier()
x = startsw() - x
print x
with both

Code: Select all

mpiexec -np 1 `which nrniv` -mpi nproc.hoc
mpiexec -np 4 `which nrniv` -mpi nproc.hoc
and all the times printed should be about the same.

By the way, I have had very good results with mpich2 configured with

Code: Select all

./configure --prefix=/home/hines/mpich2 --with-device=ch3:nemesis
and get close to linear speedup on even modest size 3-d reconstructions when using multisplit.