From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2133 invoked by alias); 24 Feb 2019 17:45:47 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 595 invoked by uid 89); 24 Feb 2019 17:45:25 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,TIME_LIMIT_EXCEEDED autolearn=unavailable version=3.3.2 spammy= X-HELO: eggs.gnu.org Received: from eggs.gnu.org (HELO eggs.gnu.org) (209.51.188.92) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 24 Feb 2019 17:45:07 +0000 Received: from fencepost.gnu.org ([2001:470:142:3::e]:44595) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gxxpq-0002W6-7V; Sun, 24 Feb 2019 12:45:06 -0500 Received: from [176.228.60.248] (port=2257 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gxxpp-0005ki-R8; Sun, 24 Feb 2019 12:45:06 -0500 Date: Sun, 24 Feb 2019 17:45:00 -0000 Message-Id: <83r2bxnkrb.fsf@gnu.org> From: Eli Zaretskii To: Tom Tromey CC: gdb-patches@sourceware.org In-reply-to: <87va19jdy4.fsf@tromey.com> (message from Tom Tromey on Sun, 24 Feb 2019 10:25:55 -0700) Subject: Re: [RFC 00/17] Merge event loop implementations References: <20190224165153.5062-1-tom@tromey.com> <83sgwdnm6r.fsf@gnu.org> <87va19jdy4.fsf@tromey.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-IsSubscribed: yes X-SW-Source: 2019-02/txt/msg00411.txt.bz2 > From: Tom Tromey > Cc: Tom Tromey , gdb-patches@sourceware.org > Date: Sun, 24 Feb 2019 10:25:55 -0700 > > >>>>> "Eli" == Eli Zaretskii writes: > > Eli> The problem here is that Windows' implementation of 'select' works > Eli> only on sockets, and wants HSOCKET handles instead of file > Eli> descriptors. If you feed it a file descriptor, it won't work, even if > Eli> the descriptor is for a socket. > > Thanks. > > I am still not sure what to do. Move the mingw-hdep select code to > common? Or is it better to reintroduce gdb_fildes_t and use it > everywhere? The former seems simpler I suppose, but the way that the > mingw-hdep select implementation relies on readline gives me pause. The readline bits should IMO be moved to readline, where it calls 'select'. > Though perhaps that code will be removed in the readline upgrade, when I > get back to that? So one idea might be to try to land that first. I'm sorry, I cannot help you with this dilemma. Not unless someone describes in more detail the actual needs of both GDB and gdbserver for which they call 'select'. I myself don't know enough about the internals to give any advice. The long-term goal is probably to import the Gnulib implementation of 'select', which AFAIR supports any kind of descriptors. But that would need some adaptation work. So, if no one chimes in with more specific advice, perhaps leave this particular part out of this series.