about summary refs log tree commit diff
path: root/qemu_mode/patches/tcg-runtime.diff
diff options
context:
space:
mode:
authorDominik Maier <domenukk@gmail.com>2020-02-12 12:00:38 +0100
committerDominik Maier <domenukk@gmail.com>2020-02-12 12:00:38 +0100
commit5a114fd840305dff0692ccfb3c3aca0475f9ca8f (patch)
treeedb9483260e6858617cb90bab1e3c5fd952cff8d /qemu_mode/patches/tcg-runtime.diff
parent9db58da8b7be0f47209cba3b2d49247e3f1e13cf (diff)
parent54bbddec602feef0bd4e3bdc066c50779825d178 (diff)
downloadafl++-5a114fd840305dff0692ccfb3c3aca0475f9ca8f.tar.gz
Merge branch 'master' of github.com:vanhauser-thc/AFLplusplus
Diffstat (limited to 'qemu_mode/patches/tcg-runtime.diff')
-rw-r--r--qemu_mode/patches/tcg-runtime.diff24
1 files changed, 24 insertions, 0 deletions
diff --git a/qemu_mode/patches/tcg-runtime.diff b/qemu_mode/patches/tcg-runtime.diff
new file mode 100644
index 00000000..54a62ba8
--- /dev/null
+++ b/qemu_mode/patches/tcg-runtime.diff
@@ -0,0 +1,24 @@
+diff --git a/accel/tcg/tcg-runtime.c b/accel/tcg/tcg-runtime.c
+index d0d44844..46154af1 100644
+--- a/accel/tcg/tcg-runtime.c
++++ b/accel/tcg/tcg-runtime.c
+@@ -31,6 +31,8 @@
+ #include "disas/disas.h"
+ #include "exec/log.h"
+ 
++#include "../../../patches/afl-qemu-common.h"
++
+ /* 32-bit helpers */
+ 
+ int32_t HELPER(div_i32)(int32_t arg1, int32_t arg2)
+@@ -167,3 +169,10 @@ void HELPER(exit_atomic)(CPUArchState *env)
+ {
+     cpu_loop_exit_atomic(ENV_GET_CPU(env), GETPC());
+ }
++
++
++void HELPER(afl_entry_routine)(CPUArchState *env) {
++  
++  afl_forkserver(ENV_GET_CPU(env));
++  
++}