Parallel DO - Output

$username@machine [~/workshop/OpenMP-matrix-matrix] % f77 -mp -O3 ser_mm.f
$username@machine [~/workshop/OpenMP-matrix-matrix] % setenv OMP_NUM_THREADS 1
$username@machine [~/workshop/OpenMP-matrix-matrix] % time a.out
Done
c(1,1)= 1000.000000000000
c(NRA,NCB)= 1000.000000000000
6.352u 0.193s 0:06.63 98.6% 0+0k 1+5io 1pf+0w
$username@machine [~/workshop/OpenMP-matrix-matrix] % setenv OMP_NUM_THREADS 2
$username@machine [~/workshop/OpenMP-matrix-matrix] % time a.out
Done
c(1,1)= 1000.000000000000
c(NRA,NCB)= 1000.000000000000
6.418u 0.239s 0:03.51 189.1% 0+0k 1+5io 1pf+0w
$username@machine [~/workshop/OpenMP-matrix-matrix] % setenv OMP_NUM_THREADS 4
$username@machine [~/workshop/OpenMP-matrix-matrix] % time a.out
Done
c(1,1)= 1000.000000000000
c(NRA,NCB)= 1000.000000000000
6.579u 0.273s 0:01.96 348.9% 0+0k 1+5io 1pf+0w

Timing for different number of processors

OMP_NUM_THREADS time(sec) CPU utilization 1 6.63 98.6% 2 3.31 189.1% 4 1.96 348.9%

The following timing were obtained running interactively. Better results can be obtained by submitting jobs in the queue and increasing the size of the problem.