3 ms·
ubsan could help a lot: http://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html http://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html
by vmorgulis 11y ago
ubsan could help a lot: http://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html http://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html
- Kristine1975 11y agoAnd ASAN (the Address Sanitizer). I always have them turned on for development builds (slowdown of about 100%). Only release builds have them switched off. Recently: Use-after-free of a memory block. ASAN told me: 1. Where and in which thread the use-after-free occurred (including stacktrace). 2. Where and in which thread the memory was deallocated (including stacktrace). 3. Where and in which thread the memory had originally been allocated (including stacktrace). Fixing the bug took about 30s with that info.