LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 01-29-2012, 11:43 PM   #1
rpd25
LQ Newbie
 
Registered: Dec 2011
Posts: 12

Rep: Reputation: Disabled
Compare times to run a program - Serial vs MPI


Hi,

I have a fortran program with serial and MPI version. I want to compare the time taken by these programs to run. I use ifort/gfortran compiler.

How to compare the time taken by each program to run? Is there any sample code for comparison?

Thanks,
Rakesh
 
Old 01-30-2012, 05:27 PM   #2
evo2
LQ Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and CentOS
Posts: 6,724

Rep: Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705
Hi,

i you just want the total execution time, you could use the have you tried using the "time" command on the command line.

Eg.
Code:
time program
If you want actual profiling, you could try using valgrind with the callgrind or cachegrind tools. You can view the output of valgrind with the kcachegrind gui.

HTH,

Evo2.
 
  


Reply

Tags
compare, mpi, time



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mpi program farooq1220 Programming 4 10-31-2010 08:04 PM
problem compiling mpi program(not while install) gamekiller Programming 3 10-02-2007 11:17 PM
MPI program running on cluster. ArthurHuang Programming 1 09-24-2007 01:20 AM
how to compile and run mpi on beowulf hussykoala Linux - Networking 1 09-16-2006 12:20 AM
Command to run a program at designated times nigma Linux - Software 5 05-06-2003 09:07 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 04:46 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration