From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1EMhKS-00041l-RR for qemu-devel@nongnu.org; Tue, 04 Oct 2005 03:35:14 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1EMhKN-0003zH-4h for qemu-devel@nongnu.org; Tue, 04 Oct 2005 03:35:07 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EMhKM-0003pq-LS for qemu-devel@nongnu.org; Tue, 04 Oct 2005 03:35:06 -0400 Received: from [206.46.252.42] (helo=vms042pub.verizon.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1EMh4F-0003iG-53 for qemu-devel@nongnu.org; Tue, 04 Oct 2005 03:18:27 -0400 Received: from [192.168.0.102] ([151.203.11.163]) by vms042.mailsrvcs.net (Sun Java System Messaging Server 6.2 HotFix 0.04 (built Dec 24 2004)) with ESMTPA id <0INT00CBKQYOL2W2@vms042.mailsrvcs.net> for qemu-devel@nongnu.org; Tue, 04 Oct 2005 02:18:24 -0500 (CDT) Date: Tue, 04 Oct 2005 03:17:45 -0400 From: John Coiner Subject: Re: [Qemu-devel] [patch] non-blocking disk IO In-reply-to: <46d6db660510030558y3413a698ra74d5a270de58bf2@mail.gmail.com> Message-id: <43422C99.2010300@stanfordalumni.org> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii; format=flowed Content-transfer-encoding: 7bit References: <4340D479.7030301@stanfordalumni.org> <434100A3.5030104@dblab.ece.ntua.gr> <46d6db660510030558y3413a698ra74d5a270de58bf2@mail.gmail.com> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Christian MICHON , qemu-devel@nongnu.org Whoops. I had the mistaken belief that Qemu already used pthreads. So, the makefiles and configure script need to handle pthreads somehow (especially on windows.) Pthreads-w32 is refusing to 'make install' itself into standard lib and include directories. Unlike SDL, there is no 'pthread-config' to tell us where it lives. Suppose that on Windows, we tell people to unpack the pthread distribution within the qemu tree. Qemu's configure script could find it, build a static pthread library, and link that into Qemu. This removes the need for the user to: * read pthreads-w32 documents, * issue a separate build command for pthreads-w32, * get confused before realizing that pthreads-w32 doesn't really support 'make install', * hack at qemu until it points to the uninstalled pthreads dir, * copy the pthreads DLL into c:\windows I'll look at adding this to the configure script. -john Christian MICHON wrote: > I managed to make it work (qemu+non blocking IO on windows host), > with a rough estimation of 10% speed increase at the early stage of > windows setup. I expect more once windows installs itself in true > multitasking mode. :) > > What you need to do is: > - download pthreads-w32-2-6-0-release.tar.gz and compile it from scratch > (make clean GC) > - you also need to add the following lines inside block.c (usleep is not > present in win32/mingw32) > > #ifdef WIN32 > void usleep(unsigned long usec) > { > Sleep(usec/1000); > } > #endif > > - you need to update the link to include "-lpthreadGC2 -lz", and > keep a copy of the pthreadGC2.dll where qemu.exe will be > (to pu it just in from of "-lz" is just my personal suggestion) > > HIH, > Christian > > On 10/3/05, Elefterios Stamatogiannakis wrote: > >>With which pthreads library have you compiled it under windows? >> >>I've tried it with the one here: >> >>ftp://sources.redhat.com/pub/pthreads-win32/ >> >>but it didn't compile. >> >>teris. > > > > _______________________________________________ > Qemu-devel mailing list > Qemu-devel@nongnu.org > http://lists.nongnu.org/mailman/listinfo/qemu-devel > >