From aef818bc286ac7792c1a2faa8da0a7286f4d3c55 Mon Sep 17 00:00:00 2001 From: Nils Wentzell Date: Mon, 26 Nov 2018 12:04:35 -0500 Subject: [PATCH] add float-cast-overflow and float-divide-by-zero to ubsan checks --- c++/app4triqs/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/c++/app4triqs/CMakeLists.txt b/c++/app4triqs/CMakeLists.txt index d19f0dee..477db797 100644 --- a/c++/app4triqs/CMakeLists.txt +++ b/c++/app4triqs/CMakeLists.txt @@ -74,7 +74,7 @@ option(UBSAN OFF "Compile library and executables with LLVM Undefined Behavior S if(UBSAN) find_package(libubsan_rt REQUIRED) target_compile_options(app4triqs_c PUBLIC -fsanitize=undefined -fno-omit-frame-pointer -fno-sanitize=vptr) - target_link_libraries(app4triqs_c INTERFACE "-fsanitize=undefined -fno-omit-frame-pointer") + target_link_libraries(app4triqs_c INTERFACE "-fsanitize=undefined -fsanitize=float-divide-by-zero -fsanitize=float-cast-overflow -fno-omit-frame-pointer") endif() if(ASAN OR UBSAN AND ${CMAKE_CXX_COMPILER_ID} STREQUAL "GNU")