summaryrefslogtreecommitdiff
path: root/.ci
diff options
context:
space:
mode:
authorDumitru Ceara <dceara@redhat.com>2022-04-11 13:39:16 +0200
committerIlya Maximets <i.maximets@ovn.org>2022-05-17 23:10:41 +0200
commitd7c0b90fa360a694f0f3b4f4ce1c514fec4e4359 (patch)
tree084bf70be965402243aa439f8d16645ccd588209 /.ci
parentc8c49a9db9f20e8b5115e9ef7924e702ee70f4c3 (diff)
downloadopenvswitch-d7c0b90fa360a694f0f3b4f4ce1c514fec4e4359.tar.gz
ci: Add UB Sanitizer.
Note: There still is an UB instance when using SSE4.2 as reported here: https://mail.openvswitch.org/pipermail/ovs-dev/2022-January/390904.html Acked-by: Aaron Conole <aconole@redhat.com> Signed-off-by: Dumitru Ceara <dceara@redhat.com> Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
Diffstat (limited to '.ci')
-rwxr-xr-x.ci/linux-build.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/.ci/linux-build.sh b/.ci/linux-build.sh
index 6cd38ff3e..afd4379e6 100755
--- a/.ci/linux-build.sh
+++ b/.ci/linux-build.sh
@@ -250,6 +250,12 @@ if [ "$ASAN" ]; then
CFLAGS_FOR_OVS="${CFLAGS_FOR_OVS} ${CFLAGS_ASAN}"
fi
+if [ "$UBSAN" ]; then
+ # Use the default options configured in tests/atlocal.in, in UBSAN_OPTIONS.
+ CFLAGS_UBSAN="-O1 -fno-omit-frame-pointer -fno-common -fsanitize=undefined"
+ CFLAGS_FOR_OVS="${CFLAGS_FOR_OVS} ${CFLAGS_UBSAN}"
+fi
+
save_OPTS="${OPTS} $*"
OPTS="${EXTRA_OPTS} ${save_OPTS}"