hands-on: compiling mpi codes with pgi dušan vudragović

8
June 24-25, 2008 Regional Grid Training, University of Belgrade, Serbia A c a d e m i c a n d E d u c a t i o n a l G r i d I n i t i a t i v e o f S e r b i a A E G I S Hands-on: Compiling MPI codes with PGI Dušan Vudragović [email protected] SCL, Institute of Physics Belgrade

Upload: noel

Post on 15-Jan-2016

25 views

Category:

Documents


0 download

DESCRIPTION

Hands-on: Compiling MPI codes with PGI Dušan Vudragović [email protected] SCL, Institute of Physics Belgrade. Advanced job types. Job Collections Type = "Collection"; DAG jobs (Direct Acyclic Graphs) Type = “Dag"; Parametric jobs Type = "Parametric"; Interactive Jobs - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

June 24-25, 2008

Regional Grid Training, University of Belgrade, Serbia

Acad

em

ic a

nd E

ducat ional Gr id Init iat ive o

f Serbia

A E G I S

Hands-on: Compiling MPI codes with PGI

Dušan Vudragović[email protected], Institute of Physics Belgrade

Page 2: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

Advanced job typesAdvanced job types Job Collections

Type = "Collection"; DAG jobs (Direct Acyclic Graphs)

Type = “Dag"; Parametric jobs

Type = "Parametric"; Interactive Jobs

Type = "Interactive”; MPI Jobs (Message Passing

Interface) JobType = ”MPICH”;

https://edms.cern.ch/file/722398/1.2/gLite-3-UserGuide.html

Regional Grid Training, University of Belgrade, Serbia

Page 3: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

PGI WorkstationPGI Workstation

High-performance compilers F77, F95, HPF, C and C++

compilers 64-bit x64 and 32-bit x86

processor http://www.pgroup.com/products/

workpgi.htm

Regional Grid Training, University of Belgrade, Serbia

Page 4: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

Simple Example (f77)Simple Example (f77)

Regional Grid Training, University of Belgrade, Serbia

PROGRAM mpi INCLUDE 'mpif.h' INTEGER ierr, rank, size CALL MPI_INIT(ierr) CALL MPI_COMM_RANK(MPI_COMM_WORLD, rank, ierr) CALL MPI_COMM_SIZE(MPI_COMM_WORLD, size, ierr) PRINT *, 'I am ', rank, ' of ', size CALL MPI_FINALIZE(ierr) END

http://wiki.egee-see.org/index.php/SG_Gridification_Guide#MPI_.28T9.29

Page 5: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

Simple Example (jdl)Simple Example (jdl)

Regional Grid Training, University of Belgrade, Serbia

JobType = "mpich";NodeNumber = 3;Executable = "mpif";StdOutput = "std.out";StdError = "std.err";InputSandbox = {"mpif"};OutputSandbox = {"std.out", "std.err"};Requirements = (other.GlueCEInfoLRMSType == "pbs") && RegExp("ce64.phy.bg.ac.yu*", other.GlueCEUniqueID);

http://wiki.egee-see.org/index.php/SG_Gridification_Guide#MPI_.28T9.29

Page 6: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

Advanced Example Advanced Example (pgi) (pgi)

Regional Grid Training, University of Belgrade, Serbia

number_of_intervals=1000000000

step=1.0D+00/dble(number_of_intervals)node_integral=0.0D+00

do counter = node_id+1, number_of_intervals, number_of_nodes x=step*(dble(counter) - 0.5D+00) node_integral=node_integral+f(x)end do

Page 7: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

Advanced Example Advanced Example (pgi vs. gnu) (pgi vs. gnu)

Regional Grid Training, University of Belgrade, Serbia

Node: 1Node integral: 1.047197550530024 Node: 2Node integral: 1.047197549863390 Number of nodes: 3Number of intervals: 1000000000Node: 0Node integral: 1.047197553196500 PI exact : 3.141592741012573 PI estimate: 3.141592653589914 PI diff : 0.8742265888983525E-07 Wall clock time: 11.238281

GNU

Page 8: Hands-on: Compiling MPI codes with PGI Dušan Vudragović

A E G I S

June 24-25, 2008

Advanced Example Advanced Example (pgi vs. gnu) (pgi vs. gnu)

Regional Grid Training, University of Belgrade, Serbia

Node: 1Node integral: 1.047197550530024 Node: 2Node integral: 1.047197549863390 Number of nodes: 3Number of intervals: 1000000000Node: 0Node integral: 1.047197553196500 PI exact : 3.141592741012573 PI estimate: 3.141592653589914 PI diff : 0.8742265888983525E-07 Wall clock time: 8.765625

PGI