compile_dag_result.sh 2.66 KB
Newer Older
1 2
#!/bin/sh
export SCALFMM_SIMGRIDOUT='scalfmm.out'
Martin Khannouz's avatar
Martin Khannouz committed
3 4
export GROUP_SIZE=2000
export TREE_HEIGHT=6
5
export NB_NODE=3
6
#export NB_PARTICLE_PER_NODE=$(( (`awk "BEGIN{print 8 ** ($TREE_HEIGHT-1)}"` / $NB_NODE) ))
Martin Khannouz's avatar
Martin Khannouz committed
7 8 9 10 11 12 13
export NB_PARTICLE=2500000
export STARPU_NCPU=5
export STARPU_STATS=0
export STARPU_MEMORY_STATS=0
export STARPU_COMM_STATS=0
export STARPU_WATCHDOG_TIMEOUT=10000000 #10s
export STARPU_WATCHDOG_CRASH=1
14
export STARPU_FXT_PREFIX=`pwd`/
15

16 17 18 19 20
echo "GROUP_SIZE=$GROUP_SIZE"
echo "TREE_HEIGHT=$TREE_HEIGHT"
echo "NB_NODE=$NB_NODE"
echo "NB_PARTICLE_PER_NODE=$NB_PARTICLE_PER_NODE"

21
#Compile only what we need
22
time make testBlockedChebyshev testBlockedImplicitChebyshev testBlockedMpiChebyshev testBlockedImplicitAlgorithm testBlockedMpiAlgorithm compareDAGmapping  -j $((`nproc`*2))
23 24 25
if [ $? -ne 0 ]; then
	exit
fi
26

27 28 29
test_kernel()
{
	#Execute explicit mpi version
Martin Khannouz's avatar
Martin Khannouz committed
30
	mpiexec -n $NB_NODE ./Tests/Release/testBlockedMpiAlgorithm -nb $NB_PARTICLE -bs $GROUP_SIZE -h $TREE_HEIGHT
31 32 33 34 35 36
	if [ $? -ne 0 ]; then
		echo
		echo " /!\\Error on explicit"
		echo
		exit
	fi
37

38
	#Aggregate task information from explicit execution
Martin Khannouz's avatar
Martin Khannouz committed
39 40 41 42 43 44
	#a=`ls $SCALFMM_SIMGRIDOUT\_*`
	#rm -f $SCALFMM_SIMGRIDOUT
	#for i in $a; do
		#cat $i >> $SCALFMM_SIMGRIDOUT
		#rm -f $i
	#done
45

46
	#Get task information
Martin Khannouz's avatar
Martin Khannouz committed
47
	#cp -f $SCALFMM_SIMGRIDOUT scalfmm_explicit.out
48

49
	#Execute implicit version
Martin Khannouz's avatar
Martin Khannouz committed
50
	mpiexec -n $NB_NODE ./Tests/Release/testBlockedImplicitAlgorithm -nb $NB_PARTICLE -bs $GROUP_SIZE -h $TREE_HEIGHT
51 52 53 54 55 56 57
	if [ $? -ne 0 ]; then
		echo
		echo " /!\\Error on implicit"
		echo
		exit
	fi
	#Get task information
Martin Khannouz's avatar
Martin Khannouz committed
58 59
	#cp -f $SCALFMM_SIMGRIDOUT\_0 scalfmm_implicit.out
	#rm -f $SCALFMM_SIMGRIDOUT\_*
60 61 62


	#Compare DAGs
Martin Khannouz's avatar
Martin Khannouz committed
63
	#./Tests/Release/compareDAGmapping -e scalfmm_explicit.out -i scalfmm_implicit.out -h $TREE_HEIGHT > output
64 65 66
}
chebyshev_kernel()
{
Martin Khannouz's avatar
Martin Khannouz committed
67
	#mpiexec -n $NB_NODE ./Tests/Release/testBlockedMpiChebyshev -nb $NB_PARTICLE -bs $GROUP_SIZE -h $TREE_HEIGHT
68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85
	#if [ $? -ne 0 ]; then
		#echo
		#echo " /!\\Error on explicit Chebyshev"
		#echo
		#exit
	#fi

	###Aggregate task information from explicit execution
	#a=`ls $SCALFMM_SIMGRIDOUT\_*`
	#rm -f $SCALFMM_SIMGRIDOUT
	#for i in $a; do
		#cat $i >> $SCALFMM_SIMGRIDOUT
		#rm -f $i
	#done

	##Get task information
	#cp -f $SCALFMM_SIMGRIDOUT scalfmm_explicit.out

Martin Khannouz's avatar
Martin Khannouz committed
86
	mpiexec -n $NB_NODE ./Tests/Release/testBlockedImplicitChebyshev -nb $NB_PARTICLE -bs $GROUP_SIZE -h $TREE_HEIGHT
87 88 89 90 91 92 93 94
	if [ $? -ne 0 ]; then
		echo
		echo " /!\\Error on implicit Chebyshev"
		echo
		exit
	fi

	#Get task information
95 96
	#cp -f $SCALFMM_SIMGRIDOUT\_0 scalfmm_implicit.out
	#rm -f $SCALFMM_SIMGRIDOUT\_*
97 98 99


	#Compare DAGs
100
	#./Tests/Release/compareDAGmapping -e scalfmm_explicit.out -i scalfmm_implicit.out -h $TREE_HEIGHT > narval
101 102
}

103
#test_kernel
104
chebyshev_kernel
105