From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O6sIt-0000LC-Ar for qemu-devel@nongnu.org; Tue, 27 Apr 2010 17:26:51 -0400 Received: from [140.186.70.92] (port=50889 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O6sIs-0000Jr-0G for qemu-devel@nongnu.org; Tue, 27 Apr 2010 17:26:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O6sIq-0003y9-Pp for qemu-devel@nongnu.org; Tue, 27 Apr 2010 17:26:49 -0400 Received: from mail-bw0-f209.google.com ([209.85.218.209]:56045) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O6sIq-0003xv-Ks for qemu-devel@nongnu.org; Tue, 27 Apr 2010 17:26:48 -0400 Received: by bwz1 with SMTP id 1so17363648bwz.2 for ; Tue, 27 Apr 2010 14:26:47 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: Date: Tue, 27 Apr 2010 22:26:46 +0100 Message-ID: Subject: Re: [Qemu-devel] thread synchronization in qcow2.c and qcow2-cluster.c From: Stefan Hajnoczi Content-Type: text/plain; charset=ISO-8859-1 List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Chunqiang (CQ) Tang" Cc: qemu-devel@nongnu.org On Tue, Apr 27, 2010 at 9:39 PM, Chunqiang (CQ) Tang wrote: > Thank you for the information. I also suspected that > qemu_mutex_lock_iothread() does the synchronization. However, my > profiling showed that qemu-kvm.c:kvm_cpu_exec() in is actually > executed, instead of kvm-all.c:kvm_cpu_exec(). Are you using qemu-kvm.git? Can you double check that qemu-kvm.o is being linked in instead of kvm-all.o? I looked at the link map for qemu-system-x86_64 and verified that kvm-all.o is linked in and qemu-kvm.o is not linked in. Stefan diff --git a/Makefile.target b/Makefile.target index 1ffd802..122b951 100644 --- a/Makefile.target +++ b/Makefile.target @@ -30,6 +30,7 @@ endif PROGS=$(QEMU_PROG) +LDFLAGS+=-Wl,-Map=$(QEMU_PROG).map LIBS+=-lm kvm.o kvm-all.o: QEMU_CFLAGS+=$(KVM_CFLAGS)