From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19580 invoked by alias); 25 Apr 2005 00:04:22 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 19546 invoked from network); 25 Apr 2005 00:04:16 -0000 Received: from unknown (HELO mail.codesourcery.com) (65.74.133.9) by sourceware.org with SMTP; 25 Apr 2005 00:04:16 -0000 Received: (qmail 20941 invoked from network); 25 Apr 2005 00:04:15 -0000 Received: from localhost (HELO ?10.253.176.34?) (mitchell@127.0.0.1) by mail.codesourcery.com with SMTP; 25 Apr 2005 00:04:15 -0000 Message-ID: <426C33F7.2020404@codesourcery.com> Date: Mon, 25 Apr 2005 00:04:00 -0000 From: Mark Mitchell Organization: CodeSourcery, LLC User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) MIME-Version: 1.0 To: Mark Kettenis CC: drow@false.org, eliz@gnu.org, gdb-patches@sources.redhat.com Subject: Re: PATCH: Support Windows in event-loop.c References: <200504210549.j3L5n2nP027728@sirius.codesourcery.com> <01c546a1$Blat.v2.4$e03250c0@zahav.net.il> <4267F742.2090108@codesourcery.com> <01c546b0$Blat.v2.4$c193bb40@zahav.net.il> <20050421205617.GA13146@nevyn.them.org> <01c54713$Blat.v2.4$5d0b4ea0@zahav.net.il> <20050424221806.GA13942@nevyn.them.org> <200504242228.j3OMSoMh021198@elgar.sibelius.xs4all.nl> In-Reply-To: <200504242228.j3OMSoMh021198@elgar.sibelius.xs4all.nl> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2005-04/txt/msg00303.txt.bz2 Mark Kettenis wrote: > The problem here is that traditional gdb programmers are familliar > with POSIX and therefore certainly with select, and probably with > poll. They might very well not be familliar with Windows and the > magic of WaitForMultipleObjects. If we accept the patch as-is, the > number of people that can hack on the event loop code decreases since > the number of people who are familliar with both Windows and POSIX is > smaller than the number of people who know about POSIX. This is why I > think it would be preferable if an emulation for select or poll would > be used here. The flip side of this argument is that unless we can provide something that really does behave like select, people will *think* they understand what's going on in this code, but won't. For example, if we end up with a select that can't handle waiting for "write" events on file descriptors, then at some point someone might add such a thing, and then Windows will break. This is a somewhat different situation from the sockets situation, where the Windows API is very nearly identical to the UNIX API, modulo spelling, for the purposes of GDB. Intuition about UNIX sockets applies to Windows sockets, but intuition about UNIX file descriptors and select doesn't apply all that well to Windows. I have a feeling, though, that I'm shouting into the wind. I understand that the GDB community is POSIX-centric and of course GNU is Not UNIX, rather than Not Windows. I understand that, and it's much more important to me that the functionality be provided than that any particular form be used. I think my current intent is to wait for Chris' comments re. WaitForMultipleObjects and then try to make something that works like a limited form of select. -- Mark Mitchell CodeSourcery, LLC mark@codesourcery.com (916) 791-8304