-
Notifications
You must be signed in to change notification settings - Fork 30
/
build_and_test.sh
executable file
·138 lines (106 loc) · 5.23 KB
/
build_and_test.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
#!/bin/bash
CURRENTDIR=`pwd`
BUILD_DIR=$CURRENTDIR/build/
TOOL_DIR=$CURRENTDIR/tools
MAKE_CMD="make -j"
THIRDPARTY_BUILD=$CURRENTDIR/third-party/build/
INSTALL_DIR=$BUILD_DIR
#creating build directory if not present
if [ ! -d "$BUILD_DIR" ]; then
echo "Creating $BUILD_DIR"
mkdir -p $BUILD_DIR
fi
#set library path
export LD_LIBRARY_PATH=$THIRDPARTY_BUILD/lib/:$THIRDPARTY_BUILD/lib64/:$LD_LIBRARY_PATH
#Build and run test with MemoryServer allocator
cd $BUILD_DIR
#cmake .. -DCMAKE_BUILD_TYPE=Release -DENABLE_CHECK_OFFSETS=1 -DENABLE_THALLIUM=1 -DLIBFABRIC_PATH=/usr/lib64 -DPMIX_PATH=/usr/lib64; $MAKE_CMD ; make install
cmake ..; $MAKE_CMD ; make install
if [[ $? > 0 ]]
then
echo "OpenFAM build with memoryserver version failed.. exit..."
exit 1
fi
echo "==========================================================="
echo "Test OpenFAM with cis-rpc-meta-direct-mem-rpc configuration"
echo "==========================================================="
CONFIG_OUT_DIR=$BUILD_DIR/test/config_files/config-cis-rpc-meta-direct-mem-rpc
export OPENFAM_ROOT=$CONFIG_OUT_DIR
$BUILD_DIR/bin/openfam_adm @$TOOL_DIR/common-config-arg.txt --install_path $INSTALL_DIR --model memory_server --cisinterface rpc --memserverinterface rpc --metaserverinterface direct --create_config_files --config_file_path $CONFIG_OUT_DIR --start_service --runtests
if [[ $? > 0 ]]
then
echo "OpenFAM test with cis-rpc-meta-direct-mem-rpc configuration failed. exit..."
exit 1
fi
sleep 5
$BUILD_DIR/bin/openfam_adm --stop_service --clean
sleep 5
echo "========================================================"
echo "Test OpenFAM with cis-rpc-meta-rpc-mem-rpc configuration"
echo "========================================================"
CONFIG_OUT_DIR=$BUILD_DIR/test/config_files/config-cis-rpc-meta-rpc-mem-rpc
export OPENFAM_ROOT=$CONFIG_OUT_DIR
$BUILD_DIR/bin/openfam_adm @$TOOL_DIR/common-config-arg.txt --install_path $INSTALL_DIR --model memory_server --cisinterface rpc --memserverinterface rpc --metaserverinterface rpc --create_config_files --config_file_path $CONFIG_OUT_DIR --start_service --runtests
if [[ $? > 0 ]]
then
echo "OpenFAM test with cis-rpc-meta-rpc-mem-rpc configuration failed. exit..."
exit 1
fi
sleep 5
$BUILD_DIR/bin/openfam_adm --stop_service --clean
sleep 5
echo "=============================================================="
echo "Test OpenFAM with cis-rpc-meta-direct-mem-direct configuration"
echo "=============================================================="
CONFIG_OUT_DIR=$BUILD_DIR/test/config_files/config-cis-rpc-meta-direct-mem-direct
export OPENFAM_ROOT=$CONFIG_OUT_DIR
$BUILD_DIR/bin/openfam_adm @$TOOL_DIR/common-config-arg.txt --install_path $INSTALL_DIR --model memory_server --cisinterface rpc --memserverinterface direct --metaserverinterface direct --create_config_files --config_file_path $CONFIG_OUT_DIR --start_service --runtests
if [[ $? > 0 ]]
then
echo "OpenFAM test with cis-rpc-meta-direct-mem-direct configuration failed. exit..."
exit 1
fi
sleep 5
$BUILD_DIR/bin/openfam_adm --stop_service --clean
sleep 5
echo "==========================================================="
echo "Test OpenFAM with cis-direct-meta-rpc-mem-rpc configuration"
echo "==========================================================="
CONFIG_OUT_DIR=$BUILD_DIR/test/config_files/config-cis-direct-meta-rpc-mem-rpc
export OPENFAM_ROOT=$CONFIG_OUT_DIR
$BUILD_DIR/bin/openfam_adm @$TOOL_DIR/common-config-arg.txt --install_path $INSTALL_DIR --model memory_server --cisinterface direct --memserverinterface rpc --metaserverinterface rpc --create_config_files --config_file_path $CONFIG_OUT_DIR --start_service --runtests
if [[ $? > 0 ]]
then
echo "OpenFAM test with cis-direct-meta-rpc-mem-rpc configuration failed. exit..."
exit 1
fi
sleep 5
$BUILD_DIR/bin/openfam_adm --stop_service --clean
sleep 5
echo "==========================================================="
echo "Test OpenFAM with shared memory configuration"
echo "==========================================================="
CONFIG_OUT_DIR=$BUILD_DIR/test/config_files/config-shared-memory
export OPENFAM_ROOT=$CONFIG_OUT_DIR
$BUILD_DIR/bin/openfam_adm @$TOOL_DIR/common-config-arg.txt --install_path $INSTALL_DIR --model shared_memory --cisinterface direct --memserverinterface direct --metaserverinterface direct --create_config_files --config_file_path $CONFIG_OUT_DIR --start_service --runtests
if [[ $? > 0 ]]
then
echo "OpenFAM test with shared memory configuration failed. exit..."
exit 1
fi
sleep 5
$BUILD_DIR/bin/openfam_adm --stop_service --clean
sleep 5
echo "==========================================================="
echo "Test OpenFAM with multiple memory servers in all rpc configuration"
echo "==========================================================="
CONFIG_OUT_DIR=$BUILD_DIR/test/config_files/config-multi-mem
export OPENFAM_ROOT=$CONFIG_OUT_DIR
$BUILD_DIR/bin/openfam_adm @$TOOL_DIR/multi-mem-config-arg.txt --install_path $INSTALL_DIR --create_config_files --config_file_path $CONFIG_OUT_DIR --start_service --runtests
if [[ $? > 0 ]]
then
echo "OpenFAM test with multiple memory servers in all rpc configuration failed. exit..."
exit 1
fi
$BUILD_DIR/bin/openfam_adm --stop_service --clean
cd $CURRENTDIR