This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: Gfortran vs Ifort when using MPI
- From: FX <fxcoudert at gmail dot com>
- To: Tobias Burnus <burnus at net-b dot de>
- Cc: Johan Seland <johan dot seland at gmail dot com>, fortran at gcc dot gnu dot org
- Date: Tue, 8 Jul 2008 22:25:06 +0200
- Subject: Re: Gfortran vs Ifort when using MPI
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:in-reply-to:references :mime-version:content-type:message-id:cc:content-transfer-encoding :from:subject:date:to:x-mailer; bh=5jyEm5WuEd0D10eFQwgfS6zuO+mnq+CIWmF7x+APvdA=; b=ZeiUDwFKcdOrdsRW16z4Fufibfrcx7ew37Rz9y954r6pDhAreL4n4P817Wk81v0TDH LaRqjRI8dCS4rGpn9Oi4eA+9VzPFTVoH3khcfG6PM5BgwIrj/dvlqtK36BWSIC7hlGfq sRo0TbtIY/PXMcF5IzN/kgdjhmMM3ORAEvb40=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=in-reply-to:references:mime-version:content-type:message-id:cc :content-transfer-encoding:from:subject:date:to:x-mailer; b=oh0aTiFuvAMUGz9Dh28LQ9061TRLdUAK+2Z+rWSJqGljy/7GEVF4quoONa7GH9nGO9 FhFRt+tzMpgGd0fZMG3IFZbBB9S8JIL7kZ2jPAuf0iprRm0o6aZq31fp4x7srS4XQPCF dOsqeskrI0d1tTxWyg+eew4v2dEOrS3ZZq3VQ=
- References: <c86493ec0807080618x4baa4b6ewb86bb922cb67d621@mail.gmail.com> <4873708A.2070404@sbcglobal.net> <4873B17E.10407@net-b.de>
Depending on the system, using the right -march makes a big
difference. Try -march=native (not supported on all targets). (If
the compiler thinks that there is no SSE, -march=native can help a
lot; if I recall correctly, for x86 the settings are rather
conservative.
For a 50x-100x performance difference, I suppose there is something
*awfully* wrong going on, like wrong alignment or NaNs all over the
place. I suggest a) checking the results, b) roughly profiling the
gfortran code ("gfortran -pg" and using gprof) to get an idea where
it spends so much time. It'll be much easier than us shooting in the
dark.
FX
--
François-Xavier Coudert
http://www.homepages.ucl.ac.uk/~uccafco/