Skip to content

Commit c39c1d5

Browse files
authored
Update asan-known-issues.md
wording update
1 parent 64a2995 commit c39c1d5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/sanitizers/asan-known-issues.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,11 @@ As a workaround, create a *`Directory.Build.props`* file in the root of your pro
7979

8080
Thread local variables (global variables declared with `__declspec(thread)` or `thread_local`) aren't protected by AddressSanitizer. This limitation isn't specific to Windows or Microsoft Visual C++, but is a general limitation.
8181

82-
## Custom code skipping normal function return sequences
82+
## Custom code skips normal function return sequence
8383

84-
Using custom code / assembly to leave the current stack frame without the usual return mechanisms, such as a long jump or equivalent, is not supported and risks inducing false positives.
84+
Using custom code or assembly language to leave the current stack frame without honoring the usual return mechanisms isn't supported. For example, leaving the current stack frame via a long jump may generate false positives.
8585

86-
A mitigation for this is to invoke [`__asan_handle_no_return()`](https://github.com/llvm/llvm-project/blob/ba84d0c8d762f093c6ef6d5ef5a446a42a8548a5/compiler-rt/include/sanitizer/asan_interface.h#L325-L330) prior to invoking your custom long jump-like procedure. This function clears all shadow bytes associated with the current thread's stack, which means losing some coverage (i.e. risk false negatives) but will allow your program to safely unwind the stack without running into false positives from stale stack shadow bytes.
86+
Instead, before invoking custom long jump-like code, call [`__asan_handle_no_return()`](https://github.com/llvm/llvm-project/blob/ba84d0c8d762f093c6ef6d5ef5a446a42a8548a5/compiler-rt/include/sanitizer/asan_interface.h#L325-L330) . This function clears all of the shadow bytes associated with the current thread's stack. This results in losing some coverage and introduces a risk of false negatives, but your program can then safely unwind the stack without running into false positives due to stale stack shadow bytes.
8787

8888
## Issues with partially sanitized executables
8989

0 commit comments

Comments
 (0)