diff options
author | Nick Clifton <nickc@redhat.com> | 2004-08-17 12:19:58 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2004-08-17 12:19:58 +0000 |
commit | 329e276daf98fb4c8b3770a6c2f02fd22472a638 (patch) | |
tree | 9faf3443e26885446e02a6f38d80656b3b4a143d /gas/doc | |
parent | 469aff8eec9fab2c81b46eaf8939eee82423e293 (diff) | |
download | gdb-329e276daf98fb4c8b3770a6c2f02fd22472a638.zip gdb-329e276daf98fb4c8b3770a6c2f02fd22472a638.tar.gz gdb-329e276daf98fb4c8b3770a6c2f02fd22472a638.tar.bz2 |
Add support for a -g switch to GAS
Diffstat (limited to 'gas/doc')
-rw-r--r-- | gas/doc/as.texinfo | 12 | ||||
-rw-r--r-- | gas/doc/internals.texi | 28 |
2 files changed, 32 insertions, 8 deletions
diff --git a/gas/doc/as.texinfo b/gas/doc/as.texinfo index 800d447..89868c2 100644 --- a/gas/doc/as.texinfo +++ b/gas/doc/as.texinfo @@ -227,8 +227,8 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}. @smallexample @c man begin SYNOPSIS @value{AS} [@b{-a}[@b{cdhlns}][=@var{file}]] [@b{--alternate}] [@b{-D}] - [@b{--defsym} @var{sym}=@var{val}] [@b{-f}] [@b{--gstabs}] [@b{--gstabs+}] - [@b{--gdwarf2}] [@b{--help}] [@b{-I} @var{dir}] [@b{-J}] [@b{-K}] [@b{-L}] + [@b{--defsym} @var{sym}=@var{val}] [@b{-f}] [@b{-g}] [@b{--gstabs}] [@b{--gstabs+}] + [@b{--gdwarf-2}] [@b{--help}] [@b{-I} @var{dir}] [@b{-J}] [@b{-K}] [@b{-L}] [@b{--listing-lhs-width}=@var{NUM}] [@b{--listing-lhs-width2}=@var{NUM}] [@b{--listing-rhs-width}=@var{NUM}] [@b{--listing-cont-lines}=@var{NUM}] [@b{--keep-locals}] [@b{-o} @var{objfile}] [@b{-R}] [@b{--statistics}] [@b{-v}] @@ -479,6 +479,12 @@ indicates a hexadecimal value, and a leading @samp{0} indicates an octal value. ``fast''---skip whitespace and comment preprocessing (assume source is compiler output). +@item -g +@itemx --gen-debug +Generate debugging information for each assembler source line using whichever +debug format is preferred by the target. This currently means either STABS, +ECOFF or DWARF2. + @item --gstabs Generate stabs debugging information for each assembler line. This may help debugging assembler code, if the debugger can handle it. @@ -490,7 +496,7 @@ debuggers crash or refuse to read your program. This may help debugging assembler code. Currently the only GNU extension is the location of the current working directory at assembling time. -@item --gdwarf2 +@item --gdwarf-2 Generate DWARF2 debugging information for each assembler line. This may help debugging assembler code, if the debugger can handle it. Note---this option is only supported by some targets, not all of them. diff --git a/gas/doc/internals.texi b/gas/doc/internals.texi index 6719bbf..1c3ad97 100644 --- a/gas/doc/internals.texi +++ b/gas/doc/internals.texi @@ -858,13 +858,17 @@ independent string passed to @code{getopt}. @code{md_longopts} is a passed to @code{getopt}; you may use @code{OPTION_MD_BASE}, defined in @file{as.h}, as the start of a set of long option indices, if necessary. @code{md_longopts_size} is a @code{size_t} holding the size @code{md_longopts}. + GAS will call @code{md_parse_option} whenever @code{getopt} returns an unrecognized code, presumably indicating a special code value which appears in -@code{md_longopts}. GAS will call @code{md_show_usage} when a usage message is -printed; it should print a description of the machine specific options. -@code{md_after_pase_args}, if defined, is called after all options are -processed, to let the backend override settings done by the generic option -parsing. +@code{md_longopts}. This function should return non-zero if it handled the +option and zero otherwise. There is no need to print a message about an option +not being recognised. This will be handled by the generic code. + +GAS will call @code{md_show_usage} when a usage message is printed; it should +print a description of the machine specific options. @code{md_after_pase_args}, +if defined, is called after all options are processed, to let the backend +override settings done by the generic option parsing. @item md_begin @cindex md_begin @@ -1520,6 +1524,20 @@ It should return the size of an address, as it should be represented in debugging info. If you don't define this macro, the default definition uses the number of bits per address, as defined in @var{bfd}, divided by 8. +@item MD_DEBUG_FORMAT_SELECTOR +@cindex MD_DEBUG_FORMAT_SELECTOR +If defined this macro is the name of a function to be called when the +@samp{--gen-debug} switch is detected on the assembler's command line. The +prototype for the function looks like this: + +@smallexample + enum debug_info_type MD_DEBUG_FORMAT_SELECTOR (int * use_gnu_extensions) +@end smallexample + +The function should return the debug format that is preferred by the CPU +backend. This format will be used when generating assembler specific debug +information. + @end table @node Object format backend |