All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] target/i386: Remove #ifdeffed-out icebp debugging hack
@ 2018-10-09 18:33 Peter Maydell
  2018-10-10 14:22 ` Richard Henderson
  0 siblings, 1 reply; 2+ messages in thread
From: Peter Maydell @ 2018-10-09 18:33 UTC (permalink / raw)
  To: qemu-devel; +Cc: patches, Richard Henderson, Paolo Bonzini, Eduardo Habkost

Remove a debugging hack which could be used to cause the
undocumented 'icebp' instruction to enable QEMU internal
debug logging. This code has always been #ifdeffed out
since it was introduced in commit aba9d61e34b9 in 2005;
judging by the rest of that commit (which is entirely
unrelated) it may have even been committed by accident.

(Note that WANT_ICEBP is not defined by default anyway.)

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
Mostly I wanted to get rid of the weird call to tb_flush(),
which is a bit unexpected to find in target frontend code.

 target/i386/translate.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/target/i386/translate.c b/target/i386/translate.c
index 83c1ebe4917..f8bc7680af5 100644
--- a/target/i386/translate.c
+++ b/target/i386/translate.c
@@ -7028,13 +7028,7 @@ static target_ulong disas_insn(DisasContext *s, CPUState *cpu)
 #ifdef WANT_ICEBP
     case 0xf1: /* icebp (undocumented, exits to external debugger) */
         gen_svm_check_intercept(s, pc_start, SVM_EXIT_ICEBP);
-#if 1
         gen_debug(s, pc_start - s->cs_base);
-#else
-        /* start debug */
-        tb_flush(CPU(x86_env_get_cpu(env)));
-        qemu_set_log(CPU_LOG_INT | CPU_LOG_TB_IN_ASM);
-#endif
         break;
 #endif
     case 0xfa: /* cli */
-- 
2.19.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH] target/i386: Remove #ifdeffed-out icebp debugging hack
  2018-10-09 18:33 [Qemu-devel] [PATCH] target/i386: Remove #ifdeffed-out icebp debugging hack Peter Maydell
@ 2018-10-10 14:22 ` Richard Henderson
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Henderson @ 2018-10-10 14:22 UTC (permalink / raw)
  To: Peter Maydell, qemu-devel; +Cc: patches, Paolo Bonzini, Eduardo Habkost

On 10/9/18 11:33 AM, Peter Maydell wrote:
> Remove a debugging hack which could be used to cause the
> undocumented 'icebp' instruction to enable QEMU internal
> debug logging. This code has always been #ifdeffed out
> since it was introduced in commit aba9d61e34b9 in 2005;
> judging by the rest of that commit (which is entirely
> unrelated) it may have even been committed by accident.
> 
> (Note that WANT_ICEBP is not defined by default anyway.)
> 
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
> Mostly I wanted to get rid of the weird call to tb_flush(),
> which is a bit unexpected to find in target frontend code.
> 
>  target/i386/translate.c | 6 ------
>  1 file changed, 6 deletions(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>


r~

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-10-10 14:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-09 18:33 [Qemu-devel] [PATCH] target/i386: Remove #ifdeffed-out icebp debugging hack Peter Maydell
2018-10-10 14:22 ` Richard Henderson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.