Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | [libFuzzer] Fix bug in detecting timeouts when input string is empty. | Marcos Pividori | 2016-12-13 | 1 | -0/+1 |
| | | | | | | | | | | | | | | I added a new flag RunningCB to know if the Fuzzer's main thread is running the CB function, instead of using (!CurrentUnitSize). (!CurrentUnitSize) doesn't work properly. For example, in FuzzerLoop.cpp, inside ShuffleAndMinimize() function, we execute the callback with an empty string (size=0). Previous implementation failed to detect timeouts in that execution. Also, I add a regression test for that case. Differential Revision: https://reviews.llvm.org/D27433 llvm-svn: 289561 | ||||
* | [libFuzzer] Clean up headers and file formatting of LibFuzzer files. | Marcos Pividori | 2016-12-13 | 1 | -7/+6 |
| | | | | | | | | | | | | Reorganize #includes to follow LLVM Coding Standards. Include some missing headers. Required to use `Printf()`. Aside from that, this patch contains no functional change. It is purely a re-organization. Differential Revision: https://reviews.llvm.org/D27363 llvm-svn: 289560 | ||||
* | [libFuzzer] implement crash-resistant merge ↵ | Kostya Serebryany | 2016-12-09 | 1 | -0/+3 |
| | | | | | | (https://github.com/google/sanitizers/issues/722). This is a first experimental variant that needs some more testing, thus not yet adding a lit test (but there are unit tests). llvm-svn: 289166 | ||||
* | [libFuzzer] extend -rss_limit_mb to crash instantly on a single malloc that ↵ | Kostya Serebryany | 2016-11-30 | 1 | -0/+2 |
| | | | | | | exceeds the limit llvm-svn: 288281 | ||||
* | [LibFuzzer] Split up some functions among different headers. | Zachary Turner | 2016-11-30 | 1 | -0/+1 |
| | | | | | | | | | | | | | | | | | | | | | In an effort to get libfuzzer working on Windows, we need to make a distinction between what functions require platform specific code (e.g. different code on Windows vs Linux) and what code doesn't. IO functions, for example, tend to be platform specific. This patch separates out some of the functions which will need to have platform specific implementations into different headers, so that we can then provide different implementations for each platform. Aside from that, this patch contains no functional change. It is purely a re-organization. Patch by Marcos Pividori Differential Revision: https://reviews.llvm.org/D27230 llvm-svn: 288264 | ||||
* | [libFuzzer] simplify the code to print new PCs | Kostya Serebryany | 2016-10-26 | 1 | -2/+0 |
| | | | | llvm-svn: 285145 | ||||
* | [libFuzzer] detect leaks after every run when executing fixed inputs ↵ | Kostya Serebryany | 2016-10-18 | 1 | -2/+2 |
| | | | | | | (./fuzzer -runs=1000000 my-file) llvm-svn: 284514 | ||||
* | [libFuzzer] reshuffle the code for -exit_on_src_pos and -exit_on_item | Kostya Serebryany | 2016-10-18 | 1 | -2/+1 |
| | | | | llvm-svn: 284508 | ||||
* | [libFuzzer] better algorithm for -minimize_crash | Kostya Serebryany | 2016-10-15 | 1 | -0/+8 |
| | | | | llvm-svn: 284299 | ||||
* | [libFuzzer] refactoring to make -shrink=1 work for value profile, added a test. | Kostya Serebryany | 2016-10-05 | 1 | -6/+2 |
| | | | | llvm-svn: 283409 | ||||
* | [libFuzzer] remove dfsan support and some related stale code. This is not ↵ | Kostya Serebryany | 2016-10-04 | 1 | -1/+0 |
| | | | | | | being used and as is is pretty weak anyway llvm-svn: 283187 | ||||
* | [libFuzzer] implement the -shrink=1 option that tires to make elements of ↵ | Kostya Serebryany | 2016-10-01 | 1 | -0/+1 |
| | | | | | | the corpus smaller, off by default llvm-svn: 282995 | ||||
* | [libFuzzer] remove some experimental code | Kostya Serebryany | 2016-09-30 | 1 | -1/+1 |
| | | | | llvm-svn: 282983 | ||||
* | [libFuzzer] remove the code for -print_pcs=1 with the old coverage. It still ↵ | Kostya Serebryany | 2016-09-30 | 1 | -7/+0 |
| | | | | | | works with the new one (trace-pc-guard) llvm-svn: 282831 | ||||
* | [libFuzzer] add -exit_on_src_pos to test libFuzzer itself, add a test script ↵ | Kostya Serebryany | 2016-09-27 | 1 | -0/+1 |
| | | | | | | for RE2 that uses this flag llvm-svn: 282458 | ||||
* | [libFuzzer] simplify HandleTrace again, start re-running interesting units ↵ | Kostya Serebryany | 2016-09-23 | 1 | -0/+1 |
| | | | | | | and collecting their features. llvm-svn: 282316 | ||||
* | [libFuzzer] fix merging with trace-pc-guard | Kostya Serebryany | 2016-09-23 | 1 | -1/+1 |
| | | | | llvm-svn: 282224 | ||||
* | [libFuzzer] move value profiling logic into TracePC | Kostya Serebryany | 2016-09-23 | 1 | -4/+0 |
| | | | | llvm-svn: 282219 | ||||
* | [libFuzzer] change ValueBitMap to remember the number of bits in it | Kostya Serebryany | 2016-09-23 | 1 | -3/+1 |
| | | | | llvm-svn: 282216 | ||||
* | [libFuzzer] simplify the crash minimizer; split MaxLen into two: MaxInputLen ↵ | Kostya Serebryany | 2016-09-22 | 1 | -2/+6 |
| | | | | | | and MaxMutationLen, allow MaxMutationLen to be less than MaxInputLen llvm-svn: 282211 | ||||
* | [libFuzzer] add 'features' to the corpus elements, allow mutations with Size ↵ | Kostya Serebryany | 2016-09-22 | 1 | -1/+1 |
| | | | | | | > MaxSize, fix sha1 in corpus stats; various refactorings llvm-svn: 282129 | ||||
* | [libFuzzer] add stats to the corpus; more refactoring | Kostya Serebryany | 2016-09-21 | 1 | -10/+5 |
| | | | | llvm-svn: 282121 | ||||
* | [libFuzzer] more refactoring; don't compute sha1sum every time we mutate a ↵ | Kostya Serebryany | 2016-09-21 | 1 | -13/+2 |
| | | | | | | unit from the corpus, use the stored one. llvm-svn: 282115 | ||||
* | [libFuzzer] fix libc++ build | Kostya Serebryany | 2016-09-21 | 1 | -0/+1 |
| | | | | llvm-svn: 282050 | ||||
* | [libFuzzer] more refactoring; NFC | Kostya Serebryany | 2016-09-21 | 1 | -38/+1 |
| | | | | llvm-svn: 282047 | ||||
* | [libFuzzer] refactoring: split the large header into many; NFC | Kostya Serebryany | 2016-09-21 | 1 | -389/+2 |
| | | | | llvm-svn: 282044 | ||||
* | [libFuzzer] refactoring: move the Corpus into a separate class; delete two ↵ | Kostya Serebryany | 2016-09-21 | 1 | -15/+41 |
| | | | | | | unused experimental features llvm-svn: 282042 | ||||
* | [libFuzzer] add -print_coverage=1 flag to print coverage directly from ↵ | Kostya Serebryany | 2016-09-18 | 1 | -0/+7 |
| | | | | | | libFuzzer llvm-svn: 281866 | ||||
* | [libFuzzer] use 'if guard' instead of 'if guard >= 0' with trace-pc; change ↵ | Kostya Serebryany | 2016-09-18 | 1 | -3/+6 |
| | | | | | | the guard type to intptr_t; use separate array for 8-bit counters llvm-svn: 281845 | ||||
* | [libFuzzer] properly reset the guards when reseting the coverage. Also try ↵ | Kostya Serebryany | 2016-09-17 | 1 | -0/+3 |
| | | | | | | to fix check-fuzzer on the bot llvm-svn: 281814 | ||||
* | [libFuzzer] change trace-pc to use 8-byte guards | Kostya Serebryany | 2016-09-17 | 1 | -3/+20 |
| | | | | llvm-svn: 281810 | ||||
* | [libFuzzer] make caller-callee feedback work with trace-pc-guard | Kostya Serebryany | 2016-09-15 | 1 | -0/+1 |
| | | | | llvm-svn: 281667 | ||||
* | [libFuzzer] implement print_pcs with trace-pc-guard. Change the ↵ | Kostya Serebryany | 2016-09-15 | 1 | -0/+15 |
| | | | | | | trace-pc-guard heuristic for 8-bit counters to look more like in AFL (not that it's provable better, but the existin test preferes this heuristic) llvm-svn: 281577 | ||||
* | [libFuzzer] add 8-bit counters to trace-pc-guard handler | Kostya Serebryany | 2016-09-15 | 1 | -2/+13 |
| | | | | llvm-svn: 281568 | ||||
* | [libFuzzer] start using trace-pc-guard as an alternative source of coverage | Kostya Serebryany | 2016-09-14 | 1 | -7/+12 |
| | | | | llvm-svn: 281435 | ||||
* | [libFuzzer] print a visible message if merge fails due to a crash | Kostya Serebryany | 2016-09-10 | 1 | -0/+2 |
| | | | | llvm-svn: 281122 | ||||
* | [libFuzzer] improve -print_pcs to not print new PCs coming from libFuzzer itself | Kostya Serebryany | 2016-09-09 | 1 | -3/+2 |
| | | | | llvm-svn: 281016 | ||||
* | [libFuzzer] remove unneeded call | Kostya Serebryany | 2016-09-09 | 1 | -1/+0 |
| | | | | llvm-svn: 281014 | ||||
* | [libFuzzer] remove use_traces=1 since use_value_profile seems to be strictly ↵ | Kostya Serebryany | 2016-09-09 | 1 | -1/+0 |
| | | | | | | better llvm-svn: 281007 | ||||
* | [libFizzer] rename -print_new_cov_pcs=1 into -print_pcs=1 and make it more ↵ | Kostya Serebryany | 2016-08-25 | 1 | -1/+3 |
| | | | | | | useful: print PCs only after the initial corpus has been read and symbolize them llvm-svn: 279787 | ||||
* | [libFuzzer] simplify the code, NFC | Kostya Serebryany | 2016-08-25 | 1 | -4/+9 |
| | | | | llvm-svn: 279697 | ||||
* | [libFuzzer] use __attribute__((target("popcnt"))) only on x86_64 | Kostya Serebryany | 2016-08-24 | 1 | -4/+10 |
| | | | | llvm-svn: 279601 | ||||
* | [libFuzzer] one more mutation: ChangeBinaryInteger; also fix the breakage ↵ | Kostya Serebryany | 2016-08-17 | 1 | -0/+2 |
| | | | | | | from r278970 llvm-svn: 278982 | ||||
* | [libFuzzer] when printing the reproducer input, also print the base input ↵ | Kostya Serebryany | 2016-08-17 | 1 | -0/+2 |
| | | | | | | and the mutation sequence llvm-svn: 278975 | ||||
* | [libFuzzer] more mutations | Kostya Serebryany | 2016-08-17 | 1 | -0/+7 |
| | | | | llvm-svn: 278950 | ||||
* | [libFuzzer] new experimental feature: value profiling. Profiles values that ↵ | Kostya Serebryany | 2016-08-16 | 1 | -0/+8 |
| | | | | | | affect control flow and treats new values as new coverage. llvm-svn: 278839 | ||||
* | [libFuzzer] refactoring around PCMap, NFC | Kostya Serebryany | 2016-08-16 | 1 | -5/+7 |
| | | | | llvm-svn: 278825 | ||||
* | [libFuzzer] add InsertRepeatedBytes and EraseBytes. | Kostya Serebryany | 2016-08-15 | 1 | -2/+4 |
| | | | | | | | | | | | | | New mutation: InsertRepeatedBytes. Updated mutation: EraseByte => EraseBytes. This helps https://github.com/google/sanitizers/issues/710 where libFuzzer was not able to find a known bug. Now it finds it in minutes. Hopefully, the change is general enough to help other targets. llvm-svn: 278687 | ||||
* | [sanitizers] trace buffer API to use user-allocated buffer. | Mike Aizatsky | 2016-08-05 | 1 | -3/+7 |
| | | | | | | Differential Revision: https://reviews.llvm.org/D23185 llvm-svn: 277859 | ||||
* | [libFuzzer] add hooks for strstr, strcasestr, strcasecmp, strncasecmp | Kostya Serebryany | 2016-07-15 | 1 | -1/+2 |
| | | | | llvm-svn: 275648 |