@@ -14,190 +14,33 @@ env:
1414 proc_num : $(nproc)
1515
1616# https://github.com/actions/runner-images
17+ # https://github.com/SF-Zhou/setup-soft-roce-action/blob/main/.github/workflows/main.yml
1718jobs :
18- compile-with-make :
19- runs-on : ubuntu-22.04
20- steps :
21- - uses : actions/checkout@v2
22- - uses : ./.github/actions/install-all-dependencies
23-
24- - name : gcc with default options
25- uses : ./.github/actions/compile-with-make
26- with :
27- options : --headers=/usr/include --libs=/usr/lib /usr/lib64 --cc=gcc --cxx=g++ --werror
28-
29- - name : gcc with all options
30- uses : ./.github/actions/compile-with-make
31- with :
32- options : --headers=/usr/include --libs=/usr/lib /usr/lib64 --cc=gcc --cxx=g++ --werror --with-thrift --with-glog --with-rdma --with-debug-bthread-sche-safety --with-debug-lock --with-bthread-tracer --with-asan
33-
34- - name : clang with default options
35- uses : ./.github/actions/compile-with-make
36- with :
37- options : --headers=/usr/include --libs=/usr/lib /usr/lib64 --cc=clang --cxx=clang++ --werror
38-
39- - name : clang with all options
40- uses : ./.github/actions/compile-with-make
41- with :
42- options : --headers=/usr/include --libs=/usr/lib /usr/lib64 --cc=clang --cxx=clang++ --werror --with-thrift --with-glog --with-rdma --with-debug-bthread-sche-safety --with-debug-lock --with-bthread-tracer --with-asan
43-
44- compile-with-cmake :
45- runs-on : ubuntu-22.04
46- steps :
47- - uses : actions/checkout@v2
48- - uses : ./.github/actions/install-all-dependencies
49-
50- - name : gcc with default options
51- run : |
52- export CC=gcc && export CXX=g++
53- mkdir gcc_build && cd gcc_build && cmake -DCMAKE_POLICY_VERSION_MINIMUM=3.5 ..
54- make -j ${{env.proc_num}} && make clean
55-
56- - name : gcc with all options
57- run : |
58- export CC=gcc && export CXX=g++
59- mkdir gcc_build_all && cd gcc_build_all
60- cmake -DWITH_MESALINK=OFF -DWITH_GLOG=ON -DWITH_THRIFT=ON -DWITH_RDMA=ON -DWITH_DEBUG_BTHREAD_SCHE_SAFETY=ON -DWITH_DEBUG_LOCK=ON -DWITH_BTHREAD_TRACER=ON -DWITH_ASAN=ON -DCMAKE_POLICY_VERSION_MINIMUM=3.5 ..
61- make -j ${{env.proc_num}} && make clean
62-
63- - name : clang with default options
64- run : |
65- export CC=clang && export CXX=clang++
66- mkdir clang_build && cd clang_build && cmake -DCMAKE_POLICY_VERSION_MINIMUM=3.5 ..
67- make -j ${{env.proc_num}} && make clean
68-
69- - name : clang with all options
70- run : |
71- export CC=clang && export CXX=clang++
72- mkdir clang_build_all && cd clang_build_all
73- cmake -DWITH_MESALINK=OFF -DWITH_GLOG=ON -DWITH_THRIFT=ON -DWITH_RDMA=ON -DWITH_DEBUG_BTHREAD_SCHE_SAFETY=ON -DWITH_DEBUG_LOCK=ON -DWITH_BTHREAD_TRACER=ON -DWITH_ASAN=ON -DCMAKE_POLICY_VERSION_MINIMUM=3.5 ..
74- make -j ${{env.proc_num}} && make clean
75-
76- gcc-compile-with-make-protobuf :
77- runs-on : ubuntu-22.04
78- steps :
79- - uses : actions/checkout@v2
80- - uses : ./.github/actions/install-essential-dependencies
81-
82- - name : protobuf 3.5.1
83- uses : ./.github/actions/compile-with-make-protobuf
84- with :
85- protobuf-version : 3.5.1
86- protobuf-cpp-version : 3.5.1
87- protobuf-install-dir : /protobuf-3.5.1
88- config-brpc-options : --cc=gcc --cxx=g++ --werror
89-
90- - name : protobuf 3.12.4
91- uses : ./.github/actions/compile-with-make-protobuf
92- with :
93- protobuf-version : 3.12.4
94- protobuf-cpp-version : 3.12.4
95- protobuf-install-dir : /protobuf-3.12.4
96- config-brpc-options : --cc=gcc --cxx=g++ --werror
97-
98- - name : protobuf 21.12
99- uses : ./.github/actions/compile-with-make-protobuf
100- with :
101- protobuf-version : 21.12
102- protobuf-cpp-version : 3.21.12
103- protobuf-install-dir : /protobuf-3.21.12
104- config-brpc-options : --cc=gcc --cxx=g++ --werror
105-
106- gcc-compile-with-bazel :
107- runs-on : ubuntu-22.04
108- steps :
109- - uses : actions/checkout@v2
110- - run : bazel build --verbose_failures -- //... -//example/...
111-
112- gcc-compile-with-boringssl :
113- runs-on : ubuntu-22.04
114- steps :
115- - uses : actions/checkout@v2
116- - run : bazel build --verbose_failures --define with_mesalink=false --define with_glog=true --define with_thrift=true --define BRPC_WITH_BORINGSSL=true -- //... -//example/...
117-
118- gcc-compile-with-bazel-all-options :
119- runs-on : ubuntu-22.04
120- steps :
121- - uses : actions/checkout@v2
122- - run : |
123- bazel build --verbose_failures \
124- --define with_mesalink=false \
125- --define with_glog=true \
126- --define with_thrift=true \
127- --define with_debug_bthread_sche_safety=true \
128- --define with_debug_lock=true \
129- --define with_asan=true \
130- --define with_bthread_tracer=true \
131- --define BRPC_WITH_NO_PTHREAD_MUTEX_HOOK=true \
132- -- //... -//example/...
133-
134- clang-compile-with-make-protobuf :
135- runs-on : ubuntu-22.04
136- steps :
137- - uses : actions/checkout@v2
138- - uses : ./.github/actions/install-essential-dependencies
139-
140- - name : protobuf 3.5.1
141- uses : ./.github/actions/compile-with-make-protobuf
142- with :
143- protobuf-version : 3.5.1
144- protobuf-cpp-version : 3.5.1
145- protobuf-install-dir : /protobuf-3.5.1
146- config-brpc-options : --cc=clang --cxx=clang++ --werror
147-
148- - name : protobuf 3.12.4
149- uses : ./.github/actions/compile-with-make-protobuf
150- with :
151- protobuf-version : 3.12.4
152- protobuf-cpp-version : 3.12.4
153- protobuf-install-dir : /protobuf-3.12.4
154- config-brpc-options : --cc=clang --cxx=clang++ --werror
155-
156- - name : protobuf 21.12
157- uses : ./.github/actions/compile-with-make-protobuf
158- with :
159- protobuf-version : 21.12
160- protobuf-cpp-version : 3.21.12
161- protobuf-install-dir : /protobuf-3.21.12
162- config-brpc-options : --cc=clang --cxx=clang++ --werror
163-
164- clang-compile-with-bazel :
165- runs-on : ubuntu-22.04
166- steps :
167- - uses : actions/checkout@v2
168- - run : bazel build --verbose_failures --action_env=CC=clang -- //... -//example/...
169-
170- clang-compile-with-boringssl :
171- runs-on : ubuntu-22.04
172- steps :
173- - uses : actions/checkout@v2
174- - run : bazel build --verbose_failures --action_env=CC=clang --define with_mesalink=false --define with_glog=true --define with_thrift=true --define BRPC_WITH_BORINGSSL=true -- //... -//example/...
175-
176- clang-compile-with-bazel-all-options :
177- runs-on : ubuntu-22.04
178- steps :
179- - uses : actions/checkout@v2
180- - run : |
181- bazel build --verbose_failures \
182- --action_env=CC=clang \
183- --define with_mesalink=false \
184- --define with_glog=true \
185- --define with_thrift=true \
186- --define with_debug_bthread_sche_safety=true \
187- --define with_debug_lock=true \
188- --define with_asan=true \
189- --define with_bthread_tracer=true \
190- --define BRPC_WITH_NO_PTHREAD_MUTEX_HOOK=true \
191- -- //... -//example/...
192-
19319 clang-unittest :
19420 runs-on : ubuntu-22.04
19521 steps :
19622 - uses : actions/checkout@v2
19723 - uses : ./.github/actions/install-essential-dependencies
19824 - uses : ./.github/actions/init-ut-make-config
19925 with :
200- options : --with-bthread-tracer
26+ options : --with-bthread-tracer --with-thrift
27+ - name : Setup Soft-RoCE
28+ run : |
29+ KERNEL_VERSION=$(uname -r | cut -d '-' -f 1)
30+ KERNEL_NAME="linux-${KERNEL_VERSION%'.0'}"
31+ DOWNLOAD_LINK="https://cdn.kernel.org/pub/linux/kernel/v${KERNEL_VERSION%%.*}.x/${KERNEL_NAME}.tar.xz"
32+ ETHERNET_CARD=$(ip link | awk -F ": " '$0 !~ "lo|vir|wl|^[^0-9]"{print $2;getline}' | head -1)
33+ echo "kernel version is ${KERNEL_VERSION}, download link is ${DOWNLOAD_LINK}, ethernet card is ${ETHERNET_CARD}"
34+ wget -q $DOWNLOAD_LINK -O /tmp/$KERNEL_NAME.tar.xz
35+ tar xf /tmp/$KERNEL_NAME.tar.xz --directory=/tmp
36+ RXE_PATH="/tmp/$KERNEL_NAME/drivers/infiniband/sw/rxe"
37+ sed 's/$(CONFIG_RDMA_RXE)/m/g' $RXE_PATH/Makefile > $RXE_PATH/Kbuild
38+ make -C /lib/modules/$(uname -r)/build M=$RXE_PATH modules -j
39+ sudo modprobe ib_core
40+ sudo modprobe rdma_ucm
41+ sudo insmod $RXE_PATH/rdma_rxe.ko
42+ sudo rdma link add rxe_0 type rxe netdev $ETHERNET_CARD
43+ rdma link
20144 - name : compile tests
20245 run : |
20346 cat config.mk
@@ -207,30 +50,3 @@ jobs:
20750 run : |
20851 cd test
20952 sh ./run_tests.sh
210-
211- clang-unittest-asan :
212- runs-on : ubuntu-22.04
213- steps :
214- - uses : actions/checkout@v2
215- - uses : ./.github/actions/install-essential-dependencies
216- - uses : ./.github/actions/init-ut-make-config
217- with :
218- options : --with-bthread-tracer --with-asan
219- - name : compile tests
220- run : |
221- cat config.mk
222- cd test
223- make NEED_GPERFTOOLS=0 -j ${{env.proc_num}}
224- - name : run tests
225- run : |
226- cd test
227- sh ./run_tests.sh
228-
229- bazel-bvar-unittest :
230- runs-on : ubuntu-22.04
231- steps :
232- - uses : actions/checkout@v2
233- - run : bazel test --verbose_failures //test:bvar_test
234- - run : bazel test --verbose_failures --define with_babylon_counter=true //test:bvar_test
235- - run : bazel test --verbose_failures --action_env=CC=clang //test:bvar_test
236- - run : bazel test --verbose_failures --action_env=CC=clang --define with_babylon_counter=true //test:bvar_test
0 commit comments