Skip to content

Commit f9fbba0

Browse files
committed
support all arch
1 parent 1b6deb6 commit f9fbba0

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

accel/tcg/translate-all.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,16 @@ static int libafl_setjmp_gen_code(CPUArchState *env, TranslationBlock *tb,
350350

351351
// -- start gen_intermediate_code
352352
const int num_insns = 1; // do "as-if" we were translating a single target instruction
353+
354+
#ifndef TARGET_INSN_START_EXTRA_WORDS
355+
tcg_gen_insn_start(pc);
356+
#elif TARGET_INSN_START_EXTRA_WORDS == 1
353357
tcg_gen_insn_start(pc, 0);
358+
#elif TARGET_INSN_START_EXTRA_WORDS == 2
359+
tcg_gen_insn_start(pc, 0, 0);
360+
#else
361+
#error Unhandled TARGET_INSN_START_EXTRA_WORDS value
362+
#endif
354363

355364
struct libafl_edge_hook* hook = libafl_edge_hooks;
356365
while (hook) {

0 commit comments

Comments
 (0)