Received: from eggs.gnu.org ([2001:4830:134:3::10]:51441) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZXN3k-0001WH-Kp for qemu-devel@nongnu.org; Thu, 03 Sep 2015 01:27:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZXN3j-0007sX-JM for qemu-devel@nongnu.org; Thu, 03 Sep 2015 01:27:40 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Date: Thu, 03 Sep 2015 08:27:32 +0300 From: Sergey Smolov In-Reply-To: References: <55E6F1DF.1090807@ispras.ru> <55E6FEA6.5080708@ispras.ru> Message-ID: <5964af82a6f8f9b491dc4407b631895b@ispras.ru> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] QEMU+Aarch64: in_asm log skips instructions of loop-programs List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: QEMU Developers , qemu-devel-bounces+smolov=ispras.ru@nongnu.org Peter Maydell =D0=BF=D0=B8=D1=81=D0=B0=D0=BB 2015-09-02 19:39: > On 2 September 2015 at 14:50, Sergey Smolov wrote: >> 02.09.2015 16:55, Sergey Smolov =D0=BF=D0=B8=D1=88=D0=B5=D1=82: >>> It seems that QEMU skips some internal instructions when generates >>> "in_asm" log. How to eliminate this? >=20 > It might help if you said what you thought was missing. >=20 > -- PMM I mean that in this example QEMU does not write to log "intermediate"=20 SUBS instructions which appear in loop-unrolling process. For me it woulb be ok if QEMU generate the following in_asm log: [log] IN: 0x0000000000000000: 94000001 bl #+0x4 (addr 0x4) ---------------- IN: 0x0000000000000004: d2800140 mov x0, #0xa ---------------- IN: 0x0000000000000008: f1000400 subs x0, x0, #0x1 (1) ---------------- IN: 0x000000000000000c: 54000040 b.eq #+0x8 (addr 0x14) ---------------- IN: 0x0000000000000008: f1000400 subs x0, x0, #0x1 (1) ---------------- IN: 0x000000000000000c: 54000040 b.eq #+0x8 (addr 0x14) ---------------- IN: 0x0000000000000008: f1000400 subs x0, x0, #0x1 (1) ---------------- IN: 0x000000000000000c: 54000040 b.eq #+0x8 (addr 0x14) ... ... ---------------- IN: 0x0000000000000010: 17fffffd b #-0xc (addr 0x4) [/log] In terms of functional programming languages (like C), my idea is to=20 generate for the following program: for (i =3D 0; i < 2; i++) { func(i); } the log like: func(0) func(1) but QEMU generates log that contains exactly one call of "func". Sergey Smolov