Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Sergio Durigan Junior <sergiodj@redhat.com>
To: John Baldwin <jhb@freebsd.org>
Cc: GDB Patches <gdb-patches@sourceware.org>,
	 Pedro Alves <palves@redhat.com>,
	 Simon Marchi <simon.marchi@polymtl.ca>
Subject: Re: [PATCH v2 2/2] Rearrange gdb/configure.nat to make it simpler and less redundant
Date: Wed, 03 May 2017 17:28:00 -0000	[thread overview]
Message-ID: <87vaphetpd.fsf@redhat.com> (raw)
In-Reply-To: <13974428.RlsgoICUZ5@ralph.baldwin.cx> (John Baldwin's message of	"Wed, 03 May 2017 09:34:06 -0700")

On Wednesday, May 03 2017, John Baldwin wrote:

> On Tuesday, May 02, 2017 11:49:31 PM Sergio Durigan Junior wrote:
>> The previous commit introduced gdb/configure.nat, but it was just a
>> copy-and-past (with the necessary adjustments) from the files under
>> gdb/config/.  We can do better than that.
>> 
>> Instead of using one big 'case' statement that matches the
>> ${gdb_host_cpu} and then match each ${gdb_host}, it is possible to
>> remove a lof of redundancy by matching the most common ${gdb_host}'s
>> first, setting the common variables for each, and then proceed to
>> matching specific ${gdb_host}'s and ${gdb_host_cpu}'s.  In other
>> words, reverse the order of the 'case's and take advantage of the fact
>> that a lot of parameters are the same for each host.
>> 
>> This commit was tested on x86_64 without regressions.
>
> Thanks.  Just one minor nit that I see:
>  
>> +    fbsd)
>> +	case ${gdb_host_cpu} in
>> +	    i386)
>> +		# Host: FreeBSD/i386
>> +		NATDEPFILES="${NATDEPFILES} x86-nat.o x86-dregs.o \
>> +		x86-bsd-nat.o i386-bsd-nat.o i386-fbsd-nat.o bsd-kvm.o"
>> +		NAT_FILE='nm-fbsd.h'
>> +		;;
>> +	    mips)
>> +		# Host: FreeBSD/mips
>> +		NATDEPFILES="${NATDEPFILES} mips-fbsd-nat.o"
>> +		HAVE_NATIVE_GCORE_HOST=1
>
> This seems redundant as it is set in the "global" fbsd section?

You're right, John.  Fixed in my local tree.

Thanks for the review,

-- 
Sergio
GPG key ID: 237A 54B1 0287 28BF 00EF  31F4 D0EB 7628 65FC 5E36
Please send encrypted e-mail if possible
http://sergiodj.net/


  reply	other threads:[~2017-05-03 17:28 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-25 20:23 [PATCH] Introduce "gdb/configure.nat" (and delete "gdb/config/*/*.mh" files) Sergio Durigan Junior
2017-04-25 21:08 ` John Baldwin
2017-05-01 18:45 ` Sergio Durigan Junior
2017-05-02  2:44 ` Simon Marchi
2017-05-02 14:57   ` John Baldwin
2017-05-02 17:01     ` Simon Marchi
2017-05-02 19:28   ` Sergio Durigan Junior
2017-05-02 20:16     ` Simon Marchi
2017-05-02 21:30       ` Pedro Alves
2017-05-02 22:17       ` Sergio Durigan Junior
2017-05-03  3:49 ` [PATCH v2 0/2] Introduce gdb/configure.nat Sergio Durigan Junior
2017-05-03  3:49   ` [PATCH v2 1/2] Introduce "gdb/configure.nat" (and delete "gdb/config/*/*.mh" files) Sergio Durigan Junior
2017-05-04 16:16     ` Pedro Alves
2017-05-05  3:58       ` Sergio Durigan Junior
2017-05-05  9:41         ` Pedro Alves
2017-05-06 14:04           ` Sergio Durigan Junior
2017-05-17 14:03             ` Pedro Alves
2017-05-03  3:49   ` [PATCH v2 2/2] Rearrange gdb/configure.nat to make it simpler and less redundant Sergio Durigan Junior
2017-05-03 16:45     ` John Baldwin
2017-05-03 17:28       ` Sergio Durigan Junior [this message]
2017-05-04 16:34     ` Pedro Alves
2017-05-05  4:23       ` Sergio Durigan Junior
2017-05-05  4:31 ` [PATCH v3 0/2] Introduce gdb/configure.nat Sergio Durigan Junior
2017-05-05  4:31   ` [PATCH v3 2/2] Rearrange gdb/configure.nat to make it simpler and less redundant Sergio Durigan Junior
2017-05-06 14:13     ` Sergio Durigan Junior
2017-05-05  4:32   ` [PATCH v3 1/2] Introduce "gdb/configure.nat" (and delete "gdb/config/*/*.mh" files) Sergio Durigan Junior
2017-05-05 16:35     ` Pedro Alves
2017-05-06 14:13       ` Sergio Durigan Junior
2017-05-17 13:22         ` Pedro Alves
2017-05-23 14:40           ` Sergio Durigan Junior

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87vaphetpd.fsf@redhat.com \
    --to=sergiodj@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jhb@freebsd.org \
    --cc=palves@redhat.com \
    --cc=simon.marchi@polymtl.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox