forked from OSchip/llvm-project
8f46269f0c
Summary: There is no need to write out gcdas when forking because we can just reset the counters in the parent process. Let say a counter is N before the fork, then fork and this counter is set to 0 in the child process. In the parent process, the counter is incremented by P and in the child process it's incremented by C. When dump is ran at exit, parent process will dump N+P for the given counter and the child process will dump 0+C, so when the gcdas are merged the resulting counter will be N+P+C. About exec** functions, since the current process is replaced by an another one there is no need to reset the counters but just write out the gcdas since the counters are definitely lost. To avoid to have lists in a bad state, we just lock them during the fork and the flush (if called explicitely) and lock them when an element is added. Reviewers: marco-c Reviewed By: marco-c Subscribers: hiraditya, cfe-commits, #sanitizers, llvm-commits, sylvestre.ledru Tags: #clang, #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D74953 |
||
---|---|---|
.. | ||
cmake | ||
docs | ||
include | ||
lib | ||
test | ||
tools | ||
unittests | ||
utils | ||
www | ||
.arcconfig | ||
.gitignore | ||
CMakeLists.txt | ||
CODE_OWNERS.TXT | ||
CREDITS.TXT | ||
LICENSE.TXT | ||
README.txt |
README.txt
Compiler-RT ================================ This directory and its subdirectories contain source code for the compiler support routines. Compiler-RT is open source software. You may freely distribute it under the terms of the license agreement found in LICENSE.txt. ================================