Add UBSAN to ASAN builds#678
Conversation
Signed-off-by: Clayton Smith <argilo@gmail.com>
|
This changes runtime behavior. A quick search indicated that this change may affect performance. Do we want this to happen? Maybe it is sufficient to add a CI test with this option enabled. |
|
ASAN changes runtime behaviour and reduces performance in the same way; it's only meant to be used for finding bugs. The intent here is to add more checks so that more bugs can be caught. I think that's compatible with the intent of #192, which added an ASAN build type in the first place, and seems to have been aimed at finding bugs by hand. Running CI tests with ASAN+UBSAN at least once for each platform we care about (x86, ARM) would definitely help catch more bugs. The |
|
Got it. CMake provides I merge this PR now. We can add the CI tests in another PR. |
Adding the Undefined Behaviour Sanitizer (UBSAN) to ASAN builds will allow more bugs to be uncovered. I already found a number of bugs this way: