qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paul Brook <paul@codesourcery.com>
To: qemu-devel@nongnu.org
Cc: Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [Qemu-devel] [Bug] qemu-system-ppc: "invalid/unsupported opcode" during debug session
Date: Sun, 28 Feb 2010 14:02:33 +0000	[thread overview]
Message-ID: <201002281402.34086.paul@codesourcery.com> (raw)
In-Reply-To: <20100228131830.GJ10291@volta.aurel32.net>

> > invalid/unsupported opcode: 00 - 00 - 00 (00000000) 4800fa44 1
> 
> I have fixed that in HEAD by stopping the translation just after a trap,
> as the instructions might never be executed.
> 
> It is not a full fix, as the OS can actually use any instruction that
> always generate a trap (even a memory access) as an instruction barrier
> to make sure the following instructions are never executed. This
> actually affects all targets, but is unlikely to happen.
> 
> One solution for that would be to only generate an exception for an
> unsupported instruction when it is the first instruction of a TB, and
> otherwise just end the translation before this instruction.

By my reading the code is correct. We end up calling gen_invalid which output 
code to raise an invalid instruction exception. If earlier code faults at 
runtime then that code is never executed, and everything is happy.

The real bug is that we have debugging printfs enabled by default.

Paul

  reply	other threads:[~2010-02-28 14:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <4B3A1B9D.7010004@mail.berlios.de>
2010-02-28 13:18 ` [Qemu-devel] [Bug] qemu-system-ppc: "invalid/unsupported opcode" during debug session Aurelien Jarno
2010-02-28 14:02   ` Paul Brook [this message]
2010-02-28 15:00     ` Aurelien Jarno
2010-02-28 15:25   ` Jamie Lokier
2010-02-28 15:29     ` Aurelien Jarno

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201002281402.34086.paul@codesourcery.com \
    --to=paul@codesourcery.com \
    --cc=aurelien@aurel32.net \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).