Received: from eggs.gnu.org ([208.118.235.92]:60337) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S2iuN-0007VR-DK for qemu-devel@nongnu.org; Wed, 29 Feb 2012 07:45:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S2iuI-0006fj-1R for qemu-devel@nongnu.org; Wed, 29 Feb 2012 07:45:26 -0500 Received: from csmailer.cs.nctu.edu.tw ([140.113.235.130]:39156) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S2iuH-0006en-C1 for qemu-devel@nongnu.org; Wed, 29 Feb 2012 07:45:21 -0500 Received: from csmailer.cs.nctu.edu.tw (localhost [127.0.0.1]) by csmailer.cs.nctu.edu.tw (Postfix) with ESMTP id B70CAC3D for ; Wed, 29 Feb 2012 20:50:28 +0800 (CST) Received: from alumni.cs.nctu.edu.tw (alumni.cs.nctu.edu.tw [140.113.235.116]) by csmailer.cs.nctu.edu.tw (Postfix) with ESMTP id B1251C3C for ; Wed, 29 Feb 2012 20:50:28 +0800 (CST) Received: (from chenwj@localhost) by alumni.cs.nctu.edu.tw (8.14.4/8.14.4/Submit) id q1TCj7Mn084239 for qemu-devel@nongnu.org; Wed, 29 Feb 2012 20:45:07 +0800 (CST) (envelope-from chenwj) Date: Wed, 29 Feb 2012 20:45:07 +0800 From: =?utf-8?B?6Zmz6Z+L5Lu7?= Message-ID: <20120229124507.GA83323@cs.nctu.edu.tw> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] How QEMU handle precise exception? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Hi all, I would like to know how QEMU handle precise exception. Basically, QEMU= need to maintain a well-defined guest architecture state (register + memory) b= efore returning to the exception handler. For the guest register, does QEMU save the guest registers (except gues= t pc) before every guest instruction which might raise exception? For the guest= memory, is it because how QEMU does (see below) so that guest memory is in a cons= istent state when guest exception occured? - Emulate guest "store" memory operations in the same order as in the o= riginal program order. - Emulate all potentially trapping guest instructions in the same order= with respect to the guest store instructions.=20 =20 Thanks! Regards, chenwj --=20 Wei-Ren Chen (=E9=99=B3=E9=9F=8B=E4=BB=BB) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj