From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8657 invoked by alias); 28 Jun 2013 18:26:04 -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 8646 invoked by uid 89); 28 Jun 2013 18:26:04 -0000 X-Spam-SWARE-Status: No, score=-8.1 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Fri, 28 Jun 2013 18:26:03 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r5SIQ1UW004475 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 28 Jun 2013 14:26:01 -0400 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.ams2.redhat.com [10.39.146.11]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r5SIPxF8027212; Fri, 28 Jun 2013 14:26:00 -0400 Message-ID: <51CDD537.3040300@redhat.com> Date: Fri, 28 Jun 2013 19:05:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6 MIME-Version: 1.0 To: Eli Zaretskii CC: tromey@redhat.com, gdb-patches@sourceware.org Subject: Re: [PATCH] Make file transfer commands work with all (native) targets. References: <1371835506-15691-1-git-send-email-tromey@redhat.com> <1371835506-15691-5-git-send-email-tromey@redhat.com> <51C880C5.6050307@redhat.com> <87bo6rmhin.fsf@fleche.redhat.com> <51CDBAF6.4040209@redhat.com> <83txkidtap.fsf@gnu.org> In-Reply-To: <83txkidtap.fsf@gnu.org> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2013-06/txt/msg00922.txt.bz2 On 06/28/2013 06:44 PM, Eli Zaretskii wrote: >> Date: Fri, 28 Jun 2013 17:33:58 +0100 >> From: Pedro Alves >> CC: gdb-patches@sourceware.org >> >>> Pedro> remote_file_get could nowadays be using the target_fileio_XXX methods >>> Pedro> instead of remote_hostio_XXX, and therefore the command could be >>> Pedro> generalized to work with all targets. >> >> Actually, doing this is quite easy, so I went ahead, in the name >> of local/remote feature parity. We can connect to a local gdbserver >> and do file transfer in the local system; there seems to be no >> reason we can't do it with native debugging too. >> >> WDYT? > > What is the use case? Yeah, I admit it fits more in the general "as fewer differences we have between local/remote debugging, the better" theme than driven by a particular use case. A possible example would be something like gdb scripts working the same whether connected to a remote or local target (and unaware of whether the local target is implemented by local gdbserver or the native built-in target). > Without a good use case, having "remote get" serve like a poor man's > 'cp' is confusing, IMO. Would you be OK with, or prefer, adding "target get/put/delete", leaving the "remote" variants in place? The difference between the "target" and "remote" variants would be that the former would work with any target, while the later would still only work with the remote target. -- Pedro Alves