Compiling with ASan will completely distort the VmPeak memory usage
statistics the benchmark provides, and it is incompatible with Valgrind.
In addition, the timing statistics with either sanitizer will be
distorted too. So exit immediately if compiled with either.

Reported-at: 
https://patchwork.ozlabs.org/project/ovn/patch/[email protected]/
Fixes: f4a66b7871d6 ("tutorial: Add developer performance benchmark.")
Signed-off-by: Rosemarie O'Riorden <[email protected]>
---
v2:
 - Rather than using nm, grep for asan/ubsan in the version string.
v3:
 - Update ASAN and UBSAN to all caps.
---
 tutorial/ovn-benchmark.sh | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/tutorial/ovn-benchmark.sh b/tutorial/ovn-benchmark.sh
index 01c090e84..f9838768f 100755
--- a/tutorial/ovn-benchmark.sh
+++ b/tutorial/ovn-benchmark.sh
@@ -161,6 +161,13 @@ if [ ! -d "$PWD/sandbox" ]; then
     exit 1
 fi
 
+if [ "$(ovn-controller --version | grep "ASAN\|UBSAN")" ]; then
+    echo "Compiled with sanitizer, which is incompatible."
+    echo "$(ovn-controller --version | grep "ASAN\|UBSAN")"
+    echo "$(ovn-northd --version | grep "ASAN\|UBSAN")"
+    exit 1
+fi
+
 # Apply defaults if not set by user.
 NODES=${NODES:-$DEFAULT_NODES}
 
-- 
2.56.0

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to