1 processor is faster than 8 processor?!!!!!!!

option, parallelism,...

Moderators: fgoudreault, mcote

Forum rules
Please have a look at ~abinit/doc/config/build-config.ac in the source package for detailed and up-to-date information about the configuration of Abinit 8 builds.
For a video explanation on how to build Abinit 7.x for Linux, please go to: http://www.youtube.com/watch?v=DppLQ-KQA68.
IMPORTANT: when an answer solves your problem, please check the little green V-like button on its upper-right corner to accept it.
Locked
User avatar
new_986
Posts: 77
Joined: Wed Aug 04, 2010 9:27 pm

1 processor is faster than 8 processor?!!!!!!!

Post by new_986 » Sun Apr 29, 2018 2:00 pm

Hi everybody
I have installed abinit in parallel on my computer which have the following environment:
cpu
description: CPU
product: Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz
bus info: cpu@0
version: Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz
8 processor
16 GB RAM
and the log file is attached

The problem is when I run abinit with one processor is faster than when i run it with 8 processor!!!!!
any help ??

Thanks

Nawzad
Attachments
config.log
Configure Log file:
(11.63 KiB) Downloaded 392 times

ebousquet
Posts: 469
Joined: Tue Apr 19, 2011 11:13 am
Location: University of Liege, Belgium

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by ebousquet » Sun Apr 29, 2018 8:03 pm

Dear Nawzad,
You have enabled OpenMP in the configure flags (--enable-openmp). Did you submit your calculation using MPI only, both MPI/OpenMP or only OpenMP?
Check also what is your OMP_NUM_THREADS value on your machine, because if it is not 1 and that your running only MPI, you will find that 1 CPU is faster...
Best wishes,
Eric

User avatar
new_986
Posts: 77
Joined: Wed Aug 04, 2010 9:27 pm

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by new_986 » Sun Apr 29, 2018 11:30 pm

ebousquet wrote:Dear Nawzad,
You have enabled OpenMP in the configure flags (--enable-openmp). Did you submit your calculation using MPI only, both MPI/OpenMP or only OpenMP?
Check also what is your OMP_NUM_THREADS value on your machine, because if it is not 1 and that your running only MPI, you will find that 1 CPU is faster...
Best wishes,
Eric



Hi Eric
I use mpirun -np 8 abinit<xxxxx.files to run abinit
and I don't know how to check OMP_NUM_THREADS on my machine :?

regards
Nawzad

ebousquet
Posts: 469
Joined: Tue Apr 19, 2011 11:13 am
Location: University of Liege, Belgium

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by ebousquet » Mon Apr 30, 2018 12:21 pm

You can get it from the command line:

Code: Select all

echo $OMP_NUM_THREADS


You can tune its value as follows:

Code: Select all

export OMP_NUM_THREADS=1

Here you put it to 1, meaning no OpenMP threads will be used.

User avatar
new_986
Posts: 77
Joined: Wed Aug 04, 2010 9:27 pm

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by new_986 » Mon Apr 30, 2018 9:00 pm

Dear Eric

I did that but still same problem I have
I believe i have did configure not correct
with such environment, can you give me an idea about configuring?

Thanks

Nawzad

ebousquet
Posts: 469
Joined: Tue Apr 19, 2011 11:13 am
Location: University of Liege, Belgium

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by ebousquet » Wed May 02, 2018 2:38 pm

Dear Nawzad,
To be sure, can you recompile Abinit without OpenMP, i.e. removing the --enable-openmp flag in your configure run?
If it is still there, this means there is another problem somewhere else I don't see from a quick look.
Lets see without --enable-openmp what this gives.
Best wishes,
Eric

ebousquet
Posts: 469
Joined: Tue Apr 19, 2011 11:13 am
Location: University of Liege, Belgium

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by ebousquet » Wed May 02, 2018 2:48 pm

I indeed went too quickly to your config.log, actually the origin of the problem is more simple, if I'm right you didn't activate mpi parallelism (enable_mpi)? At the end of a configure run you have a small summary where you can check what has been activated or not (MPI, OpenMP, etc), please check it before going further.
Best wishes,
Eric

User avatar
new_986
Posts: 77
Joined: Wed Aug 04, 2010 9:27 pm

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by new_986 » Wed May 02, 2018 11:54 pm

Dear Eric

Without enable openmpi? you meam not parallelism? if you mean that, it works with running command ( abinit <xx.files>) but very slow because my computer is not powerful
I have reinstalled again and confgured using the following command
./configure FC=mpifort CC=mpicc --enable-openmp
I have enabled openmpi, still same problem I have
I have attached my input file also maybe there is something wrong about it ?
there is a funny thing happening with me, even when i run it with more number of processors what i have it, abinit still works, is that possible ?!!!

regards
Nawzad
Attachments
GWBANDGAP.in
This is my input file
(4.18 KiB) Downloaded 364 times
config.log
Log file :
(119.87 KiB) Downloaded 354 times

ebousquet
Posts: 469
Joined: Tue Apr 19, 2011 11:13 am
Location: University of Liege, Belgium

Re: 1 processor is faster than 8 processor?!!!!!!!

Post by ebousquet » Thu May 03, 2018 12:59 pm

Dear Nawzad,
Be careful OpenMP and Open-MPI are not the same thing, please google them to make sure you understand the difference otherwise it'll be hard to communicate on this problem.
OpenMP use threading parallelism and I think this is your problem because you run your calculation as if it is with MPI parallelism but you don't enable it in the compilation, you enabled only OpenMP. So my advise is that don't enable OpenMP and enable MPI instead, that will fix your problem.
Best wishes,
Eric

Locked