aboutsummaryrefslogtreecommitdiff
path: root/clang/docs/MemorySanitizer.rst
diff options
context:
space:
mode:
authorVitaly Buka <vitalybuka@google.com>2022-04-19 18:42:17 -0700
committerVitaly Buka <vitalybuka@google.com>2022-04-21 14:02:02 -0700
commitb580c0e019826074a22e2676dd0889a57d8558fb (patch)
tree5983865acb48b3aca9db2b864e4800d0a3a6392c /clang/docs/MemorySanitizer.rst
parent311929267d296ff2bf0ca4488223ba7e79ed4acd (diff)
downloadllvm-b580c0e019826074a22e2676dd0889a57d8558fb.zip
llvm-b580c0e019826074a22e2676dd0889a57d8558fb.tar.gz
llvm-b580c0e019826074a22e2676dd0889a57d8558fb.tar.bz2
[msan] Update Use-after-destruction documentation
Reviewed By: kda, eugenis Differential Revision: https://reviews.llvm.org/D124058
Diffstat (limited to 'clang/docs/MemorySanitizer.rst')
-rw-r--r--clang/docs/MemorySanitizer.rst15
1 files changed, 7 insertions, 8 deletions
diff --git a/clang/docs/MemorySanitizer.rst b/clang/docs/MemorySanitizer.rst
index 5f387ca..bcc6cc8 100644
--- a/clang/docs/MemorySanitizer.rst
+++ b/clang/docs/MemorySanitizer.rst
@@ -162,17 +162,16 @@ not intermediate stores.
Use-after-destruction detection
===============================
-You can enable experimental use-after-destruction detection in MemorySanitizer.
-After invocation of the destructor, the object will be considered no longer
-readable, and using underlying memory will lead to error reports in runtime.
-Refer to the standard for `lifetime <https://eel.is/c++draft/basic.life#1>`_ definition.
+MemorySanitizer includes use-after-destruction detection. After invocation of
+the destructor, the object will be considered no longer readable, and using
+underlying memory will lead to error reports in runtime. Refer to the standard
+for `lifetime <https://eel.is/c++draft/basic.life#1>`_ definition.
-This feature is still experimental, in order to enable it at runtime you need
-to:
+This feature can be disabled with either:
-#. Pass addition Clang option ``-fsanitize-memory-use-after-dtor`` during
+#. Pass addition Clang option ``-fno-sanitize-memory-use-after-dtor`` during
compilation.
-#. Set environment variable `MSAN_OPTIONS=poison_in_dtor=1` before running
+#. Set environment variable `MSAN_OPTIONS=poison_in_dtor=0` before running
the program.
Handling external code