qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Graf <agraf@suse.de>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH] Store correct IPs
Date: Wed, 04 Jun 2008 17:41:13 +0200	[thread overview]
Message-ID: <4846B799.5000608@suse.de> (raw)

[-- Attachment #1: Type: text/plain, Size: 133 bytes --]

If a VMEXIT occurs, the IP value needs to be current. This is the case 
with most instructions, except for CPUID and invlpg.

Alex



[-- Attachment #2: qemu-svn-ip.patch --]
[-- Type: text/x-patch, Size: 766 bytes --]

Index: target-i386/translate.c
===================================================================
--- target-i386/translate.c	(revision 4661)
+++ target-i386/translate.c	(working copy)
@@ -6407,6 +6407,7 @@
         break;
 #endif
     case 0x1a2: /* cpuid */
+        gen_jmp_im(s->pc - s->cs_base);
         tcg_gen_helper_0_0(helper_cpuid);
         break;
     case 0xf4: /* hlt */
@@ -6700,8 +6701,8 @@
                     }
                 } else {
                     gen_lea_modrm(s, modrm, &reg_addr, &offset_addr);
+                    gen_jmp_im(s->pc - s->cs_base);
                     tcg_gen_helper_0_1(helper_invlpg, cpu_A0);
-                    gen_jmp_im(s->pc - s->cs_base);
                     gen_eob(s);
                 }
             }

                 reply	other threads:[~2008-06-04 16:38 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=4846B799.5000608@suse.de \
    --to=agraf@suse.de \
    --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).