beautypg.com

HP XC System 4.x Software User Manual

Page 78

background image

Running a Program

Ensure that the -static-libcxa flag is used when you use mpirun.mpich to launch a C or
Fortran program.

The following is a C example called vtjacobic:

# mpirun.mpich -np 2 ~/xc_PDE_work/ITC_examples_xc6000/vtjacobic
warning: this is a development version of HP-MPI for internal R&D use only
/nis.home/user_name/xc_PDE_work/ITC_examples_xc6000/vtjacobic: 100 iterations in
0.228252 secs (28.712103 MFlops), m=130 n=130 np=2
[0] Intel Trace Collector INFO: Writing tracefile vtjacobic.stf in
/nis.home/user_name/xc_PDE_work/ITC_examples_xc6000
mpirun exits with status: 0

The following is a Fortran example called vtjacobif:

# mpirun.mpich -np 2 ~/xc_PDE_work/ITC_examples_xc6000/vtjacobif
warning: this is a development version of HP-MPI for internal R&D use only
2 Difference is 0.390625000000000
4 Difference is 0.123413085937500
6 Difference is 6.341743469238281E-002
8 Difference is 3.945139702409506E-002
10 Difference is 2.718273504797253E-002
12 Difference is 1.992697400677912E-002
14 Difference is 1.520584760276139E-002
16 Difference is 1.192225932086809E-002
18 Difference is 9.527200632430437E-003
20 Difference is 7.718816241067778E-003
22 Difference is 6.318016878920021E-003
24 Difference is 5.211741863535576E-003
26 Difference is 4.324933536667125E-003
28 Difference is 3.605700997191797E-003
30 Difference is 3.016967266492488E-003
32 Difference is 2.531507385360385E-003
34 Difference is 2.128864474525351E-003
36 Difference is 1.793360334698915E-003
38 Difference is 1.512772311960036E-003
40 Difference is 1.277430422527046E-003
42 Difference is 1.079587281504879E-003
44 Difference is 9.129693228356968E-004
46 Difference is 7.724509294615510E-004
48 Difference is 6.538134083283944E-004
50 Difference is 5.535635456297787E-004
52 Difference is 4.687947140887371E-004
54 Difference is 3.970788908277634E-004
56 Difference is 3.363815146174385E-004
58 Difference is 2.849935053418584E-004
60 Difference is 2.414763917353628E-004
62 Difference is 2.046176064805586E-004
64 Difference is 1.733937801556939E-004
66 Difference is 1.469404085386082E-004
68 Difference is 1.245266549586746E-004
70 Difference is 1.055343296682637E-004
72 Difference is 8.944029434752290E-005
74 Difference is 7.580169395426893E-005
76 Difference is 6.424353519703476E-005
78 Difference is 5.444822123484475E-005
80 Difference is 4.614672291984789E-005
82 Difference is 3.911112299221254E-005
84 Difference is 3.314831465581266E-005
86 Difference is 2.809467246160129E-005
88 Difference is 2.381154327036583E-005
90 Difference is 2.018142964565221E-005
92 Difference is 1.710475838933507E-005
94 Difference is 1.449714388058985E-005
96 Difference is 1.228707004052045E-005
98 Difference is 1.041392661369357E-005

78

Tuning Applications