From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7620 invoked by alias); 29 Aug 2014 01:38:25 -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 7592 invoked by uid 89); 29 Aug 2014 01:38:19 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.7 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 29 Aug 2014 01:38:17 +0000 Received: from svr-orw-fem-06.mgc.mentorg.com ([147.34.97.120]) by relay1.mentorg.com with esmtp id 1XNB8n-0003ZW-93 from Yao_Qi@mentor.com ; Thu, 28 Aug 2014 18:38:13 -0700 Received: from GreenOnly (147.34.91.1) by SVR-ORW-FEM-06.mgc.mentorg.com (147.34.97.120) with Microsoft SMTP Server id 14.2.247.3; Thu, 28 Aug 2014 18:38:12 -0700 From: Yao Qi To: Pedro Alves CC: Subject: Re: [PATCH] Another board file for remote host References: <1409232690-24185-1-git-send-email-yao@codesourcery.com> <53FF3C68.6040905@redhat.com> Date: Fri, 29 Aug 2014 01:38:00 -0000 In-Reply-To: <53FF3C68.6040905@redhat.com> (Pedro Alves's message of "Thu, 28 Aug 2014 15:27:52 +0100") Message-ID: <87a96of59j.fsf@codesourcery.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2014-08/txt/msg00631.txt.bz2 Pedro Alves writes: > I'm confused on the choice of "native" for name. > local-remote-host.exp/local-remote-host-notty.exp seem just or more > more native to me, as they assume a shared filesystem, while > the whole point of this one is emulate the case of _not_ sharing > the filesystem? This board file is used to emulate the real remote host testing, in which file system of host and build are not shared. To be concrete, I'd like this board file to emulate the testing we do for native mingw32 GDB. GDB is built on x86_64-linux, is run on Windows, and does debugging on Windows. I find such testing mode exposes some problems in test cases, such as files not copied to host or referencing build file path on host, etc. Existing board files local-remote-host-*.exp share the file system, so the problem of copying needed files to host is not exposed. This board file is to emulate the testing to a native gdb (host =3D=3D target) on a remote host (host !=3D build), so I name it local-remote-host-native. At first, I name it local-remote-host-target, but I discard it as it is confusing. > >> +# To use this file: >> +# bash$ cd ${build_dir}/gdb >> +# bash$ make check >> RUNTESTFLAGS=3D"--host_board=3Dlocal-remote-host-native >> --target_board=3Dlocal-remote-host-native" >> + >> +if { $board_type =3D=3D "target" } { >> + set_board_info compiler gcc > > Why do we need to also use the board as a target board? > Because [is_remote target] is true when I pass --host_board=3Dlocal-remote-host-native --target_board=3Dlocal-remote-host-native to DejaGNU. If I do "--host_board=3Dlocal-remote-host-native (--target_board=3Dunix)", [is_remote target] is false. Since I am doing test under target =3D=3D host !=3D build, so [is_remote target] is expected to be true, isn't? >> +} > >> +if { $board_type =3D=3D "host" } { >> + set_board_info gdb_opts "-ex \"dir ${tmp_dir}\"" > > No biggie, but this: > > set_board_info gdb_opts "-d \"${tmp_dir}\"" > > looks a little simpler to me, just for the fact that it runs > through less code / fewer indirections in GDB. OK, I'll fix it. I realize that the rationale and explanations are missing for this board file, and I'll add more comments about them if the board file is OK. --=20 Yao (=E9=BD=90=E5=B0=A7)