[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-30 Thread Matt Morehouse via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL312185: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer (authored by morehouse). Changed prior to commit: https://reviews.llvm.org/D37156?vs=113177&id=113329#toc Repository: rL L

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-29 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 113177. morehouse added a comment. - Only enable stack depth tracking on Linux. - Ignore __sancov_lowest_stack in interface symbols tests. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/lib/sanitizer_common/sanit

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-29 Thread Matt Morehouse via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL312026: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer (authored by morehouse). Changed prior to commit: https://reviews.llvm.org/D37156?vs=113133&id=113136#toc Repository: rL L

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-29 Thread Kostya Serebryany via Phabricator via cfe-commits
kcc accepted this revision. kcc added a comment. LGTM https://reviews.llvm.org/D37156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-29 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 113133. morehouse added a comment. - Eliminate "#if". - Replace uintptr_t with uptr. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/lib/sanitizer_common/sanitizer_coverage_libcdep_new.cc compiler-rt/lib/sanitiz

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-29 Thread Kostya Serebryany via Phabricator via cfe-commits
kcc added inline comments. Comment at: clang/lib/Driver/SanitizerArgs.cpp:297 CoverageTraceCmp | CoveragePCTable; +#if !defined(__APPLE__) +// Due to TLS differences, stack depth tracking is disabled on Mac. please use if(Some

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-29 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 113129. morehouse added a comment. - Disable stack depth tracking on Mac. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/lib/sanitizer_common/sanitizer_coverage_libcdep_new.cc compiler-rt/lib/sanitizer_common/s

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-28 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @kcc I've disabled the relevant test on Mac in r311916, please revert my change once this CR goes through. https://reviews.llvm.org/D37156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.o

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-28 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. I don't, but I can check whether tests pass. https://reviews.llvm.org/D37156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-28 Thread Kostya Serebryany via Phabricator via cfe-commits
kcc added a reviewer: george.karpenkov. kcc added a comment. +George, in case he knows about __attribute__((tls_model("initial-exec"))) on Mac Comment at: compiler-rt/lib/sanitizer_common/sanitizer_coverage_libcdep_new.cc:218 +SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTR

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-28 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 112923. morehouse added a comment. Herald added a subscriber: kubamracek. - Add weak definition of __sancov_lowest_stack to runtime. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/lib/sanitizer_common/sanitizer_c

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 112759. morehouse added a comment. Full diff. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/test/fuzzer/deep-recursion.test llvm/lib/Transforms/Instrumentation/SanitizerCoverage.cpp llvm/test/Instrumentation

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 112756. morehouse added a comment. - Add weak reference in SanitizerCoverage.cpp https://reviews.llvm.org/D37156 Files: llvm/lib/Transforms/Instrumentation/SanitizerCoverage.cpp Index: llvm/lib/Transforms/Instrumentation/SanitizerCoverage.cpp

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse reopened this revision. morehouse added a comment. This revision is now accepted and ready to land. Turns out I should have been testing the benchmarks with `FUZZING_ENGINE=fsanitize_fuzzer`. My mistake. After adding the weak reference to SanitizerCoverage.cpp, both lcms and proj4 bu

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL311801: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer (authored by morehouse). Changed prior to commit: https://reviews.llvm.org/D37156?vs=112739&id=112746#toc Repository: rL L

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Kostya Serebryany via Phabricator via cfe-commits
kcc accepted this revision. kcc added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D37156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse updated this revision to Diff 112739. morehouse added a comment. - Use existing linear scan, and check for InvokeInst. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/test/fuzzer/deep-recursion.test llvm/lib/Transforms/Instrumentation/Saniti

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse added a comment. In https://reviews.llvm.org/D37156#852780, @kcc wrote: > Did you check this on something other than the unit tests? > E.g. a couple of benchmarks from fuzzer-test-suite? Just tested on the proj4 and lcms benchmarks and no issues came up. https://reviews.llvm.org/D

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Kostya Serebryany via Phabricator via cfe-commits
kcc added a comment. Did you check this on something other than the unit tests? E.g. a couple of benchmarks from fuzzer-test-suite? Comment at: llvm/lib/Transforms/Instrumentation/SanitizerCoverage.cpp:177 +bool IsLeafFunc(const Function &F) { + for (const BasicBlock &BB :

[PATCH] D37156: [SanitizeCoverage] Enable stack-depth coverage for -fsanitize=fuzzer

2017-08-25 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse created this revision. Herald added a subscriber: hiraditya. - Don't sanitize __sancov_lowest_stack. - Don't instrument leaf functions. - Add CoverageStackDepth to Fuzzer and FuzzerNoLink. https://reviews.llvm.org/D37156 Files: clang/lib/Driver/SanitizerArgs.cpp compiler-rt/test/f