diff options
author | Sanjay Patel <spatel@rotateright.com> | 2018-04-26 17:04:07 +0000 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2018-04-26 17:04:07 +0000 |
commit | 5fad6ea6c23244f92bdda582b5552557c6451ced (patch) | |
tree | 81becc1213e355bff84f5cfce7056b200b5de306 /docs/ReleaseNotes.rst | |
parent | 588fa1cad7755009c0b61ca1a8f5fc217c5a4cb2 (diff) |
[docs] provide the specific sanitizer option to detect junk-in-the-ftrunc
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@330958 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'docs/ReleaseNotes.rst')
-rw-r--r-- | docs/ReleaseNotes.rst | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/docs/ReleaseNotes.rst b/docs/ReleaseNotes.rst index 43c6c9a30e9..cf00ae2ad56 100644 --- a/docs/ReleaseNotes.rst +++ b/docs/ReleaseNotes.rst @@ -63,7 +63,8 @@ Non-comprehensive list of changes in this release * Optimization of floating-point casts is improved. This may cause surprising results for code that is relying on undefined behavior. Code sanitizers can - be used to detect affected patterns such as this: + be used to detect affected patterns. The option for detecting this problem + alone is "-fsanitize=float-cast-overflow": .. code-block:: c @@ -76,7 +77,7 @@ Non-comprehensive list of changes in this release .. code-block:: bash - clang -O1 ftrunc.c -fsanitize=undefined ; ./a.out + clang -O1 ftrunc.c -fsanitize=float-cast-overflow ; ./a.out ftrunc.c:5:15: runtime error: 4.29497e+09 is outside the range of representable values of type 'int' junk in the ftrunc: 0.000000 |