public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Alan Modra <amodra@gmail.com>
To: "Maciej W. Rozycki" <macro@codesourcery.com>
Cc: binutils@sourceware.org
Subject: Re: [PATCH] MIPS: Opcode membership proposal
Date: Mon, 17 Jun 2013 11:51:00 -0000	[thread overview]
Message-ID: <20130617115141.GU21523@bubble.grove.modra.org> (raw)
In-Reply-To: <alpine.DEB.1.10.1208092012040.20608@tp.orcam.me.uk>

On Fri, Aug 10, 2012 at 12:07:11PM +0100, Maciej W. Rozycki wrote:
> +micromips-opc.lo: micromips-opc.c
> +	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ $<
> +
> +mips-opc.lo: mips-opc.c
> +	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ $<
> +
> +mips16-opc.lo: mips16-opc.c
> +	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ $<
> +

This patch resulted in no dependencies being generated for the mips
opcode files, causing my regression tests to fail spectacularly from
time to time.  I finally got around to looking into the problem.

	* Makefile.am (mips-opc.lo): Add rules to create automatic
	dependency files.  Pass archdefs.
	(micromips-opc.lo, mips16-opc.lo): Likewise.
	* Makefile.in: Regenerate.

Index: opcodes/Makefile.am
===================================================================
RCS file: /cvs/src/src/opcodes/Makefile.am,v
retrieving revision 1.172
diff -u -p -r1.172 Makefile.am
--- opcodes/Makefile.am	6 Feb 2013 23:22:25 -0000	1.172
+++ opcodes/Makefile.am	17 Jun 2013 11:06:21 -0000
@@ -573,13 +573,43 @@ $(srcdir)/rl78-decode.c: @MAINT@ $(srcdi
 	./opc2c$(EXEEXT_FOR_BUILD) $(srcdir)/rl78-decode.opc > $(srcdir)/rl78-decode.c
 
 micromips-opc.lo: micromips-opc.c
-	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ $<
+if am__fastdepCC
+	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) \
+	  -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ @archdefs@ $<
+	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+else
+if AMDEP
+	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+endif
+	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ @archdefs@ $<
+endif
 
 mips-opc.lo: mips-opc.c
-	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ $<
+if am__fastdepCC
+	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) \
+	  -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ @archdefs@ $<
+	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+else
+if AMDEP
+	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+endif
+	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ @archdefs@ $<
+endif
 
 mips16-opc.lo: mips16-opc.c
-	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ $<
+if am__fastdepCC
+	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) \
+	  -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ @archdefs@ $<
+	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+else
+if AMDEP
+	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+endif
+	$(LTCOMPILE) $(NO_WMISSING_FIELD_INITIALIZERS) -c -o $@ @archdefs@ $<
+endif
 
 $(srcdir)/rx-decode.c: @MAINT@ $(srcdir)/rx-decode.opc opc2c$(EXEEXT_FOR_BUILD)
 	./opc2c$(EXEEXT_FOR_BUILD) $(srcdir)/rx-decode.opc > $(srcdir)/rx-decode.c


-- 
Alan Modra
Australia Development Lab, IBM

  parent reply	other threads:[~2013-06-17 11:51 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-18 12:55 Maciej W. Rozycki
2010-12-20 18:15 ` David Daney
2010-12-20 18:33   ` Andrew Pinski
2011-10-31 12:47 ` Maciej W. Rozycki
2011-11-17 18:45   ` Richard Sandiford
2012-08-10 11:08     ` Maciej W. Rozycki
2012-08-12 18:33       ` Richard Sandiford
2012-08-13 14:56         ` Maciej W. Rozycki
2013-06-17 11:51       ` Alan Modra [this message]
2013-06-17 15:18         ` Maciej W. Rozycki
2013-06-17 19:53           ` Richard Sandiford
2013-06-17 22:30             ` Maciej W. Rozycki
2013-06-18  0:27           ` Alan Modra
2013-06-24 14:28             ` Maciej W. Rozycki

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=20130617115141.GU21523@bubble.grove.modra.org \
    --to=amodra@gmail.com \
    --cc=binutils@sourceware.org \
    --cc=macro@codesourcery.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).