Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: Tom Tromey <tom@tromey.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH/committed 2/8] sim: ppc: replace filter_filename with lbasename
Date: Tue, 9 Jan 2024 12:41:58 -0500	[thread overview]
Message-ID: <ZZ2FZgNrJ3TWwsVE@vapier> (raw)
In-Reply-To: <87a5pewp73.fsf@tromey.com>

[-- Attachment #1: Type: text/plain, Size: 1519 bytes --]

On 09 Jan 2024 07:34, Tom Tromey wrote:
> >>>>> "Mike" == Mike Frysinger <vapier@gentoo.org> writes:
> 
> Mike> The lbasename function from libiberty provides the same API as this
> Mike> custom function.  The common/ code already made the switch, so make
> Mike> the same change to the ppc code to avoid target duplication.
> 
> When updating and rebuilding in an existing tree, some patch -- I guess
> probably this one, I didn't bisect -- caused a build failure in sim/ppc
> because filter_filename was missing.  Removing sim/ppc/*.o and
> rebuilding fixed it, but I suppose this means there is a missing
> dependency somewhere.

ppc/ used to generate a filter_host.c file in the output dir, and compile the
.o from that.  it switched to using the igen/filter_host.c in the source dir.
when i've migrated code like this, i haven't left behind clean rules to delete
files that only mattered to old builds since any new builds would never see
that stuff.  but it means bisect/incremental (re)builds across that timespan
might break.  i don't know what the general policy is in the tree for these
cases, but it seems like we just don't bother.

also a lot of sim rules rely on VPATH to locate sources.  e.g. the makefiles
write ppc/foo.c instead of $(srcdir)/ppc/foo.c.  the only time we really use
$(srcdir) is with generated files we commit to the tree.  i think this pattern
is standard in the binutils-gdb tree.  but it also contributes to incremental
(re)build failures like this.
-mike

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2024-01-09 17:42 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-01 23:22 [PATCH/committed 1/8] sim: ppc: hoist igen compilation into top-level Mike Frysinger
2024-01-01 23:22 ` [PATCH/committed 2/8] sim: ppc: replace filter_filename with lbasename Mike Frysinger
2024-01-09 14:34   ` Tom Tromey
2024-01-09 17:41     ` Mike Frysinger [this message]
2024-01-01 23:22 ` [PATCH/committed 3/8] sim: ppc: unify igen filter_filename implementations Mike Frysinger
2024-01-01 23:22 ` [PATCH/committed 4/8] sim: igen: minor constify logic Mike Frysinger
2024-01-01 23:22 ` [PATCH/committed 5/8] sim: ppc: rename igen max_insn_bit_size Mike Frysinger
2024-01-01 23:22 ` [PATCH/committed 6/8] sim: igen: extend error to take arguments Mike Frysinger
2024-01-01 23:22 ` [PATCH/committed 7/8] sim: ppc: rework igen error to match common Mike Frysinger
2024-01-01 23:22 ` [PATCH/committed 8/8] sim: ppc: merge misc igen APIs Mike Frysinger

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=ZZ2FZgNrJ3TWwsVE@vapier \
    --to=vapier@gentoo.org \
    --cc=gdb-patches@sourceware.org \
    --cc=tom@tromey.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