Skip to content

Commit eb078d7

Browse files
committed
Initial commit for mpi devel branch using mpiP
1 parent e47ff6a commit eb078d7

File tree

6 files changed

+86
-0
lines changed

6 files changed

+86
-0
lines changed

extra/mpiP-3.4.1.tar.gz

211 KB
Binary file not shown.

extra/sysstat-11.5.3.tar.gz

471 KB
Binary file not shown.

install.sh

+16
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,22 @@ make mpstat | tee -a $BUILD_LOG
6464
echo "Installing mpstat ..."
6565
cp mpstat $REMORA_DIR/bin
6666

67+
#Now build mpiP
68+
echo "Building mpiP ..." | tee -a $BUILD_LOG
69+
cd $REMORA_BUILD_DIR/extra
70+
mpipfile=`ls -ld mpiP* | awk '{print $9}' | head -n 1`
71+
mpipdir=`echo ${mpipfile%%.tar.gz}`
72+
tar xzvf ${mpipfile}
73+
cd ${mpipdir}
74+
export ARCH=x86_64
75+
export CC=mpicc
76+
export F77=mpif77
77+
./configure CFLAGS="-g" --enable-demangling --disable-bfd --disable-libunwind --prefix=${REMORA_DIR} | tee -a $BUILD_LOG
78+
make | tee -a $BUILD_LOG
79+
make shared | tee -a $BUILD_LOG
80+
echo "Installing mpiP ..."
81+
make install
82+
6783
if [ "$PHI_BUILD" == "1" ]; then
6884
echo "Building Xeon Phi affinity script ..." | tee -a $BUILD_LOG
6985
cd $REMORA_BUILD_DIR/extra/

src/config/modules

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
cpu,CPU
22
memory,MEMORY
3+
mpi,MPI
34
numa,NUMA
45
dvs,IO
56
lustre,IO

src/modules/mpi

+67
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
#!/bin/sh
2+
#
3+
#========================================================================
4+
# HEADER
5+
#========================================================================
6+
#% DESCRIPTION
7+
#% mpi
8+
#%
9+
#% DO NOT call this script directly. This is called by REMORA
10+
#%
11+
#========================================================================
12+
#- IMPLEMENTATION
13+
#- version REMORA 1.7
14+
#- authors Carlos Rosales ([email protected])
15+
#- Antonio Gomez ([email protected])
16+
#- license MIT
17+
#========================================================================
18+
19+
# All the functions take three arguments:
20+
# 1.- The name of the node where this function is running
21+
# 2.- The full path where the output will be stored/read
22+
# 3.- The full path to an optional temporary storage location
23+
24+
init_module_mpi()
25+
{
26+
:
27+
# REMORA_NODE=$1; REMORA_OUTDIR=$2; REMORA_TMPDIR=$3
28+
# source $REMORA_OUTDIR/remora_env.txt
29+
# export LD_PRELOAD=$REMORA_BIN/../lib/libmpiP.so:$LD_PRELOAD
30+
}
31+
32+
collect_data_mpi()
33+
{
34+
:
35+
}
36+
37+
# This function might perform some processing on the data.
38+
# If nothing needs to be done, it can be empty (but declared)
39+
process_data_mpi()
40+
{
41+
:
42+
}
43+
44+
monitor_data_mpi()
45+
{
46+
:
47+
}
48+
49+
finalize_module_mpi()
50+
{
51+
REMORA_NODE=$1; REMORA_OUTDIR=$2; REMORA_TMPDIR=$3
52+
source $REMORA_OUTDIR/remora_env.txt
53+
REMORA_MASTER=`head -n 1 $REMORA_OUTDIR/remora_nodes.txt`
54+
if [ "$REMORA_NODE" == "$REMORA_MASTER" ]; then
55+
if [ "$REMORA_MODE" == "FULL" ] || [ "$REMORA_MODE" == "MONITOR" ]; then
56+
outfile=`ls -ltr *.mpiP | tail -n 1 | awk '{print $9}'`
57+
mpiNum=`grep -c "MPI Task Assignment" $outfile`
58+
nodeNum=`cat $REMORA_OUTDIR/remora_nodes.txt | wc -l`
59+
appTime=`grep "*" ./outfile | head -n 1 | awk '{print $2}'`
60+
mpiTime=`grep "*" ./outfile | head -n 1 | awk '{print $3}'`
61+
mpiFrac=`grep "*" ./outfile | head -n 1 | awk '{print $4}'`
62+
echo "Number of Nodes : $nodeNum" > $REMORA_OUTDIR/mpi_info.txt
63+
echo "Number of MPI Tasks : $mpiTaskNum" >> $REMORA_OUTDIR/mpi_info.txt
64+
echo "Communication Time : $mpiFrac %" >> $REMORA_OUTDIR/mpi_info.txt
65+
fi
66+
fi
67+
}

src/remora

+2
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,8 @@ if [ "$REMORA_VERBOSE" == "1" ]; then
108108
echo "REMORA: Running command: $@ "
109109
echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"
110110
fi
111+
export LD_PRELOAD=$REMORA_BIN/../lib/libmpiP.so
112+
#export MPIP="-f $REMORA_OUTDIR"
111113
START=$(date +%s%N)
112114
$@
113115
END=$(date +%s%N)

0 commit comments

Comments
 (0)