This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] document Blackfin-specific gas options


On 03/10/2010 11:03 AM, Joseph S. Myers wrote:
On Tue, 9 Mar 2010, Mike Frysinger wrote:

	* doc/as.texinfo: Add Blackfin options.
	* doc/c-bfin.texi: Document -mfdpic, -mno-fdpic and -mnopic.

This is only changing two of the three places that list options for each target. You're changing the summary, and the documentation in c-$target.texi. But there's also documentation of the options for many targets in as.texinfo, and only that documentation of the individual options, and not that in c-$target.texi, ends up in the manpage. (Some targets do e.g.

@ifset CRIS
See the info pages for documentation of the CRIS-specific options.
@end ifset

in as.texinfo, avoiding some duplication but resulting in a less helpful
manpage.)

This duplication does have the unfortunate effect of options only being
documented in some of the three places (for example, the ARM -mimplicit-it
option is only documented in c-arm.texi, although ARM has documentation in
all three places).  It might be nice to reduce them to two places by
eliminating the text in as.texinfo that effectively duplicates
c-$target.texi (while ensuring that any places where that text is better
than c-$target.texi are merged into c-$target.texi), while arranging for
the option information from c-$target.texi to end up in the manpage.  But
until anyone does that, you should probably at least put something like
the CRIS text in the text that ends up in the manpage, if not a copy of
the documentation of individual options.

Thank you for pointing it out! I modified the patch accordingly and committed it. It's attached. I just duplicate it since it's easiest to do. ;-)

Btw, I don't know how to write the email address. I wrote the patch when I worked for ADI. I tried to put my Analog email address alongside with my CodeSourcery email address. But it looks too weird. So I just only put my current email address. If I should put both or there is any better solutions by Binutils or GNU project convention, please let me know.

Regards,
--
Jie Zhang
CodeSourcery
(650) 331-3385 x735
2009-07-13  Jie Zhang  <jie.zhang@analog.com>

	* doc/as.texinfo: Add Blackfin options.
	* doc/c-bfin.texi: Document -mfdpic, -mno-fdpic and -mnopic.
	* config/tc-bfin.c (md_show_usage): Show usage for all
	Blackfin specific options.

Index: config/tc-bfin.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-bfin.c,v
retrieving revision 1.32
diff -u -p -r1.32 tc-bfin.c
--- config/tc-bfin.c	11 Dec 2009 13:42:10 -0000	1.32
+++ config/tc-bfin.c	10 Mar 2010 03:53:08 -0000
@@ -418,9 +418,12 @@ md_parse_option (int c ATTRIBUTE_UNUSED,
 }
 
 void
-md_show_usage (FILE * stream ATTRIBUTE_UNUSED)
+md_show_usage (FILE * stream)
 {
-  fprintf (stream, _(" BFIN specific command line options:\n"));
+  fprintf (stream, _(" Blackfin specific assembler options:\n"));
+  fprintf (stream, _("  -mcpu=<cpu[-sirevision]> specify the name of the target CPU\n"));
+  fprintf (stream, _("  -mfdpic                  assemble for the FDPIC ABI\n"));
+  fprintf (stream, _("  -mno-fdpic/-mnopic       disable -mfdpic\n"));
 }
 
 /* Perform machine-specific initializations.  */
Index: doc/as.texinfo
===================================================================
RCS file: /cvs/src/src/gas/doc/as.texinfo,v
retrieving revision 1.215
diff -u -p -r1.215 as.texinfo
--- doc/as.texinfo	27 Jan 2010 22:01:37 -0000	1.215
+++ doc/as.texinfo	10 Mar 2010 03:53:10 -0000
@@ -39,6 +39,9 @@
 @ifset ARM/Thumb
 @set ARM
 @end ifset
+@ifset Blackfin
+@set Blackfin
+@end ifset
 @ifset BOUT
 @set aout-bout
 @end ifset
@@ -273,6 +276,14 @@ gcc(1), ld(1), and the Info entries for 
     @b{-mapcs-reentrant}]
    [@b{-mthumb-interwork}] [@b{-k}]
 @end ifset
+@ifset Blackfin
+
+@emph{Target Blackfin options:}
+   [@b{-mcpu}=@var{processor}[-@var{sirevision}]]
+   [@b{-mfdpic}]
+   [@b{-mno-fdpic}]
+   [@b{-mnopic}]
+@end ifset
 @ifset CRIS
 
 @emph{Target CRIS options:}
@@ -715,6 +726,21 @@ Specify that PIC code has been generated
 @end table
 @end ifset
 
+@ifset Blackfin
+The following options are available when @value{AS} is configured for
+the Blackfin processor family.
+
+@table @gcctabopt
+@item -mcpu=@var{processor}@r{[}-@var{sirevision}@r{]}
+This option specifies the target processor.  The optional @var{sirevision}
+is not used in assembler.
+@item -mfdpic
+Assemble for the FDPIC ABI.
+@item -mno-fdpic/-mnopic
+Disable -mfdpic.
+@end table
+@end ifset
+
 @ifset CRIS
 See the info pages for documentation of the CRIS-specific options.
 @end ifset
Index: doc/c-bfin.texi
===================================================================
RCS file: /cvs/src/src/gas/doc/c-bfin.texi,v
retrieving revision 1.5
diff -u -p -r1.5 c-bfin.texi
--- doc/c-bfin.texi	4 Sep 2009 02:31:44 -0000	1.5
+++ doc/c-bfin.texi	10 Mar 2010 03:53:10 -0000
@@ -66,6 +66,14 @@ recognized: 
 and
 @code{bf561}.
 
+@cindex @code{-mfdpic} command line option, Blackfin
+@item -mfdpic
+Assemble for the FDPIC ABI.
+
+@cindex @code{-mno-fdpic} command line option, Blackfin
+@cindex @code{-mnopic} command line option, Blackfin
+@item -mno-fdpic/-mnopic
+Disable -mfdpic.
 @end table
 
 @node Blackfin Syntax

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]