aboutsummaryrefslogtreecommitdiff
path: root/gdb/doc
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-08-18 15:32:46 -0600
committerTom Tromey <tom@tromey.com>2018-10-03 15:19:06 -0600
commitf35d5adea1cee8ce9141ad85a7e59d008c2e4d42 (patch)
tree88cb5d24575333e1977ac5aab23466d476992288 /gdb/doc
parent1dffa580e7e083a43216fd7cbcadd72c760cf29d (diff)
downloadgdb-f35d5adea1cee8ce9141ad85a7e59d008c2e4d42.zip
gdb-f35d5adea1cee8ce9141ad85a7e59d008c2e4d42.tar.gz
gdb-f35d5adea1cee8ce9141ad85a7e59d008c2e4d42.tar.bz2
Add --enable-ubsan
This adds --enable-ubsan to gdb's configure. By default it is enabled in development mode, and disabled otherwise. This passes both -fsanitize=undefined and -fno-sanitize-recover=undefined to compilations, so that undefined behavior violations will be sure to cause test failures. gdb/ChangeLog 2018-10-03 Tom Tromey <tom@tromey.com> * README: Mention --enable-ubsan. * NEWS: Mention --enable-ubsan. * acinclude.m4: Include sanitize.m4. * configure: Rebuild. * configure.ac: Call AM_GDB_UBSAN. * sanitize.m4: New file. gdb/doc/ChangeLog 2018-10-03 Tom Tromey <tom@tromey.com> * gdb.texinfo (Configure Options): Document --enable-ubsan.
Diffstat (limited to 'gdb/doc')
-rw-r--r--gdb/doc/ChangeLog4
-rw-r--r--gdb/doc/gdb.texinfo8
2 files changed, 12 insertions, 0 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog
index c26b8e6..99aefc2 100644
--- a/gdb/doc/ChangeLog
+++ b/gdb/doc/ChangeLog
@@ -1,3 +1,7 @@
+2018-10-03 Tom Tromey <tom@tromey.com>
+
+ * gdb.texinfo (Configure Options): Document --enable-ubsan.
+
2018-10-02 John Darrington <john@darrington.wattle.id.au>
* gdb.texinfo (Remote Connection Commands): Describe
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index d37c9e4..5653bdc 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -35763,6 +35763,14 @@ compiler you are using.
Treat compiler warnings as werrors. It adds the @code{-Werror} flag
to the compiler, which will fail the compilation if the compiler
outputs any warning messages.
+
+@item --enable-ubsan
+Enable the GCC undefined behavior sanitizer. By default this is
+disabled in @value{GDBN} releases, but enabled, when available, when
+building from git. The undefined behavior sanitizer checks for
+C@t{++} undefined behavior. It has a performance cost, so if you are
+looking at @value{GDBN}'s performance, you should disable it. The
+undefined behavior sanitizer was first introduced in GCC 4.9.
@end table
@node System-wide configuration