diff options
author | bellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-05-22 16:56:05 +0000 |
---|---|---|
committer | bellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-05-22 16:56:05 +0000 |
commit | 7e4597d7aea6a085f5ebfcfe56654d4c46a2ede7 (patch) | |
tree | 92e7f11f8a6f7925f1b7a352b700ab15b6866bdf /tcg/tcg-op.h | |
parent | 437a88a51cfa9a0e7080153f3a54cfa45f424b76 (diff) |
added debug_insn_start debug instruction
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4531 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'tcg/tcg-op.h')
-rw-r--r-- | tcg/tcg-op.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tcg/tcg-op.h b/tcg/tcg-op.h index b354100e65..b92b7bd162 100644 --- a/tcg/tcg-op.h +++ b/tcg/tcg-op.h @@ -1291,6 +1291,18 @@ static inline void tcg_gen_macro_2(TCGv ret0, TCGv ret1, int macro_id) #error must include QEMU headers #endif +/* debug info: write the PC of the corresponding QEMU CPU instruction */ +static inline void tcg_gen_debug_insn_start(uint64_t pc) +{ + /* XXX: must really use a 32 bit size for TCGArg in all cases */ +#if TARGET_LONG_BITS > TCG_TARGET_REG_BITS + tcg_gen_op2i(INDEX_op_debug_insn_start, + (uint32_t)(pc), (uint32_t)(pc >> 32)); +#else + tcg_gen_op1i(INDEX_op_debug_insn_start, pc); +#endif +} + static inline void tcg_gen_exit_tb(tcg_target_long val) { tcg_gen_op1i(INDEX_op_exit_tb, val); |