about summary refs log tree commit diff
path: root/qemu_mode/patches/afl-qemu-common.h
diff options
context:
space:
mode:
authorAndrea Fioraldi <andreafioraldi@gmail.com>2019-09-13 11:37:26 +0200
committerGitHub <noreply@github.com>2019-09-13 11:37:26 +0200
commit8ee11fecc475dd6bcaab7f1e5a38c1cfac4c7e56 (patch)
treef728ee952e94bb299bd5fc603009fbcd51dd85cb /qemu_mode/patches/afl-qemu-common.h
parenta67d86c6e2ca58db81f2ddf6d0a4c837be88271d (diff)
parent36020c41df88ae863fbc2a148765f9c61c7f8bf8 (diff)
downloadafl++-8ee11fecc475dd6bcaab7f1e5a38c1cfac4c7e56.tar.gz
Merge pull request #57 from vanhauser-thc/persistent_qemu
Persistent mode in QEMU
Diffstat (limited to 'qemu_mode/patches/afl-qemu-common.h')
-rw-r--r--qemu_mode/patches/afl-qemu-common.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/qemu_mode/patches/afl-qemu-common.h b/qemu_mode/patches/afl-qemu-common.h
index 88c110b4..053585a7 100644
--- a/qemu_mode/patches/afl-qemu-common.h
+++ b/qemu_mode/patches/afl-qemu-common.h
@@ -47,3 +47,25 @@
 #define INC_AFL_AREA(loc) afl_area_ptr[loc]++
 #endif
 
+/* Declared in afl-qemu-cpu-inl.h */
+
+extern unsigned char *afl_area_ptr;
+extern unsigned int   afl_inst_rms;
+extern abi_ulong      afl_start_code, afl_end_code;
+extern abi_ulong      afl_persistent_addr;
+extern abi_ulong      afl_persistent_ret_addr;
+extern u8             afl_compcov_level;
+extern unsigned char  afl_fork_child;
+extern unsigned char  is_persistent;
+extern target_long    persistent_stack_offset;
+
+extern __thread abi_ulong afl_prev_loc;
+
+void afl_persistent_loop();
+
+void tcg_gen_afl_call0(void *func);
+void tcg_gen_afl_compcov_log_call(void *func, target_ulong cur_loc,
+                                  TCGv_i64 arg1, TCGv_i64 arg2);
+
+void tcg_gen_afl_maybe_log_call(target_ulong cur_loc);
+