Author: nico Date: Mon Feb 27 15:27:07 2017 New Revision: 296387 URL: http://llvm.org/viewvc/llvm-project?rev=296387&view=rev Log: UBSan docs: Explicitly mention that `-fsanitize=unsigned-integer-overflow` does not catch UB.
https://reviews.llvm.org/D27455 Modified: cfe/trunk/docs/UndefinedBehaviorSanitizer.rst Modified: cfe/trunk/docs/UndefinedBehaviorSanitizer.rst URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/docs/UndefinedBehaviorSanitizer.rst?rev=296387&r1=296386&r2=296387&view=diff ============================================================================== --- cfe/trunk/docs/UndefinedBehaviorSanitizer.rst (original) +++ cfe/trunk/docs/UndefinedBehaviorSanitizer.rst Mon Feb 27 15:27:07 2017 @@ -117,7 +117,9 @@ Available checks are: - ``-fsanitize=unreachable``: If control flow reaches ``__builtin_unreachable``. - ``-fsanitize=unsigned-integer-overflow``: Unsigned integer - overflows. + overflows. Note that unlike signed integer overflow, unsigned integer + is not undefined behavior. However, while it has well-defined semantics, + it is often unintentional, so UBSan offers to catch it. - ``-fsanitize=vla-bound``: A variable-length array whose bound does not evaluate to a positive value. - ``-fsanitize=vptr``: Use of an object whose vptr indicates that _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits