aboutsummaryrefslogtreecommitdiffstats
path: root/executor/executor.h
Commit message (Collapse)AuthorAgeFilesLines
* executor: harden a bit against fuzzer madnessDmitry Vyukov2018-01-191-8/+14
|
* executor: tidy up debug outputDmitry Vyukov2018-01-131-2/+1
| | | | | 1. Don't print copyin (there are too many of them). 2. Print copyout value (it's usually important).
* executor: introduce uint64/32/16/8 typesDmitry Vyukov2017-12-271-149/+149
| | | | | | | | | | | | | | | The "define uint64_t unsigned long long" were too good to work. With a different toolchain I am getting: cstdint:69:11: error: expected unqualified-id using ::uint64_t; ^ executor/common.h:34:18: note: expanded from macro 'uint64_t' Do it the proper way: introduce uint64/32/16/8 types and use them. pkg/csource then does s/uint64/uint64_t/ to not clutter code with additional typedefs.
* executor: check format stringsDmitry Vyukov2017-12-271-18/+18
| | | | | | | | | | | | | | | | | | | I see a crash which says: #0: too much cover 0 (errno 0) while the code is: uint64_t n = ...; if (n >= kCoverSize) fail("#%d: too much cover %u", th->id, n); It seems that the high part of n is set, but we don't see it. Add printf format attribute to fail and friends and fix all similar cases. Caught a bunch of similar cases and a missing argument in: exitf("opendir(%s) failed due to NOFILE, exiting");
* pkg/csource: fix handling of proc typesDmitry Vyukov2017-12-221-17/+39
| | | | | | | | | | Generated program always uses pid=0 even when there are multiple processes. Make each process use own pid. Unfortunately required to do quite significant changes to prog, because the current format only supported fixed pid. Fixes #490
* prog: use dense indexes for copyout instructionsDmitry Vyukov2017-12-171-18/+24
| | | | Fixes #174
* executor: remove unneeded NONFAILINGDmitry Vyukov2017-12-171-1/+1
| | | | copyin is already NONFAILING.
* pkg/ipc: make threaded/collide per-program optionsDmitry Vyukov2017-12-171-10/+10
| | | | | | | Currently threaded/collide are global environment flags. It can be useful to turn off collider during some executions (minimization, triage, etc). Make them per-program options.
* executor: prevent executor from messing with output regionDmitry Vyukov2017-10-231-16/+22
| | | | | | | | When comparisons are enabled fuzzer somehow manages to discover the output region and corrupt it. It seems to fetch the address from some memory operations (mmap/munmap). Don't leak the output region address.
* pkg/ipc: move fallback coverage into executorDmitry Vyukov2017-10-181-0/+1
| | | | | It seems to explode linux corpus. So make it freebsd-specific.
* executor: use forkserver for freebsdDmitry Vyukov2017-10-181-0/+1
| | | | | | | Use forkserver and shmem for freebsd. This greatly improves speed. Also introduce fallback coverage signal based on unique (syscall+errno) pairs.
* executor: improvements for akarosDmitry Vyukov2017-10-171-14/+11
| | | | | | | 1. remove workaround for pthread attrs (was fixed in akaros) 2. remove workaround for dup2 (was fixed in akaros) 3. check that we receive a program 4. implement timeout for test processes
* executor, pkg/ipc: unify ipc protocol between linux and other OSesDmitry Vyukov2017-10-161-4/+148
| | | | | | | | | | | | | | | | | We currently use more complex and functional protocol on linux, and a simple ad-hoc protocol on other OSes. This leads to code duplication in both ipc and executor. Linux supports coverage, shared memory communication and fork server, which would also be useful for most other OSes. Unify communication protocol and parametrize it by (1) use of shmem or only pipes, (2) use of fork server. This reduces duplication in ipc and executor and will allow to support the useful features for other OSes easily. Finally, this fixes akaros support as it currently uses syz-stress running on host (linux) and executor running on akaros.
* executor: add PC to kcov_comparison_tAlexander Potapenko2017-10-161-1/+4
| | | | | | | KCOV comparisons support is in the kernel mm tree already, and the patch contains an additional uint64_t to store PCs of functions calling __sanitizer_cov_trace_XXX(). Change kcov_comparison_t accordingly.
* executor, sys/windows: initial windows supportDmitry Vyukov2017-09-251-18/+4
|
* all: more assorted fuchsia supportDmitry Vyukov2017-09-221-0/+684