From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3899 invoked by alias); 31 Mar 2010 23:43:45 -0000 Received: (qmail 3868 invoked by uid 22791); 31 Mar 2010 23:43:44 -0000 X-SWARE-Spam-Status: No, hits=-1.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,SARE_MSGID_LONG45,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.44.51) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 31 Mar 2010 23:43:38 +0000 Received: from kpbe17.cbf.corp.google.com (kpbe17.cbf.corp.google.com [172.25.105.81]) by smtp-out.google.com with ESMTP id o2VNha1D022524 for ; Wed, 31 Mar 2010 16:43:36 -0700 Received: from gwj21 (gwj21.prod.google.com [10.200.10.21]) by kpbe17.cbf.corp.google.com with ESMTP id o2VNhYNg004609 for ; Wed, 31 Mar 2010 16:43:35 -0700 Received: by gwj21 with SMTP id 21so384304gwj.34 for ; Wed, 31 Mar 2010 16:43:34 -0700 (PDT) MIME-Version: 1.0 Received: by 10.150.157.20 with HTTP; Wed, 31 Mar 2010 16:43:34 -0700 (PDT) In-Reply-To: References: <1269899363-10054-1-git-send-email-vapier@gentoo.org> <201003301907.28723.vapier@gentoo.org> <201003301941.45755.vapier@gentoo.org> Date: Wed, 31 Mar 2010 23:43:00 -0000 Received: by 10.150.118.26 with SMTP id q26mr426125ybc.325.1270079014225; Wed, 31 Mar 2010 16:43:34 -0700 (PDT) Message-ID: Subject: Re: [PATCH] sim: constify watchpoint interrupt names From: Doug Evans To: Hans-Peter Nilsson Cc: Mike Frysinger , gdb-patches@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-System-Of-Record: true X-IsSubscribed: yes 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 X-SW-Source: 2010-03/txt/msg01125.txt.bz2 On Tue, Mar 30, 2010 at 6:45 PM, Hans-Peter Nilsson wrote: > On Tue, 30 Mar 2010, Mike Frysinger wrote: >> On Tuesday 30 March 2010 19:20:56 Hans-Peter Nilsson wrote: >> > Feel free to commit with a suitable ChangeLog entry if >> > tests pass. >> >> they do pass, and this reminds me of why dejagnu is so damn annoying. = =A0a >> simple `make check-sim` fails by default because the sim framework attem= pts to >> execute the binary on the host instead of through the sim. =A0seems pret= ty dumb >> to me. > > JFTR, you're supposed to specify a "board", like so: > "make check-sim RUNTESTFLAGS=3D--target_board=3Dv850-sim" but you > know that as you have run tests. > > Target executable files always default to the host (through > "unix.exp" aka. --target_board=3Dunix). =A0That you're testing the > simulator itself by running the target executable files there is > just a special-case, but anyway I guess it'd be a good idea > (read: feel free to send patches) for the simulator Makefile.in > to default to its dejagnu board when running the tests, e.g. to > default RUNTESTFLAGS to the above. =A0...or maybe even better, as > Doug suggested. For reference sake, an alternative to explicitly passing --target_board is to point $DEJAGNU at a file that specifies what target to use, e.g. based on target-triplet/tool. The m32r case I use is mildly interesting. The syntax is clumsy, but I keep it around to remind me how to automagically run multiple variations with one "make check". A "make check" of m32r produces: =3D=3D=3D sim tests =3D=3D=3D Schedule of variations: m32r-sim/-mmodel=3Dsmall/-G 0/-m32r m32r-sim/-mmodel=3Dsmall/-G 0/-m32rx m32r-sim/-mmodel=3Dsmall/-msdata=3Duse -G 8/-m32r m32r-sim/-mmodel=3Dsmall/-msdata=3Duse -G 8/-m32rx m32r-sim/-mmodel=3Dmedium/-G 0/-m32r m32r-sim/-mmodel=3Dmedium/-G 0/-m32rx m32r-sim/-mmodel=3Dmedium/-msdata=3Duse -G 8/-m32r m32r-sim/-mmodel=3Dmedium/-msdata=3Duse -G 8/-m32rx m32r-sim/-mmodel=3Dlarge/-G 0/-m32r m32r-sim/-mmodel=3Dlarge/-G 0/-m32rx m32r-sim/-mmodel=3Dlarge/-msdata=3Duse -G 8/-m32r m32r-sim/-mmodel=3Dlarge/-msdata=3Duse -G 8/-m32rx Running target m32r-sim/-mmodel=3Dsmall/-G 0/-m32r Using /usr/share/dejagnu/baseboards/m32r-sim.exp as board description file for target. [...] [There's also the MULTIPASS/PASS vars to control running multiple passes in one "make check" if one wants to do that kind of thing.] In case it helps, here's $DEJAGNU from one of my systems: --- snip --- set run_multiple_targets 1 send_user "target_triplet: $target_triplet\n" if [info exists tool] { send_user "tool: $tool\n" } switch -glob "$target_triplet" { "arm-*-elf" { if { "$tool" =3D=3D "sim" } { set target_list { arm-sim } } else { set target_list { arm-sid } } } "powerpc-*-*" { set target_list { powerpc-sim } } "powerpcle-*-*" { set target_list { powerpcle-sim } } "m32r-*-elf*" { if { $run_multiple_targets } { set target_list {{{m32r-sim{-mmodel=3Dsmall,-mmodel=3Dmedium,-mmodel=3Dlarge}{-G 0,-msdata=3Duse -G 8}}{-m32r,-m32rx}}} } else { set target_list { m32r-sim } } } "i?86-*-nacl*" { set target_list "nacl" } "i?86-*-*" { set target_list { unix } } "x86_64-*-*" { set target_list { unix } } "i960-*-coff" { set target_list { i960-sim } } "cris-*-elf" { set target_list { cris-sim } } "fr30-*-elf" { set target_list { fr30-sim } } "frv-*-elf" { set target_list { frv-sim } } "ip2k-*-elf" { set target_list { ip2k-sim } } "iq2000-*-elf" { set target_list { iq2000-sim } } "lm32-*-elf" { set target_list { lm32-sim } } "m32c-*-elf" { set target_list { m32c-sim } } "m68hc08-*-*" { set target_list { m68hc08-sim } } "mep-*-elf" { set target_list { mep-sim } } "mt-*-elf" { set target_list { mt-sim } } "openrisc-*-elf" { set target_list { openrisc-sim } } "or32-*-elf" { set target_list { openrisc-sim } } "sh64-*-elf" { set target_list { sh64-sim } } "xc16x-*-elf" { set target_list { xc16x-sim } } "xstormy16-*-elf" { set target_list { xstormy16-sid } } default { send_user "ERROR: dejagnu.exp Unknown target $target_triplet\n" exit 1 } } if [info exists target_list] { send_user "target_list: $target_list\n" } else { send_user "target_list: unspecified\n" }