summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2017-06-16 21:03:44 +0000
committerDimitry Andric <dim@FreeBSD.org>2017-06-16 21:03:44 +0000
commit325377b57338e700317f5e423e5b0f1c08d99a39 (patch)
treeacd401a9713562cf3e93d13fa6a70ad67eb5cd99 /docs
parent1b08b196ac845675036ac78f3ac927d0a37f707c (diff)
Notes
Diffstat (limited to 'docs')
-rw-r--r--docs/ClangFormatStyleOptions.rst10
-rw-r--r--docs/ReleaseNotes.rst25
-rw-r--r--docs/UndefinedBehaviorSanitizer.rst6
3 files changed, 36 insertions, 5 deletions
diff --git a/docs/ClangFormatStyleOptions.rst b/docs/ClangFormatStyleOptions.rst
index 9e0bacaf7c14a..fb014241809cc 100644
--- a/docs/ClangFormatStyleOptions.rst
+++ b/docs/ClangFormatStyleOptions.rst
@@ -521,12 +521,12 @@ the configuration (without a prefix: ``Auto``).
.. code-block:: c++
true:
- class foo {};
-
- false:
class foo
{};
+ false:
+ class foo {};
+
* ``bool AfterControlStatement`` Wrap control statements (``if``/``for``/``while``/``switch``/..).
.. code-block:: c++
@@ -603,12 +603,12 @@ the configuration (without a prefix: ``Auto``).
struct foo
{
int x;
- }
+ };
false:
struct foo {
int x;
- }
+ };
* ``bool AfterUnion`` Wrap union definitions.
diff --git a/docs/ReleaseNotes.rst b/docs/ReleaseNotes.rst
index f7e31e5c98d53..f9a3317811eb1 100644
--- a/docs/ReleaseNotes.rst
+++ b/docs/ReleaseNotes.rst
@@ -187,6 +187,31 @@ Static Analyzer
...
+Undefined Behavior Sanitizer (UBSan)
+------------------------------------
+
+- The Undefined Behavior Sanitizer has a new check for pointer overflow. This
+ check is on by default. The flag to control this functionality is
+ -fsanitize=pointer-overflow.
+
+ Pointer overflow is an indicator of undefined behavior: when a pointer
+ indexing expression wraps around the address space, or produces other
+ unexpected results, its result may not point to a valid object.
+
+- UBSan has several new checks which detect violations of nullability
+ annotations. These checks are off by default. The flag to control this group
+ of checks is -fsanitize=nullability. The checks can be individially enabled
+ by -fsanitize=nullability-arg (which checks calls),
+ -fsanitize=nullability-assign (which checks assignments), and
+ -fsanitize=nullability-return (which checks return statements).
+
+- UBSan can now detect invalid loads from bitfields and from ObjC BOOLs.
+
+- UBSan can now avoid emitting unnecessary type checks in C++ class methods and
+ in several other cases where the result is known at compile-time. UBSan can
+ also avoid emitting unnecessary overflow checks in arithmetic expressions
+ with promoted integer operands.
+
Core Analysis Improvements
==========================
diff --git a/docs/UndefinedBehaviorSanitizer.rst b/docs/UndefinedBehaviorSanitizer.rst
index ea776a7704705..85dd549baaf80 100644
--- a/docs/UndefinedBehaviorSanitizer.rst
+++ b/docs/UndefinedBehaviorSanitizer.rst
@@ -148,6 +148,12 @@ You can also use the following check groups:
nullability does not have undefined behavior, it is often unintentional,
so UBSan offers to catch it.
+Volatile
+--------
+
+The ``null``, ``alignment``, ``object-size``, and ``vptr`` checks do not apply
+to pointers to types with the ``volatile`` qualifier.
+
Stack traces and report symbolization
=====================================
If you want UBSan to print symbolized stack trace for each error report, you