qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug: fstenv is wrongly implemented


From: Ziqiao Kong
Subject: Re: Bug: fstenv is wrongly implemented
Date: Tue, 6 Apr 2021 21:16:23 +0800

Hi!

I checked that bug and list discussion and it indeed was the bug I
referred to. It seems that the patch should be quite straightforward
but no idea why the review of the patch was stalled at that time. I
would try to draft an updated patch these days.

Ziqiao

On Fri, Apr 2, 2021 at 6:49 PM Peter Maydell <peter.maydell@linaro.org> wrote:
>
> On Fri, 2 Apr 2021 at 09:47, Paolo Bonzini <pbonzini@redhat.com> wrote:
> >
> > On 02/04/21 10:29, Ziqiao Kong wrote:
> > >
> > > According to git blame, this bug is introduced about 13 years ago:
> > > https://github.com/qemu/qemu/blame/633decd71119a4293e5e53e6059026c517a8bef0/target-i386/fpu_helper.c#L997.
> > >
> > > We also had a patch for this bug:
> > > https://github.com/unicorn-engine/unicorn/commit/59b09a71bfc6fd8b95357944f6be9aa54f424421
> > > which you may refer to. I can also help draft a patch if necessary.
> >
> > Hi!
> >
> > Unfortunately the patch is incorrect, because fpu_update_ip is called
> > only at translation time and not at run-time.  If more than one x87
> > instruction is present in the same translation block, or if a
> > translation block has been compiled after the one that is executing,
> > env->fpip will be incorrect.
>
> I think this is https://bugs.launchpad.net/qemu/+bug/661696 ?
> That had a patch attached which got some on-list discussion
> back in 2010:
> https://lists.gnu.org/archive/html/qemu-devel/2010-11/msg02497.html
> The review comments may be of help in coming up with an updated patch.
>
> thanks
> -- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]