Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tromey@redhat.com>
To: Pedro Alves <palves@redhat.com>
Cc: lgustavo@codesourcery.com,
	       "'gdb-patches\@sourceware.org'"
	<gdb-patches@sourceware.org>
Subject: Re: [PATCH] Share ptrace options discovery/linux native code between GDB and gdbserver
Date: Tue, 30 Jul 2013 19:20:00 -0000	[thread overview]
Message-ID: <87ehaflusc.fsf@fleche.redhat.com> (raw)
In-Reply-To: <51F80CDB.3050106@redhat.com> (Pedro Alves's message of "Tue, 30	Jul 2013 19:58:35 +0100")

>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:

Pedro> That's a roundabout way of ending up with all code in a
Pedro> single file anyway.  And it left us with a weird linux-nat-common.c file
Pedro> in a few intermediate steps where it no longer hold code used by the
Pedro> gdb side backend (because by then there's no gdb side backend!).  If the
Pedro> code within is well isolated, we could even consider not merging it
Pedro> back into linux-low.c in the end, keeping the backend split in smaller
Pedro> modules.  But in order to do that, we best name it something actually
Pedro> indicative or its contents, and avoid coming up with new kitchen sinks.
Pedro> Say, this file holds the waitpid/__WALL/EINTR wrapper replacement, so
Pedro> what about linux-waitpid.c ?  Then:

Pedro> linux-nat.c, gdbserver/linux-low.c,
Pedro> -> linux-nat.c, gdbserver/linux-low.c, common/linux-waitpid.c
Pedro> -> gdbserver/linux-low.c, common/linux-waitpid.c
Pedro> -> common/linux-low.c, common/linux-waitpid.c

My initial reaction was that combining movement and refactoring is bad.
But on reflection it seems like just movement: the functions (pretty
much) stay the same; they may get some minor tweaks (as you'd expect
from a merge); but putting them into separate smaller new files is
really no different from stuffing them all into one big new file.

So I'm on board.

More stuff to put on the project page on the wiki...

Tom


  reply	other threads:[~2013-07-30 19:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-24 21:01 Luis Machado
2013-07-30 18:58 ` Pedro Alves
2013-07-30 19:20   ` Tom Tromey [this message]
2013-08-06 15:28   ` Luis Machado
2013-08-14 18:30     ` Pedro Alves

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=87ehaflusc.fsf@fleche.redhat.com \
    --to=tromey@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=lgustavo@codesourcery.com \
    --cc=palves@redhat.com \
    /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