[PATCH] D83494: [libFuzzer] Link libFuzzer's own interceptors when other compiler runtimes are not linked.
Dokyung Song via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jul 9 10:34:10 PDT 2020
dokyungs created this revision.
Herald added subscribers: Sanitizers, cfe-commits, mgorny.
Herald added projects: clang, Sanitizers.
libFuzzer intercepts certain library functions such as memcmp/strcmp by defining weak hooks. Weak hooks, however, are called only when other runtimes such as ASan is linked. This patch defines libFuzzer's own interceptors, which is linked into the libFuzzer executable when other runtimes are not linked, i.e., when -fsanitize=fuzzer is given, but not others.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D83494
Files:
clang/include/clang/Driver/SanitizerArgs.h
clang/lib/Driver/SanitizerArgs.cpp
clang/lib/Driver/ToolChains/CommonArgs.cpp
compiler-rt/lib/fuzzer/CMakeLists.txt
compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D83494.276776.patch
Type: text/x-patch
Size: 5936 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200709/e1e37bfd/attachment.bin>
More information about the cfe-commits
mailing list