summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--gnu/usr.bin/binutils/bfd/hosts/i386nbsd.h14
-rw-r--r--gnu/usr.bin/binutils/bfd/hosts/m68knbsd.h13
-rw-r--r--gnu/usr.bin/binutils/bfd/hosts/mipsnbsd.h13
-rw-r--r--gnu/usr.bin/binutils/bfd/hosts/nbsd.h14
-rw-r--r--gnu/usr.bin/binutils/bfd/hosts/ns32knbsd.h13
-rw-r--r--gnu/usr.bin/binutils/bfd/hosts/sparcnbsd.h18
-rw-r--r--gnu/usr.bin/binutils/binutils/alloca.c191
-rw-r--r--gnu/usr.bin/binutils/binutils/arlex.c1802
-rw-r--r--gnu/usr.bin/binutils/binutils/arparse.c1026
-rw-r--r--gnu/usr.bin/binutils/binutils/arparse.h26
-rw-r--r--gnu/usr.bin/binutils/binutils/binutils.info1668
-rw-r--r--gnu/usr.bin/binutils/binutils/gmalloc.c1116
-rw-r--r--gnu/usr.bin/binutils/binutils/nlmheader.c1931
-rw-r--r--gnu/usr.bin/binutils/binutils/sysinfo.c1249
-rw-r--r--gnu/usr.bin/binutils/binutils/sysinfo.h13
-rw-r--r--gnu/usr.bin/binutils/binutils/syslex.c1651
-rw-r--r--gnu/usr.bin/binutils/config.sub1
-rw-r--r--gnu/usr.bin/binutils/config/mh-i386win3226
-rw-r--r--gnu/usr.bin/binutils/configure2
-rw-r--r--gnu/usr.bin/binutils/configure.bat17
-rw-r--r--gnu/usr.bin/binutils/etc/configure.info64
-rw-r--r--gnu/usr.bin/binutils/etc/configure.info-11174
-rw-r--r--gnu/usr.bin/binutils/etc/configure.info-2572
-rw-r--r--gnu/usr.bin/binutils/etc/standards.info59
-rw-r--r--gnu/usr.bin/binutils/etc/standards.info-11225
-rw-r--r--gnu/usr.bin/binutils/etc/standards.info-21462
-rw-r--r--gnu/usr.bin/binutils/gas/config/te-delta88.h13
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info262
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info-11338
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info-21464
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info-31393
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info-41388
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info-5741
-rw-r--r--gnu/usr.bin/binutils/gas/doc/as.info-6776
-rw-r--r--gnu/usr.bin/binutils/gas/doc/gasp.info1087
-rw-r--r--gnu/usr.bin/binutils/gas/m68k-parse.c1916
-rw-r--r--gnu/usr.bin/binutils/gas/make-gas.com126
-rw-r--r--gnu/usr.bin/binutils/gprof/bsd_callg_bl.c118
-rw-r--r--gnu/usr.bin/binutils/gprof/flat_bl.c37
-rw-r--r--gnu/usr.bin/binutils/gprof/fsf_callg_bl.c93
-rw-r--r--gnu/usr.bin/binutils/gprof/gprof.info951
-rw-r--r--gnu/usr.bin/binutils/ld/ld.info66
-rw-r--r--gnu/usr.bin/binutils/ld/ld.info-11239
-rw-r--r--gnu/usr.bin/binutils/ld/ld.info-2924
-rw-r--r--gnu/usr.bin/binutils/ld/ld.info-3343
-rw-r--r--gnu/usr.bin/binutils/ld/ldgram.c2052
-rw-r--r--gnu/usr.bin/binutils/ld/ldgram.h94
-rw-r--r--gnu/usr.bin/binutils/ld/ldlex.c3270
-rw-r--r--gnu/usr.bin/binutils/ld/mpw-eppcmacos.c841
-rw-r--r--gnu/usr.bin/binutils/libiberty/config/mh-hpux1
-rw-r--r--gnu/usr.bin/binutils/libiberty/config/mh-i386win325
-rw-r--r--gnu/usr.bin/binutils/libiberty/win32.c64
-rw-r--r--gnu/usr.bin/binutils/makeall.bat16
-rw-r--r--gnu/usr.bin/binutils/opcodes/stamp-h1
54 files changed, 1 insertions, 35978 deletions
diff --git a/gnu/usr.bin/binutils/bfd/hosts/i386nbsd.h b/gnu/usr.bin/binutils/bfd/hosts/i386nbsd.h
deleted file mode 100644
index 1fd3bedf2db..00000000000
--- a/gnu/usr.bin/binutils/bfd/hosts/i386nbsd.h
+++ /dev/null
@@ -1,14 +0,0 @@
-/* Intel 386 running NetBSD */
-
-#ifndef hosts_i386bsd_H
-#define hosts_i386bsd_H
-
-#include "hosts/nbsd.h"
-
-#define HOST_MACHINE_ARCH bfd_arch_i386
-
-#define TRAD_UNIX_CORE_FILE_FAILING_SIGNAL(core_bfd) \
- ((core_bfd)->tdata.trad_core_data->u.u_sig)
-#define u_comm u_kproc.kp_proc.p_comm
-#endif
-
diff --git a/gnu/usr.bin/binutils/bfd/hosts/m68knbsd.h b/gnu/usr.bin/binutils/bfd/hosts/m68knbsd.h
deleted file mode 100644
index 8dccf674f39..00000000000
--- a/gnu/usr.bin/binutils/bfd/hosts/m68knbsd.h
+++ /dev/null
@@ -1,13 +0,0 @@
-/* m68k hosts running NetBSD */
-
-#ifndef hosts_m68knbsd_h
-#define hosts_m68knbsd_h
-
-#include "hosts/nbsd.h"
-
-#define HOST_MACHINE_ARCH bfd_arch_m68k
-
-#define TRAD_UNIX_CORE_FILE_FAILING_SIGNAL(core_bfd) \
- ((core_bfd)->tdata.trad_core_data->u.u_sig)
-#define u_comm u_kproc.kp_proc.p_comm
-#endif
diff --git a/gnu/usr.bin/binutils/bfd/hosts/mipsnbsd.h b/gnu/usr.bin/binutils/bfd/hosts/mipsnbsd.h
deleted file mode 100644
index 32e895a9908..00000000000
--- a/gnu/usr.bin/binutils/bfd/hosts/mipsnbsd.h
+++ /dev/null
@@ -1,13 +0,0 @@
-/* mips running NetBSD */
-
-#ifndef hosts_mips
-#define hosts_mips
-
-#include "hosts/nbsd.h"
-
-#define HOST_MACHINE_ARCH bfd_arch_mips
-
-#define TRAD_UNIX_CORE_FILE_FAILING_SIGNAL(core_bfd) \
- ((core_bfd)->tdata.trad_core_data->u.u_sig)
-#define u_comm u_kproc.kp_proc.p_comm
-#endif
diff --git a/gnu/usr.bin/binutils/bfd/hosts/nbsd.h b/gnu/usr.bin/binutils/bfd/hosts/nbsd.h
deleted file mode 100644
index d773ee64960..00000000000
--- a/gnu/usr.bin/binutils/bfd/hosts/nbsd.h
+++ /dev/null
@@ -1,14 +0,0 @@
-/* Architecture independant NetBSD host support */
-
-#include <machine/endian.h>
-#include <machine/vmparam.h>
-#include <machine/param.h>
-#include <machine/reg.h>
-
-#define HOST_PAGE_SIZE NBPG
-#define HOST_TEXT_START_ADDR USRTEXT
-#define HOST_STACK_END_ADDR USRSTACK
-
-#if BYTE_ORDER == BIG_ENDIAN
-#define HOST_BIG_ENDIAN_P
-#endif
diff --git a/gnu/usr.bin/binutils/bfd/hosts/ns32knbsd.h b/gnu/usr.bin/binutils/bfd/hosts/ns32knbsd.h
deleted file mode 100644
index d072d6d1c0d..00000000000
--- a/gnu/usr.bin/binutils/bfd/hosts/ns32knbsd.h
+++ /dev/null
@@ -1,13 +0,0 @@
-/* ns32k running NetBSD */
-
-#ifndef hosts_ns32knbsd_h
-#define hosts_ns32knbsd_h
-
-#include "hosts/nbsd.h"
-
-#define HOST_MACHINE_ARCH bfd_arch_ns32k
-
-#define TRAD_UNIX_CORE_FILE_FAILING_SIGNAL(core_bfd) \
- ((core_bfd)->tdata.trad_core_data->u.u_sig)
-#define u_comm u_kproc.kp_proc.p_comm
-#endif
diff --git a/gnu/usr.bin/binutils/bfd/hosts/sparcnbsd.h b/gnu/usr.bin/binutils/bfd/hosts/sparcnbsd.h
deleted file mode 100644
index c0a4a8d4639..00000000000
--- a/gnu/usr.bin/binutils/bfd/hosts/sparcnbsd.h
+++ /dev/null
@@ -1,18 +0,0 @@
-/* Sparc running NetBSD */
-
-#ifndef hosts_sparcnbsd_h
-#define hosts_sparcnbsd_h
-
-#include "hosts/nbsd.h"
-
-#define HOST_MACHINE_ARCH bfd_arch_sparc
-
-#define TRAD_UNIX_CORE_FILE_FAILING_SIGNAL(core_bfd) \
- ((core_bfd)->tdata.trad_core_data->u.u_sig)
-#define u_comm u_kproc.kp_proc.p_comm
-#define TRAD_CORE_REGPOS(core_bfd) \
- ((bfd_vma)(core_bfd)->tdata.trad_core_data->u.u_kproc.kp_proc.p_md.md_tf)
-
-#define CORE_FPU_OFFSET (sizeof(struct trapframe))
-
-#endif
diff --git a/gnu/usr.bin/binutils/binutils/alloca.c b/gnu/usr.bin/binutils/binutils/alloca.c
deleted file mode 100644
index 9639def3142..00000000000
--- a/gnu/usr.bin/binutils/binutils/alloca.c
+++ /dev/null
@@ -1,191 +0,0 @@
-/*
- alloca -- (mostly) portable public-domain implementation -- D A Gwyn
-
- last edit: 86/05/30 rms
- include config.h, since on VMS it renames some symbols.
- Use xmalloc instead of malloc.
-
- This implementation of the PWB library alloca() function,
- which is used to allocate space off the run-time stack so
- that it is automatically reclaimed upon procedure exit,
- was inspired by discussions with J. Q. Johnson of Cornell.
-
- It should work under any C implementation that uses an
- actual procedure stack (as opposed to a linked list of
- frames). There are some preprocessor constants that can
- be defined when compiling for your specific system, for
- improved efficiency; however, the defaults should be okay.
-
- The general concept of this implementation is to keep
- track of all alloca()-allocated blocks, and reclaim any
- that are found to be deeper in the stack than the current
- invocation. This heuristic does not reclaim storage as
- soon as it becomes invalid, but it will do so eventually.
-
- As a special case, alloca(0) reclaims storage without
- allocating any. It is a good idea to use alloca(0) in
- your main control loop, etc. to force garbage collection.
-*/
-#ifndef lint
-static char SCCSid[] = "@(#)alloca.c 1.1"; /* for the "what" utility */
-#endif
-
-#ifdef emacs
-#include "config.h"
-#ifdef static
-/* actually, only want this if static is defined as ""
- -- this is for usg, in which emacs must undefine static
- in order to make unexec workable
- */
-#ifndef STACK_DIRECTION
-you
-lose
--- must know STACK_DIRECTION at compile-time
-#endif /* STACK_DIRECTION undefined */
-#endif /* static */
-#endif /* emacs */
-
-#ifdef X3J11
-typedef void *pointer; /* generic pointer type */
-#else
-typedef char *pointer; /* generic pointer type */
-#endif
-
-#define NULL 0 /* null pointer constant */
-
-extern void free();
-extern pointer xmalloc();
-
-/*
- Define STACK_DIRECTION if you know the direction of stack
- growth for your system; otherwise it will be automatically
- deduced at run-time.
-
- STACK_DIRECTION > 0 => grows toward higher addresses
- STACK_DIRECTION < 0 => grows toward lower addresses
- STACK_DIRECTION = 0 => direction of growth unknown
-*/
-
-#ifndef STACK_DIRECTION
-#define STACK_DIRECTION 0 /* direction unknown */
-#endif
-
-#if STACK_DIRECTION != 0
-
-#define STACK_DIR STACK_DIRECTION /* known at compile-time */
-
-#else /* STACK_DIRECTION == 0; need run-time code */
-
-static int stack_dir; /* 1 or -1 once known */
-#define STACK_DIR stack_dir
-
-static void
-find_stack_direction (/* void */)
-{
- static char *addr = NULL; /* address of first
- `dummy', once known */
- auto char dummy; /* to get stack address */
-
- if (addr == NULL)
- { /* initial entry */
- addr = &dummy;
-
- find_stack_direction (); /* recurse once */
- }
- else /* second entry */
- if (&dummy > addr)
- stack_dir = 1; /* stack grew upward */
- else
- stack_dir = -1; /* stack grew downward */
-}
-
-#endif /* STACK_DIRECTION == 0 */
-
-/*
- An "alloca header" is used to:
- (a) chain together all alloca()ed blocks;
- (b) keep track of stack depth.
-
- It is very important that sizeof(header) agree with malloc()
- alignment chunk size. The following default should work okay.
-*/
-
-#ifndef ALIGN_SIZE
-#define ALIGN_SIZE sizeof(double)
-#endif
-
-typedef union hdr
-{
- char align[ALIGN_SIZE]; /* to force sizeof(header) */
- struct
- {
- union hdr *next; /* for chaining headers */
- char *deep; /* for stack depth measure */
- } h;
-} header;
-
-/*
- alloca( size ) returns a pointer to at least `size' bytes of
- storage which will be automatically reclaimed upon exit from
- the procedure that called alloca(). Originally, this space
- was supposed to be taken from the current stack frame of the
- caller, but that method cannot be made to work for some
- implementations of C, for example under Gould's UTX/32.
-*/
-
-static header *last_alloca_header = NULL; /* -> last alloca header */
-
-pointer
-alloca (size) /* returns pointer to storage */
- unsigned size; /* # bytes to allocate */
-{
- auto char probe; /* probes stack depth: */
- register char *depth = &probe;
-
-#if STACK_DIRECTION == 0
- if (STACK_DIR == 0) /* unknown growth direction */
- find_stack_direction ();
-#endif
-
- /* Reclaim garbage, defined as all alloca()ed storage that
- was allocated from deeper in the stack than currently. */
-
- {
- register header *hp; /* traverses linked list */
-
- for (hp = last_alloca_header; hp != NULL;)
- if (STACK_DIR > 0 && hp->h.deep > depth
- || STACK_DIR < 0 && hp->h.deep < depth)
- {
- register header *np = hp->h.next;
-
- free ((pointer) hp); /* collect garbage */
-
- hp = np; /* -> next header */
- }
- else
- break; /* rest are not deeper */
-
- last_alloca_header = hp; /* -> last valid storage */
- }
-
- if (size == 0)
- return NULL; /* no allocation required */
-
- /* Allocate combined header + user data storage. */
-
- {
- register pointer new = xmalloc (sizeof (header) + size);
- /* address of header */
-
- ((header *)new)->h.next = last_alloca_header;
- ((header *)new)->h.deep = depth;
-
- last_alloca_header = (header *)new;
-
- /* User storage begins just after header. */
-
- return (pointer)((char *)new + sizeof(header));
- }
-}
-
diff --git a/gnu/usr.bin/binutils/binutils/arlex.c b/gnu/usr.bin/binutils/binutils/arlex.c
deleted file mode 100644
index d3f5d0ab483..00000000000
--- a/gnu/usr.bin/binutils/binutils/arlex.c
+++ /dev/null
@@ -1,1802 +0,0 @@
-/* A lexical scanner generated by flex */
-
-/* Scanner skeleton version:
- * $Header: /home/cvs/src/gnu/usr.bin/binutils/binutils/Attic/arlex.c,v 1.1.1.1 1996/01/08 11:03:56 niklas Exp $
- */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 5
-
-#include <stdio.h>
-
-
-/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
-#ifdef c_plusplus
-#ifndef __cplusplus
-#define __cplusplus
-#endif
-#endif
-
-
-#ifdef __cplusplus
-
-#include <stdlib.h>
-#include <unistd.h>
-
-/* Use prototypes in function declarations. */
-#define YY_USE_PROTOS
-
-/* The "const" storage-class-modifier is valid. */
-#define YY_USE_CONST
-
-#else /* ! __cplusplus */
-
-#if __STDC__
-
-#define YY_USE_PROTOS
-#define YY_USE_CONST
-
-#endif /* __STDC__ */
-#endif /* ! __cplusplus */
-
-#ifdef __TURBOC__
- #pragma warn -rch
- #pragma warn -use
-#include <io.h>
-#include <stdlib.h>
-#define YY_USE_CONST
-#define YY_USE_PROTOS
-#endif
-
-#ifdef YY_USE_CONST
-#define yyconst const
-#else
-#define yyconst
-#endif
-
-
-#ifdef YY_USE_PROTOS
-#define YY_PROTO(proto) proto
-#else
-#define YY_PROTO(proto) ()
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an unsigned
- * integer for use as an array index. If the signed char is negative,
- * we want to instead treat it as an 8-bit unsigned char, hence the
- * double cast.
- */
-#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
-
-/* Enter a start condition. This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yy_start = 1 + 2 *
-
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state. The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yy_start - 1) / 2)
-#define YYSTATE YY_START
-
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin )
-
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#define YY_BUF_SIZE 16384
-
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-
-extern int yyleng;
-extern FILE *yyin, *yyout;
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
-/* The funky do-while in the following #define is used to turn the definition
- * int a single C statement (which needs a semi-colon terminator). This
- * avoids problems with code like:
- *
- * if ( condition_holds )
- * yyless( 5 );
- * else
- * do_something_else();
- *
- * Prior to using the do-while the compiler would get upset at the
- * "else" because it interpreted the "if" statement as being all
- * done when it reached the ';' after the yyless() call.
- */
-
-/* Return all but the first 'n' matched characters back to the input stream. */
-
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- *yy_cp = yy_hold_char; \
- yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- } \
- while ( 0 )
-
-#define unput(c) yyunput( c, yytext_ptr )
-
-/* The following is because we cannot portably get our hands on size_t
- * (without autoconf's help, which isn't available because we want
- * flex-generated scanners to compile on their own).
- */
-typedef unsigned int yy_size_t;
-
-
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- yy_size_t yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
- /* When an EOF's been seen but there's still some text to process
- * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- * shouldn't try reading from the input source any more. We might
- * still have a bunch of tokens to match, though, because of
- * possible backing-up.
- *
- * When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
- * just pointing yyin at a new input file.
- */
-#define YY_BUFFER_EOF_PENDING 2
- };
-
-static YY_BUFFER_STATE yy_current_buffer = 0;
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- */
-#define YY_CURRENT_BUFFER yy_current_buffer
-
-
-/* yy_hold_char holds the character lost when yytext is formed. */
-static char yy_hold_char;
-
-static int yy_n_chars; /* number of characters read into yy_ch_buf */
-
-
-int yyleng;
-
-/* Points to current character in buffer. */
-static char *yy_c_buf_p = (char *) 0;
-static int yy_init = 1; /* whether we need to initialize */
-static int yy_start = 0; /* start state number */
-
-/* Flag which is used to allow yywrap()'s to do buffer switches
- * instead of setting up a fresh yyin. A bit of a hack ...
- */
-static int yy_did_buffer_switch_on_eof;
-
-void yyrestart YY_PROTO(( FILE *input_file ));
-
-void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
-void yy_load_buffer_state YY_PROTO(( void ));
-YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
-void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
-void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-#define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
-
-YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
-YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *str ));
-YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
-
-static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
-static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
-static void yy_flex_free YY_PROTO(( void * ));
-
-#define yy_new_buffer yy_create_buffer
-
-#define yy_set_interactive(is_interactive) \
- { \
- if ( ! yy_current_buffer ) \
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
- yy_current_buffer->yy_is_interactive = is_interactive; \
- }
-
-#define yy_set_bol(at_bol) \
- { \
- if ( ! yy_current_buffer ) \
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
- yy_current_buffer->yy_at_bol = at_bol; \
- }
-
-#define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
-
-typedef unsigned char YY_CHAR;
-FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
-typedef int yy_state_type;
-extern char *yytext;
-#define yytext_ptr yytext
-
-static yy_state_type yy_get_previous_state YY_PROTO(( void ));
-static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
-static int yy_get_next_buffer YY_PROTO(( void ));
-static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
- yytext_ptr = yy_bp; \
- yyleng = (int) (yy_cp - yy_bp); \
- yy_hold_char = *yy_cp; \
- *yy_cp = '\0'; \
- yy_c_buf_p = yy_cp;
-
-#define YY_NUM_RULES 40
-#define YY_END_OF_BUFFER 41
-static yyconst short int yy_accept[177] =
- { 0,
- 0, 0, 41, 40, 39, 38, 35, 32, 33, 36,
- 40, 34, 37, 35, 35, 35, 35, 35, 35, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
- 35, 35, 35, 35, 35, 35, 36, 31, 37, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
- 35, 35, 7, 35, 35, 35, 35, 35, 35, 35,
- 35, 35, 35, 35, 35, 35, 22, 35, 35, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
-
- 35, 35, 35, 10, 11, 12, 35, 15, 35, 35,
- 35, 35, 35, 35, 35, 35, 35, 25, 26, 27,
- 35, 30, 35, 35, 35, 3, 35, 35, 35, 35,
- 35, 35, 35, 35, 35, 18, 35, 35, 35, 35,
- 35, 35, 35, 1, 2, 4, 5, 35, 35, 35,
- 35, 35, 16, 17, 19, 20, 35, 35, 35, 35,
- 35, 35, 8, 9, 13, 14, 35, 23, 24, 28,
- 29, 35, 35, 6, 21, 0
- } ;
-
-static yyconst int yy_ec[256] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 2,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 3, 1, 1, 1, 4, 1, 1, 1, 5,
- 6, 7, 8, 9, 4, 4, 4, 4, 4, 4,
- 4, 4, 4, 4, 4, 4, 4, 4, 10, 1,
- 1, 1, 1, 1, 11, 12, 13, 14, 15, 16,
- 4, 17, 18, 4, 4, 19, 20, 21, 22, 23,
- 4, 24, 25, 26, 27, 28, 4, 29, 30, 4,
- 1, 1, 1, 1, 4, 1, 31, 32, 33, 34,
-
- 35, 36, 4, 37, 38, 4, 4, 39, 40, 41,
- 42, 43, 4, 44, 45, 46, 47, 48, 4, 49,
- 50, 4, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1
- } ;
-
-static yyconst int yy_meta[51] =
- { 0,
- 1, 2, 1, 3, 1, 1, 1, 1, 1, 1,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3
- } ;
-
-static yyconst short int yy_base[180] =
- { 0,
- 0, 0, 193, 194, 194, 194, 0, 194, 194, 0,
- 190, 194, 0, 177, 32, 37, 32, 163, 174, 170,
- 164, 171, 174, 169, 149, 15, 22, 17, 135, 146,
- 142, 136, 143, 146, 141, 0, 0, 194, 0, 161,
- 159, 158, 153, 147, 156, 143, 149, 148, 141, 150,
- 141, 135, 138, 127, 125, 124, 119, 113, 122, 109,
- 115, 114, 107, 116, 107, 101, 104, 43, 136, 135,
- 130, 129, 0, 119, 123, 118, 114, 118, 119, 122,
- 124, 25, 104, 103, 98, 97, 0, 87, 91, 86,
- 82, 86, 87, 90, 92, 105, 100, 97, 94, 93,
-
- 105, 106, 102, 0, 0, 0, 104, 0, 92, 75,
- 70, 67, 64, 63, 75, 76, 72, 0, 0, 0,
- 74, 0, 62, 91, 88, 0, 86, 85, 73, 85,
- 79, 83, 70, 62, 59, 0, 57, 56, 44, 56,
- 50, 54, 41, 0, 0, 0, 0, 63, 58, 59,
- 67, 66, 0, 0, 0, 0, 38, 33, 34, 42,
- 41, 51, 0, 0, 0, 0, 30, 0, 0, 0,
- 0, 43, 21, 0, 0, 194, 65, 66, 69
- } ;
-
-static yyconst short int yy_def[180] =
- { 0,
- 176, 1, 176, 176, 176, 176, 177, 176, 176, 178,
- 176, 176, 179, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 178, 176, 179, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
-
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,
- 177, 177, 177, 177, 177, 0, 176, 176, 176
- } ;
-
-static yyconst short int yy_nxt[245] =
- { 0,
- 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,
- 14, 7, 15, 16, 17, 18, 19, 7, 20, 7,
- 7, 21, 7, 22, 23, 7, 7, 24, 7, 7,
- 25, 7, 26, 27, 28, 29, 30, 7, 31, 7,
- 7, 32, 7, 33, 34, 7, 7, 35, 7, 7,
- 41, 43, 45, 55, 44, 42, 57, 59, 56, 58,
- 46, 96, 97, 110, 111, 60, 37, 36, 37, 39,
- 175, 39, 174, 173, 172, 171, 170, 169, 168, 167,
- 166, 165, 164, 163, 162, 161, 160, 159, 158, 157,
- 156, 155, 154, 153, 152, 151, 150, 149, 148, 147,
-
- 146, 145, 144, 143, 142, 141, 140, 139, 138, 137,
- 136, 135, 134, 133, 132, 131, 130, 129, 128, 127,
- 126, 125, 124, 123, 122, 121, 120, 119, 118, 117,
- 116, 115, 114, 113, 112, 109, 108, 107, 106, 105,
- 104, 103, 102, 101, 100, 99, 98, 95, 94, 93,
- 92, 91, 90, 89, 88, 87, 86, 85, 84, 83,
- 82, 81, 80, 79, 78, 77, 76, 75, 74, 73,
- 72, 71, 70, 69, 68, 67, 66, 65, 64, 63,
- 62, 61, 54, 53, 52, 51, 50, 49, 48, 47,
- 40, 38, 176, 3, 176, 176, 176, 176, 176, 176,
-
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176
- } ;
-
-static yyconst short int yy_chk[245] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 15, 16, 17, 26, 16, 15, 27, 28, 26, 27,
- 17, 68, 68, 82, 82, 28, 178, 177, 178, 179,
- 173, 179, 172, 167, 162, 161, 160, 159, 158, 157,
- 152, 151, 150, 149, 148, 143, 142, 141, 140, 139,
- 138, 137, 135, 134, 133, 132, 131, 130, 129, 128,
-
- 127, 125, 124, 123, 121, 117, 116, 115, 114, 113,
- 112, 111, 110, 109, 107, 103, 102, 101, 100, 99,
- 98, 97, 96, 95, 94, 93, 92, 91, 90, 89,
- 88, 86, 85, 84, 83, 81, 80, 79, 78, 77,
- 76, 75, 74, 72, 71, 70, 69, 67, 66, 65,
- 64, 63, 62, 61, 60, 59, 58, 57, 56, 55,
- 54, 53, 52, 51, 50, 49, 48, 47, 46, 45,
- 44, 43, 42, 41, 40, 35, 34, 33, 32, 31,
- 30, 29, 25, 24, 23, 22, 21, 20, 19, 18,
- 14, 11, 3, 176, 176, 176, 176, 176, 176, 176,
-
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
- 176, 176, 176, 176
- } ;
-
-static yy_state_type yy_last_accepting_state;
-static char *yy_last_accepting_cpos;
-
-/* The intent behind this definition is that it'll catch
- * any uses of REJECT which flex missed.
- */
-#define REJECT reject_used_but_not_detected
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-char *yytext;
-#line 1 "./arlex.l"
-#define INITIAL 0
-#line 2 "./arlex.l"
-/* arlex.l - Strange script language lexer */
-
-/* Copyright (C) 1992 Free Software Foundation, Inc.
-
-This file is part of GNU Binutils.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-
-/* Contributed by Steve Chamberlain
- sac@cygnus.com
-
-*/
-#define DONTDECLARE_MALLOC
-#include <ansidecl.h>
-#include "arparse.h"
-extern char *strdup();
-int linenumber;
-#line 502 "lex.yy.c"
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap YY_PROTO(( void ));
-#else
-extern int yywrap YY_PROTO(( void ));
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-static void yyunput YY_PROTO(( int c, char *buf_ptr ));
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput YY_PROTO(( void ));
-#else
-static int input YY_PROTO(( void ));
-#endif
-#endif
-
-#if YY_STACK_USED
-static int yy_start_stack_ptr = 0;
-static int yy_start_stack_depth = 0;
-static int *yy_start_stack = 0;
-#ifndef YY_NO_PUSH_STATE
-static void yy_push_state YY_PROTO(( int new_state ));
-#endif
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state YY_PROTO(( void ));
-#endif
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state YY_PROTO(( void ));
-#endif
-
-#else
-#define YY_NO_PUSH_STATE 1
-#define YY_NO_POP_STATE 1
-#define YY_NO_TOP_STATE 1
-#endif
-
-#ifdef YY_MALLOC_DECL
-YY_MALLOC_DECL
-#else
-#if __STDC__
-#ifndef __cplusplus
-#include <stdlib.h>
-#endif
-#else
-/* Just try to get by without declaring the routines. This will fail
- * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
- * or sizeof(void*) != sizeof(int).
- */
-#endif
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#define YY_READ_BUF_SIZE 8192
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
-#endif
-
-/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
- if ( yy_current_buffer->yy_is_interactive ) \
- { \
- int c = '*', n; \
- for ( n = 0; n < max_size && \
- (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
- buf[n] = (char) c; \
- if ( c == '\n' ) \
- buf[n++] = (char) c; \
- if ( c == EOF && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- result = n; \
- } \
- else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
- && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" );
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL int yylex YY_PROTO(( void ))
-#endif
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK break;
-#endif
-
-#define YY_RULE_SETUP \
- YY_USER_ACTION
-
-YY_DECL
- {
- register yy_state_type yy_current_state;
- register char *yy_cp, *yy_bp;
- register int yy_act;
-
-#line 33 "./arlex.l"
-
-
-#line 652 "lex.yy.c"
-
- if ( yy_init )
- {
- yy_init = 0;
-
-#ifdef YY_USER_INIT
- YY_USER_INIT;
-#endif
-
- if ( ! yy_start )
- yy_start = 1; /* first start state */
-
- if ( ! yyin )
- yyin = stdin;
-
- if ( ! yyout )
- yyout = stdout;
-
- if ( ! yy_current_buffer )
- yy_current_buffer =
- yy_create_buffer( yyin, YY_BUF_SIZE );
-
- yy_load_buffer_state();
- }
-
- while ( 1 ) /* loops until end-of-file is reached */
- {
- yy_cp = yy_c_buf_p;
-
- /* Support of yytext. */
- *yy_cp = yy_hold_char;
-
- /* yy_bp points to the position in yy_ch_buf of the start of
- * the current run.
- */
- yy_bp = yy_cp;
-
- yy_current_state = yy_start;
-yy_match:
- do
- {
- register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 177 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- ++yy_cp;
- }
- while ( yy_base[yy_current_state] != 194 );
-
-yy_find_action:
- yy_act = yy_accept[yy_current_state];
- if ( yy_act == 0 )
- { /* have to back up */
- yy_cp = yy_last_accepting_cpos;
- yy_current_state = yy_last_accepting_state;
- yy_act = yy_accept[yy_current_state];
- }
-
- YY_DO_BEFORE_ACTION;
-
-
-do_action: /* This label is used only to access EOF actions. */
-
-
- switch ( yy_act )
- { /* beginning of action switch */
- case 0: /* must back up */
- /* undo the effects of YY_DO_BEFORE_ACTION */
- *yy_cp = yy_hold_char;
- yy_cp = yy_last_accepting_cpos;
- yy_current_state = yy_last_accepting_state;
- goto yy_find_action;
-
-case 1:
-YY_RULE_SETUP
-#line 35 "./arlex.l"
-{ return ADDLIB; }
- YY_BREAK
-case 2:
-YY_RULE_SETUP
-#line 36 "./arlex.l"
-{ return ADDMOD; }
- YY_BREAK
-case 3:
-YY_RULE_SETUP
-#line 37 "./arlex.l"
-{ return CLEAR; }
- YY_BREAK
-case 4:
-YY_RULE_SETUP
-#line 38 "./arlex.l"
-{ return CREATE; }
- YY_BREAK
-case 5:
-YY_RULE_SETUP
-#line 39 "./arlex.l"
-{ return DELETE; }
- YY_BREAK
-case 6:
-YY_RULE_SETUP
-#line 40 "./arlex.l"
-{ return DIRECTORY; }
- YY_BREAK
-case 7:
-YY_RULE_SETUP
-#line 41 "./arlex.l"
-{ return END; }
- YY_BREAK
-case 8:
-YY_RULE_SETUP
-#line 42 "./arlex.l"
-{ return EXTRACT; }
- YY_BREAK
-case 9:
-YY_RULE_SETUP
-#line 43 "./arlex.l"
-{ return FULLDIR; }
- YY_BREAK
-case 10:
-YY_RULE_SETUP
-#line 44 "./arlex.l"
-{ return HELP; }
- YY_BREAK
-case 11:
-YY_RULE_SETUP
-#line 45 "./arlex.l"
-{ return LIST; }
- YY_BREAK
-case 12:
-YY_RULE_SETUP
-#line 46 "./arlex.l"
-{ return OPEN; }
- YY_BREAK
-case 13:
-YY_RULE_SETUP
-#line 47 "./arlex.l"
-{ return REPLACE; }
- YY_BREAK
-case 14:
-YY_RULE_SETUP
-#line 48 "./arlex.l"
-{ return VERBOSE; }
- YY_BREAK
-case 15:
-YY_RULE_SETUP
-#line 49 "./arlex.l"
-{ return SAVE; }
- YY_BREAK
-case 16:
-YY_RULE_SETUP
-#line 50 "./arlex.l"
-{ return ADDLIB; }
- YY_BREAK
-case 17:
-YY_RULE_SETUP
-#line 51 "./arlex.l"
-{ return ADDMOD; }
- YY_BREAK
-case 18:
-YY_RULE_SETUP
-#line 52 "./arlex.l"
-{ return CLEAR; }
- YY_BREAK
-case 19:
-YY_RULE_SETUP
-#line 53 "./arlex.l"
-{ return CREATE; }
- YY_BREAK
-case 20:
-YY_RULE_SETUP
-#line 54 "./arlex.l"
-{ return DELETE; }
- YY_BREAK
-case 21:
-YY_RULE_SETUP
-#line 55 "./arlex.l"
-{ return DIRECTORY; }
- YY_BREAK
-case 22:
-YY_RULE_SETUP
-#line 56 "./arlex.l"
-{ return END; }
- YY_BREAK
-case 23:
-YY_RULE_SETUP
-#line 57 "./arlex.l"
-{ return EXTRACT; }
- YY_BREAK
-case 24:
-YY_RULE_SETUP
-#line 58 "./arlex.l"
-{ return FULLDIR; }
- YY_BREAK
-case 25:
-YY_RULE_SETUP
-#line 59 "./arlex.l"
-{ return HELP; }
- YY_BREAK
-case 26:
-YY_RULE_SETUP
-#line 60 "./arlex.l"
-{ return LIST; }
- YY_BREAK
-case 27:
-YY_RULE_SETUP
-#line 61 "./arlex.l"
-{ return OPEN; }
- YY_BREAK
-case 28:
-YY_RULE_SETUP
-#line 62 "./arlex.l"
-{ return REPLACE; }
- YY_BREAK
-case 29:
-YY_RULE_SETUP
-#line 63 "./arlex.l"
-{ return VERBOSE; }
- YY_BREAK
-case 30:
-YY_RULE_SETUP
-#line 64 "./arlex.l"
-{ return SAVE; }
- YY_BREAK
-case 31:
-YY_RULE_SETUP
-#line 65 "./arlex.l"
-{ linenumber ++; }
- YY_BREAK
-case 32:
-YY_RULE_SETUP
-#line 66 "./arlex.l"
-{ return '('; }
- YY_BREAK
-case 33:
-YY_RULE_SETUP
-#line 67 "./arlex.l"
-{ return ')'; }
- YY_BREAK
-case 34:
-YY_RULE_SETUP
-#line 68 "./arlex.l"
-{ return ','; }
- YY_BREAK
-case 35:
-YY_RULE_SETUP
-#line 69 "./arlex.l"
-{
- yylval.name = strdup(yytext);
- return FILENAME;
- }
- YY_BREAK
-case 36:
-YY_RULE_SETUP
-#line 73 "./arlex.l"
-{ }
- YY_BREAK
-case 37:
-YY_RULE_SETUP
-#line 74 "./arlex.l"
-{ }
- YY_BREAK
-case 38:
-YY_RULE_SETUP
-#line 75 "./arlex.l"
-{ }
- YY_BREAK
-case 39:
-YY_RULE_SETUP
-#line 76 "./arlex.l"
-{ linenumber ++; return NEWLINE; }
- YY_BREAK
-case 40:
-YY_RULE_SETUP
-#line 78 "./arlex.l"
-ECHO;
- YY_BREAK
-#line 938 "lex.yy.c"
-case YY_STATE_EOF(INITIAL):
- yyterminate();
-
- case YY_END_OF_BUFFER:
- {
- /* Amount of text matched not including the EOB char. */
- int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
-
- /* Undo the effects of YY_DO_BEFORE_ACTION. */
- *yy_cp = yy_hold_char;
-
- if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
- {
- /* We're scanning a new file or input source. It's
- * possible that this happened because the user
- * just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
- * consistency between yy_current_buffer and our
- * globals. Here is the right place to do so, because
- * this is the first action (other than possibly a
- * back-up) that will match for the new input source.
- */
- yy_n_chars = yy_current_buffer->yy_n_chars;
- yy_current_buffer->yy_input_file = yyin;
- yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
- }
-
- /* Note that here we test for yy_c_buf_p "<=" to the position
- * of the first EOB in the buffer, since yy_c_buf_p will
- * already have been incremented past the NUL character
- * (since all states make transitions on EOB to the
- * end-of-buffer state). Contrast this with the test
- * in input().
- */
- if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- { /* This was really a NUL. */
- yy_state_type yy_next_state;
-
- yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state();
-
- /* Okay, we're now positioned to make the NUL
- * transition. We couldn't have
- * yy_get_previous_state() go ahead and do it
- * for us because it doesn't know how to deal
- * with the possibility of jamming (and we don't
- * want to build jamming into it because then it
- * will run more slowly).
- */
-
- yy_next_state = yy_try_NUL_trans( yy_current_state );
-
- yy_bp = yytext_ptr + YY_MORE_ADJ;
-
- if ( yy_next_state )
- {
- /* Consume the NUL. */
- yy_cp = ++yy_c_buf_p;
- yy_current_state = yy_next_state;
- goto yy_match;
- }
-
- else
- {
- yy_cp = yy_c_buf_p;
- goto yy_find_action;
- }
- }
-
- else switch ( yy_get_next_buffer() )
- {
- case EOB_ACT_END_OF_FILE:
- {
- yy_did_buffer_switch_on_eof = 0;
-
- if ( yywrap() )
- {
- /* Note: because we've taken care in
- * yy_get_next_buffer() to have set up
- * yytext, we can now set up
- * yy_c_buf_p so that if some total
- * hoser (like flex itself) wants to
- * call the scanner after we return the
- * YY_NULL, it'll still work - another
- * YY_NULL will get returned.
- */
- yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
-
- yy_act = YY_STATE_EOF(YY_START);
- goto do_action;
- }
-
- else
- {
- if ( ! yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
- }
- break;
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yy_c_buf_p =
- yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state();
-
- yy_cp = yy_c_buf_p;
- yy_bp = yytext_ptr + YY_MORE_ADJ;
- goto yy_match;
-
- case EOB_ACT_LAST_MATCH:
- yy_c_buf_p =
- &yy_current_buffer->yy_ch_buf[yy_n_chars];
-
- yy_current_state = yy_get_previous_state();
-
- yy_cp = yy_c_buf_p;
- yy_bp = yytext_ptr + YY_MORE_ADJ;
- goto yy_find_action;
- }
- break;
- }
-
- default:
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--no action found" );
- } /* end of action switch */
- } /* end of scanning one token */
- } /* end of yylex */
-
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- * EOB_ACT_LAST_MATCH -
- * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- * EOB_ACT_END_OF_FILE - end of file
- */
-
-static int yy_get_next_buffer()
- {
- register char *dest = yy_current_buffer->yy_ch_buf;
- register char *source = yytext_ptr;
- register int number_to_move, i;
- int ret_val;
-
- if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--end of buffer missed" );
-
- if ( yy_current_buffer->yy_fill_buffer == 0 )
- { /* Don't try to fill the buffer, so this is an EOF. */
- if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
- {
- /* We matched a singled characater, the EOB, so
- * treat this as a final EOF.
- */
- return EOB_ACT_END_OF_FILE;
- }
-
- else
- {
- /* We matched some text prior to the EOB, first
- * process it.
- */
- return EOB_ACT_LAST_MATCH;
- }
- }
-
- /* Try to read more data. */
-
- /* First move last chars to start of buffer. */
- number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
-
- for ( i = 0; i < number_to_move; ++i )
- *(dest++) = *(source++);
-
- if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
- /* don't do the read, it's not guaranteed to return an EOF,
- * just force an EOF
- */
- yy_n_chars = 0;
-
- else
- {
- int num_to_read =
- yy_current_buffer->yy_buf_size - number_to_move - 1;
-
- while ( num_to_read <= 0 )
- { /* Not enough room in the buffer - grow it. */
-#ifdef YY_USES_REJECT
- YY_FATAL_ERROR(
-"input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
-#else
-
- /* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = yy_current_buffer;
-
- int yy_c_buf_p_offset =
- (int) (yy_c_buf_p - b->yy_ch_buf);
-
- if ( b->yy_is_our_buffer )
- {
- int new_size = b->yy_buf_size * 2;
-
- if ( new_size <= 0 )
- b->yy_buf_size += b->yy_buf_size / 8;
- else
- b->yy_buf_size *= 2;
-
- b->yy_ch_buf = (char *)
- /* Include room in for 2 EOB chars. */
- yy_flex_realloc( (void *) b->yy_ch_buf,
- b->yy_buf_size + 2 );
- }
- else
- /* Can't grow it, we don't own it. */
- b->yy_ch_buf = 0;
-
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR(
- "fatal error - scanner input buffer overflow" );
-
- yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
- num_to_read = yy_current_buffer->yy_buf_size -
- number_to_move - 1;
-#endif
- }
-
- if ( num_to_read > YY_READ_BUF_SIZE )
- num_to_read = YY_READ_BUF_SIZE;
-
- /* Read in more data. */
- YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
- yy_n_chars, num_to_read );
- }
-
- if ( yy_n_chars == 0 )
- {
- if ( number_to_move == YY_MORE_ADJ )
- {
- ret_val = EOB_ACT_END_OF_FILE;
- yyrestart( yyin );
- }
-
- else
- {
- ret_val = EOB_ACT_LAST_MATCH;
- yy_current_buffer->yy_buffer_status =
- YY_BUFFER_EOF_PENDING;
- }
- }
-
- else
- ret_val = EOB_ACT_CONTINUE_SCAN;
-
- yy_n_chars += number_to_move;
- yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
- yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
-
- return ret_val;
- }
-
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-static yy_state_type yy_get_previous_state()
- {
- register yy_state_type yy_current_state;
- register char *yy_cp;
-
- yy_current_state = yy_start;
-
- for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
- {
- register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 177 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- }
-
- return yy_current_state;
- }
-
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- * next_state = yy_try_NUL_trans( current_state );
- */
-
-#ifdef YY_USE_PROTOS
-static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
-#else
-static yy_state_type yy_try_NUL_trans( yy_current_state )
-yy_state_type yy_current_state;
-#endif
- {
- register int yy_is_jam;
- register char *yy_cp = yy_c_buf_p;
-
- register YY_CHAR yy_c = 1;
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 177 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- yy_is_jam = (yy_current_state == 176);
-
- return yy_is_jam ? 0 : yy_current_state;
- }
-
-
-#ifndef YY_NO_UNPUT
-#ifdef YY_USE_PROTOS
-static void yyunput( int c, register char *yy_bp )
-#else
-static void yyunput( c, yy_bp )
-int c;
-register char *yy_bp;
-#endif
- {
- register char *yy_cp = yy_c_buf_p;
-
- /* undo effects of setting up yytext */
- *yy_cp = yy_hold_char;
-
- if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- { /* need to shift things up to make room */
- /* +2 for EOB chars. */
- register int number_to_move = yy_n_chars + 2;
- register char *dest = &yy_current_buffer->yy_ch_buf[
- yy_current_buffer->yy_buf_size + 2];
- register char *source =
- &yy_current_buffer->yy_ch_buf[number_to_move];
-
- while ( source > yy_current_buffer->yy_ch_buf )
- *--dest = *--source;
-
- yy_cp += (int) (dest - source);
- yy_bp += (int) (dest - source);
- yy_n_chars = yy_current_buffer->yy_buf_size;
-
- if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- YY_FATAL_ERROR( "flex scanner push-back overflow" );
- }
-
- *--yy_cp = (char) c;
-
-
- yytext_ptr = yy_bp;
- yy_hold_char = *yy_cp;
- yy_c_buf_p = yy_cp;
- }
-#endif /* ifndef YY_NO_UNPUT */
-
-
-#ifdef __cplusplus
-static int yyinput()
-#else
-static int input()
-#endif
- {
- int c;
-
- *yy_c_buf_p = yy_hold_char;
-
- if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- {
- /* yy_c_buf_p now points to the character we want to return.
- * If this occurs *before* the EOB characters, then it's a
- * valid NUL; if not, then we've hit the end of the buffer.
- */
- if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- /* This was really a NUL. */
- *yy_c_buf_p = '\0';
-
- else
- { /* need more input */
- yytext_ptr = yy_c_buf_p;
- ++yy_c_buf_p;
-
- switch ( yy_get_next_buffer() )
- {
- case EOB_ACT_END_OF_FILE:
- {
- if ( yywrap() )
- {
- yy_c_buf_p =
- yytext_ptr + YY_MORE_ADJ;
- return EOF;
- }
-
- if ( ! yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
-#ifdef __cplusplus
- return yyinput();
-#else
- return input();
-#endif
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
- break;
-
- case EOB_ACT_LAST_MATCH:
-#ifdef __cplusplus
- YY_FATAL_ERROR(
- "unexpected last match in yyinput()" );
-#else
- YY_FATAL_ERROR(
- "unexpected last match in input()" );
-#endif
- }
- }
- }
-
- c = *(unsigned char *) yy_c_buf_p; /* cast for 8-bit char's */
- *yy_c_buf_p = '\0'; /* preserve yytext */
- yy_hold_char = *++yy_c_buf_p;
-
-
- return c;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yyrestart( FILE *input_file )
-#else
-void yyrestart( input_file )
-FILE *input_file;
-#endif
- {
- if ( ! yy_current_buffer )
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
-
- yy_init_buffer( yy_current_buffer, input_file );
- yy_load_buffer_state();
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
-#else
-void yy_switch_to_buffer( new_buffer )
-YY_BUFFER_STATE new_buffer;
-#endif
- {
- if ( yy_current_buffer == new_buffer )
- return;
-
- if ( yy_current_buffer )
- {
- /* Flush out information for old buffer. */
- *yy_c_buf_p = yy_hold_char;
- yy_current_buffer->yy_buf_pos = yy_c_buf_p;
- yy_current_buffer->yy_n_chars = yy_n_chars;
- }
-
- yy_current_buffer = new_buffer;
- yy_load_buffer_state();
-
- /* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
- * to go ahead and always set it.
- */
- yy_did_buffer_switch_on_eof = 1;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_load_buffer_state( void )
-#else
-void yy_load_buffer_state()
-#endif
- {
- yy_n_chars = yy_current_buffer->yy_n_chars;
- yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
- yyin = yy_current_buffer->yy_input_file;
- yy_hold_char = *yy_c_buf_p;
- }
-
-
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
-#else
-YY_BUFFER_STATE yy_create_buffer( file, size )
-FILE *file;
-int size;
-#endif
- {
- YY_BUFFER_STATE b;
-
- b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- * we need to put in 2 end-of-buffer characters.
- */
- b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_is_our_buffer = 1;
-
- yy_init_buffer( b, file );
-
- return b;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_delete_buffer( YY_BUFFER_STATE b )
-#else
-void yy_delete_buffer( b )
-YY_BUFFER_STATE b;
-#endif
- {
- if ( ! b )
- return;
-
- if ( b == yy_current_buffer )
- yy_current_buffer = (YY_BUFFER_STATE) 0;
-
- if ( b->yy_is_our_buffer )
- yy_flex_free( (void *) b->yy_ch_buf );
-
- yy_flex_free( (void *) b );
- }
-
-
-#ifndef YY_ALWAYS_INTERACTIVE
-#ifndef YY_NEVER_INTERACTIVE
-extern int isatty YY_PROTO(( int ));
-#endif
-#endif
-
-#ifdef YY_USE_PROTOS
-void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
-#else
-void yy_init_buffer( b, file )
-YY_BUFFER_STATE b;
-FILE *file;
-#endif
-
-
- {
- yy_flush_buffer( b );
-
- b->yy_input_file = file;
- b->yy_fill_buffer = 1;
-
-#if YY_ALWAYS_INTERACTIVE
- b->yy_is_interactive = 1;
-#else
-#if YY_NEVER_INTERACTIVE
- b->yy_is_interactive = 0;
-#else
- b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-#endif
-#endif
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_flush_buffer( YY_BUFFER_STATE b )
-#else
-void yy_flush_buffer( b )
-YY_BUFFER_STATE b;
-#endif
-
- {
- b->yy_n_chars = 0;
-
- /* We always need two end-of-buffer characters. The first causes
- * a transition to the end-of-buffer state. The second causes
- * a jam in that state.
- */
- b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
- b->yy_buf_pos = &b->yy_ch_buf[0];
-
- b->yy_at_bol = 1;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- if ( b == yy_current_buffer )
- yy_load_buffer_state();
- }
-
-
-#ifndef YY_NO_SCAN_BUFFER
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
-#else
-YY_BUFFER_STATE yy_scan_buffer( base, size )
-char *base;
-yy_size_t size;
-#endif
- {
- YY_BUFFER_STATE b;
-
- if ( size < 2 ||
- base[size-2] != YY_END_OF_BUFFER_CHAR ||
- base[size-1] != YY_END_OF_BUFFER_CHAR )
- /* They forgot to leave room for the EOB's. */
- return 0;
-
- b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
- b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
- b->yy_buf_pos = b->yy_ch_buf = base;
- b->yy_is_our_buffer = 0;
- b->yy_input_file = 0;
- b->yy_n_chars = b->yy_buf_size;
- b->yy_is_interactive = 0;
- b->yy_at_bol = 1;
- b->yy_fill_buffer = 0;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- yy_switch_to_buffer( b );
-
- return b;
- }
-#endif
-
-
-#ifndef YY_NO_SCAN_STRING
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_string( yyconst char *str )
-#else
-YY_BUFFER_STATE yy_scan_string( str )
-yyconst char *str;
-#endif
- {
- int len;
- for ( len = 0; str[len]; ++len )
- ;
-
- return yy_scan_bytes( str, len );
- }
-#endif
-
-
-#ifndef YY_NO_SCAN_BYTES
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
-#else
-YY_BUFFER_STATE yy_scan_bytes( bytes, len )
-yyconst char *bytes;
-int len;
-#endif
- {
- YY_BUFFER_STATE b;
- char *buf;
- yy_size_t n;
- int i;
-
- /* Get memory for full buffer, including space for trailing EOB's. */
- n = len + 2;
- buf = (char *) yy_flex_alloc( n );
- if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
- for ( i = 0; i < len; ++i )
- buf[i] = bytes[i];
-
- buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
-
- b = yy_scan_buffer( buf, n );
- if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
- /* It's okay to grow etc. this buffer, and we should throw it
- * away when we're done.
- */
- b->yy_is_our_buffer = 1;
-
- return b;
- }
-#endif
-
-
-#ifndef YY_NO_PUSH_STATE
-#ifdef YY_USE_PROTOS
-static void yy_push_state( int new_state )
-#else
-static void yy_push_state( new_state )
-int new_state;
-#endif
- {
- if ( yy_start_stack_ptr >= yy_start_stack_depth )
- {
- yy_size_t new_size;
-
- yy_start_stack_depth += YY_START_STACK_INCR;
- new_size = yy_start_stack_depth * sizeof( int );
-
- if ( ! yy_start_stack )
- yy_start_stack = (int *) yy_flex_alloc( new_size );
-
- else
- yy_start_stack = (int *) yy_flex_realloc(
- (void *) yy_start_stack, new_size );
-
- if ( ! yy_start_stack )
- YY_FATAL_ERROR(
- "out of memory expanding start-condition stack" );
- }
-
- yy_start_stack[yy_start_stack_ptr++] = YY_START;
-
- BEGIN(new_state);
- }
-#endif
-
-
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state()
- {
- if ( --yy_start_stack_ptr < 0 )
- YY_FATAL_ERROR( "start-condition stack underflow" );
-
- BEGIN(yy_start_stack[yy_start_stack_ptr]);
- }
-#endif
-
-
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state()
- {
- return yy_start_stack[yy_start_stack_ptr - 1];
- }
-#endif
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-#ifdef YY_USE_PROTOS
-static void yy_fatal_error( yyconst char msg[] )
-#else
-static void yy_fatal_error( msg )
-char msg[];
-#endif
- {
- (void) fprintf( stderr, "%s\n", msg );
- exit( YY_EXIT_FAILURE );
- }
-
-
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- yytext[yyleng] = yy_hold_char; \
- yy_c_buf_p = yytext + n - YY_MORE_ADJ; \
- yy_hold_char = *yy_c_buf_p; \
- *yy_c_buf_p = '\0'; \
- yyleng = n; \
- } \
- while ( 0 )
-
-
-/* Internal utility routines. */
-
-#ifndef yytext_ptr
-#ifdef YY_USE_PROTOS
-static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
-#else
-static void yy_flex_strncpy( s1, s2, n )
-char *s1;
-yyconst char *s2;
-int n;
-#endif
- {
- register int i;
- for ( i = 0; i < n; ++i )
- s1[i] = s2[i];
- }
-#endif
-
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_alloc( yy_size_t size )
-#else
-static void *yy_flex_alloc( size )
-yy_size_t size;
-#endif
- {
- return (void *) malloc( size );
- }
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_realloc( void *ptr, yy_size_t size )
-#else
-static void *yy_flex_realloc( ptr, size )
-void *ptr;
-yy_size_t size;
-#endif
- {
- /* The cast to (char *) in the following accommodates both
- * implementations that use char* generic pointers, and those
- * that use void* generic pointers. It works with the latter
- * because both ANSI C and C++ allow castless assignment from
- * any pointer type to void*, and deal with argument conversions
- * as though doing an assignment.
- */
- return (void *) realloc( (char *) ptr, size );
- }
-
-#ifdef YY_USE_PROTOS
-static void yy_flex_free( void *ptr )
-#else
-static void yy_flex_free( ptr )
-void *ptr;
-#endif
- {
- free( ptr );
- }
-
-#if YY_MAIN
-int main()
- {
- yylex();
- return 0;
- }
-#endif
-#line 78 "./arlex.l"
-
-#ifndef yywrap
-/* Needed for lex, though not flex. */
-int yywrap() { return 1; }
-#endif
diff --git a/gnu/usr.bin/binutils/binutils/arparse.c b/gnu/usr.bin/binutils/binutils/arparse.c
deleted file mode 100644
index 13ca9c4c894..00000000000
--- a/gnu/usr.bin/binutils/binutils/arparse.c
+++ /dev/null
@@ -1,1026 +0,0 @@
-
-/* A Bison parser, made from ./arparse.y with Bison version GNU Bison version 1.24
- */
-
-#define YYBISON 1 /* Identify Bison output. */
-
-#define NEWLINE 258
-#define VERBOSE 259
-#define FILENAME 260
-#define ADDLIB 261
-#define LIST 262
-#define ADDMOD 263
-#define CLEAR 264
-#define CREATE 265
-#define DELETE 266
-#define DIRECTORY 267
-#define END 268
-#define EXTRACT 269
-#define FULLDIR 270
-#define HELP 271
-#define QUIT 272
-#define REPLACE 273
-#define SAVE 274
-#define OPEN 275
-
-#line 1 "./arparse.y"
-
-/* arparse.y - Stange script language parser */
-
-/* Copyright (C) 1992 Free Software Foundation, Inc.
-
-This file is part of GNU Binutils.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-
-/* Contributed by Steve Chamberlain
- sac@cygnus.com
-
-*/
-#define DONTDECLARE_MALLOC
-#include "bfd.h"
-#include <sysdep.h>
-#include "arsup.h"
-extern int verbose;
-
-#line 34 "./arparse.y"
-typedef union {
- char *name;
-struct list *list ;
-
-} YYSTYPE;
-
-#ifndef YYLTYPE
-typedef
- struct yyltype
- {
- int timestamp;
- int first_line;
- int first_column;
- int last_line;
- int last_column;
- char *text;
- }
- yyltype;
-
-#define YYLTYPE yyltype
-#endif
-
-#include <stdio.h>
-
-#ifndef __cplusplus
-#ifndef __STDC__
-#define const
-#endif
-#endif
-
-
-
-#define YYFINAL 53
-#define YYFLAG -32768
-#define YYNTBASE 24
-
-#define YYTRANSLATE(x) ((unsigned)(x) <= 275 ? yytranslate[x] : 45)
-
-static const char yytranslate[] = { 0,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 21,
- 22, 2, 2, 23, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 1, 2, 3, 4, 5,
- 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20
-};
-
-#if YYDEBUG != 0
-static const short yyprhs[] = { 0,
- 0, 1, 4, 7, 8, 11, 13, 15, 17, 19,
- 21, 23, 25, 27, 29, 31, 33, 35, 37, 39,
- 41, 42, 45, 48, 50, 53, 56, 58, 60, 63,
- 66, 70, 75, 77, 78, 82, 83, 87, 88, 90,
- 91
-};
-
-static const short yyrhs[] = { -1,
- 25, 26, 0, 26, 27, 0, 0, 28, 3, 0,
- 36, 0, 37, 0, 44, 0, 39, 0, 38, 0,
- 31, 0, 33, 0, 35, 0, 29, 0, 30, 0,
- 32, 0, 34, 0, 13, 0, 1, 0, 5, 0,
- 0, 14, 42, 0, 18, 42, 0, 9, 0, 11,
- 42, 0, 8, 42, 0, 7, 0, 19, 0, 20,
- 5, 0, 10, 5, 0, 6, 5, 41, 0, 12,
- 5, 41, 40, 0, 5, 0, 0, 21, 42, 22,
- 0, 0, 42, 43, 5, 0, 0, 23, 0, 0,
- 4, 0
-};
-
-#endif
-
-#if YYDEBUG != 0
-static const short yyrline[] = { 0,
- 64, 66, 68, 70, 73, 76, 78, 79, 80, 81,
- 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
- 92, 96, 101, 106, 111, 115, 120, 125, 132, 137,
- 143, 147, 154, 157, 160, 163, 167, 174, 178, 180,
- 184
-};
-
-static const char * const yytname[] = { "$","error","$undefined.","NEWLINE",
-"VERBOSE","FILENAME","ADDLIB","LIST","ADDMOD","CLEAR","CREATE","DELETE","DIRECTORY",
-"END","EXTRACT","FULLDIR","HELP","QUIT","REPLACE","SAVE","OPEN","'('","')'",
-"','","start","@1","session","command_line","command","extract_command","replace_command",
-"clear_command","delete_command","addmod_command","list_command","save_command",
-"open_command","create_command","addlib_command","directory_command","optional_filename",
-"modulelist","modulename","optcomma","verbose_command",""
-};
-#endif
-
-static const short yyr1[] = { 0,
- 25, 24, 26, 26, 27, 28, 28, 28, 28, 28,
- 28, 28, 28, 28, 28, 28, 28, 28, 28, 28,
- 28, 29, 30, 31, 32, 33, 34, 35, 36, 37,
- 38, 39, 40, 40, 41, 41, 42, 42, 43, 43,
- 44
-};
-
-static const short yyr2[] = { 0,
- 0, 2, 2, 0, 2, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 0, 2, 2, 1, 2, 2, 1, 1, 2, 2,
- 3, 4, 1, 0, 3, 0, 3, 0, 1, 0,
- 1
-};
-
-static const short yydefact[] = { 1,
- 4, 0, 19, 41, 20, 0, 27, 38, 24, 0,
- 38, 0, 18, 38, 38, 28, 0, 3, 0, 14,
- 15, 11, 16, 12, 17, 13, 6, 7, 10, 9,
- 8, 36, 26, 30, 25, 36, 22, 23, 29, 5,
- 38, 31, 39, 0, 34, 40, 37, 33, 32, 35,
- 0, 0, 0
-};
-
-static const short yydefgoto[] = { 51,
- 1, 2, 18, 19, 20, 21, 22, 23, 24, 25,
- 26, 27, 28, 29, 30, 49, 42, 33, 44, 31
-};
-
-static const short yypact[] = {-32768,
--32768, 5,-32768,-32768,-32768, -4,-32768,-32768,-32768, 2,
--32768, 21,-32768,-32768,-32768,-32768, 22,-32768, 25,-32768,
--32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
--32768, 8, -3,-32768, -3, 8, -3, -3,-32768,-32768,
--32768,-32768,-32768, 26, 27, -1,-32768,-32768,-32768,-32768,
- 33, 34,-32768
-};
-
-static const short yypgoto[] = {-32768,
--32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
--32768,-32768,-32768,-32768,-32768,-32768, 0, -11,-32768,-32768
-};
-
-
-#define YYLAST 36
-
-
-static const short yytable[] = { 35,
- 32, -40, 37, 38, -2, 3, 34, -21, 4, 5,
- 6, 7, 8, 9, 10, 11, 12, 13, 14, 43,
- 50, 43, 15, 16, 17, 36, 39, 40, 41, 46,
- 47, 48, 52, 53, 0, 45
-};
-
-static const short yycheck[] = { 11,
- 5, 5, 14, 15, 0, 1, 5, 3, 4, 5,
- 6, 7, 8, 9, 10, 11, 12, 13, 14, 23,
- 22, 23, 18, 19, 20, 5, 5, 3, 21, 41,
- 5, 5, 0, 0, -1, 36
-};
-/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
-#line 3 "/usr/unsupported/share/bison.simple"
-
-/* Skeleton output parser for bison,
- Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-#ifndef alloca
-#ifdef __GNUC__
-#define alloca __builtin_alloca
-#else /* not GNU C. */
-#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi)
-#include <alloca.h>
-#else /* not sparc */
-#if defined (MSDOS) && !defined (__TURBOC__)
-#include <malloc.h>
-#else /* not MSDOS, or __TURBOC__ */
-#if defined(_AIX)
-#include <malloc.h>
- #pragma alloca
-#else /* not MSDOS, __TURBOC__, or _AIX */
-#ifdef __hpux
-#ifdef __cplusplus
-extern "C" {
-void *alloca (unsigned int);
-};
-#else /* not __cplusplus */
-void *alloca ();
-#endif /* not __cplusplus */
-#endif /* __hpux */
-#endif /* not _AIX */
-#endif /* not MSDOS, or __TURBOC__ */
-#endif /* not sparc. */
-#endif /* not GNU C. */
-#endif /* alloca not defined. */
-
-/* This is the parser code that is written into each bison parser
- when the %semantic_parser declaration is not specified in the grammar.
- It was written by Richard Stallman by simplifying the hairy parser
- used when %semantic_parser is specified. */
-
-/* Note: there must be only one dollar sign in this file.
- It is replaced by the list of actions, each action
- as one case of the switch. */
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY -2
-#define YYEOF 0
-#define YYACCEPT return(0)
-#define YYABORT return(1)
-#define YYERROR goto yyerrlab1
-/* Like YYERROR except do call yyerror.
- This remains here temporarily to ease the
- transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. */
-#define YYFAIL goto yyerrlab
-#define YYRECOVERING() (!!yyerrstatus)
-#define YYBACKUP(token, value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { yychar = (token), yylval = (value); \
- yychar1 = YYTRANSLATE (yychar); \
- YYPOPSTACK; \
- goto yybackup; \
- } \
- else \
- { yyerror ("syntax error: cannot back up"); YYERROR; } \
-while (0)
-
-#define YYTERROR 1
-#define YYERRCODE 256
-
-#ifndef YYPURE
-#define YYLEX yylex()
-#endif
-
-#ifdef YYPURE
-#ifdef YYLSP_NEEDED
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval, &yylloc)
-#endif
-#else /* not YYLSP_NEEDED */
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval)
-#endif
-#endif /* not YYLSP_NEEDED */
-#endif
-
-/* If nonreentrant, generate the variables here */
-
-#ifndef YYPURE
-
-int yychar; /* the lookahead symbol */
-YYSTYPE yylval; /* the semantic value of the */
- /* lookahead symbol */
-
-#ifdef YYLSP_NEEDED
-YYLTYPE yylloc; /* location data for the lookahead */
- /* symbol */
-#endif
-
-int yynerrs; /* number of parse errors so far */
-#endif /* not YYPURE */
-
-#if YYDEBUG != 0
-int yydebug; /* nonzero means print parse trace */
-/* Since this is uninitialized, it does not stop multiple parsers
- from coexisting. */
-#endif
-
-/* YYINITDEPTH indicates the initial size of the parser's stacks */
-
-#ifndef YYINITDEPTH
-#define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH is the maximum size the stacks can grow to
- (effective only if the built-in stack extension method is used). */
-
-#if YYMAXDEPTH == 0
-#undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-#define YYMAXDEPTH 10000
-#endif
-
-/* Prevent warning if -Wstrict-prototypes. */
-#ifdef __GNUC__
-int yyparse (void);
-#endif
-
-#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
-#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT)
-#else /* not GNU C or C++ */
-#ifndef __cplusplus
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (from, to, count)
- char *from;
- char *to;
- int count;
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#else /* __cplusplus */
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (char *from, char *to, int count)
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#endif
-#endif
-
-#line 192 "/usr/unsupported/share/bison.simple"
-
-/* The user can define YYPARSE_PARAM as the name of an argument to be passed
- into yyparse. The argument should have type void *.
- It should actually point to an object.
- Grammar actions can access the variable by casting it
- to the proper pointer type. */
-
-#ifdef YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
-#else
-#define YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL
-#endif
-
-int
-yyparse(YYPARSE_PARAM)
- YYPARSE_PARAM_DECL
-{
- register int yystate;
- register int yyn;
- register short *yyssp;
- register YYSTYPE *yyvsp;
- int yyerrstatus; /* number of tokens to shift before error messages enabled */
- int yychar1 = 0; /* lookahead token as an internal (translated) token number */
-
- short yyssa[YYINITDEPTH]; /* the state stack */
- YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
-
- short *yyss = yyssa; /* refer to the stacks thru separate pointers */
- YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
-
-#ifdef YYLSP_NEEDED
- YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */
- YYLTYPE *yyls = yylsa;
- YYLTYPE *yylsp;
-
-#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
-#else
-#define YYPOPSTACK (yyvsp--, yyssp--)
-#endif
-
- int yystacksize = YYINITDEPTH;
-
-#ifdef YYPURE
- int yychar;
- YYSTYPE yylval;
- int yynerrs;
-#ifdef YYLSP_NEEDED
- YYLTYPE yylloc;
-#endif
-#endif
-
- YYSTYPE yyval; /* the variable used to return */
- /* semantic values from the action */
- /* routines */
-
- int yylen;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Starting parse\n");
-#endif
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
-
- yyssp = yyss - 1;
- yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
- yylsp = yyls;
-#endif
-
-/* Push a new state, which is found in yystate . */
-/* In all cases, when you get here, the value and location stacks
- have just been pushed. so pushing a state here evens the stacks. */
-yynewstate:
-
- *++yyssp = yystate;
-
- if (yyssp >= yyss + yystacksize - 1)
- {
- /* Give user a chance to reallocate the stack */
- /* Use copies of these so that the &'s don't force the real ones into memory. */
- YYSTYPE *yyvs1 = yyvs;
- short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
- YYLTYPE *yyls1 = yyls;
-#endif
-
- /* Get the current used size of the three stacks, in elements. */
- int size = yyssp - yyss + 1;
-
-#ifdef yyoverflow
- /* Each stack pointer address is followed by the size of
- the data in use in that stack, in bytes. */
-#ifdef YYLSP_NEEDED
- /* This used to be a conditional around just the two extra args,
- but that might be undefined if yyoverflow is a macro. */
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yyls1, size * sizeof (*yylsp),
- &yystacksize);
-#else
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yystacksize);
-#endif
-
- yyss = yyss1; yyvs = yyvs1;
-#ifdef YYLSP_NEEDED
- yyls = yyls1;
-#endif
-#else /* no yyoverflow */
- /* Extend the stack our own way. */
- if (yystacksize >= YYMAXDEPTH)
- {
- yyerror("parser stack overflow");
- return 2;
- }
- yystacksize *= 2;
- if (yystacksize > YYMAXDEPTH)
- yystacksize = YYMAXDEPTH;
- yyss = (short *) alloca (yystacksize * sizeof (*yyssp));
- __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp));
- yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp));
- __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp));
-#ifdef YYLSP_NEEDED
- yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp));
- __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp));
-#endif
-#endif /* no yyoverflow */
-
- yyssp = yyss + size - 1;
- yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
- yylsp = yyls + size - 1;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Stack size increased to %d\n", yystacksize);
-#endif
-
- if (yyssp >= yyss + yystacksize - 1)
- YYABORT;
- }
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Entering state %d\n", yystate);
-#endif
-
- goto yybackup;
- yybackup:
-
-/* Do appropriate processing given the current state. */
-/* Read a lookahead token if we need one and don't already have one. */
-/* yyresume: */
-
- /* First try to decide what to do without reference to lookahead token. */
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* yychar is either YYEMPTY or YYEOF
- or a valid token in external form. */
-
- if (yychar == YYEMPTY)
- {
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Reading a token: ");
-#endif
- yychar = YYLEX;
- }
-
- /* Convert token to internal form (in yychar1) for indexing tables with */
-
- if (yychar <= 0) /* This means end of input. */
- {
- yychar1 = 0;
- yychar = YYEOF; /* Don't call YYLEX any more */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Now at end of input.\n");
-#endif
- }
- else
- {
- yychar1 = YYTRANSLATE(yychar);
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
- /* Give the individual parser a way to print the precise meaning
- of a token, for further debugging info. */
-#ifdef YYPRINT
- YYPRINT (stderr, yychar, yylval);
-#endif
- fprintf (stderr, ")\n");
- }
-#endif
- }
-
- yyn += yychar1;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
- goto yydefault;
-
- yyn = yytable[yyn];
-
- /* yyn is what to do for this token type in this state.
- Negative => reduce, -yyn is rule number.
- Positive => shift, yyn is new state.
- New state is final state => don't bother to shift,
- just return success.
- 0, or most negative number => error. */
-
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrlab;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- /* Shift the lookahead token. */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
-#endif
-
- /* Discard the token being shifted unless it is eof. */
- if (yychar != YYEOF)
- yychar = YYEMPTY;
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- /* count tokens shifted since error; after three, turn off error status. */
- if (yyerrstatus) yyerrstatus--;
-
- yystate = yyn;
- goto yynewstate;
-
-/* Do the default action for the current state. */
-yydefault:
-
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
-
-/* Do a reduction. yyn is the number of a rule to reduce with. */
-yyreduce:
- yylen = yyr2[yyn];
- if (yylen > 0)
- yyval = yyvsp[1-yylen]; /* implement default value of the action */
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- int i;
-
- fprintf (stderr, "Reducing via rule %d (line %d), ",
- yyn, yyrline[yyn]);
-
- /* Print the symbols being reduced, and their result. */
- for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
- fprintf (stderr, "%s ", yytname[yyrhs[i]]);
- fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
- }
-#endif
-
-
- switch (yyn) {
-
-case 1:
-#line 65 "./arparse.y"
-{ prompt(); ;
- break;}
-case 5:
-#line 74 "./arparse.y"
-{ prompt(); ;
- break;}
-case 18:
-#line 89 "./arparse.y"
-{ ar_end(); return 0; ;
- break;}
-case 20:
-#line 91 "./arparse.y"
-{ yyerror("foo"); ;
- break;}
-case 22:
-#line 98 "./arparse.y"
-{ ar_extract(yyvsp[0].list); ;
- break;}
-case 23:
-#line 103 "./arparse.y"
-{ ar_replace(yyvsp[0].list); ;
- break;}
-case 24:
-#line 108 "./arparse.y"
-{ ar_clear(); ;
- break;}
-case 25:
-#line 113 "./arparse.y"
-{ ar_delete(yyvsp[0].list); ;
- break;}
-case 26:
-#line 117 "./arparse.y"
-{ ar_addmod(yyvsp[0].list); ;
- break;}
-case 27:
-#line 122 "./arparse.y"
-{ ar_list(); ;
- break;}
-case 28:
-#line 127 "./arparse.y"
-{ ar_save(); ;
- break;}
-case 29:
-#line 134 "./arparse.y"
-{ ar_open(yyvsp[0].name,0); ;
- break;}
-case 30:
-#line 139 "./arparse.y"
-{ ar_open(yyvsp[0].name,1); ;
- break;}
-case 31:
-#line 145 "./arparse.y"
-{ ar_addlib(yyvsp[-1].name,yyvsp[0].list); ;
- break;}
-case 32:
-#line 149 "./arparse.y"
-{ ar_directory(yyvsp[-2].name, yyvsp[-1].list, yyvsp[0].name); ;
- break;}
-case 33:
-#line 156 "./arparse.y"
-{ yyval.name = yyvsp[0].name; ;
- break;}
-case 34:
-#line 157 "./arparse.y"
-{ yyval.name = 0; ;
- break;}
-case 35:
-#line 162 "./arparse.y"
-{ yyval.list = yyvsp[-1].list; ;
- break;}
-case 36:
-#line 164 "./arparse.y"
-{ yyval.list = 0; ;
- break;}
-case 37:
-#line 169 "./arparse.y"
-{ struct list *n = (struct list *) malloc(sizeof(struct list));
- n->next = yyvsp[-2].list;
- n->name = yyvsp[0].name;
- yyval.list = n;
- ;
- break;}
-case 38:
-#line 174 "./arparse.y"
-{ yyval.list = 0; ;
- break;}
-case 41:
-#line 186 "./arparse.y"
-{ verbose = !verbose; ;
- break;}
-}
- /* the action file gets copied in in place of this dollarsign */
-#line 487 "/usr/unsupported/share/bison.simple"
-
- yyvsp -= yylen;
- yyssp -= yylen;
-#ifdef YYLSP_NEEDED
- yylsp -= yylen;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
- *++yyvsp = yyval;
-
-#ifdef YYLSP_NEEDED
- yylsp++;
- if (yylen == 0)
- {
- yylsp->first_line = yylloc.first_line;
- yylsp->first_column = yylloc.first_column;
- yylsp->last_line = (yylsp-1)->last_line;
- yylsp->last_column = (yylsp-1)->last_column;
- yylsp->text = 0;
- }
- else
- {
- yylsp->last_line = (yylsp+yylen-1)->last_line;
- yylsp->last_column = (yylsp+yylen-1)->last_column;
- }
-#endif
-
- /* Now "shift" the result of the reduction.
- Determine what state that goes to,
- based on the state we popped back to
- and the rule number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
- if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTBASE];
-
- goto yynewstate;
-
-yyerrlab: /* here on detecting error */
-
- if (! yyerrstatus)
- /* If not already recovering from an error, report this error. */
- {
- ++yynerrs;
-
-#ifdef YYERROR_VERBOSE
- yyn = yypact[yystate];
-
- if (yyn > YYFLAG && yyn < YYLAST)
- {
- int size = 0;
- char *msg;
- int x, count;
-
- count = 0;
- /* Start X at -yyn if nec to avoid negative indexes in yycheck. */
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- size += strlen(yytname[x]) + 15, count++;
- msg = (char *) malloc(size + 15);
- if (msg != 0)
- {
- strcpy(msg, "parse error");
-
- if (count < 5)
- {
- count = 0;
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- {
- strcat(msg, count == 0 ? ", expecting `" : " or `");
- strcat(msg, yytname[x]);
- strcat(msg, "'");
- count++;
- }
- }
- yyerror(msg);
- free(msg);
- }
- else
- yyerror ("parse error; also virtual memory exceeded");
- }
- else
-#endif /* YYERROR_VERBOSE */
- yyerror("parse error");
- }
-
- goto yyerrlab1;
-yyerrlab1: /* here on error raised explicitly by an action */
-
- if (yyerrstatus == 3)
- {
- /* if just tried and failed to reuse lookahead token after an error, discard it. */
-
- /* return failure if at end of input */
- if (yychar == YYEOF)
- YYABORT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
-#endif
-
- yychar = YYEMPTY;
- }
-
- /* Else will try to reuse lookahead token
- after shifting the error token. */
-
- yyerrstatus = 3; /* Each real token shifted decrements this */
-
- goto yyerrhandle;
-
-yyerrdefault: /* current state does not do anything special for the error token. */
-
-#if 0
- /* This is wrong; only states that explicitly want error tokens
- should shift them. */
- yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
- if (yyn) goto yydefault;
-#endif
-
-yyerrpop: /* pop the current state because it cannot handle the error token */
-
- if (yyssp == yyss) YYABORT;
- yyvsp--;
- yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
- yylsp--;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "Error: state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
-yyerrhandle:
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yyerrdefault;
-
- yyn += YYTERROR;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
- goto yyerrdefault;
-
- yyn = yytable[yyn];
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrpop;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrpop;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting error token, ");
-#endif
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- yystate = yyn;
- goto yynewstate;
-}
-#line 190 "./arparse.y"
-
-
-
-int
-yyerror(x)
-char *x;
-{
- extern int linenumber;
- printf("Synax error in archive script, line %d\n", linenumber + 1);
- return 0;
-}
diff --git a/gnu/usr.bin/binutils/binutils/arparse.h b/gnu/usr.bin/binutils/binutils/arparse.h
deleted file mode 100644
index 3212fe3af24..00000000000
--- a/gnu/usr.bin/binutils/binutils/arparse.h
+++ /dev/null
@@ -1,26 +0,0 @@
-typedef union {
- char *name;
-struct list *list ;
-
-} YYSTYPE;
-#define NEWLINE 258
-#define VERBOSE 259
-#define FILENAME 260
-#define ADDLIB 261
-#define LIST 262
-#define ADDMOD 263
-#define CLEAR 264
-#define CREATE 265
-#define DELETE 266
-#define DIRECTORY 267
-#define END 268
-#define EXTRACT 269
-#define FULLDIR 270
-#define HELP 271
-#define QUIT 272
-#define REPLACE 273
-#define SAVE 274
-#define OPEN 275
-
-
-extern YYSTYPE yylval;
diff --git a/gnu/usr.bin/binutils/binutils/binutils.info b/gnu/usr.bin/binutils/binutils/binutils.info
deleted file mode 100644
index 43a8f0bab65..00000000000
--- a/gnu/usr.bin/binutils/binutils/binutils.info
+++ /dev/null
@@ -1,1668 +0,0 @@
-This is Info file binutils.info, produced by Makeinfo-1.55 from the
-input file ./binutils.texi.
-
-START-INFO-DIR-ENTRY
-* Binutils: (binutils). The GNU binary utilities "ar", "objcopy",
- "objdump", "nm", "nlmconv", "size",
- "strings", "strip", and "ranlib".
-END-INFO-DIR-ENTRY
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided also
-that the entire resulting derived work is distributed under the terms
-of a permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: binutils.info, Node: Top, Next: ar, Prev: (DIR), Up: (DIR)
-
-Introduction
-************
-
- This brief manual contains preliminary documentation for the GNU
-binary utilities (collectively version 2.6):
-
-* Menu:
-
-* ar:: Create, modify, and extract from archives
-* nm:: List symbols from object files
-* objcopy:: Copy and translate object files
-* objdump:: Display information from object files
-* ranlib:: Generate index to archive contents
-* size:: List section sizes and total size
-* strings:: List printable strings from files
-* strip:: Discard symbols
-* c++filt:: Filter to demangle encoded C++ symbols
-* nlmconv:: Converts object code into an NLM
-* Selecting The Target System:: How these utilities determine the target.
-* Index::
-
-
-File: binutils.info, Node: ar, Next: nm, Prev: Top, Up: Top
-
-ar
-**
-
- ar [-]P[MOD [RELPOS]] ARCHIVE [MEMBER...]
- ar -M [ <mri-script ]
-
- The GNU `ar' program creates, modifies, and extracts from archives.
-An "archive" is a single file holding a collection of other files in a
-structure that makes it possible to retrieve the original individual
-files (called "members" of the archive).
-
- The original files' contents, mode (permissions), timestamp, owner,
-and group are preserved in the archive, and can be restored on
-extraction.
-
- GNU `ar' can maintain archives whose members have names of any
-length; however, depending on how `ar' is configured on your system, a
-limit on member-name length may be imposed for compatibility with
-archive formats maintained with other tools. If it exists, the limit
-is often 15 characters (typical of formats related to a.out) or 16
-characters (typical of formats related to coff).
-
- `ar' is considered a binary utility because archives of this sort
-are most often used as "libraries" holding commonly needed subroutines.
-
- `ar' creates an index to the symbols defined in relocatable object
-modules in the archive when you specify the modifier `s'. Once
-created, this index is updated in the archive whenever `ar' makes a
-change to its contents (save for the `q' update operation). An archive
-with such an index speeds up linking to the library, and allows
-routines in the library to call each other without regard to their
-placement in the archive.
-
- You may use `nm -s' or `nm --print-armap' to list this index table.
-If an archive lacks the table, another form of `ar' called `ranlib' can
-be used to add just the table.
-
- GNU `ar' is designed to be compatible with two different facilities.
-You can control its activity using command-line options, like the
-different varieties of `ar' on Unix systems; or, if you specify the
-single command-line option `-M', you can control it with a script
-supplied via standard input, like the MRI "librarian" program.
-
-* Menu:
-
-* ar cmdline:: Controlling `ar' on the command line
-* ar scripts:: Controlling `ar' with a script
-
-
-File: binutils.info, Node: ar cmdline, Next: ar scripts, Up: ar
-
-Controlling `ar' on the command line
-====================================
-
- ar [-]P[MOD [RELPOS]] ARCHIVE [MEMBER...]
-
- When you use `ar' in the Unix style, `ar' insists on at least two
-arguments to execute: one keyletter specifying the *operation*
-(optionally accompanied by other keyletters specifying *modifiers*),
-and the archive name to act on.
-
- Most operations can also accept further MEMBER arguments, specifying
-particular files to operate on.
-
- GNU `ar' allows you to mix the operation code P and modifier flags
-MOD in any order, within the first command-line argument.
-
- If you wish, you may begin the first command-line argument with a
-dash.
-
- The P keyletter specifies what operation to execute; it may be any
-of the following, but you must specify only one of them:
-
-`d'
- *Delete* modules from the archive. Specify the names of modules to
- be deleted as MEMBER...; the archive is untouched if you specify
- no files to delete.
-
- If you specify the `v' modifier, `ar' lists each module as it is
- deleted.
-
-`m'
- Use this operation to *move* members in an archive.
-
- The ordering of members in an archive can make a difference in how
- programs are linked using the library, if a symbol is defined in
- more than one member.
-
- If no modifiers are used with `m', any members you name in the
- MEMBER arguments are moved to the *end* of the archive; you can
- use the `a', `b', or `i' modifiers to move them to a specified
- place instead.
-
-`p'
- *Print* the specified members of the archive, to the standard
- output file. If the `v' modifier is specified, show the member
- name before copying its contents to standard output.
-
- If you specify no MEMBER arguments, all the files in the archive
- are printed.
-
-`q'
- *Quick append*; add the files MEMBER... to the end of ARCHIVE,
- without checking for replacement.
-
- The modifiers `a', `b', and `i' do *not* affect this operation;
- new members are always placed at the end of the archive.
-
- The modifier `v' makes `ar' list each file as it is appended.
-
- Since the point of this operation is speed, the archive's symbol
- table index is not updated, even if it already existed; you can
- use `ar s' or `ranlib' explicitly to update the symbol table index.
-
-`r'
- Insert the files MEMBER... into ARCHIVE (with *replacement*). This
- operation differs from `q' in that any previously existing members
- are deleted if their names match those being added.
-
- If one of the files named in MEMBER... does not exist, `ar'
- displays an error message, and leaves undisturbed any existing
- members of the archive matching that name.
-
- By default, new members are added at the end of the file; but you
- may use one of the modifiers `a', `b', or `i' to request placement
- relative to some existing member.
-
- The modifier `v' used with this operation elicits a line of output
- for each file inserted, along with one of the letters `a' or `r'
- to indicate whether the file was appended (no old member deleted)
- or replaced.
-
-`t'
- Display a *table* listing the contents of ARCHIVE, or those of the
- files listed in MEMBER... that are present in the archive.
- Normally only the member name is shown; if you also want to see
- the modes (permissions), timestamp, owner, group, and size, you can
- request that by also specifying the `v' modifier.
-
- If you do not specify a MEMBER, all files in the archive are
- listed.
-
- If there is more than one file with the same name (say, `fie') in
- an archive (say `b.a'), `ar t b.a fie' lists only the first
- instance; to see them all, you must ask for a complete listing--in
- our example, `ar t b.a'.
-
-`x'
- *Extract* members (named MEMBER) from the archive. You can use
- the `v' modifier with this operation, to request that `ar' list
- each name as it extracts it.
-
- If you do not specify a MEMBER, all files in the archive are
- extracted.
-
- A number of modifiers (MOD) may immediately follow the P keyletter,
-to specify variations on an operation's behavior:
-
-`a'
- Add new files *after* an existing member of the archive. If you
- use the modifier `a', the name of an existing archive member must
- be present as the RELPOS argument, before the ARCHIVE
- specification.
-
-`b'
- Add new files *before* an existing member of the archive. If you
- use the modifier `b', the name of an existing archive member must
- be present as the RELPOS argument, before the ARCHIVE
- specification. (same as `i').
-
-`c'
- *Create* the archive. The specified ARCHIVE is always created if
- it did not exist, when you request an update. But a warning is
- issued unless you specify in advance that you expect to create it,
- by using this modifier.
-
-`f'
- Truncate names in the archive. GNU `ar' will normally permit file
- names of any length. This will cause it to create archives which
- are not compatible with the native `ar' program on some systems.
- If this is a concern, the `f' modifier may be used to truncate file
- names when putting them in the archive.
-
-`i'
- Insert new files *before* an existing member of the archive. If
- you use the modifier `i', the name of an existing archive member
- must be present as the RELPOS argument, before the ARCHIVE
- specification. (same as `b').
-
-`l'
- This modifier is accepted but not used.
-
-`o'
- Preserve the *original* dates of members when extracting them. If
- you do not specify this modifier, files extracted from the archive
- are stamped with the time of extraction.
-
-`s'
- Write an object-file index into the archive, or update an existing
- one, even if no other change is made to the archive. You may use
- this modifier flag either with any operation, or alone. Running
- `ar s' on an archive is equivalent to running `ranlib' on it.
-
-`u'
- Normally, `ar r'... inserts all files listed into the archive. If
- you would like to insert *only* those of the files you list that
- are newer than existing members of the same names, use this
- modifier. The `u' modifier is allowed only for the operation `r'
- (replace). In particular, the combination `qu' is not allowed,
- since checking the timestamps would lose any speed advantage from
- the operation `q'.
-
-`v'
- This modifier requests the *verbose* version of an operation. Many
- operations display additional information, such as filenames
- processed, when the modifier `v' is appended.
-
-`V'
- This modifier shows the version number of `ar'.
-
-
-File: binutils.info, Node: ar scripts, Prev: ar cmdline, Up: ar
-
-Controlling `ar' with a script
-==============================
-
- ar -M [ <SCRIPT ]
-
- If you use the single command-line option `-M' with `ar', you can
-control its operation with a rudimentary command language. This form
-of `ar' operates interactively if standard input is coming directly
-from a terminal. During interactive use, `ar' prompts for input (the
-prompt is `AR >'), and continues executing even after errors. If you
-redirect standard input to a script file, no prompts are issued, and
-`ar' abandons execution (with a nonzero exit code) on any error.
-
- The `ar' command language is *not* designed to be equivalent to the
-command-line options; in fact, it provides somewhat less control over
-archives. The only purpose of the command language is to ease the
-transition to GNU `ar' for developers who already have scripts written
-for the MRI "librarian" program.
-
- The syntax for the `ar' command language is straightforward:
- * commands are recognized in upper or lower case; for example, `LIST'
- is the same as `list'. In the following descriptions, commands are
- shown in upper case for clarity.
-
- * a single command may appear on each line; it is the first word on
- the line.
-
- * empty lines are allowed, and have no effect.
-
- * comments are allowed; text after either of the characters `*' or
- `;' is ignored.
-
- * Whenever you use a list of names as part of the argument to an `ar'
- command, you can separate the individual names with either commas
- or blanks. Commas are shown in the explanations below, for
- clarity.
-
- * `+' is used as a line continuation character; if `+' appears at
- the end of a line, the text on the following line is considered
- part of the current command.
-
- Here are the commands you can use in `ar' scripts, or when using
-`ar' interactively. Three of them have special significance:
-
- `OPEN' or `CREATE' specify a "current archive", which is a temporary
-file required for most of the other commands.
-
- `SAVE' commits the changes so far specified by the script. Prior to
-`SAVE', commands affect only the temporary copy of the current archive.
-
-`ADDLIB ARCHIVE'
-`ADDLIB ARCHIVE (MODULE, MODULE, ... MODULE)'
- Add all the contents of ARCHIVE (or, if specified, each named
- MODULE from ARCHIVE) to the current archive.
-
- Requires prior use of `OPEN' or `CREATE'.
-
-`ADDMOD MEMBER, MEMBER, ... MEMBER'
- Add each named MEMBER as a module in the current archive.
-
- Requires prior use of `OPEN' or `CREATE'.
-
-`CLEAR'
- Discard the contents of the current archive, cancelling the effect
- of any operations since the last `SAVE'. May be executed (with no
- effect) even if no current archive is specified.
-
-`CREATE ARCHIVE'
- Creates an archive, and makes it the current archive (required for
- many other commands). The new archive is created with a temporary
- name; it is not actually saved as ARCHIVE until you use `SAVE'.
- You can overwrite existing archives; similarly, the contents of any
- existing file named ARCHIVE will not be destroyed until `SAVE'.
-
-`DELETE MODULE, MODULE, ... MODULE'
- Delete each listed MODULE from the current archive; equivalent to
- `ar -d ARCHIVE MODULE ... MODULE'.
-
- Requires prior use of `OPEN' or `CREATE'.
-
-`DIRECTORY ARCHIVE (MODULE, ... MODULE)'
-`DIRECTORY ARCHIVE (MODULE, ... MODULE) OUTPUTFILE'
- List each named MODULE present in ARCHIVE. The separate command
- `VERBOSE' specifies the form of the output: when verbose output is
- off, output is like that of `ar -t ARCHIVE MODULE...'. When
- verbose output is on, the listing is like `ar -tv ARCHIVE
- MODULE...'.
-
- Output normally goes to the standard output stream; however, if you
- specify OUTPUTFILE as a final argument, `ar' directs the output to
- that file.
-
-`END'
- Exit from `ar', with a `0' exit code to indicate successful
- completion. This command does not save the output file; if you
- have changed the current archive since the last `SAVE' command,
- those changes are lost.
-
-`EXTRACT MODULE, MODULE, ... MODULE'
- Extract each named MODULE from the current archive, writing them
- into the current directory as separate files. Equivalent to `ar -x
- ARCHIVE MODULE...'.
-
- Requires prior use of `OPEN' or `CREATE'.
-
-`LIST'
- Display full contents of the current archive, in "verbose" style
- regardless of the state of `VERBOSE'. The effect is like `ar tv
- ARCHIVE'). (This single command is a GNU `ld' enhancement, rather
- than present for MRI compatibility.)
-
- Requires prior use of `OPEN' or `CREATE'.
-
-`OPEN ARCHIVE'
- Opens an existing archive for use as the current archive (required
- for many other commands). Any changes as the result of subsequent
- commands will not actually affect ARCHIVE until you next use
- `SAVE'.
-
-`REPLACE MODULE, MODULE, ... MODULE'
- In the current archive, replace each existing MODULE (named in the
- `REPLACE' arguments) from files in the current working directory.
- To execute this command without errors, both the file, and the
- module in the current archive, must exist.
-
- Requires prior use of `OPEN' or `CREATE'.
-
-`VERBOSE'
- Toggle an internal flag governing the output from `DIRECTORY'.
- When the flag is on, `DIRECTORY' output matches output from `ar
- -tv '....
-
-`SAVE'
- Commit your changes to the current archive, and actually save it
- as a file with the name specified in the last `CREATE' or `OPEN'
- command.
-
- Requires prior use of `OPEN' or `CREATE'.
-
-
-File: binutils.info, Node: nm, Next: objcopy, Prev: ar, Up: Top
-
-nm
-**
-
- nm [ -a | --debug-syms ] [ -g | --extern-only ]
- [ -B ] [ -C | --demangle ] [ -D | --dynamic ]
- [ -s | --print-armap ] [ -A | -o | --print-file-name ]
- [ -n | -v | --numeric-sort ] [ -p | --no-sort ]
- [ -r | --reverse-sort ] [ --size-sort ] [ -u | --undefined-only ]
- [ -t RADIX | --radix=RADIX ] [ -P | --portability ]
- [ --target=BFDNAME ] [ -f FORMAT | --format=FORMAT ]
- [ --no-demangle ] [ -V | --version ] [ --help ] [ OBJFILE... ]
-
- GNU `nm' lists the symbols from object files OBJFILE.... If no
-object files are listed as arguments, `nm' assumes `a.out'.
-
- For each symbol, `nm' shows:
-
- * The symbol value, in the radix selected by options (see below), or
- hexadecimal by default.
-
- * The symbol type. At least the following types are used; others
- are, as well, depending on the object file format. If lowercase,
- the symbol is local; if uppercase, the symbol is global (external).
-
- `A'
- Absolute.
-
- `B'
- BSS (uninitialized data).
-
- `C'
- Common.
-
- `D'
- Initialized data.
-
- `I'
- Indirect reference.
-
- `T'
- Text (program code).
-
- `U'
- Undefined.
-
- * The symbol name.
-
- The long and short forms of options, shown here as alternatives, are
-equivalent.
-
-`-A'
-`-o'
-`--print-file-name'
- Precede each symbol by the name of the input file (or archive
- element) in which it was found, rather than identifying the input
- file once only, before all of its symbols.
-
-`-a'
-`--debug-syms'
- Display all symbols, even debugger-only symbols; normally these
- are not listed.
-
-`-B'
- The same as `--format=bsd' (for compatibility with the MIPS `nm').
-
-`-C'
-`--demangle'
- Decode ("demangle") low-level symbol names into user-level names.
- Besides removing any initial underscore prepended by the system,
- this makes C++ function names readable. *Note c++filt::, for more
- information on demangling.
-
-`--no-demangle'
- Do not demangle low-level symbol names. This is the default.
-
-`-D'
-`--dynamic'
- Display the dynamic symbols rather than the normal symbols. This
- is only meaningful for dynamic objects, such as certain types of
- shared libraries.
-
-`-f FORMAT'
-`--format=FORMAT'
- Use the output format FORMAT, which can be `bsd', `sysv', or
- `posix'. The default is `bsd'. Only the first character of
- FORMAT is significant; it can be either upper or lower case.
-
-`-g'
-`--extern-only'
- Display only external symbols.
-
-`-n'
-`-v'
-`--numeric-sort'
- Sort symbols numerically by their addresses, rather than
- alphabetically by their names.
-
-`-p'
-`--no-sort'
- Do not bother to sort the symbols in any order; print them in the
- order encountered.
-
-`-P'
-`--portability'
- Use the POSIX.2 standard output format instead of the default
- format. Equivalent to `-f posix'.
-
-`-s'
-`--print-armap'
- When listing symbols from archive members, include the index: a
- mapping (stored in the archive by `ar' or `ranlib') of which
- modules contain definitions for which names.
-
-`-r'
-`--reverse-sort'
- Reverse the order of the sort (whether numeric or alphabetic); let
- the last come first.
-
-`--size-sort'
- Sort symbols by size. The size is computed as the difference
- between the value of the symbol and the value of the symbol with
- the next higher value. The size of the symbol is printed, rather
- than the value.
-
-`-t RADIX'
-`--radix=RADIX'
- Use RADIX as the radix for printing the symbol values. It must be
- `d' for decimal, `o' for octal, or `x' for hexadecimal.
-
-`--target=BFDNAME'
- Specify an object code format other than your system's default
- format. *Note Target Selection::, for more information.
-
-`-u'
-`--undefined-only'
- Display only undefined symbols (those external to each object
- file).
-
-`-V'
-`--version'
- Show the version number of `nm' and exit.
-
-`--help'
- Show a summary of the options to `nm' and exit.
-
-
-File: binutils.info, Node: objcopy, Next: objdump, Prev: nm, Up: Top
-
-objcopy
-*******
-
- objcopy [ -F BFDNAME | --target=BFDNAME ]
- [ -I BFDNAME | --input-target=BFDNAME ]
- [ -O BFDNAME | --output-target=BFDNAME ]
- [ -S | --strip-all ] [ -g | --strip-debug ]
- [ -K SYMBOLNAME | --keep-symbol=SYMBOLNAME ]
- [ -N SYMBOLNAME | --strip-symbol=SYMBOLNAME ]
- [ -x | --discard-all ] [ -X | --discard-locals ]
- [ -b BYTE | --byte=BYTE ]
- [ -i INTERLEAVE | --interleave=INTERLEAVE ]
- [ -R SECTIONNAME | --remove-section=SECTIONNAME ]
- [ --gap-fill=VAL ] [ --pad-to=ADDRESS ]
- [ --set-start=VAL ] [ --adjust-start=INCR ]
- [ --adjust-vma=INCR ]
- [ --adjust-section-vma=SECTION{=,+,-}VAL ]
- [ --adjust-warnings ] [ --no-adjust-warnings ]
- [ --set-section-flags=SECTION=FLAGS ]
- [ --add-section=SECTIONNAME=FILENAME ]
- [ -v | --verbose ] [ -V | --version ] [ --help ]
- INFILE [OUTFILE]
-
- The GNU `objcopy' utility copies the contents of an object file to
-another. `objcopy' uses the GNU BFD Library to read and write the
-object files. It can write the destination object file in a format
-different from that of the source object file. The exact behavior of
-`objcopy' is controlled by command-line options.
-
- `objcopy' creates temporary files to do its translations and deletes
-them afterward. `objcopy' uses BFD to do all its translation work; it
-has access to all the formats described in BFD and thus is able to
-recognize most formats without being told explicitly. *Note BFD:
-(ld.info)BFD.
-
- `objcopy' can be used to generate S-records by using an output
-target of `srec' (e.g., use `-O srec').
-
- `objcopy' can be used to generate a raw binary file by using an
-output target of `binary' (e.g., use `-O binary'). When `objcopy'
-generates a raw binary file, it will essentially produce a memory dump
-of the contents of the input object file. All symbols and relocation
-information will be discarded. The memory dump will start at the
-virtual address of the lowest section copied into the output file.
-
- When generating an S-record or a raw binary file, it may be helpful
-to use `-S' to remove sections containing debugging information. In
-some cases `-R' will be useful to remove sections which contain
-information which is not needed by the binary file.
-
-`INFILE'
-`OUTFILE'
- The source and output files, respectively. If you do not specify
- OUTFILE, `objcopy' creates a temporary file and destructively
- renames the result with the name of INFILE.
-
-`-I BFDNAME'
-`--input-target=BFDNAME'
- Consider the source file's object format to be BFDNAME, rather than
- attempting to deduce it. *Note Target Selection::, for more
- information.
-
-`-O BFDNAME'
-`--output-target=BFDNAME'
- Write the output file using the object format BFDNAME. *Note
- Target Selection::, for more information.
-
-`-F BFDNAME'
-`--target=BFDNAME'
- Use BFDNAME as the object format for both the input and the output
- file; i.e., simply transfer data from source to destination with no
- translation. *Note Target Selection::, for more information.
-
-`-R SECTIONNAME'
-`--remove-section=SECTIONNAME'
- Remove any section named SECTIONNAME from the output file. This
- option may be given more than once. Note that using this option
- inappropriately may make the output file unusable.
-
-`-S'
-`--strip-all'
- Do not copy relocation and symbol information from the source file.
-
-`-g'
-`--strip-debug'
- Do not copy debugging symbols from the source file.
-
-`--strip-unneeded'
- Strip all symbols that are not needed for relocation processing.
-
-`-K SYMBOLNAME'
-`--keep-symbol=SYMBOLNAME'
- Copy only symbol SYMBOLNAME from the source file. This option may
- be given more than once.
-
-`-N SYMBOLNAME'
-`--strip-symbol=SYMBOLNAME'
- Do not copy symbol SYMBOLNAME from the source file. This option
- may be given more than once, and may be combined with strip options
- other than `-K'.
-
-`-x'
-`--discard-all'
- Do not copy non-global symbols from the source file.
-
-`-X'
-`--discard-locals'
- Do not copy compiler-generated local symbols. (These usually
- start with `L' or `.'.)
-
-`-b BYTE'
-`--byte=BYTE'
- Keep only every BYTEth byte of the input file (header data is not
- affected). BYTE can be in the range from 0 to INTERLEAVE-1, where
- INTERLEAVE is given by the `-i' or `--interleave' option, or the
- default of 4. This option is useful for creating files to program
- ROM. It is typically used with an `srec' output target.
-
-`-i INTERLEAVE'
-`--interleave=INTERLEAVE'
- Only copy one out of every INTERLEAVE bytes. Select which byte to
- copy with the -B or `--byte' option. The default is 4. `objcopy'
- ignores this option if you do not specify either `-b' or `--byte'.
-
-`--gap-fill VAL'
- Fill gaps between sections with VAL. This is done by increasing
- the size of the section with the lower address, and filling in the
- extra space created with VAL.
-
-`--pad-to ADDRESS'
- Pad the output file up to the virtual address ADDRESS. This is
- done by increasing the size of the last section. The extra space
- is filled in with the value specified by `--gap-fill' (default
- zero).
-
-`--set-start VAL'
- Set the address of the new file to VAL. Not all object file
- formats support setting the start address.
-
-`--adjust-start INCR'
- Adjust the start address by adding INCR. Not all object file
- formats support setting the start address.
-
-`--adjust-vma INCR'
- Adjust the address of all sections, as well as the start address,
- by adding INCR. Some object file formats do not permit section
- addresses to be changed arbitrarily. Note that this does not
- relocate the sections; if the program expects sections to be
- loaded at a certain address, and this option is used to change the
- sections such that they are loaded at a different address, the
- program may fail.
-
-`--adjust-section-vma SECTION{=,+,-}VAL'
- Set or adjust the address of the named SECTION. If `=' is used,
- the section address is set to VAL. Otherwise, VAL is added to or
- subtracted from the section address. See the comments under
- `--adjust-vma', above. If SECTION does not exist in the input
- file, a warning will be issued, unless `--no-adjust-warnings' is
- used.
-
-`--adjust-warnings'
- If `--adjust-section-vma' is used, and the named section does not
- exist, issue a warning. This is the default.
-
-`--no-adjust-warnings'
- Do not issue a warning if `--adjust-section-vma' is used, even if
- the named section does not exist.
-
-`--set-section-flags SECTION=FLAGS'
- Set the flags for the named section. The FLAGS argument is a
- comma separated string of flag names. The recognized names are
- `alloc', `load', `readonly', `code', `data', and `rom'. Not all
- flags are meaningful for all object file formats.
-
-`--add-section SECTIONNAME=FILENAME'
- Add a new section named SECTIONNAME while copying the file. The
- contents of the new section are taken from the file FILENAME. The
- size of the section will be the size of the file. This option only
- works on file formats which can support sections with arbitrary
- names.
-
-`-V'
-`--version'
- Show the version number of `objcopy'.
-
-`-v'
-`--verbose'
- Verbose output: list all object files modified. In the case of
- archives, `objcopy -V' lists all members of the archive.
-
-`--help'
- Show a summary of the options to `objcopy'.
-
-
-File: binutils.info, Node: objdump, Next: ranlib, Prev: objcopy, Up: Top
-
-objdump
-*******
-
- objdump [ -a | --archive-headers ]
- [ -b BFDNAME | --target=BFDNAME ]
- [ -d | --disassemble ] [ -D | --disassemble-all ]
- [ -f | --file-headers ]
- [ -h | --section-headers | --headers ] [ -i | --info ]
- [ -j SECTION | --section=SECTION ]
- [ -l | --line-numbers ] [ -S | --source ]
- [ -m MACHINE | --architecture=MACHINE ]
- [ -r | --reloc ] [ -R | --dynamic-reloc ]
- [ -s | --full-contents ] [ --stabs ]
- [ -t | --syms ] [ -T | --dynamic-syms ] [ -x | --all-headers ]
- [ -w | --wide ] [ --start-address=ADDRESS ]
- [ --stop-address=ADDRESS ] [ --version ] [ --help ]
- OBJFILE...
-
- `objdump' displays information about one or more object files. The
-options control what particular information to display. This
-information is mostly useful to programmers who are working on the
-compilation tools, as opposed to programmers who just want their
-program to compile and work.
-
- OBJFILE... are the object files to be examined. When you specify
-archives, `objdump' shows information on each of the member object
-files.
-
- The long and short forms of options, shown here as alternatives, are
-equivalent. At least one option besides `-l' must be given.
-
-`-a'
-`--archive-header'
- If any of the OBJFILE files are archives, display the archive
- header information (in a format similar to `ls -l'). Besides the
- information you could list with `ar tv', `objdump -a' shows the
- object file format of each archive member.
-
-`-b BFDNAME'
-`--target=BFDNAME'
- Specify that the object-code format for the object files is
- BFDNAME. This option may not be necessary; OBJDUMP can
- automatically recognize many formats.
-
- For example,
- objdump -b oasys -m vax -h fu.o
-
- displays summary information from the section headers (`-h') of
- `fu.o', which is explicitly identified (`-m') as a VAX object file
- in the format produced by Oasys compilers. You can list the
- formats available with the `-i' option. *Note Target Selection::,
- for more information.
-
-`-d'
-`--disassemble'
- Display the assembler mnemonics for the machine instructions from
- OBJFILE. This option only disassembles those sections which are
- expected to contain instructions.
-
-`-D'
-`--disassemble-all'
- Like `-d', but disassemble the contents of all sections, not just
- those expected to contain instructions.
-
-`-f'
-`--file-header'
- Display summary information from the overall header of each of the
- OBJFILE files.
-
-`-h'
-`--section-header'
-`--header'
- Display summary information from the section headers of the object
- file.
-
- File segments may be relocated to nonstandard addresses, for
- example by using the `-Ttext', `-Tdata', or `-Tbss' options to
- `ld'. However, some object file formats, such as a.out, do not
- store the starting address of the file segments. In those
- situations, although `ld' relocates the sections correctly, using
- `objdump -h' to list the file section headers cannot show the
- correct addresses. Instead, it shows the usual addresses, which
- are implicit for the target.
-
-`--help'
- Print a summary of the options to `objdump' and exit.
-
-`-i'
-`--info'
- Display a list showing all architectures and object formats
- available for specification with `-b' or `-m'.
-
-`-j NAME'
-`--section=NAME'
- Display information only for section NAME.
-
-`-l'
-`--line-numbers'
- Label the display (using debugging information) with the filename
- and source line numbers corresponding to the object code shown.
- Only useful with `-d' or `-D'.
-
-`-m MACHINE'
-`--architecture=MACHINE'
- Specify that the object files OBJFILE are for architecture
- MACHINE. You can list available architectures using the `-i'
- option.
-
-`-r'
-`--reloc'
- Print the relocation entries of the file. If used with `-d' or
- `-D', the relocations are printed interspersed with the
- disassembly.
-
-`-R'
-`--dynamic-reloc'
- Print the dynamic relocation entries of the file. This is only
- meaningful for dynamic objects, such as certain types of shared
- libraries.
-
-`-s'
-`--full-contents'
- Display the full contents of any sections requested.
-
-`-S'
-`--source'
- Display source code intermixed with disassembly, if possible.
- Implies `-d'.
-
-`--stabs'
- Display the full contents of any sections requested. Display the
- contents of the .stab and .stab.index and .stab.excl sections from
- an ELF file. This is only useful on systems (such as Solaris 2.0)
- in which `.stab' debugging symbol-table entries are carried in an
- ELF section. In most other file formats, debugging symbol-table
- entries are interleaved with linkage symbols, and are visible in
- the `--syms' output.
-
-`--start-address=ADDRESS'
- Start displaying data at the specified address. This affects the
- output of the `-d', `-r' and `-s' options.
-
-`--stop-address=ADDRESS'
- Stop displaying data at the specified address. This affects the
- output of the `-d', `-r' and `-s' options.
-
-`-t'
-`--syms'
- Print the symbol table entries of the file. This is similar to
- the information provided by the `nm' program.
-
-`-T'
-`--dynamic-syms'
- Print the dynamic symbol table entries of the file. This is only
- meaningful for dynamic objects, such as certain types of shared
- libraries. This is similar to the information provided by the `nm'
- program when given the `-D' (`--dynamic') option.
-
-`--version'
- Print the version number of `objdump' and exit.
-
-`-x'
-`--all-header'
- Display all available header information, including the symbol
- table and relocation entries. Using `-x' is equivalent to
- specifying all of `-a -f -h -r -t'.
-
-`-w'
-`--wide'
- Format some lines for output devices that have more than 80
- columns.
-
-
-File: binutils.info, Node: ranlib, Next: size, Prev: objdump, Up: Top
-
-ranlib
-******
-
- ranlib [-vV] ARCHIVE
-
- `ranlib' generates an index to the contents of an archive and stores
-it in the archive. The index lists each symbol defined by a member of
-an archive that is a relocatable object file.
-
- You may use `nm -s' or `nm --print-armap' to list this index.
-
- An archive with such an index speeds up linking to the library and
-allows routines in the library to call each other without regard to
-their placement in the archive.
-
- The GNU `ranlib' program is another form of GNU `ar'; running
-`ranlib' is completely equivalent to executing `ar -s'. *Note ar::.
-
-`-v'
-`-V'
- Show the version number of `ranlib'.
-
-
-File: binutils.info, Node: size, Next: strings, Prev: ranlib, Up: Top
-
-size
-****
-
- size [ -A | -B | --format=COMPATIBILITY ]
- [ --help ] [ -d | -o | -x | --radix=NUMBER ]
- [ --target=BFDNAME ] [ -V | --version ]
- OBJFILE...
-
- The GNU `size' utility lists the section sizes--and the total
-size--for each of the object or archive files OBJFILE in its argument
-list. By default, one line of output is generated for each object file
-or each module in an archive.
-
- OBJFILE... are the object files to be examined.
-
- The command line options have the following meanings:
-
-`-A'
-`-B'
-`--format=COMPATIBILITY'
- Using one of these options, you can choose whether the output from
- GNU `size' resembles output from System V `size' (using `-A', or
- `--format=sysv'), or Berkeley `size' (using `-B', or
- `--format=berkeley'). The default is the one-line format similar
- to Berkeley's.
-
- Here is an example of the Berkeley (default) format of output from
- `size':
- size --format=Berkeley ranlib size
- text data bss dec hex filename
- 294880 81920 11592 388392 5ed28 ranlib
- 294880 81920 11888 388688 5ee50 size
-
- This is the same data, but displayed closer to System V
- conventions:
-
- size --format=SysV ranlib size
- ranlib :
- section size addr
- .text 294880 8192
- .data 81920 303104
- .bss 11592 385024
- Total 388392
-
-
- size :
- section size addr
- .text 294880 8192
- .data 81920 303104
- .bss 11888 385024
- Total 388688
-
-`--help'
- Show a summary of acceptable arguments and options.
-
-`-d'
-`-o'
-`-x'
-`--radix=NUMBER'
- Using one of these options, you can control whether the size of
- each section is given in decimal (`-d', or `--radix=10'); octal
- (`-o', or `--radix=8'); or hexadecimal (`-x', or `--radix=16').
- In `--radix=NUMBER', only the three values (8, 10, 16) are
- supported. The total size is always given in two radices; decimal
- and hexadecimal for `-d' or `-x' output, or octal and hexadecimal
- if you're using `-o'.
-
-`--target=BFDNAME'
- Specify that the object-code format for OBJFILE is BFDNAME. This
- option may not be necessary; `size' can automatically recognize
- many formats. *Note Target Selection::, for more information.
-
-`-V'
-`--version'
- Display the version number of `size'.
-
-
-File: binutils.info, Node: strings, Next: strip, Prev: size, Up: Top
-
-strings
-*******
-
- strings [-afov] [-MIN-LEN] [-n MIN-LEN] [-t RADIX] [-]
- [--all] [--print-file-name] [--bytes=MIN-LEN]
- [--radix=RADIX] [--target=BFDNAME]
- [--help] [--version] FILE...
-
- For each FILE given, GNU `strings' prints the printable character
-sequences that are at least 4 characters long (or the number given with
-the options below) and are followed by an unprintable character. By
-default, it only prints the strings from the initialized and loaded
-sections of object files; for other types of files, it prints the
-strings from the whole file.
-
- `strings' is mainly useful for determining the contents of non-text
-files.
-
-`-a'
-`--all'
-`-'
- Do not scan only the initialized and loaded sections of object
- files; scan the whole files.
-
-`-f'
-`--print-file-name'
- Print the name of the file before each string.
-
-`--help'
- Print a summary of the program usage on the standard output and
- exit.
-
-`-MIN-LEN'
-`-n MIN-LEN'
-`--bytes=MIN-LEN'
- Print sequences of characters that are at least MIN-LEN characters
- long, instead of the default 4.
-
-`-o'
- Like `-t o'. Some other versions of `strings' have `-o' act like
- `-t d' instead. Since we can not be compatible with both ways, we
- simply chose one.
-
-`-t RADIX'
-`--radix=RADIX'
- Print the offset within the file before each string. The single
- character argument specifies the radix of the offset--`o' for
- octal, `x' for hexadecimal, or `d' for decimal.
-
-`--target=BFDNAME'
- Specify an object code format other than your system's default
- format. *Note Target Selection::, for more information.
-
-`-v'
-`--version'
- Print the program version number on the standard output and exit.
-
-
-File: binutils.info, Node: strip, Next: c++filt, Prev: strings, Up: Top
-
-strip
-*****
-
- strip [ -F BFDNAME | --target=BFDNAME | --target=BFDNAME ]
- [ -I BFDNAME | --input-target=BFDNAME ]
- [ -O BFDNAME | --output-target=BFDNAME ]
- [ -s | --strip-all ] [ -S | -g | --strip-debug ]
- [ -K SYMBOLNAME | --keep-symbol=SYMBOLNAME ]
- [ -N SYMBOLNAME | --strip-symbol=SYMBOLNAME ]
- [ -x | --discard-all ] [ -X | --discard-locals ]
- [ -R SECTIONNAME | --remove-section=SECTIONNAME ]
- [ -v | --verbose ] [ -V | --version ] [ --help ]
- OBJFILE...
-
- GNU `strip' discards all symbols from object files OBJFILE. The
-list of object files may include archives. At least one object file
-must be given.
-
- `strip' modifies the files named in its argument, rather than
-writing modified copies under different names.
-
-`-F BFDNAME'
-`--target=BFDNAME'
- Treat the original OBJFILE as a file with the object code format
- BFDNAME, and rewrite it in the same format. *Note Target
- Selection::, for more information.
-
-`--help'
- Show a summary of the options to `strip' and exit.
-
-`-I BFDNAME'
-`--input-target=BFDNAME'
- Treat the original OBJFILE as a file with the object code format
- BFDNAME. *Note Target Selection::, for more information.
-
-`-O BFDNAME'
-`--output-target=BFDNAME'
- Replace OBJFILE with a file in the output format BFDNAME. *Note
- Target Selection::, for more information.
-
-`-R SECTIONNAME'
-`--remove-section=SECTIONNAME'
- Remove any section named SECTIONNAME from the output file. This
- option may be given more than once. Note that using this option
- inappropriately may make the output file unusable.
-
-`-s'
-`--strip-all'
- Remove all symbols.
-
-`-g'
-`-S'
-`--strip-debug'
- Remove debugging symbols only.
-
-`--strip-unneeded'
- Remove all symbols that are not needed for relocation processing.
-
-`-K SYMBOLNAME'
-`--keep-symbol=SYMBOLNAME'
- Keep only symbol SYMBOLNAME from the source file. This option may
- be given more than once.
-
-`-N SYMBOLNAME'
-`--strip-symbol=SYMBOLNAME'
- Remove symbol SYMBOLNAME from the source file. This option may be
- given more than once, and may be combined with strip options other
- than `-K'.
-
-`-x'
-`--discard-all'
- Remove non-global symbols.
-
-`-X'
-`--discard-locals'
- Remove compiler-generated local symbols. (These usually start
- with `L' or `.'.)
-
-`-V'
-`--version'
- Show the version number for `strip'.
-
-`-v'
-`--verbose'
- Verbose output: list all object files modified. In the case of
- archives, `strip -v' lists all members of the archive.
-
-
-File: binutils.info, Node: c++filt, Next: nlmconv, Prev: strip, Up: Top
-
-c++filt
-*******
-
- c++filt [ -_ | --strip-underscores ]
- [ -n | --no-strip-underscores ]
- [ -s FORMAT | --format=FORMAT ]
- [ --help ] [ --version ] [ SYMBOL... ]
-
- The C++ language provides function overloading, which means that you
-can write many functions with the same name (providing each takes
-parameters of different types). All C++ function names are encoded
-into a low-level assembly label (this process is known as "mangling").
-The `c++filt' program does the inverse mapping: it decodes
-("demangles") low-level names into user-level names so that the linker
-can keep these overloaded functions from clashing.
-
- Every alphanumeric word (consisting of letters, digits, underscores,
-dollars, or periods) seen in the input is a potential label. If the
-label decodes into a C++ name, the C++ name replaces the low-level name
-in the output.
-
- You can use `c++filt' to decipher individual symbols:
-
- c++filt SYMBOL
-
- If no SYMBOL arguments are given, `c++filt' reads symbol names from
-the standard input and writes the demangled names to the standard
-output. All results are printed on the standard output.
-
-`-_'
-`--strip-underscores'
- On some systems, both the C and C++ compilers put an underscore in
- front of every name. For example, the C name `foo' gets the
- low-level name `_foo'. This option removes the initial
- underscore. Whether `c++filt' removes the underscore by default
- is target dependent.
-
-`-n'
-`--no-strip-underscores'
- Do not remove the initial underscore.
-
-`-s FORMAT'
-`--format=FORMAT'
- GNU `nm' can decode three different methods of mangling, used by
- different C++ compilers. The argument to this option selects which
- method it uses:
-
- `gnu'
- the one used by the GNU compiler (the default method)
-
- `lucid'
- the one used by the Lucid compiler
-
- `arm'
- the one specified by the C++ Annotated Reference Manual
-
-`--help'
- Print a summary of the options to `c++filt' and exit.
-
-`--version'
- Print the version number of `c++filt' and exit.
-
- *Warning:* `c++filt' is a new utility, and the details of its user
- interface are subject to change in future releases. In particular,
- a command-line option may be required in the the future to decode
- a name passed as an argument on the command line; in other words,
-
- c++filt SYMBOL
-
- may in a future release become
-
- c++filt OPTION SYMBOL
-
-
-File: binutils.info, Node: nlmconv, Next: Selecting The Target System, Prev: c++filt, Up: Top
-
-nlmconv
-*******
-
- `nlmconv' converts a relocatable object file into a NetWare Loadable
-Module.
-
- *Warning:* `nlmconv' is not always built as part of the binary
- utilities, since it is only useful for NLM targets.
-
- nlmconv [ -I BFDNAME | --input-target=BFDNAME ]
- [ -O BFDNAME | --output-target=BFDNAME ]
- [ -T HEADERFILE | --header-file=HEADERFILE ]
- [ -d | --debug] [ -l LINKER | --linker=LINKER ]
- [ -h | --help ] [ -V | --version ]
- INFILE OUTFILE
-
- `nlmconv' converts the relocatable `i386' object file INFILE into
-the NetWare Loadable Module OUTFILE, optionally reading HEADERFILE for
-NLM header information. For instructions on writing the NLM command
-file language used in header files, see the `linkers' section,
-`NLMLINK' in particular, of the `NLM Development and Tools Overview',
-which is part of the NLM Software Developer's Kit ("NLM SDK"),
-available from Novell, Inc. `nlmconv' uses the GNU Binary File
-Descriptor library to read INFILE; see *Note BFD: (ld.info)BFD, for
-more information.
-
- `nlmconv' can perform a link step. In other words, you can list
-more than one object file for input if you list them in the definitions
-file (rather than simply specifying one input file on the command line).
-In this case, `nlmconv' calls the linker for you.
-
-`-I BFDNAME'
-`--input-target=BFDNAME'
- Object format of the input file. `nlmconv' can usually determine
- the format of a given file (so no default is necessary). *Note
- Target Selection::, for more information.
-
-`-O BFDNAME'
-`--output-target=BFDNAME'
- Object format of the output file. `nlmconv' infers the output
- format based on the input format, e.g. for a `i386' input file the
- output format is `nlm32-i386'. *Note Target Selection::, for more
- information.
-
-`-T HEADERFILE'
-`--header-file=HEADERFILE'
- Reads HEADERFILE for NLM header information. For instructions on
- writing the NLM command file language used in header files, see
- see the `linkers' section, of the `NLM Development and Tools
- Overview', which is part of the NLM Software Developer's Kit,
- available from Novell, Inc.
-
-`-d'
-`--debug'
- Displays (on standard error) the linker command line used by
- `nlmconv'.
-
-`-l LINKER'
-`--linker=LINKER'
- Use LINKER for any linking. LINKER can be an abosolute or a
- relative pathname.
-
-`-h'
-`--help'
- Prints a usage summary.
-
-`-V'
-`--version'
- Prints the version number for `nlmconv'.
-
-
-File: binutils.info, Node: Selecting The Target System, Next: Index, Prev: nlmconv, Up: Top
-
-Selecting the target system
-***************************
-
- You can specify three aspects of the target system to the GNU binary
-file utilities, each in several ways:
-
- * the target
-
- * the architecture
-
- * the linker emulation (which applies to the linker only)
-
- In the following summaries, the lists of ways to specify values are
-in order of decreasing precedence. The ways listed first override those
-listed later.
-
- The commands to list valid values only list the values for which the
-programs you are running were configured. If they were configured with
-`--enable-targets=all', the commands list most of the available values,
-but a few are left out; not all targets can be configured in at once
-because some of them can only be configured "native" (on hosts with the
-same type as the target system).
-
-* Menu:
-
-* Target Selection::
-* Architecture Selection::
-* Linker Emulation Selection::
-
-
-File: binutils.info, Node: Target Selection, Next: Architecture Selection, Up: Selecting The Target System
-
-Target Selection
-================
-
- A "target" is an object file format. A given target may be
-supported for multiple architectures (*note Architecture Selection::.).
-A target selection may also have variations for different operating
-systems or architectures.
-
- The command to list valid target values is `objdump -i' (the first
-column of output contains the relevant information).
-
- Some sample values are: `a.out-hp300bsd', `ecoff-littlemips',
-`a.out-sunos-big'.
-
-`objdump' Target
-----------------
-
- Ways to specify:
-
- 1. command line option: `-b' or `--target'
-
- 2. environment variable `GNUTARGET'
-
- 3. deduced from the input file
-
-`objcopy' and `strip' Input Target
-----------------------------------
-
- Ways to specify:
-
- 1. command line options: `-I' or `--input-target', or `-F' or
- `--target'
-
- 2. environment variable `GNUTARGET'
-
- 3. deduced from the input file
-
-`objcopy' and `strip' Output Target
------------------------------------
-
- Ways to specify:
-
- 1. command line options: `-O' or `--output-target', or `-F' or
- `--target'
-
- 2. the input target (see "`objcopy' and `strip' Input Target" above)
-
- 3. environment variable `GNUTARGET'
-
- 4. deduced from the input file
-
-`nm', `size', and `strings' Target
-----------------------------------
-
- Ways to specify:
-
- 1. command line option: `--target'
-
- 2. environment variable `GNUTARGET'
-
- 3. deduced from the input file
-
-Linker Input Target
--------------------
-
- Ways to specify:
-
- 1. command line option: `-b' or `--format' (*note Options:
- (ld.info)Options.)
-
- 2. script command `TARGET' (*note Option Commands: (ld.info)Option
- Commands.)
-
- 3. environment variable `GNUTARGET' (*note Environment:
- (ld.info)Environment.)
-
- 4. the default target of the selected linker emulation (*note Linker
- Emulation Selection::.)
-
-Linker Output Target
---------------------
-
- Ways to specify:
-
- 1. command line option: `-oformat' (*note Options: (ld.info)Options.)
-
- 2. script command `OUTPUT_FORMAT' (*note Option Commands:
- (ld.info)Option Commands.)
-
- 3. the linker input target (see "Linker Input Target" above)
-
-
-File: binutils.info, Node: Architecture Selection, Next: Linker Emulation Selection, Prev: Target Selection, Up: Selecting The Target System
-
-Architecture selection
-======================
-
- An "architecture" is a type of CPU on which an object file is to
-run. Its name may contain a colon, separating the name of the
-processor family from the name of the particular CPU.
-
- The command to list valid architecture values is `objdump -i' (the
-second column contains the relevant information).
-
- Sample values: `m68k:68020', `mips:3000', `sparc'.
-
-`objdump' Architecture
-----------------------
-
- Ways to specify:
-
- 1. command line option: `-m' or `--architecture'
-
- 2. deduced from the input file
-
-`objcopy', `nm', `size', `strings' Architecture
------------------------------------------------
-
- Ways to specify:
-
- 1. deduced from the input file
-
-Linker Input Architecture
--------------------------
-
- Ways to specify:
-
- 1. deduced from the input file
-
-Linker Output Architecture
---------------------------
-
- Ways to specify:
-
- 1. script command `OUTPUT_ARCH' (*note Option Commands:
- (ld.info)Option Commands.)
-
- 2. the default architecture from the linker output target (*note
- Target Selection::.)
-
-
-File: binutils.info, Node: Linker Emulation Selection, Prev: Architecture Selection, Up: Selecting The Target System
-
-Linker emulation selection
-==========================
-
- A linker "emulation" is a "personality" of the linker, which gives
-the linker default values for the other aspects of the target system.
-In particular, it consists of
-
- * the linker script
-
- * the target
-
- * several "hook" functions that are run at certain stages of the
- linking process to do special things that some targets require
-
- The command to list valid linker emulation values is `ld -V'.
-
- Sample values: `hp300bsd', `mipslit', `sun4'.
-
- Ways to specify:
-
- 1. command line option: `-m' (*note Options: (ld.info)Options.)
-
- 2. environment variable `LDEMULATION'
-
- 3. compiled-in `DEFAULT_EMULATION' from `Makefile', which comes from
- `EMUL' in `config/TARGET.mt'
-
-
-File: binutils.info, Node: Index, Prev: Selecting The Target System, Up: Top
-
-Index
-*****
-
-* Menu:
-
-* .stab: objdump.
-* ar compatibility: ar.
-* nm compatibility: nm.
-* nm compatibility: nm.
-* nm format: nm.
-* nm format: nm.
-* size display format: size.
-* size number format: size.
-* all header information, object file: objdump.
-* ar: ar.
-* architecture: objdump.
-* architectures available: objdump.
-* archive contents: ranlib.
-* archive headers: objdump.
-* archives: ar.
-* c++filt: c++filt.
-* collections of files: ar.
-* compatibility, ar: ar.
-* contents of archive: ar cmdline.
-* creating archives: ar cmdline.
-* dates in archive: ar cmdline.
-* debug symbols: objdump.
-* debugging symbols: nm.
-* deleting from archive: ar cmdline.
-* demangling C++ symbols: c++filt.
-* demangling C++ symbols: nm.
-* disassembling object code: objdump.
-* disassembly, with source: objdump.
-* discarding symbols: strip.
-* dynamic relocation entries, in object file: objdump.
-* dynamic symbol table entries, printing: objdump.
-* dynamic symbols: nm.
-* ELF object file format: objdump.
-* external symbols: nm.
-* external symbols: nm.
-* extract from archive: ar cmdline.
-* file name: nm.
-* header information, all: objdump.
-* input file name: nm.
-* libraries: ar.
-* listings strings: strings.
-* machine instructions: objdump.
-* moving in archive: ar cmdline.
-* MRI compatibility, ar: ar scripts.
-* name duplication in archive: ar cmdline.
-* name length: ar.
-* nm: nm.
-* objdump: objdump.
-* object code format: size.
-* object code format: nm.
-* object code format: objdump.
-* object code format: strings.
-* object file header: objdump.
-* object file information: objdump.
-* object file sections: objdump.
-* object formats available: objdump.
-* operations on archive: ar cmdline.
-* printing from archive: ar cmdline.
-* printing strings: strings.
-* quick append to archive: ar cmdline.
-* radix for section sizes: size.
-* ranlib: ranlib.
-* relative placement in archive: ar cmdline.
-* relocation entries, in object file: objdump.
-* removing symbols: strip.
-* repeated names in archive: ar cmdline.
-* replacement in archive: ar cmdline.
-* scripts, ar: ar scripts.
-* section headers: objdump.
-* section information: objdump.
-* section sizes: size.
-* sections, full contents: objdump.
-* size: size.
-* sorting symbols: nm.
-* source disassembly: objdump.
-* source file name: nm.
-* source filenames for object files: objdump.
-* stab: objdump.
-* start-address: objdump.
-* stop-address: objdump.
-* strings: strings.
-* strings, printing: strings.
-* strip: strip.
-* symbol index: ar.
-* symbol index: ranlib.
-* symbol index, listing: nm.
-* symbol table entries, printing: objdump.
-* symbols: nm.
-* symbols, discarding: strip.
-* undefined symbols: nm.
-* Unix compatibility, ar: ar cmdline.
-* updating an archive: ar cmdline.
-* version: Top.
-* wide output, printing: objdump.
-* writing archive index: ar cmdline.
-
-
-
-Tag Table:
-Node: Top967
-Node: ar1892
-Node: ar cmdline4058
-Node: ar scripts10818
-Node: nm16499
-Node: objcopy20615
-Node: objdump28342
-Node: ranlib34411
-Node: size35145
-Node: strings37812
-Node: strip39637
-Node: c++filt42313
-Node: nlmconv44872
-Node: Selecting The Target System47495
-Node: Target Selection48503
-Node: Architecture Selection50751
-Node: Linker Emulation Selection51983
-Node: Index52861
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/binutils/gmalloc.c b/gnu/usr.bin/binutils/binutils/gmalloc.c
deleted file mode 100644
index c259a5f1441..00000000000
--- a/gnu/usr.bin/binutils/binutils/gmalloc.c
+++ /dev/null
@@ -1,1116 +0,0 @@
-
-/* gmalloc.c - THIS FILE IS AUTOMAGICALLY GENERATED SO DON'T EDIT IT. */
-
-/* Single-file skeleton for GNU malloc.
- Copyright 1989 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#define __ONEFILE
-
-/* DO NOT DELETE THIS LINE -- ansidecl.h INSERTED HERE. */
-/* Copyright (C) 1989 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 1, or (at your option)
-any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with the GNU C Library; see the file COPYING. If not, write to
-the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-/* ANSI and traditional C compatibility macros
-
- ANSI C is assumed if __STDC__ is #defined.
-
- Macros
- PTR - Generic pointer type
- LONG_DOUBLE - `long double' type
- CONST - `const' keyword
- VOLATILE - `volatile' keyword
- SIGNED - `signed' keyword
- PTRCONST - Generic const pointer (void *const)
-
- EXFUN(name, prototype) - declare external function NAME
- with prototype PROTOTYPE
- DEFUN(name, arglist, args) - define function NAME with
- args ARGLIST of types in ARGS
- DEFUN_VOID(name) - define function NAME with no args
- AND - argument separator for ARGS
- NOARGS - null arglist
- DOTS - `...' in args
-
- For example:
- extern int EXFUN(printf, (CONST char *format DOTS));
- int DEFUN(fprintf, (stream, format),
- FILE *stream AND CONST char *format DOTS) { ... }
- void DEFUN_VOID(abort) { ... }
-*/
-
-#ifndef _ANSIDECL_H
-
-#define _ANSIDECL_H 1
-
-
-/* Every source file includes this file,
- so they will all get the switch for lint. */
-/* LINTLIBRARY */
-
-
-#ifdef __STDC__
-
-#define PTR void *
-#define PTRCONST void *CONST
-#define LONG_DOUBLE long double
-
-#define AND ,
-#define NOARGS void
-#define CONST const
-#define VOLATILE volatile
-#define SIGNED signed
-#define DOTS , ...
-
-#define EXFUN(name, proto) name proto
-#define DEFUN(name, arglist, args) name(args)
-#define DEFUN_VOID(name) name(NOARGS)
-
-#else /* Not ANSI C. */
-
-#define PTR char *
-#define PTRCONST PTR
-#define LONG_DOUBLE double
-
-#define AND ;
-#define NOARGS
-#define CONST
-#define VOLATILE
-#define SIGNED
-#define DOTS
-
-#define EXFUN(name, proto) name()
-#define DEFUN(name, arglist, args) name arglist args;
-#define DEFUN_VOID(name) name()
-
-#endif /* ANSI C. */
-
-
-#endif /* ansidecl.h */
-
-#ifdef __STDC__
-#include <limits.h>
-#else
-/* DO NOT DELETE THIS LINE -- limits.h INSERTED HERE. */
-/* Number of bits in a `char'. */
-#define CHAR_BIT 8
-
-/* No multibyte characters supported yet. */
-#define MB_LEN_MAX 1
-
-/* Minimum and maximum values a `signed char' can hold. */
-#define SCHAR_MIN -128
-#define SCHAR_MAX 127
-
-/* Maximum value an `unsigned char' can hold. (Minimum is 0). */
-#define UCHAR_MAX 255U
-
-/* Minimum and maximum values a `char' can hold. */
-#ifdef __CHAR_UNSIGNED__
-#define CHAR_MIN 0
-#define CHAR_MAX 255U
-#else
-#define CHAR_MIN -128
-#define CHAR_MAX 127
-#endif
-
-/* Minimum and maximum values a `signed short int' can hold. */
-#define SHRT_MIN -32768
-#define SHRT_MAX 32767
-
-/* Maximum value an `unsigned short int' can hold. (Minimum is 0). */
-#define USHRT_MAX 65535U
-
-/* Minimum and maximum values a `signed int' can hold. */
-#define INT_MIN -2147483648
-#define INT_MAX 2147483647
-
-/* Maximum value an `unsigned int' can hold. (Minimum is 0). */
-#define UINT_MAX 4294967295U
-
-/* Minimum and maximum values a `signed long int' can hold.
- (Same as `int'). */
-#define LONG_MIN (-LONG_MAX-1)
-#define LONG_MAX 2147483647
-
-/* Maximum value an `unsigned long int' can hold. (Minimum is 0). */
-#define ULONG_MAX 4294967295U
-#endif
-
-#ifdef __STDC__
-#include <stddef.h>
-#else
-/* DO NOT DELETE THIS LINE -- stddef.h INSERTED HERE. */
-#ifndef _STDDEF_H
-#define _STDDEF_H
-
-/* Signed type of difference of two pointers. */
-
-typedef long ptrdiff_t;
-
-/* Unsigned type of `sizeof' something. */
-
-#ifndef _SIZE_T /* in case <sys/types.h> has defined it. */
-#define _SIZE_T
-typedef unsigned long size_t;
-#endif /* _SIZE_T */
-
-/* A null pointer constant. */
-
-#undef NULL /* in case <stdio.h> has defined it. */
-#define NULL 0
-
-/* Offset of member MEMBER in a struct of type TYPE. */
-
-#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
-
-#endif /* _STDDEF_H */
-#endif
-
-/* DO NOT DELETE THIS LINE -- stdlib.h INSERTED HERE. */
-/* Fake stdlib.h supplying the stuff needed by malloc. */
-
-#ifndef __ONEFILE
-#include <stddef.h>
-#endif
-
-extern void EXFUN(abort, (void));
-extern void EXFUN(free, (PTR));
-extern PTR EXFUN(malloc, (size_t));
-extern PTR EXFUN(realloc, (PTR, size_t));
-
-/* DO NOT DELETE THIS LINE -- string.h INSERTED HERE. */
-/* Fake string.h supplying stuff used by malloc. */
-#ifndef __ONEFILE
-#include <stddef.h>
-#endif
-
-extern PTR EXFUN(memcpy, (PTR, PTR, size_t));
-extern PTR EXFUN(memset, (PTR, int, size_t));
-#define memmove memcpy
-
-#define _MALLOC_INTERNAL
-/* DO NOT DELETE THIS LINE -- malloc.h INSERTED HERE. */
-/* Declarations for `malloc' and friends.
- Copyright 1990 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#ifndef _MALLOC_H
-
-#define _MALLOC_H 1
-
-#ifndef __ONEFILE
-#define __need_NULL
-#define __need_size_t
-#define __need_ptrdiff_t
-#include <stddef.h>
-#endif
-
-#ifdef _MALLOC_INTERNAL
-
-#ifndef __ONEFILE
-#include <limits.h>
-#endif
-
-/* The allocator divides the heap into blocks of fixed size; large
- requests receive one or more whole blocks, and small requests
- receive a fragment of a block. Fragment sizes are powers of two,
- and all fragments of a block are the same size. When all the
- fragments in a block have been freed, the block itself is freed. */
-#define INT_BIT (CHAR_BIT * sizeof(int))
-#define BLOCKLOG (INT_BIT > 16 ? 12 : 9)
-#define BLOCKSIZE (1 << BLOCKLOG)
-#define BLOCKIFY(SIZE) (((SIZE) + BLOCKSIZE - 1) / BLOCKSIZE)
-
-/* Determine the amount of memory spanned by the initial heap table
- (not an absolute limit). */
-#define HEAP (INT_BIT > 16 ? 4194304 : 65536)
-
-/* Number of contiguous free blocks allowed to build up at the end of
- memory before they will be returned to the system. */
-#define FINAL_FREE_BLOCKS 8
-
-/* Where to start searching the free list when looking for new memory.
- The two possible values are 0 and _heapindex. Starting at 0 seems
- to reduce total memory usage, while starting at _heapindex seems to
- run faster. */
-#define MALLOC_SEARCH_START _heapindex
-
-/* Data structure giving per-block information. */
-typedef union
- {
- /* Heap information for a busy block. */
- struct
- {
- /* Zero for a large block, or positive giving the
- logarithm to the base two of the fragment size. */
- int type;
- union
- {
- struct
- {
- size_t nfree; /* Free fragments in a fragmented block. */
- size_t first; /* First free fragment of the block. */
- } frag;
- /* Size (in blocks) of a large cluster. */
- size_t size;
- } info;
- } busy;
- /* Heap information for a free block (that may be the first of
- a free cluster). */
- struct
- {
- size_t size; /* Size (in blocks) of a free cluster. */
- size_t next; /* Index of next free cluster. */
- size_t prev; /* Index of previous free cluster. */
- } free;
- } malloc_info;
-
-/* Pointer to first block of the heap. */
-extern char *_heapbase;
-
-/* Table indexed by block number giving per-block information. */
-extern malloc_info *_heapinfo;
-
-/* Address to block number and vice versa. */
-#define BLOCK(A) (((char *) (A) - _heapbase) / BLOCKSIZE + 1)
-#define ADDRESS(B) ((PTR) (((B) - 1) * BLOCKSIZE + _heapbase))
-
-/* Current search index for the heap table. */
-extern size_t _heapindex;
-
-/* Limit of valid info table indices. */
-extern size_t _heaplimit;
-
-/* Doubly linked lists of free fragments. */
-struct list
- {
- struct list *next;
- struct list *prev;
- };
-
-/* Free list headers for each fragment size. */
-extern struct list _fraghead[];
-
-/* Instrumentation. */
-extern size_t _chunks_used;
-extern size_t _bytes_used;
-extern size_t _chunks_free;
-extern size_t _bytes_free;
-
-/* Internal version of free() used in morecore(). */
-extern void EXFUN(__free, (PTR __ptr));
-
-#endif /* _MALLOC_INTERNAL. */
-
-/* Underlying allocation function; successive calls should
- return contiguous pieces of memory. */
-extern PTR EXFUN((*__morecore), (ptrdiff_t __size));
-
-/* Default value of previous. */
-extern PTR EXFUN(__default_morecore, (ptrdiff_t __size));
-
-/* Flag whether malloc has been called. */
-extern int __malloc_initialized;
-
-/* Hooks for debugging versions. */
-extern void EXFUN((*__free_hook), (PTR __ptr));
-extern PTR EXFUN((*__malloc_hook), (size_t __size));
-extern PTR EXFUN((*__realloc_hook), (PTR __ptr, size_t __size));
-
-/* Activate a standard collection of debugging hooks. */
-extern void EXFUN(mcheck, (void EXFUN((*func), (void))));
-
-/* Statistics available to the user. */
-struct mstats
- {
- size_t bytes_total; /* Total size of the heap. */
- size_t chunks_used; /* Chunks allocated by the user. */
- size_t bytes_used; /* Byte total of user-allocated chunks. */
- size_t chunks_free; /* Chunks in the free list. */
- size_t bytes_free; /* Byte total of chunks in the free list. */
- };
-
-/* Pick up the current statistics. */
-extern struct mstats EXFUN(mstats, (NOARGS));
-
-#endif /* malloc.h */
-
-/* DO NOT DELETE THIS LINE -- free.c INSERTED HERE. */
-/* Free a block of memory allocated by `malloc'.
- Copyright 1990 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#ifndef __ONEFILE
-#include "ansidecl.h"
-#include <stddef.h>
-#include <stdlib.h>
-
-#define _MALLOC_INTERNAL
-#include "malloc.h"
-#endif /* __ONEFILE */
-
-/* Debugging hook for free. */
-void EXFUN((*__free_hook), (PTR __ptr));
-
-/* Return memory to the heap. Like free() but don't call a __free_hook
- if there is one. */
-void
-DEFUN(__free, (ptr), PTR ptr)
-{
- int type;
- size_t block, blocks;
- register size_t i;
- struct list *prev, *next;
-
- block = BLOCK(ptr);
-
- type = _heapinfo[block].busy.type;
- switch (type)
- {
- case 0:
- /* Get as many statistics as early as we can. */
- --_chunks_used;
- _bytes_used -= _heapinfo[block].busy.info.size * BLOCKSIZE;
- _bytes_free += _heapinfo[block].busy.info.size * BLOCKSIZE;
-
- /* Find the free cluster previous to this one in the free list.
- Start searching at the last block referenced; this may benefit
- programs with locality of allocation. */
- i = _heapindex;
- if (i > block)
- while (i > block)
- i = _heapinfo[i].free.prev;
- else
- {
- do
- i = _heapinfo[i].free.next;
- while (i > 0 && i < block);
- i = _heapinfo[i].free.prev;
- }
-
- /* Determine how to link this block into the free list. */
- if (block == i + _heapinfo[i].free.size)
- {
- /* Coalesce this block with its predecessor. */
- _heapinfo[i].free.size += _heapinfo[block].busy.info.size;
- block = i;
- }
- else
- {
- /* Really link this block back into the free list. */
- _heapinfo[block].free.size = _heapinfo[block].busy.info.size;
- _heapinfo[block].free.next = _heapinfo[i].free.next;
- _heapinfo[block].free.prev = i;
- _heapinfo[i].free.next = block;
- _heapinfo[_heapinfo[block].free.next].free.prev = block;
- ++_chunks_free;
- }
-
- /* Now that the block is linked in, see if we can coalesce it
- with its successor (by deleting its successor from the list
- and adding in its size). */
- if (block + _heapinfo[block].free.size == _heapinfo[block].free.next)
- {
- _heapinfo[block].free.size
- += _heapinfo[_heapinfo[block].free.next].free.size;
- _heapinfo[block].free.next
- = _heapinfo[_heapinfo[block].free.next].free.next;
- _heapinfo[_heapinfo[block].free.next].free.prev = block;
- --_chunks_free;
- }
-
- /* Now see if we can return stuff to the system. */
- blocks = _heapinfo[block].free.size;
- if (blocks >= FINAL_FREE_BLOCKS && block + blocks == _heaplimit
- && (*__morecore)(0) == ADDRESS(block + blocks))
- {
- register size_t bytes = blocks * BLOCKSIZE;
- _heaplimit -= blocks;
- (*__morecore)(- bytes);
- _heapinfo[_heapinfo[block].free.prev].free.next
- = _heapinfo[block].free.next;
- _heapinfo[_heapinfo[block].free.next].free.prev
- = _heapinfo[block].free.prev;
- block = _heapinfo[block].free.prev;
- --_chunks_free;
- _bytes_free -= bytes;
- }
-
- /* Set the next search to begin at this block. */
- _heapindex = block;
- break;
-
- default:
- /* Do some of the statistics. */
- --_chunks_used;
- _bytes_used -= 1 << type;
- ++_chunks_free;
- _bytes_free += 1 << type;
-
- /* Get the address of the first free fragment in this block. */
- prev = (struct list *) ((char *) ADDRESS(block) +
- (_heapinfo[block].busy.info.frag.first << type));
-
- if (_heapinfo[block].busy.info.frag.nfree == (BLOCKSIZE >> type) - 1)
- {
- /* If all fragments of this block are free, remove them
- from the fragment list and free the whole block. */
- next = prev;
- for (i = 1; i < BLOCKSIZE >> type; ++i)
- next = next->next;
- prev->prev->next = next;
- if (next != NULL)
- next->prev = prev->prev;
- _heapinfo[block].busy.type = 0;
- _heapinfo[block].busy.info.size = 1;
-
- /* Keep the statistics accurate. */
- ++_chunks_used;
- _bytes_used += BLOCKSIZE;
- _chunks_free -= BLOCKSIZE >> type;
- _bytes_free -= BLOCKSIZE;
-
- free(ADDRESS(block));
- }
- else if (_heapinfo[block].busy.info.frag.nfree != 0)
- {
- /* If some fragments of this block are free, link this
- fragment into the fragment list after the first free
- fragment of this block. */
- next = (struct list *) ptr;
- next->next = prev->next;
- next->prev = prev;
- prev->next = next;
- if (next->next != NULL)
- next->next->prev = next;
- ++_heapinfo[block].busy.info.frag.nfree;
- }
- else
- {
- /* No fragments of this block are free, so link this
- fragment into the fragment list and announce that
- it is the first free fragment of this block. */
- prev = (struct list *) ptr;
- _heapinfo[block].busy.info.frag.nfree = 1;
- _heapinfo[block].busy.info.frag.first = (unsigned int)
- (((char *) ptr - (char *) NULL) % BLOCKSIZE >> type);
- prev->next = _fraghead[type].next;
- prev->prev = &_fraghead[type];
- prev->prev->next = prev;
- if (prev->next != NULL)
- prev->next->prev = prev;
- }
- break;
- }
-}
-
-/* Return memory to the heap. */
-void
-DEFUN(free, (ptr), PTR ptr)
-{
- if (ptr == NULL)
- return;
-
- if (__free_hook != NULL)
- (*__free_hook)(ptr);
- else
- __free (ptr);
-}
-
-/* DO NOT DELETE THIS LINE -- malloc.c INSERTED HERE. */
-/* Memory allocator `malloc'.
- Copyright 1990 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#ifndef __ONEFILE
-#include "ansidecl.h"
-#include <stddef.h>
-#include <stdlib.h>
-#include <string.h>
-
-#define _MALLOC_INTERNAL
-#include "malloc.h"
-#endif /* __ONEFILE */
-
-/* How to really get more memory. */
-PTR EXFUN((*__morecore), (ptrdiff_t __size)) = __default_morecore;
-
-/* Debugging hook for `malloc'. */
-PTR EXFUN((*__malloc_hook), (size_t __size));
-
-/* Pointer to the base of the first block. */
-char *_heapbase;
-
-/* Block information table. Allocated with align/__free (not malloc/free). */
-malloc_info *_heapinfo;
-
-/* Number of info entries. */
-static size_t heapsize;
-
-/* Search index in the info table. */
-size_t _heapindex;
-
-/* Limit of valid info table indices. */
-size_t _heaplimit;
-
-/* Free lists for each fragment size. */
-struct list _fraghead[BLOCKLOG];
-
-/* Instrumentation. */
-size_t _chunks_used;
-size_t _bytes_used;
-size_t _chunks_free;
-size_t _bytes_free;
-
-/* Are you experienced? */
-int __malloc_initialized;
-
-/* Aligned allocation. */
-static PTR
-DEFUN(align, (size), size_t size)
-{
- PTR result;
- unsigned int adj;
-
- result = (*__morecore)(size);
- adj = (unsigned int) ((char *) result - (char *) NULL) % BLOCKSIZE;
- if (adj != 0)
- {
- adj = BLOCKSIZE - adj;
- (void) (*__morecore)(adj);
- result = (char *) result + adj;
- }
- return result;
-}
-
-/* Set everything up and remember that we have. */
-static int
-DEFUN_VOID(initialize)
-{
- heapsize = HEAP / BLOCKSIZE;
- _heapinfo = (malloc_info *) align(heapsize * sizeof(malloc_info));
- if (_heapinfo == NULL)
- return 0;
- memset(_heapinfo, 0, heapsize * sizeof(malloc_info));
- _heapinfo[0].free.size = 0;
- _heapinfo[0].free.next = _heapinfo[0].free.prev = 0;
- _heapindex = 0;
- _heapbase = (char *) _heapinfo;
- __malloc_initialized = 1;
- return 1;
-}
-
-/* Get neatly aligned memory, initializing or
- growing the heap info table as necessary. */
-static PTR
-DEFUN(morecore, (size), size_t size)
-{
- PTR result;
- malloc_info *newinfo, *oldinfo;
- size_t newsize;
-
- result = align(size);
- if (result == NULL)
- return NULL;
-
- /* Check if we need to grow the info table. */
- if (BLOCK((char *) result + size) > heapsize)
- {
- newsize = heapsize;
- while (BLOCK((char *) result + size) > newsize)
- newsize *= 2;
- newinfo = (malloc_info *) align(newsize * sizeof(malloc_info));
- if (newinfo == NULL)
- {
- (*__morecore)(- size);
- return NULL;
- }
- memset(newinfo, 0, newsize * sizeof(malloc_info));
- memcpy(newinfo, _heapinfo, heapsize * sizeof(malloc_info));
- oldinfo = _heapinfo;
- newinfo[BLOCK(oldinfo)].busy.type = 0;
- newinfo[BLOCK(oldinfo)].busy.info.size
- = BLOCKIFY(heapsize * sizeof(malloc_info));
- _heapinfo = newinfo;
- __free(oldinfo);
- heapsize = newsize;
- }
-
- _heaplimit = BLOCK((char *) result + size);
- return result;
-}
-
-/* Allocate memory from the heap. */
-PTR
-DEFUN(malloc, (size), size_t size)
-{
- PTR result;
- size_t block, blocks, lastblocks, start;
- register size_t i;
- struct list *next;
-
- if (size == 0)
- return NULL;
-
- if (__malloc_hook != NULL)
- return (*__malloc_hook)(size);
-
- if (!__malloc_initialized)
- if (!initialize())
- return NULL;
-
- if (size < sizeof(struct list))
- size = sizeof(struct list);
-
- /* Determine the allocation policy based on the request size. */
- if (size <= BLOCKSIZE / 2)
- {
- /* Small allocation to receive a fragment of a block.
- Determine the logarithm to base two of the fragment size. */
- register size_t log = 1;
- --size;
- while ((size /= 2) != 0)
- ++log;
-
- /* Look in the fragment lists for a
- free fragment of the desired size. */
- next = _fraghead[log].next;
- if (next != NULL)
- {
- /* There are free fragments of this size.
- Pop a fragment out of the fragment list and return it.
- Update the block's nfree and first counters. */
- result = (PTR) next;
- next->prev->next = next->next;
- if (next->next != NULL)
- next->next->prev = next->prev;
- block = BLOCK(result);
- if (--_heapinfo[block].busy.info.frag.nfree != 0)
- _heapinfo[block].busy.info.frag.first = (unsigned int)
- (((char *) next->next - (char *) NULL) % BLOCKSIZE) >> log;
-
- /* Update the statistics. */
- ++_chunks_used;
- _bytes_used += 1 << log;
- --_chunks_free;
- _bytes_free -= 1 << log;
- }
- else
- {
- /* No free fragments of the desired size, so get a new block
- and break it into fragments, returning the first. */
- result = malloc(BLOCKSIZE);
- if (result == NULL)
- return NULL;
-
- /* Link all fragments but the first into the free list. */
- for (i = 1; i < BLOCKSIZE >> log; ++i)
- {
- next = (struct list *) ((char *) result + (i << log));
- next->next = _fraghead[log].next;
- next->prev = &_fraghead[log];
- next->prev->next = next;
- if (next->next != NULL)
- next->next->prev = next;
- }
-
- /* Initialize the nfree and first counters for this block. */
- block = BLOCK(result);
- _heapinfo[block].busy.type = log;
- _heapinfo[block].busy.info.frag.nfree = i - 1;
- _heapinfo[block].busy.info.frag.first = i - 1;
-
- _chunks_free += (BLOCKSIZE >> log) - 1;
- _bytes_free += BLOCKSIZE - (1 << log);
- }
- }
- else
- {
- /* Large allocation to receive one or more blocks.
- Search the free list in a circle starting at the last place visited.
- If we loop completely around without finding a large enough
- space we will have to get more memory from the system. */
- blocks = BLOCKIFY(size);
- start = block = MALLOC_SEARCH_START;
- while (_heapinfo[block].free.size < blocks)
- {
- block = _heapinfo[block].free.next;
- if (block == start)
- {
- /* Need to get more from the system. Check to see if
- the new core will be contiguous with the final free
- block; if so we don't need to get as much. */
- block = _heapinfo[0].free.prev;
- lastblocks = _heapinfo[block].free.size;
- if (_heaplimit != 0 && block + lastblocks == _heaplimit &&
- (*__morecore)(0) == ADDRESS(block + lastblocks) &&
- (morecore((blocks - lastblocks) * BLOCKSIZE)) != NULL)
- {
- _heapinfo[block].free.size = blocks;
- _bytes_free += (blocks - lastblocks) * BLOCKSIZE;
- continue;
- }
- result = morecore(blocks * BLOCKSIZE);
- if (result == NULL)
- return NULL;
- block = BLOCK(result);
- _heapinfo[block].busy.type = 0;
- _heapinfo[block].busy.info.size = blocks;
- ++_chunks_used;
- _bytes_used += blocks * BLOCKSIZE;
- return result;
- }
- }
-
- /* At this point we have found a suitable free list entry.
- Figure out how to remove what we need from the list. */
- result = ADDRESS(block);
- if (_heapinfo[block].free.size > blocks)
- {
- /* The block we found has a bit left over,
- so relink the tail end back into the free list. */
- _heapinfo[block + blocks].free.size
- = _heapinfo[block].free.size - blocks;
- _heapinfo[block + blocks].free.next
- = _heapinfo[block].free.next;
- _heapinfo[block + blocks].free.prev
- = _heapinfo[block].free.prev;
- _heapinfo[_heapinfo[block].free.prev].free.next
- = _heapinfo[_heapinfo[block].free.next].free.prev
- = _heapindex = block + blocks;
- }
- else
- {
- /* The block exactly matches our requirements,
- so just remove it from the list. */
- _heapinfo[_heapinfo[block].free.next].free.prev
- = _heapinfo[block].free.prev;
- _heapinfo[_heapinfo[block].free.prev].free.next
- = _heapindex = _heapinfo[block].free.next;
- --_chunks_free;
- }
-
- _heapinfo[block].busy.type = 0;
- _heapinfo[block].busy.info.size = blocks;
- ++_chunks_used;
- _bytes_used += blocks * BLOCKSIZE;
- _bytes_free -= blocks * BLOCKSIZE;
- }
-
- return result;
-}
-
-/* DO NOT DELETE THIS LINE -- realloc.c INSERTED HERE. */
-/* Change the size of a block allocated by `malloc'.
- Copyright 1990 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#ifndef __ONEFILE
-#include "ansidecl.h"
-#include <stdlib.h>
-#include <string.h>
-
-#define _MALLOC_INTERNAL
-#include "malloc.h"
-#endif /* __ONEFILE */
-
-#define MIN(A, B) ((A) < (B) ? (A) : (B))
-
-/* Debugging hook for realloc. */
-PTR EXFUN((*__realloc_hook), (PTR __ptr, size_t __size));
-
-/* Resize the given region to the new size, returning a pointer
- to the (possibly moved) region. This is optimized for speed;
- some benchmarks seem to indicate that greater compactness is
- achieved by unconditionally allocating and copying to a
- new region. This module has incestuous knowledge of the
- internals of both free and malloc. */
-PTR
-DEFUN(realloc, (ptr, size), PTR ptr AND size_t size)
-{
- PTR result;
- int type;
- size_t block, blocks, oldlimit;
-
- if (size == 0)
- {
- free(ptr);
- return NULL;
- }
- else if (ptr == NULL)
- return malloc(size);
-
- if (__realloc_hook != NULL)
- return (*__realloc_hook)(ptr, size);
-
- block = BLOCK(ptr);
-
- type = _heapinfo[block].busy.type;
- switch (type)
- {
- case 0:
- /* Maybe reallocate a large block to a small fragment. */
- if (size <= BLOCKSIZE / 2)
- {
- result = malloc(size);
- if (result != NULL)
- {
- memcpy(result, ptr, size);
- free(ptr);
- return result;
- }
- }
-
- /* The new size is a large allocation as well;
- see if we can hold it in place. */
- blocks = BLOCKIFY(size);
- if (blocks < _heapinfo[block].busy.info.size)
- {
- /* The new size is smaller; return
- excess memory to the free list. */
- _heapinfo[block + blocks].busy.type = 0;
- _heapinfo[block + blocks].busy.info.size
- = _heapinfo[block].busy.info.size - blocks;
- _heapinfo[block].busy.info.size = blocks;
- free(ADDRESS(block + blocks));
- result = ptr;
- }
- else if (blocks == _heapinfo[block].busy.info.size)
- /* No size change necessary. */
- result = ptr;
- else
- {
- /* Won't fit, so allocate a new region that will.
- Free the old region first in case there is sufficient
- adjacent free space to grow without moving. */
- blocks = _heapinfo[block].busy.info.size;
- /* Prevent free from actually returning memory to the system. */
- oldlimit = _heaplimit;
- _heaplimit = 0;
- free(ptr);
- _heaplimit = oldlimit;
- result = malloc(size);
- if (result == NULL)
- {
- (void) malloc(blocks * BLOCKSIZE);
- return NULL;
- }
- if (ptr != result)
- memmove(result, ptr, blocks * BLOCKSIZE);
- }
- break;
-
- default:
- /* Old size is a fragment; type is logarithm
- to base two of the fragment size. */
- if (size > 1 << (type - 1) && size <= 1 << type)
- /* The new size is the same kind of fragment. */
- result = ptr;
- else
- {
- /* The new size is different; allocate a new space,
- and copy the lesser of the new size and the old. */
- result = malloc(size);
- if (result == NULL)
- return NULL;
- memcpy(result, ptr, MIN(size, 1 << type));
- free(ptr);
- }
- break;
- }
-
- return result;
-}
-
-/* DO NOT DELETE THIS LINE -- unix.c INSERTED HERE. */
-/* unix.c - get more memory with a UNIX system call.
- Copyright 1990 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#ifndef __ONEFILE
-#include "ansidecl.h"
-#include <stddef.h>
-
-#define _MALLOC_INTERNAL
-#include "malloc.h"
-#endif /* __ONEFILE */
-
-extern PTR EXFUN(sbrk, (ptrdiff_t size));
-
-PTR
-DEFUN(__default_morecore, (size), ptrdiff_t size)
-{
- PTR result;
-
- result = sbrk(size);
- if (result == (PTR) -1)
- return NULL;
- return result;
-}
-
-#define __getpagesize getpagesize
-/* DO NOT DELETE THIS LINE -- valloc.c INSERTED HERE. */
-/* Allocate memory on a page boundary.
- Copyright 1990 Free Software Foundation
- Written May 1989 by Mike Haertel.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- The author may be reached (Email) at the address mike@ai.mit.edu,
- or (US mail) as Mike Haertel c/o Free Software Foundation. */
-
-#ifndef __ONEFILE
-#include "ansidecl.h"
-#include <stdlib.h>
-#endif /* __ONEFILE */
-
-extern size_t EXFUN(__getpagesize, (NOARGS));
-
-static size_t pagesize;
-
-PTR
-DEFUN(valloc, (size), size_t size)
-{
- PTR result;
- unsigned int adj;
-
- if (pagesize == 0)
- pagesize = __getpagesize();
-
- result = malloc(size + pagesize);
- if (result == NULL)
- return NULL;
- adj = (unsigned int) ((char *) result - (char *) NULL) % pagesize;
- if (adj != 0)
- result = (char *) result + pagesize - adj;
- return result;
-}
diff --git a/gnu/usr.bin/binutils/binutils/nlmheader.c b/gnu/usr.bin/binutils/binutils/nlmheader.c
deleted file mode 100644
index c27f66292bf..00000000000
--- a/gnu/usr.bin/binutils/binutils/nlmheader.c
+++ /dev/null
@@ -1,1931 +0,0 @@
-
-/* A Bison parser, made from ./nlmheader.y with Bison version GNU Bison version 1.24
- */
-
-#define YYBISON 1 /* Identify Bison output. */
-
-#define CHECK 258
-#define CODESTART 259
-#define COPYRIGHT 260
-#define CUSTOM 261
-#define DATE 262
-#define DEBUG 263
-#define DESCRIPTION 264
-#define EXIT 265
-#define EXPORT 266
-#define FLAG_ON 267
-#define FLAG_OFF 268
-#define FULLMAP 269
-#define HELP 270
-#define IMPORT 271
-#define INPUT 272
-#define MAP 273
-#define MESSAGES 274
-#define MODULE 275
-#define MULTIPLE 276
-#define OS_DOMAIN 277
-#define OUTPUT 278
-#define PSEUDOPREEMPTION 279
-#define REENTRANT 280
-#define SCREENNAME 281
-#define SHARELIB 282
-#define STACK 283
-#define START 284
-#define SYNCHRONIZE 285
-#define THREADNAME 286
-#define TYPE 287
-#define VERBOSE 288
-#define VERSION 289
-#define XDCDATA 290
-#define STRING 291
-#define QUOTED_STRING 292
-
-#line 1 "./nlmheader.y"
-/* nlmheader.y - parse NLM header specification keywords.
- Copyright (C) 1993 Free Software Foundation, Inc.
-
-This file is part of GNU Binutils.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-/* Written by Ian Lance Taylor <ian@cygnus.com>.
-
- This bison file parses the commands recognized by the NetWare NLM
- linker, except for lists of object files. It stores the
- information in global variables.
-
- This implementation is based on the description in the NetWare Tool
- Maker Specification manual, edition 1.0. */
-
-#include <ansidecl.h>
-#include <stdio.h>
-#include <ctype.h>
-#include "bfd.h"
-#include "sysdep.h"
-#include "bucomm.h"
-#include "nlm/common.h"
-#include "nlm/internal.h"
-#include "nlmconv.h"
-
-/* Information is stored in the structures pointed to by these
- variables. */
-
-Nlm_Internal_Fixed_Header *fixed_hdr;
-Nlm_Internal_Variable_Header *var_hdr;
-Nlm_Internal_Version_Header *version_hdr;
-Nlm_Internal_Copyright_Header *copyright_hdr;
-Nlm_Internal_Extended_Header *extended_hdr;
-
-/* Procedure named by CHECK. */
-char *check_procedure;
-/* File named by CUSTOM. */
-char *custom_file;
-/* Whether to generate debugging information (DEBUG). */
-boolean debug_info;
-/* Procedure named by EXIT. */
-char *exit_procedure;
-/* Exported symbols (EXPORT). */
-struct string_list *export_symbols;
-/* List of files from INPUT. */
-struct string_list *input_files;
-/* Map file name (MAP, FULLMAP). */
-char *map_file;
-/* Whether a full map has been requested (FULLMAP). */
-boolean full_map;
-/* File named by HELP. */
-char *help_file;
-/* Imported symbols (IMPORT). */
-struct string_list *import_symbols;
-/* File named by MESSAGES. */
-char *message_file;
-/* Autoload module list (MODULE). */
-struct string_list *modules;
-/* File named by OUTPUT. */
-char *output_file;
-/* File named by SHARELIB. */
-char *sharelib_file;
-/* Start procedure name (START). */
-char *start_procedure;
-/* VERBOSE. */
-boolean verbose;
-/* RPC description file (XDCDATA). */
-char *rpc_file;
-
-/* The number of serious errors that have occurred. */
-int parse_errors;
-
-/* The current symbol prefix when reading a list of import or export
- symbols. */
-static char *symbol_prefix;
-
-/* Parser error message handler. */
-#define yyerror(msg) nlmheader_error (msg);
-
-/* Local functions. */
-static int yylex PARAMS ((void));
-static void nlmlex_file_push PARAMS ((const char *));
-static boolean nlmlex_file_open PARAMS ((const char *));
-static int nlmlex_buf_init PARAMS ((void));
-static char nlmlex_buf_add PARAMS ((int));
-static long nlmlex_get_number PARAMS ((const char *));
-static void nlmheader_identify PARAMS ((void));
-static void nlmheader_warn PARAMS ((const char *, int));
-static void nlmheader_error PARAMS ((const char *));
-static struct string_list * string_list_cons PARAMS ((char *,
- struct string_list *));
-static struct string_list * string_list_append PARAMS ((struct string_list *,
- struct string_list *));
-static struct string_list * string_list_append1 PARAMS ((struct string_list *,
- char *));
-static char *xstrdup PARAMS ((const char *));
-
-
-#line 113 "./nlmheader.y"
-typedef union
-{
- char *string;
- struct string_list *list;
-} YYSTYPE;
-
-#ifndef YYLTYPE
-typedef
- struct yyltype
- {
- int timestamp;
- int first_line;
- int first_column;
- int last_line;
- int last_column;
- char *text;
- }
- yyltype;
-
-#define YYLTYPE yyltype
-#endif
-
-#include <stdio.h>
-
-#ifndef __cplusplus
-#ifndef __STDC__
-#define const
-#endif
-#endif
-
-
-
-#define YYFINAL 82
-#define YYFLAG -32768
-#define YYNTBASE 40
-
-#define YYTRANSLATE(x) ((unsigned)(x) <= 292 ? yytranslate[x] : 50)
-
-static const char yytranslate[] = { 0,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 38,
- 39, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 1, 2, 3, 4, 5,
- 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
- 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
- 36, 37
-};
-
-#if YYDEBUG != 0
-static const short yyprhs[] = { 0,
- 0, 2, 3, 6, 9, 12, 15, 18, 23, 25,
- 28, 31, 32, 36, 39, 42, 44, 47, 50, 51,
- 55, 58, 60, 63, 66, 69, 71, 73, 76, 78,
- 80, 83, 86, 89, 92, 94, 97, 100, 102, 107,
- 111, 114, 115, 117, 119, 121, 124, 127, 131, 133,
- 134
-};
-
-static const short yyrhs[] = { 41,
- 0, 0, 42, 41, 0, 3, 36, 0, 4, 36,
- 0, 5, 37, 0, 6, 36, 0, 7, 36, 36,
- 36, 0, 8, 0, 9, 37, 0, 10, 36, 0,
- 0, 11, 43, 45, 0, 12, 36, 0, 13, 36,
- 0, 14, 0, 14, 36, 0, 15, 36, 0, 0,
- 16, 44, 45, 0, 17, 49, 0, 18, 0, 18,
- 36, 0, 19, 36, 0, 20, 49, 0, 21, 0,
- 22, 0, 23, 36, 0, 24, 0, 25, 0, 26,
- 37, 0, 27, 36, 0, 28, 36, 0, 29, 36,
- 0, 30, 0, 31, 37, 0, 32, 36, 0, 33,
- 0, 34, 36, 36, 36, 0, 34, 36, 36, 0,
- 35, 36, 0, 0, 46, 0, 48, 0, 47, 0,
- 46, 48, 0, 46, 47, 0, 38, 36, 39, 0,
- 36, 0, 0, 36, 49, 0
-};
-
-#endif
-
-#if YYDEBUG != 0
-static const short yyrline[] = { 0,
- 144, 150, 152, 157, 162, 167, 184, 188, 206, 210,
- 226, 230, 235, 238, 243, 248, 253, 258, 262, 267,
- 270, 274, 278, 282, 286, 290, 294, 298, 305, 309,
- 313, 329, 333, 338, 342, 346, 362, 367, 371, 395,
- 411, 419, 424, 434, 439, 443, 447, 455, 466, 482,
- 487
-};
-
-static const char * const yytname[] = { "$","error","$undefined.","CHECK",
-"CODESTART","COPYRIGHT","CUSTOM","DATE","DEBUG","DESCRIPTION","EXIT","EXPORT",
-"FLAG_ON","FLAG_OFF","FULLMAP","HELP","IMPORT","INPUT","MAP","MESSAGES","MODULE",
-"MULTIPLE","OS_DOMAIN","OUTPUT","PSEUDOPREEMPTION","REENTRANT","SCREENNAME",
-"SHARELIB","STACK","START","SYNCHRONIZE","THREADNAME","TYPE","VERBOSE","VERSION",
-"XDCDATA","STRING","QUOTED_STRING","'('","')'","file","commands","command","@1",
-"@2","symbol_list_opt","symbol_list","symbol_prefix","symbol","string_list",
-""
-};
-#endif
-
-static const short yyr1[] = { 0,
- 40, 41, 41, 42, 42, 42, 42, 42, 42, 42,
- 42, 43, 42, 42, 42, 42, 42, 42, 44, 42,
- 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
- 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
- 42, 45, 45, 46, 46, 46, 46, 47, 48, 49,
- 49
-};
-
-static const short yyr2[] = { 0,
- 1, 0, 2, 2, 2, 2, 2, 4, 1, 2,
- 2, 0, 3, 2, 2, 1, 2, 2, 0, 3,
- 2, 1, 2, 2, 2, 1, 1, 2, 1, 1,
- 2, 2, 2, 2, 1, 2, 2, 1, 4, 3,
- 2, 0, 1, 1, 1, 2, 2, 3, 1, 0,
- 2
-};
-
-static const short yydefact[] = { 2,
- 0, 0, 0, 0, 0, 9, 0, 0, 12, 0,
- 0, 16, 0, 19, 50, 22, 0, 50, 26, 27,
- 0, 29, 30, 0, 0, 0, 0, 35, 0, 0,
- 38, 0, 0, 1, 2, 4, 5, 6, 7, 0,
- 10, 11, 42, 14, 15, 17, 18, 42, 50, 21,
- 23, 24, 25, 28, 31, 32, 33, 34, 36, 37,
- 0, 41, 3, 0, 49, 0, 13, 43, 45, 44,
- 20, 51, 40, 8, 0, 47, 46, 39, 48, 0,
- 0, 0
-};
-
-static const short yydefgoto[] = { 80,
- 34, 35, 43, 48, 67, 68, 69, 70, 50
-};
-
-static const short yypact[] = { -3,
- -1, 1, 2, 4, 5,-32768, 6, 8,-32768, 9,
- 10, 11, 12,-32768, 13, 14, 16, 13,-32768,-32768,
- 17,-32768,-32768, 18, 20, 21, 22,-32768, 23, 25,
--32768, 26, 27,-32768, -3,-32768,-32768,-32768,-32768, 29,
--32768,-32768, -2,-32768,-32768,-32768,-32768, -2, 13,-32768,
--32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
- 30,-32768,-32768, 31,-32768, 32,-32768, -2,-32768,-32768,
--32768,-32768, 33,-32768, 3,-32768,-32768,-32768,-32768, 38,
- 51,-32768
-};
-
-static const short yypgoto[] = {-32768,
- 19,-32768,-32768,-32768, 24,-32768, -9, 7, 15
-};
-
-
-#define YYLAST 75
-
-
-static const short yytable[] = { 1,
- 2, 3, 4, 5, 6, 7, 8, 9, 10, 11,
- 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
- 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 53, 65, 36, 66, 37, 81, 38, 39,
- 40, 79, 41, 42, 44, 45, 46, 47, 49, 51,
- 82, 52, 54, 63, 55, 56, 57, 58, 76, 59,
- 60, 61, 62, 72, 64, 73, 74, 75, 78, 0,
- 0, 71, 0, 0, 77
-};
-
-static const short yycheck[] = { 3,
- 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,
- 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31, 32, 33,
- 34, 35, 18, 36, 36, 38, 36, 0, 37, 36,
- 36, 39, 37, 36, 36, 36, 36, 36, 36, 36,
- 0, 36, 36, 35, 37, 36, 36, 36, 68, 37,
- 36, 36, 36, 49, 36, 36, 36, 36, 36, -1,
- -1, 48, -1, -1, 68
-};
-/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
-#line 3 "/usr/unsupported/share/bison.simple"
-
-/* Skeleton output parser for bison,
- Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-#ifndef alloca
-#ifdef __GNUC__
-#define alloca __builtin_alloca
-#else /* not GNU C. */
-#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi)
-#include <alloca.h>
-#else /* not sparc */
-#if defined (MSDOS) && !defined (__TURBOC__)
-#include <malloc.h>
-#else /* not MSDOS, or __TURBOC__ */
-#if defined(_AIX)
-#include <malloc.h>
- #pragma alloca
-#else /* not MSDOS, __TURBOC__, or _AIX */
-#ifdef __hpux
-#ifdef __cplusplus
-extern "C" {
-void *alloca (unsigned int);
-};
-#else /* not __cplusplus */
-void *alloca ();
-#endif /* not __cplusplus */
-#endif /* __hpux */
-#endif /* not _AIX */
-#endif /* not MSDOS, or __TURBOC__ */
-#endif /* not sparc. */
-#endif /* not GNU C. */
-#endif /* alloca not defined. */
-
-/* This is the parser code that is written into each bison parser
- when the %semantic_parser declaration is not specified in the grammar.
- It was written by Richard Stallman by simplifying the hairy parser
- used when %semantic_parser is specified. */
-
-/* Note: there must be only one dollar sign in this file.
- It is replaced by the list of actions, each action
- as one case of the switch. */
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY -2
-#define YYEOF 0
-#define YYACCEPT return(0)
-#define YYABORT return(1)
-#define YYERROR goto yyerrlab1
-/* Like YYERROR except do call yyerror.
- This remains here temporarily to ease the
- transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. */
-#define YYFAIL goto yyerrlab
-#define YYRECOVERING() (!!yyerrstatus)
-#define YYBACKUP(token, value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { yychar = (token), yylval = (value); \
- yychar1 = YYTRANSLATE (yychar); \
- YYPOPSTACK; \
- goto yybackup; \
- } \
- else \
- { yyerror ("syntax error: cannot back up"); YYERROR; } \
-while (0)
-
-#define YYTERROR 1
-#define YYERRCODE 256
-
-#ifndef YYPURE
-#define YYLEX yylex()
-#endif
-
-#ifdef YYPURE
-#ifdef YYLSP_NEEDED
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval, &yylloc)
-#endif
-#else /* not YYLSP_NEEDED */
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval)
-#endif
-#endif /* not YYLSP_NEEDED */
-#endif
-
-/* If nonreentrant, generate the variables here */
-
-#ifndef YYPURE
-
-int yychar; /* the lookahead symbol */
-YYSTYPE yylval; /* the semantic value of the */
- /* lookahead symbol */
-
-#ifdef YYLSP_NEEDED
-YYLTYPE yylloc; /* location data for the lookahead */
- /* symbol */
-#endif
-
-int yynerrs; /* number of parse errors so far */
-#endif /* not YYPURE */
-
-#if YYDEBUG != 0
-int yydebug; /* nonzero means print parse trace */
-/* Since this is uninitialized, it does not stop multiple parsers
- from coexisting. */
-#endif
-
-/* YYINITDEPTH indicates the initial size of the parser's stacks */
-
-#ifndef YYINITDEPTH
-#define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH is the maximum size the stacks can grow to
- (effective only if the built-in stack extension method is used). */
-
-#if YYMAXDEPTH == 0
-#undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-#define YYMAXDEPTH 10000
-#endif
-
-/* Prevent warning if -Wstrict-prototypes. */
-#ifdef __GNUC__
-int yyparse (void);
-#endif
-
-#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
-#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT)
-#else /* not GNU C or C++ */
-#ifndef __cplusplus
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (from, to, count)
- char *from;
- char *to;
- int count;
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#else /* __cplusplus */
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (char *from, char *to, int count)
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#endif
-#endif
-
-#line 192 "/usr/unsupported/share/bison.simple"
-
-/* The user can define YYPARSE_PARAM as the name of an argument to be passed
- into yyparse. The argument should have type void *.
- It should actually point to an object.
- Grammar actions can access the variable by casting it
- to the proper pointer type. */
-
-#ifdef YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
-#else
-#define YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL
-#endif
-
-int
-yyparse(YYPARSE_PARAM)
- YYPARSE_PARAM_DECL
-{
- register int yystate;
- register int yyn;
- register short *yyssp;
- register YYSTYPE *yyvsp;
- int yyerrstatus; /* number of tokens to shift before error messages enabled */
- int yychar1 = 0; /* lookahead token as an internal (translated) token number */
-
- short yyssa[YYINITDEPTH]; /* the state stack */
- YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
-
- short *yyss = yyssa; /* refer to the stacks thru separate pointers */
- YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
-
-#ifdef YYLSP_NEEDED
- YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */
- YYLTYPE *yyls = yylsa;
- YYLTYPE *yylsp;
-
-#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
-#else
-#define YYPOPSTACK (yyvsp--, yyssp--)
-#endif
-
- int yystacksize = YYINITDEPTH;
-
-#ifdef YYPURE
- int yychar;
- YYSTYPE yylval;
- int yynerrs;
-#ifdef YYLSP_NEEDED
- YYLTYPE yylloc;
-#endif
-#endif
-
- YYSTYPE yyval; /* the variable used to return */
- /* semantic values from the action */
- /* routines */
-
- int yylen;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Starting parse\n");
-#endif
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
-
- yyssp = yyss - 1;
- yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
- yylsp = yyls;
-#endif
-
-/* Push a new state, which is found in yystate . */
-/* In all cases, when you get here, the value and location stacks
- have just been pushed. so pushing a state here evens the stacks. */
-yynewstate:
-
- *++yyssp = yystate;
-
- if (yyssp >= yyss + yystacksize - 1)
- {
- /* Give user a chance to reallocate the stack */
- /* Use copies of these so that the &'s don't force the real ones into memory. */
- YYSTYPE *yyvs1 = yyvs;
- short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
- YYLTYPE *yyls1 = yyls;
-#endif
-
- /* Get the current used size of the three stacks, in elements. */
- int size = yyssp - yyss + 1;
-
-#ifdef yyoverflow
- /* Each stack pointer address is followed by the size of
- the data in use in that stack, in bytes. */
-#ifdef YYLSP_NEEDED
- /* This used to be a conditional around just the two extra args,
- but that might be undefined if yyoverflow is a macro. */
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yyls1, size * sizeof (*yylsp),
- &yystacksize);
-#else
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yystacksize);
-#endif
-
- yyss = yyss1; yyvs = yyvs1;
-#ifdef YYLSP_NEEDED
- yyls = yyls1;
-#endif
-#else /* no yyoverflow */
- /* Extend the stack our own way. */
- if (yystacksize >= YYMAXDEPTH)
- {
- yyerror("parser stack overflow");
- return 2;
- }
- yystacksize *= 2;
- if (yystacksize > YYMAXDEPTH)
- yystacksize = YYMAXDEPTH;
- yyss = (short *) alloca (yystacksize * sizeof (*yyssp));
- __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp));
- yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp));
- __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp));
-#ifdef YYLSP_NEEDED
- yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp));
- __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp));
-#endif
-#endif /* no yyoverflow */
-
- yyssp = yyss + size - 1;
- yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
- yylsp = yyls + size - 1;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Stack size increased to %d\n", yystacksize);
-#endif
-
- if (yyssp >= yyss + yystacksize - 1)
- YYABORT;
- }
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Entering state %d\n", yystate);
-#endif
-
- goto yybackup;
- yybackup:
-
-/* Do appropriate processing given the current state. */
-/* Read a lookahead token if we need one and don't already have one. */
-/* yyresume: */
-
- /* First try to decide what to do without reference to lookahead token. */
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* yychar is either YYEMPTY or YYEOF
- or a valid token in external form. */
-
- if (yychar == YYEMPTY)
- {
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Reading a token: ");
-#endif
- yychar = YYLEX;
- }
-
- /* Convert token to internal form (in yychar1) for indexing tables with */
-
- if (yychar <= 0) /* This means end of input. */
- {
- yychar1 = 0;
- yychar = YYEOF; /* Don't call YYLEX any more */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Now at end of input.\n");
-#endif
- }
- else
- {
- yychar1 = YYTRANSLATE(yychar);
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
- /* Give the individual parser a way to print the precise meaning
- of a token, for further debugging info. */
-#ifdef YYPRINT
- YYPRINT (stderr, yychar, yylval);
-#endif
- fprintf (stderr, ")\n");
- }
-#endif
- }
-
- yyn += yychar1;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
- goto yydefault;
-
- yyn = yytable[yyn];
-
- /* yyn is what to do for this token type in this state.
- Negative => reduce, -yyn is rule number.
- Positive => shift, yyn is new state.
- New state is final state => don't bother to shift,
- just return success.
- 0, or most negative number => error. */
-
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrlab;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- /* Shift the lookahead token. */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
-#endif
-
- /* Discard the token being shifted unless it is eof. */
- if (yychar != YYEOF)
- yychar = YYEMPTY;
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- /* count tokens shifted since error; after three, turn off error status. */
- if (yyerrstatus) yyerrstatus--;
-
- yystate = yyn;
- goto yynewstate;
-
-/* Do the default action for the current state. */
-yydefault:
-
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
-
-/* Do a reduction. yyn is the number of a rule to reduce with. */
-yyreduce:
- yylen = yyr2[yyn];
- if (yylen > 0)
- yyval = yyvsp[1-yylen]; /* implement default value of the action */
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- int i;
-
- fprintf (stderr, "Reducing via rule %d (line %d), ",
- yyn, yyrline[yyn]);
-
- /* Print the symbols being reduced, and their result. */
- for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
- fprintf (stderr, "%s ", yytname[yyrhs[i]]);
- fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
- }
-#endif
-
-
- switch (yyn) {
-
-case 4:
-#line 159 "./nlmheader.y"
-{
- check_procedure = yyvsp[0].string;
- ;
- break;}
-case 5:
-#line 163 "./nlmheader.y"
-{
- nlmheader_warn ("CODESTART is not implemented; sorry", -1);
- free (yyvsp[0].string);
- ;
- break;}
-case 6:
-#line 168 "./nlmheader.y"
-{
- int len;
-
- strncpy (copyright_hdr->stamp, "CoPyRiGhT=", 10);
- len = strlen (yyvsp[0].string);
- if (len >= NLM_MAX_COPYRIGHT_MESSAGE_LENGTH)
- {
- nlmheader_warn ("copyright string is too long",
- NLM_MAX_COPYRIGHT_MESSAGE_LENGTH - 1);
- len = NLM_MAX_COPYRIGHT_MESSAGE_LENGTH - 1;
- }
- copyright_hdr->copyrightMessageLength = len;
- strncpy (copyright_hdr->copyrightMessage, yyvsp[0].string, len);
- copyright_hdr->copyrightMessage[len] = '\0';
- free (yyvsp[0].string);
- ;
- break;}
-case 7:
-#line 185 "./nlmheader.y"
-{
- custom_file = yyvsp[0].string;
- ;
- break;}
-case 8:
-#line 189 "./nlmheader.y"
-{
- /* We don't set the version stamp here, because we use the
- version stamp to detect whether the required VERSION
- keyword was given. */
- version_hdr->month = nlmlex_get_number (yyvsp[-2].string);
- version_hdr->day = nlmlex_get_number (yyvsp[-1].string);
- version_hdr->year = nlmlex_get_number (yyvsp[0].string);
- free (yyvsp[-2].string);
- free (yyvsp[-1].string);
- free (yyvsp[0].string);
- if (version_hdr->month < 1 || version_hdr->month > 12)
- nlmheader_warn ("illegal month", -1);
- if (version_hdr->day < 1 || version_hdr->day > 31)
- nlmheader_warn ("illegal day", -1);
- if (version_hdr->year < 1900 || version_hdr->year > 3000)
- nlmheader_warn ("illegal year", -1);
- ;
- break;}
-case 9:
-#line 207 "./nlmheader.y"
-{
- debug_info = true;
- ;
- break;}
-case 10:
-#line 211 "./nlmheader.y"
-{
- int len;
-
- len = strlen (yyvsp[0].string);
- if (len > NLM_MAX_DESCRIPTION_LENGTH)
- {
- nlmheader_warn ("description string is too long",
- NLM_MAX_DESCRIPTION_LENGTH);
- len = NLM_MAX_DESCRIPTION_LENGTH;
- }
- var_hdr->descriptionLength = len;
- strncpy (var_hdr->descriptionText, yyvsp[0].string, len);
- var_hdr->descriptionText[len] = '\0';
- free (yyvsp[0].string);
- ;
- break;}
-case 11:
-#line 227 "./nlmheader.y"
-{
- exit_procedure = yyvsp[0].string;
- ;
- break;}
-case 12:
-#line 231 "./nlmheader.y"
-{
- symbol_prefix = NULL;
- ;
- break;}
-case 13:
-#line 235 "./nlmheader.y"
-{
- export_symbols = string_list_append (export_symbols, yyvsp[0].list);
- ;
- break;}
-case 14:
-#line 239 "./nlmheader.y"
-{
- fixed_hdr->flags |= nlmlex_get_number (yyvsp[0].string);
- free (yyvsp[0].string);
- ;
- break;}
-case 15:
-#line 244 "./nlmheader.y"
-{
- fixed_hdr->flags &=~ nlmlex_get_number (yyvsp[0].string);
- free (yyvsp[0].string);
- ;
- break;}
-case 16:
-#line 249 "./nlmheader.y"
-{
- map_file = "";
- full_map = true;
- ;
- break;}
-case 17:
-#line 254 "./nlmheader.y"
-{
- map_file = yyvsp[0].string;
- full_map = true;
- ;
- break;}
-case 18:
-#line 259 "./nlmheader.y"
-{
- help_file = yyvsp[0].string;
- ;
- break;}
-case 19:
-#line 263 "./nlmheader.y"
-{
- symbol_prefix = NULL;
- ;
- break;}
-case 20:
-#line 267 "./nlmheader.y"
-{
- import_symbols = string_list_append (import_symbols, yyvsp[0].list);
- ;
- break;}
-case 21:
-#line 271 "./nlmheader.y"
-{
- input_files = string_list_append (input_files, yyvsp[0].list);
- ;
- break;}
-case 22:
-#line 275 "./nlmheader.y"
-{
- map_file = "";
- ;
- break;}
-case 23:
-#line 279 "./nlmheader.y"
-{
- map_file = yyvsp[0].string;
- ;
- break;}
-case 24:
-#line 283 "./nlmheader.y"
-{
- message_file = yyvsp[0].string;
- ;
- break;}
-case 25:
-#line 287 "./nlmheader.y"
-{
- modules = string_list_append (modules, yyvsp[0].list);
- ;
- break;}
-case 26:
-#line 291 "./nlmheader.y"
-{
- fixed_hdr->flags |= 0x2;
- ;
- break;}
-case 27:
-#line 295 "./nlmheader.y"
-{
- fixed_hdr->flags |= 0x10;
- ;
- break;}
-case 28:
-#line 299 "./nlmheader.y"
-{
- if (output_file == NULL)
- output_file = yyvsp[0].string;
- else
- nlmheader_warn ("ignoring duplicate OUTPUT statement", -1);
- ;
- break;}
-case 29:
-#line 306 "./nlmheader.y"
-{
- fixed_hdr->flags |= 0x8;
- ;
- break;}
-case 30:
-#line 310 "./nlmheader.y"
-{
- fixed_hdr->flags |= 0x1;
- ;
- break;}
-case 31:
-#line 314 "./nlmheader.y"
-{
- int len;
-
- len = strlen (yyvsp[0].string);
- if (len >= NLM_MAX_SCREEN_NAME_LENGTH)
- {
- nlmheader_warn ("screen name is too long",
- NLM_MAX_SCREEN_NAME_LENGTH);
- len = NLM_MAX_SCREEN_NAME_LENGTH;
- }
- var_hdr->screenNameLength = len;
- strncpy (var_hdr->screenName, yyvsp[0].string, len);
- var_hdr->screenName[NLM_MAX_SCREEN_NAME_LENGTH] = '\0';
- free (yyvsp[0].string);
- ;
- break;}
-case 32:
-#line 330 "./nlmheader.y"
-{
- sharelib_file = yyvsp[0].string;
- ;
- break;}
-case 33:
-#line 334 "./nlmheader.y"
-{
- var_hdr->stackSize = nlmlex_get_number (yyvsp[0].string);
- free (yyvsp[0].string);
- ;
- break;}
-case 34:
-#line 339 "./nlmheader.y"
-{
- start_procedure = yyvsp[0].string;
- ;
- break;}
-case 35:
-#line 343 "./nlmheader.y"
-{
- fixed_hdr->flags |= 0x4;
- ;
- break;}
-case 36:
-#line 347 "./nlmheader.y"
-{
- int len;
-
- len = strlen (yyvsp[0].string);
- if (len >= NLM_MAX_THREAD_NAME_LENGTH)
- {
- nlmheader_warn ("thread name is too long",
- NLM_MAX_THREAD_NAME_LENGTH);
- len = NLM_MAX_THREAD_NAME_LENGTH;
- }
- var_hdr->threadNameLength = len;
- strncpy (var_hdr->threadName, yyvsp[0].string, len);
- var_hdr->threadName[len] = '\0';
- free (yyvsp[0].string);
- ;
- break;}
-case 37:
-#line 363 "./nlmheader.y"
-{
- fixed_hdr->moduleType = nlmlex_get_number (yyvsp[0].string);
- free (yyvsp[0].string);
- ;
- break;}
-case 38:
-#line 368 "./nlmheader.y"
-{
- verbose = true;
- ;
- break;}
-case 39:
-#line 372 "./nlmheader.y"
-{
- long val;
-
- strncpy (version_hdr->stamp, "VeRsIoN#", 8);
- version_hdr->majorVersion = nlmlex_get_number (yyvsp[-2].string);
- val = nlmlex_get_number (yyvsp[-1].string);
- if (val < 0 || val > 99)
- nlmheader_warn ("illegal minor version number (must be between 0 and 99)",
- -1);
- else
- version_hdr->minorVersion = val;
- val = nlmlex_get_number (yyvsp[0].string);
- if (val < 0)
- nlmheader_warn ("illegal revision number (must be between 0 and 26)",
- -1);
- else if (val > 26)
- version_hdr->revision = 0;
- else
- version_hdr->revision = val;
- free (yyvsp[-2].string);
- free (yyvsp[-1].string);
- free (yyvsp[0].string);
- ;
- break;}
-case 40:
-#line 396 "./nlmheader.y"
-{
- long val;
-
- strncpy (version_hdr->stamp, "VeRsIoN#", 8);
- version_hdr->majorVersion = nlmlex_get_number (yyvsp[-1].string);
- val = nlmlex_get_number (yyvsp[0].string);
- if (val < 0 || val > 99)
- nlmheader_warn ("illegal minor version number (must be between 0 and 99)",
- -1);
- else
- version_hdr->minorVersion = val;
- version_hdr->revision = 0;
- free (yyvsp[-1].string);
- free (yyvsp[0].string);
- ;
- break;}
-case 41:
-#line 412 "./nlmheader.y"
-{
- rpc_file = yyvsp[0].string;
- ;
- break;}
-case 42:
-#line 421 "./nlmheader.y"
-{
- yyval.list = NULL;
- ;
- break;}
-case 43:
-#line 425 "./nlmheader.y"
-{
- yyval.list = yyvsp[0].list;
- ;
- break;}
-case 44:
-#line 436 "./nlmheader.y"
-{
- yyval.list = string_list_cons (yyvsp[0].string, NULL);
- ;
- break;}
-case 45:
-#line 440 "./nlmheader.y"
-{
- yyval.list = NULL;
- ;
- break;}
-case 46:
-#line 444 "./nlmheader.y"
-{
- yyval.list = string_list_append1 (yyvsp[-1].list, yyvsp[0].string);
- ;
- break;}
-case 47:
-#line 448 "./nlmheader.y"
-{
- yyval.list = yyvsp[-1].list;
- ;
- break;}
-case 48:
-#line 457 "./nlmheader.y"
-{
- if (symbol_prefix != NULL)
- free (symbol_prefix);
- symbol_prefix = yyvsp[-1].string;
- ;
- break;}
-case 49:
-#line 468 "./nlmheader.y"
-{
- if (symbol_prefix == NULL)
- yyval.string = yyvsp[0].string;
- else
- {
- yyval.string = xmalloc (strlen (symbol_prefix) + strlen (yyvsp[0].string) + 2);
- sprintf (yyval.string, "%s@%s", symbol_prefix, yyvsp[0].string);
- free (yyvsp[0].string);
- }
- ;
- break;}
-case 50:
-#line 484 "./nlmheader.y"
-{
- yyval.list = NULL;
- ;
- break;}
-case 51:
-#line 488 "./nlmheader.y"
-{
- yyval.list = string_list_cons (yyvsp[-1].string, yyvsp[0].list);
- ;
- break;}
-}
- /* the action file gets copied in in place of this dollarsign */
-#line 487 "/usr/unsupported/share/bison.simple"
-
- yyvsp -= yylen;
- yyssp -= yylen;
-#ifdef YYLSP_NEEDED
- yylsp -= yylen;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
- *++yyvsp = yyval;
-
-#ifdef YYLSP_NEEDED
- yylsp++;
- if (yylen == 0)
- {
- yylsp->first_line = yylloc.first_line;
- yylsp->first_column = yylloc.first_column;
- yylsp->last_line = (yylsp-1)->last_line;
- yylsp->last_column = (yylsp-1)->last_column;
- yylsp->text = 0;
- }
- else
- {
- yylsp->last_line = (yylsp+yylen-1)->last_line;
- yylsp->last_column = (yylsp+yylen-1)->last_column;
- }
-#endif
-
- /* Now "shift" the result of the reduction.
- Determine what state that goes to,
- based on the state we popped back to
- and the rule number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
- if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTBASE];
-
- goto yynewstate;
-
-yyerrlab: /* here on detecting error */
-
- if (! yyerrstatus)
- /* If not already recovering from an error, report this error. */
- {
- ++yynerrs;
-
-#ifdef YYERROR_VERBOSE
- yyn = yypact[yystate];
-
- if (yyn > YYFLAG && yyn < YYLAST)
- {
- int size = 0;
- char *msg;
- int x, count;
-
- count = 0;
- /* Start X at -yyn if nec to avoid negative indexes in yycheck. */
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- size += strlen(yytname[x]) + 15, count++;
- msg = (char *) malloc(size + 15);
- if (msg != 0)
- {
- strcpy(msg, "parse error");
-
- if (count < 5)
- {
- count = 0;
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- {
- strcat(msg, count == 0 ? ", expecting `" : " or `");
- strcat(msg, yytname[x]);
- strcat(msg, "'");
- count++;
- }
- }
- yyerror(msg);
- free(msg);
- }
- else
- yyerror ("parse error; also virtual memory exceeded");
- }
- else
-#endif /* YYERROR_VERBOSE */
- yyerror("parse error");
- }
-
- goto yyerrlab1;
-yyerrlab1: /* here on error raised explicitly by an action */
-
- if (yyerrstatus == 3)
- {
- /* if just tried and failed to reuse lookahead token after an error, discard it. */
-
- /* return failure if at end of input */
- if (yychar == YYEOF)
- YYABORT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
-#endif
-
- yychar = YYEMPTY;
- }
-
- /* Else will try to reuse lookahead token
- after shifting the error token. */
-
- yyerrstatus = 3; /* Each real token shifted decrements this */
-
- goto yyerrhandle;
-
-yyerrdefault: /* current state does not do anything special for the error token. */
-
-#if 0
- /* This is wrong; only states that explicitly want error tokens
- should shift them. */
- yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
- if (yyn) goto yydefault;
-#endif
-
-yyerrpop: /* pop the current state because it cannot handle the error token */
-
- if (yyssp == yyss) YYABORT;
- yyvsp--;
- yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
- yylsp--;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "Error: state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
-yyerrhandle:
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yyerrdefault;
-
- yyn += YYTERROR;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
- goto yyerrdefault;
-
- yyn = yytable[yyn];
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrpop;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrpop;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting error token, ");
-#endif
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- yystate = yyn;
- goto yynewstate;
-}
-#line 493 "./nlmheader.y"
-
-
-/* If strerror is just a macro, we want to use the one from libiberty
- since it will handle undefined values. */
-#undef strerror
-extern char *strerror ();
-
-/* The lexer is simple, too simple for flex. Keywords are only
- recognized at the start of lines. Everything else must be an
- argument. A comma is treated as whitespace. */
-
-/* The states the lexer can be in. */
-
-enum lex_state
-{
- /* At the beginning of a line. */
- BEGINNING_OF_LINE,
- /* In the middle of a line. */
- IN_LINE
-};
-
-/* We need to keep a stack of files to handle file inclusion. */
-
-struct input
-{
- /* The file to read from. */
- FILE *file;
- /* The name of the file. */
- char *name;
- /* The current line number. */
- int lineno;
- /* The current state. */
- enum lex_state state;
- /* The next file on the stack. */
- struct input *next;
-};
-
-/* The current input file. */
-
-static struct input current;
-
-/* The character which introduces comments. */
-#define COMMENT_CHAR '#'
-
-/* Start the lexer going on the main input file. */
-
-boolean
-nlmlex_file (name)
- const char *name;
-{
- current.next = NULL;
- return nlmlex_file_open (name);
-}
-
-/* Start the lexer going on a subsidiary input file. */
-
-static void
-nlmlex_file_push (name)
- const char *name;
-{
- struct input *push;
-
- push = (struct input *) xmalloc (sizeof (struct input));
- *push = current;
- if (nlmlex_file_open (name))
- current.next = push;
- else
- {
- current = *push;
- free (push);
- }
-}
-
-/* Start lexing from a file. */
-
-static boolean
-nlmlex_file_open (name)
- const char *name;
-{
- current.file = fopen (name, "r");
- if (current.file == NULL)
- {
- fprintf (stderr, "%s:%s: %s\n", program_name, name, strerror (errno));
- ++parse_errors;
- return false;
- }
- current.name = xstrdup (name);
- current.lineno = 1;
- current.state = BEGINNING_OF_LINE;
- return true;
-}
-
-/* Table used to turn keywords into tokens. */
-
-struct keyword_tokens_struct
-{
- const char *keyword;
- int token;
-};
-
-struct keyword_tokens_struct keyword_tokens[] =
-{
- { "CHECK", CHECK },
- { "CODESTART", CODESTART },
- { "COPYRIGHT", COPYRIGHT },
- { "CUSTOM", CUSTOM },
- { "DATE", DATE },
- { "DEBUG", DEBUG },
- { "DESCRIPTION", DESCRIPTION },
- { "EXIT", EXIT },
- { "EXPORT", EXPORT },
- { "FLAG_ON", FLAG_ON },
- { "FLAG_OFF", FLAG_OFF },
- { "FULLMAP", FULLMAP },
- { "HELP", HELP },
- { "IMPORT", IMPORT },
- { "INPUT", INPUT },
- { "MAP", MAP },
- { "MESSAGES", MESSAGES },
- { "MODULE", MODULE },
- { "MULTIPLE", MULTIPLE },
- { "OS_DOMAIN", OS_DOMAIN },
- { "OUTPUT", OUTPUT },
- { "PSEUDOPREEMPTION", PSEUDOPREEMPTION },
- { "REENTRANT", REENTRANT },
- { "SCREENNAME", SCREENNAME },
- { "SHARELIB", SHARELIB },
- { "STACK", STACK },
- { "STACKSIZE", STACK },
- { "START", START },
- { "SYNCHRONIZE", SYNCHRONIZE },
- { "THREADNAME", THREADNAME },
- { "TYPE", TYPE },
- { "VERBOSE", VERBOSE },
- { "VERSION", VERSION },
- { "XDCDATA", XDCDATA }
-};
-
-#define KEYWORD_COUNT (sizeof (keyword_tokens) / sizeof (keyword_tokens[0]))
-
-/* The lexer accumulates strings in these variables. */
-static char *lex_buf;
-static int lex_size;
-static int lex_pos;
-
-/* Start accumulating strings into the buffer. */
-#define BUF_INIT() \
- ((void) (lex_buf != NULL ? lex_pos = 0 : nlmlex_buf_init ()))
-
-static int
-nlmlex_buf_init ()
-{
- lex_size = 10;
- lex_buf = xmalloc (lex_size + 1);
- lex_pos = 0;
- return 0;
-}
-
-/* Finish a string in the buffer. */
-#define BUF_FINISH() ((void) (lex_buf[lex_pos] = '\0'))
-
-/* Accumulate a character into the buffer. */
-#define BUF_ADD(c) \
- ((void) (lex_pos < lex_size \
- ? lex_buf[lex_pos++] = (c) \
- : nlmlex_buf_add (c)))
-
-static char
-nlmlex_buf_add (c)
- int c;
-{
- if (lex_pos >= lex_size)
- {
- lex_size *= 2;
- lex_buf = xrealloc (lex_buf, lex_size + 1);
- }
-
- return lex_buf[lex_pos++] = c;
-}
-
-/* The lexer proper. This is called by the bison generated parsing
- code. */
-
-static int
-yylex ()
-{
- int c;
-
-tail_recurse:
-
- c = getc (current.file);
-
- /* Commas are treated as whitespace characters. */
- while (isspace ((unsigned char) c) || c == ',')
- {
- current.state = IN_LINE;
- if (c == '\n')
- {
- ++current.lineno;
- current.state = BEGINNING_OF_LINE;
- }
- c = getc (current.file);
- }
-
- /* At the end of the file we either pop to the previous file or
- finish up. */
- if (c == EOF)
- {
- fclose (current.file);
- free (current.name);
- if (current.next == NULL)
- return 0;
- else
- {
- struct input *next;
-
- next = current.next;
- current = *next;
- free (next);
- goto tail_recurse;
- }
- }
-
- /* A comment character always means to drop everything until the
- next newline. */
- if (c == COMMENT_CHAR)
- {
- do
- {
- c = getc (current.file);
- }
- while (c != '\n');
- ++current.lineno;
- current.state = BEGINNING_OF_LINE;
- goto tail_recurse;
- }
-
- /* An '@' introduces an include file. */
- if (c == '@')
- {
- do
- {
- c = getc (current.file);
- if (c == '\n')
- ++current.lineno;
- }
- while (isspace ((unsigned char) c));
- BUF_INIT ();
- while (! isspace ((unsigned char) c) && c != EOF)
- {
- BUF_ADD (c);
- c = getc (current.file);
- }
- BUF_FINISH ();
-
- ungetc (c, current.file);
-
- nlmlex_file_push (lex_buf);
- goto tail_recurse;
- }
-
- /* A non-space character at the start of a line must be the start of
- a keyword. */
- if (current.state == BEGINNING_OF_LINE)
- {
- BUF_INIT ();
- while (isalnum ((unsigned char) c) || c == '_')
- {
- if (islower ((unsigned char) c))
- BUF_ADD (toupper ((unsigned char) c));
- else
- BUF_ADD (c);
- c = getc (current.file);
- }
- BUF_FINISH ();
-
- if (c != EOF && ! isspace ((unsigned char) c) && c != ',')
- {
- nlmheader_identify ();
- fprintf (stderr, "%s:%d: illegal character in keyword: %c\n",
- current.name, current.lineno, c);
- }
- else
- {
- int i;
-
- for (i = 0; i < KEYWORD_COUNT; i++)
- {
- if (lex_buf[0] == keyword_tokens[i].keyword[0]
- && strcmp (lex_buf, keyword_tokens[i].keyword) == 0)
- {
- /* Pushing back the final whitespace avoids worrying
- about \n here. */
- ungetc (c, current.file);
- current.state = IN_LINE;
- return keyword_tokens[i].token;
- }
- }
-
- nlmheader_identify ();
- fprintf (stderr, "%s:%d: unrecognized keyword: %s\n",
- current.name, current.lineno, lex_buf);
- }
-
- ++parse_errors;
- /* Treat the rest of this line as a comment. */
- ungetc (COMMENT_CHAR, current.file);
- goto tail_recurse;
- }
-
- /* Parentheses just represent themselves. */
- if (c == '(' || c == ')')
- return c;
-
- /* Handle quoted strings. */
- if (c == '"' || c == '\'')
- {
- int quote;
- int start_lineno;
-
- quote = c;
- start_lineno = current.lineno;
-
- c = getc (current.file);
- BUF_INIT ();
- while (c != quote && c != EOF)
- {
- BUF_ADD (c);
- if (c == '\n')
- ++current.lineno;
- c = getc (current.file);
- }
- BUF_FINISH ();
-
- if (c == EOF)
- {
- nlmheader_identify ();
- fprintf (stderr, "%s:%d: end of file in quoted string\n",
- current.name, start_lineno);
- ++parse_errors;
- }
-
- /* FIXME: Possible memory leak. */
- yylval.string = xstrdup (lex_buf);
- return QUOTED_STRING;
- }
-
- /* Gather a generic argument. */
- BUF_INIT ();
- while (! isspace (c)
- && c != ','
- && c != COMMENT_CHAR
- && c != '('
- && c != ')')
- {
- BUF_ADD (c);
- c = getc (current.file);
- }
- BUF_FINISH ();
-
- ungetc (c, current.file);
-
- /* FIXME: Possible memory leak. */
- yylval.string = xstrdup (lex_buf);
- return STRING;
-}
-
-/* Get a number from a string. */
-
-static long
-nlmlex_get_number (s)
- const char *s;
-{
- long ret;
- char *send;
-
- ret = strtol (s, &send, 10);
- if (*send != '\0')
- nlmheader_warn ("bad number", -1);
- return ret;
-}
-
-/* Prefix the nlmconv warnings with a note as to where they come from.
- We don't use program_name on every warning, because then some
- versions of the emacs next-error function can't recognize the line
- number. */
-
-static void
-nlmheader_identify ()
-{
- static int done;
-
- if (! done)
- {
- fprintf (stderr, "%s: problems in NLM command language input:\n",
- program_name);
- done = 1;
- }
-}
-
-/* Issue a warning. */
-
-static void
-nlmheader_warn (s, imax)
- const char *s;
- int imax;
-{
- nlmheader_identify ();
- fprintf (stderr, "%s:%d: %s", current.name, current.lineno, s);
- if (imax != -1)
- fprintf (stderr, " (max %d)", imax);
- fprintf (stderr, "\n");
-}
-
-/* Report an error. */
-
-static void
-nlmheader_error (s)
- const char *s;
-{
- nlmheader_warn (s, -1);
- ++parse_errors;
-}
-
-/* Add a string to a string list. */
-
-static struct string_list *
-string_list_cons (s, l)
- char *s;
- struct string_list *l;
-{
- struct string_list *ret;
-
- ret = (struct string_list *) xmalloc (sizeof (struct string_list));
- ret->next = l;
- ret->string = s;
- return ret;
-}
-
-/* Append a string list to another string list. */
-
-static struct string_list *
-string_list_append (l1, l2)
- struct string_list *l1;
- struct string_list *l2;
-{
- register struct string_list **pp;
-
- for (pp = &l1; *pp != NULL; pp = &(*pp)->next)
- ;
- *pp = l2;
- return l1;
-}
-
-/* Append a string to a string list. */
-
-static struct string_list *
-string_list_append1 (l, s)
- struct string_list *l;
- char *s;
-{
- struct string_list *n;
- register struct string_list **pp;
-
- n = (struct string_list *) xmalloc (sizeof (struct string_list));
- n->next = NULL;
- n->string = s;
- for (pp = &l; *pp != NULL; pp = &(*pp)->next)
- ;
- *pp = n;
- return l;
-}
-
-/* Duplicate a string in memory. */
-
-static char *
-xstrdup (s)
- const char *s;
-{
- unsigned long len;
- char *ret;
-
- len = strlen (s);
- ret = xmalloc (len + 1);
- strcpy (ret, s);
- return ret;
-}
diff --git a/gnu/usr.bin/binutils/binutils/sysinfo.c b/gnu/usr.bin/binutils/binutils/sysinfo.c
deleted file mode 100644
index ae97bf6ffb6..00000000000
--- a/gnu/usr.bin/binutils/binutils/sysinfo.c
+++ /dev/null
@@ -1,1249 +0,0 @@
-
-/* A Bison parser, made from ./sysinfo.y with Bison version GNU Bison version 1.24
- */
-
-#define YYBISON 1 /* Identify Bison output. */
-
-#define COND 258
-#define REPEAT 259
-#define TYPE 260
-#define NAME 261
-#define NUMBER 262
-#define UNIT 263
-
-#line 1 "./sysinfo.y"
-
-#include <stdio.h>
-#include <stdlib.h>
-
-extern char *word;
-extern char writecode;
-extern int number;
-extern int unit;
-char nice_name[1000];
-char *it;
-int sofar;
-int width;
-int code;
-char * repeat;
-char *oldrepeat;
-char *name;
-int rdepth;
-char *loop [] = {"","n","m","/*BAD*/"};
-char *names[] = {" ","[n]","[n][m]"};
-char *pnames[]= {"","*","**"};
-
-#line 24 "./sysinfo.y"
-typedef union {
- int i;
- char *s;
-} YYSTYPE;
-
-#ifndef YYLTYPE
-typedef
- struct yyltype
- {
- int timestamp;
- int first_line;
- int first_column;
- int last_line;
- int last_column;
- char *text;
- }
- yyltype;
-
-#define YYLTYPE yyltype
-#endif
-
-#ifndef YYDEBUG
-#define YYDEBUG 1
-#endif
-
-#include <stdio.h>
-
-#ifndef __cplusplus
-#ifndef __STDC__
-#define const
-#endif
-#endif
-
-
-
-#define YYFINAL 55
-#define YYFLAG -32768
-#define YYNTBASE 11
-
-#define YYTRANSLATE(x) ((unsigned)(x) <= 263 ? yytranslate[x] : 29)
-
-static const char yytranslate[] = { 0,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 5,
- 6, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 1, 2, 3, 4, 7,
- 8, 9, 10
-};
-
-#if YYDEBUG != 0
-static const short yyprhs[] = { 0,
- 0, 1, 4, 7, 8, 9, 16, 19, 22, 25,
- 26, 27, 34, 35, 42, 43, 54, 56, 57, 61,
- 64, 68, 69, 70, 74, 75
-};
-
-static const short yyrhs[] = { -1,
- 12, 13, 0, 14, 13, 0, 0, 0, 5, 8,
- 9, 15, 16, 6, 0, 21, 16, 0, 19, 16,
- 0, 17, 16, 0, 0, 0, 5, 4, 8, 18,
- 16, 6, 0, 0, 5, 3, 8, 20, 16, 6,
- 0, 0, 5, 24, 5, 23, 25, 6, 26, 22,
- 27, 6, 0, 7, 0, 0, 5, 8, 6, 0,
- 9, 10, 0, 5, 8, 6, 0, 0, 0, 5,
- 28, 6, 0, 0, 28, 5, 8, 8, 6, 0
-};
-
-#endif
-
-#if YYDEBUG != 0
-static const short yyrline[] = { 0,
- 38, 59, 75, 76, 79, 130, 150, 152, 153, 154,
- 157, 186, 204, 217, 230, 233, 338, 340, 343, 348,
- 354, 356, 359, 360, 362, 363
-};
-
-static const char * const yytname[] = { "$","error","$undefined.","COND","REPEAT",
-"'('","')'","TYPE","NAME","NUMBER","UNIT","top","@1","it_list","it","@2","it_field_list",
-"repeat_it_field","@3","cond_it_field","@4","it_field","@5","attr_type","attr_desc",
-"attr_size","attr_id","enums","enum_list",""
-};
-#endif
-
-static const short yyr1[] = { 0,
- 12, 11, 13, 13, 15, 14, 16, 16, 16, 16,
- 18, 17, 20, 19, 22, 21, 23, 23, 24, 25,
- 26, 26, 27, 27, 28, 28
-};
-
-static const short yyr2[] = { 0,
- 0, 2, 2, 0, 0, 6, 2, 2, 2, 0,
- 0, 6, 0, 6, 0, 10, 1, 0, 3, 2,
- 3, 0, 0, 3, 0, 5
-};
-
-static const short yydefact[] = { 1,
- 4, 0, 2, 4, 0, 3, 5, 10, 0, 0,
- 10, 10, 10, 0, 0, 0, 0, 6, 9, 8,
- 7, 13, 11, 0, 18, 10, 10, 19, 17, 0,
- 0, 0, 0, 0, 14, 12, 20, 22, 0, 15,
- 0, 23, 21, 25, 0, 0, 16, 0, 24, 0,
- 0, 26, 0, 0, 0
-};
-
-static const short yydefgoto[] = { 53,
- 1, 3, 4, 8, 10, 11, 27, 12, 26, 13,
- 42, 30, 17, 34, 40, 45, 46
-};
-
-static const short yypact[] = {-32768,
- 3, 2,-32768, 3, 4,-32768,-32768, 6, 0, 8,
- 6, 6, 6, 9, 10, 11, 7,-32768,-32768,-32768,
--32768,-32768,-32768, 14, 15, 6, 6,-32768,-32768, 12,
- 17, 18, -1, 19,-32768,-32768,-32768, 21, 20,-32768,
- 23, 22,-32768,-32768, 24, 1,-32768, 25,-32768, 26,
- 29,-32768, 31, 32,-32768
-};
-
-static const short yypgoto[] = {-32768,
--32768, 33,-32768,-32768, -11,-32768,-32768,-32768,-32768,-32768,
--32768,-32768,-32768,-32768,-32768,-32768,-32768
-};
-
-
-#define YYLAST 37
-
-
-static const short yytable[] = { 19,
- 20, 21, 14, 15, 16, 48, 49, 2, 37, 5,
- 9, 25, 7, 18, 31, 32, 22, 23, 24, 28,
- 33, 29, 35, 36, 38, 39, 44, 41, 43, 47,
- 54, 55, 50, 51, 52, 0, 6
-};
-
-static const short yycheck[] = { 11,
- 12, 13, 3, 4, 5, 5, 6, 5, 10, 8,
- 5, 5, 9, 6, 26, 27, 8, 8, 8, 6,
- 9, 7, 6, 6, 6, 5, 5, 8, 6, 6,
- 0, 0, 8, 8, 6, -1, 4
-};
-/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
-#line 3 "/usr/unsupported/share/bison.simple"
-
-/* Skeleton output parser for bison,
- Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-#ifndef alloca
-#ifdef __GNUC__
-#define alloca __builtin_alloca
-#else /* not GNU C. */
-#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi)
-#include <alloca.h>
-#else /* not sparc */
-#if defined (MSDOS) && !defined (__TURBOC__)
-#include <malloc.h>
-#else /* not MSDOS, or __TURBOC__ */
-#if defined(_AIX)
-#include <malloc.h>
- #pragma alloca
-#else /* not MSDOS, __TURBOC__, or _AIX */
-#ifdef __hpux
-#ifdef __cplusplus
-extern "C" {
-void *alloca (unsigned int);
-};
-#else /* not __cplusplus */
-void *alloca ();
-#endif /* not __cplusplus */
-#endif /* __hpux */
-#endif /* not _AIX */
-#endif /* not MSDOS, or __TURBOC__ */
-#endif /* not sparc. */
-#endif /* not GNU C. */
-#endif /* alloca not defined. */
-
-/* This is the parser code that is written into each bison parser
- when the %semantic_parser declaration is not specified in the grammar.
- It was written by Richard Stallman by simplifying the hairy parser
- used when %semantic_parser is specified. */
-
-/* Note: there must be only one dollar sign in this file.
- It is replaced by the list of actions, each action
- as one case of the switch. */
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY -2
-#define YYEOF 0
-#define YYACCEPT return(0)
-#define YYABORT return(1)
-#define YYERROR goto yyerrlab1
-/* Like YYERROR except do call yyerror.
- This remains here temporarily to ease the
- transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. */
-#define YYFAIL goto yyerrlab
-#define YYRECOVERING() (!!yyerrstatus)
-#define YYBACKUP(token, value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { yychar = (token), yylval = (value); \
- yychar1 = YYTRANSLATE (yychar); \
- YYPOPSTACK; \
- goto yybackup; \
- } \
- else \
- { yyerror ("syntax error: cannot back up"); YYERROR; } \
-while (0)
-
-#define YYTERROR 1
-#define YYERRCODE 256
-
-#ifndef YYPURE
-#define YYLEX yylex()
-#endif
-
-#ifdef YYPURE
-#ifdef YYLSP_NEEDED
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval, &yylloc)
-#endif
-#else /* not YYLSP_NEEDED */
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval)
-#endif
-#endif /* not YYLSP_NEEDED */
-#endif
-
-/* If nonreentrant, generate the variables here */
-
-#ifndef YYPURE
-
-int yychar; /* the lookahead symbol */
-YYSTYPE yylval; /* the semantic value of the */
- /* lookahead symbol */
-
-#ifdef YYLSP_NEEDED
-YYLTYPE yylloc; /* location data for the lookahead */
- /* symbol */
-#endif
-
-int yynerrs; /* number of parse errors so far */
-#endif /* not YYPURE */
-
-#if YYDEBUG != 0
-int yydebug; /* nonzero means print parse trace */
-/* Since this is uninitialized, it does not stop multiple parsers
- from coexisting. */
-#endif
-
-/* YYINITDEPTH indicates the initial size of the parser's stacks */
-
-#ifndef YYINITDEPTH
-#define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH is the maximum size the stacks can grow to
- (effective only if the built-in stack extension method is used). */
-
-#if YYMAXDEPTH == 0
-#undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-#define YYMAXDEPTH 10000
-#endif
-
-/* Prevent warning if -Wstrict-prototypes. */
-#ifdef __GNUC__
-int yyparse (void);
-#endif
-
-#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
-#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT)
-#else /* not GNU C or C++ */
-#ifndef __cplusplus
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (from, to, count)
- char *from;
- char *to;
- int count;
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#else /* __cplusplus */
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (char *from, char *to, int count)
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#endif
-#endif
-
-#line 192 "/usr/unsupported/share/bison.simple"
-
-/* The user can define YYPARSE_PARAM as the name of an argument to be passed
- into yyparse. The argument should have type void *.
- It should actually point to an object.
- Grammar actions can access the variable by casting it
- to the proper pointer type. */
-
-#ifdef YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
-#else
-#define YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL
-#endif
-
-int
-yyparse(YYPARSE_PARAM)
- YYPARSE_PARAM_DECL
-{
- register int yystate;
- register int yyn;
- register short *yyssp;
- register YYSTYPE *yyvsp;
- int yyerrstatus; /* number of tokens to shift before error messages enabled */
- int yychar1 = 0; /* lookahead token as an internal (translated) token number */
-
- short yyssa[YYINITDEPTH]; /* the state stack */
- YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
-
- short *yyss = yyssa; /* refer to the stacks thru separate pointers */
- YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
-
-#ifdef YYLSP_NEEDED
- YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */
- YYLTYPE *yyls = yylsa;
- YYLTYPE *yylsp;
-
-#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
-#else
-#define YYPOPSTACK (yyvsp--, yyssp--)
-#endif
-
- int yystacksize = YYINITDEPTH;
-
-#ifdef YYPURE
- int yychar;
- YYSTYPE yylval;
- int yynerrs;
-#ifdef YYLSP_NEEDED
- YYLTYPE yylloc;
-#endif
-#endif
-
- YYSTYPE yyval; /* the variable used to return */
- /* semantic values from the action */
- /* routines */
-
- int yylen;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Starting parse\n");
-#endif
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
-
- yyssp = yyss - 1;
- yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
- yylsp = yyls;
-#endif
-
-/* Push a new state, which is found in yystate . */
-/* In all cases, when you get here, the value and location stacks
- have just been pushed. so pushing a state here evens the stacks. */
-yynewstate:
-
- *++yyssp = yystate;
-
- if (yyssp >= yyss + yystacksize - 1)
- {
- /* Give user a chance to reallocate the stack */
- /* Use copies of these so that the &'s don't force the real ones into memory. */
- YYSTYPE *yyvs1 = yyvs;
- short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
- YYLTYPE *yyls1 = yyls;
-#endif
-
- /* Get the current used size of the three stacks, in elements. */
- int size = yyssp - yyss + 1;
-
-#ifdef yyoverflow
- /* Each stack pointer address is followed by the size of
- the data in use in that stack, in bytes. */
-#ifdef YYLSP_NEEDED
- /* This used to be a conditional around just the two extra args,
- but that might be undefined if yyoverflow is a macro. */
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yyls1, size * sizeof (*yylsp),
- &yystacksize);
-#else
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yystacksize);
-#endif
-
- yyss = yyss1; yyvs = yyvs1;
-#ifdef YYLSP_NEEDED
- yyls = yyls1;
-#endif
-#else /* no yyoverflow */
- /* Extend the stack our own way. */
- if (yystacksize >= YYMAXDEPTH)
- {
- yyerror("parser stack overflow");
- return 2;
- }
- yystacksize *= 2;
- if (yystacksize > YYMAXDEPTH)
- yystacksize = YYMAXDEPTH;
- yyss = (short *) alloca (yystacksize * sizeof (*yyssp));
- __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp));
- yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp));
- __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp));
-#ifdef YYLSP_NEEDED
- yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp));
- __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp));
-#endif
-#endif /* no yyoverflow */
-
- yyssp = yyss + size - 1;
- yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
- yylsp = yyls + size - 1;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Stack size increased to %d\n", yystacksize);
-#endif
-
- if (yyssp >= yyss + yystacksize - 1)
- YYABORT;
- }
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Entering state %d\n", yystate);
-#endif
-
- goto yybackup;
- yybackup:
-
-/* Do appropriate processing given the current state. */
-/* Read a lookahead token if we need one and don't already have one. */
-/* yyresume: */
-
- /* First try to decide what to do without reference to lookahead token. */
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* yychar is either YYEMPTY or YYEOF
- or a valid token in external form. */
-
- if (yychar == YYEMPTY)
- {
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Reading a token: ");
-#endif
- yychar = YYLEX;
- }
-
- /* Convert token to internal form (in yychar1) for indexing tables with */
-
- if (yychar <= 0) /* This means end of input. */
- {
- yychar1 = 0;
- yychar = YYEOF; /* Don't call YYLEX any more */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Now at end of input.\n");
-#endif
- }
- else
- {
- yychar1 = YYTRANSLATE(yychar);
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
- /* Give the individual parser a way to print the precise meaning
- of a token, for further debugging info. */
-#ifdef YYPRINT
- YYPRINT (stderr, yychar, yylval);
-#endif
- fprintf (stderr, ")\n");
- }
-#endif
- }
-
- yyn += yychar1;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
- goto yydefault;
-
- yyn = yytable[yyn];
-
- /* yyn is what to do for this token type in this state.
- Negative => reduce, -yyn is rule number.
- Positive => shift, yyn is new state.
- New state is final state => don't bother to shift,
- just return success.
- 0, or most negative number => error. */
-
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrlab;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- /* Shift the lookahead token. */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
-#endif
-
- /* Discard the token being shifted unless it is eof. */
- if (yychar != YYEOF)
- yychar = YYEMPTY;
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- /* count tokens shifted since error; after three, turn off error status. */
- if (yyerrstatus) yyerrstatus--;
-
- yystate = yyn;
- goto yynewstate;
-
-/* Do the default action for the current state. */
-yydefault:
-
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
-
-/* Do a reduction. yyn is the number of a rule to reduce with. */
-yyreduce:
- yylen = yyr2[yyn];
- if (yylen > 0)
- yyval = yyvsp[1-yylen]; /* implement default value of the action */
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- int i;
-
- fprintf (stderr, "Reducing via rule %d (line %d), ",
- yyn, yyrline[yyn]);
-
- /* Print the symbols being reduced, and their result. */
- for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
- fprintf (stderr, "%s ", yytname[yyrhs[i]]);
- fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
- }
-#endif
-
-
- switch (yyn) {
-
-case 1:
-#line 38 "./sysinfo.y"
-{
- switch (writecode)
- {
- case 'i':
- printf("#ifdef SYSROFF_SWAP_IN\n");
- break;
- case 'p':
- printf("#ifdef SYSROFF_p\n");
- break;
- case 'd':
- break;
- case 'g':
- printf("#ifdef SYSROFF_SWAP_OUT\n");
- break;
- case 'c':
- printf("#ifdef SYSROFF_PRINT\n");
- printf("#include <stdio.h>\n");
- printf("#include <stdlib.h>\n");
- break;
- }
- ;
- break;}
-case 2:
-#line 59 "./sysinfo.y"
-{
- switch (writecode) {
- case 'i':
- case 'p':
- case 'g':
- case 'c':
- printf("#endif\n");
- break;
- case 'd':
- break;
- }
-;
- break;}
-case 5:
-#line 81 "./sysinfo.y"
-{
- it = yyvsp[-1].s; code = yyvsp[0].i;
- switch (writecode)
- {
- case 'd':
- printf("\n\n\n#define IT_%s_CODE 0x%x\n", it,code);
- printf("struct IT_%s { \n", it);
- break;
- case 'i':
- printf("void sysroff_swap_%s_in(ptr)\n",yyvsp[-1].s);
- printf("struct IT_%s *ptr;\n", it);
- printf("{\n");
- printf("char raw[255];\n");
- printf("\tint idx = 0 ;\n");
- printf("\tint size;\n");
- printf("memset(raw,0,255);\n");
- printf("memset(ptr,0,sizeof(*ptr));\n");
- printf("size = fillup(raw);\n");
- break;
- case 'g':
- printf("void sysroff_swap_%s_out(file,ptr)\n",yyvsp[-1].s);
- printf("FILE * file;\n");
- printf("struct IT_%s *ptr;\n", it);
- printf("{\n");
- printf("\tchar raw[255];\n");
- printf("\tint idx = 16 ;\n");
- printf("\tmemset (raw, 0, 255);\n");
- printf("\tcode = IT_%s_CODE;\n", it);
- break;
- case 'o':
- printf("void sysroff_swap_%s_out(abfd,ptr)\n",yyvsp[-1].s);
- printf("bfd * abfd;\n");
- printf("struct IT_%s *ptr;\n",it);
- printf("{\n");
- printf("int idx = 0 ;\n");
- break;
- case 'c':
- printf("void sysroff_print_%s_out(ptr)\n",yyvsp[-1].s);
- printf("struct IT_%s *ptr;\n", it);
- printf("{\n");
- printf("itheader(\"%s\", IT_%s_CODE);\n",yyvsp[-1].s,yyvsp[-1].s);
- break;
-
- case 't':
- break;
- }
-
- ;
- break;}
-case 6:
-#line 131 "./sysinfo.y"
-{
- switch (writecode) {
- case 'd':
- printf("};\n");
- break;
- case 'g':
- printf("\tchecksum(file,raw, idx, IT_%s_CODE);\n", it);
-
- case 'i':
-
- case 'o':
- case 'c':
- printf("}\n");
- }
-;
- break;}
-case 11:
-#line 158 "./sysinfo.y"
-{
- rdepth++;
- switch (writecode)
- {
- case 'c':
- if (rdepth==1)
- printf("\tprintf(\"repeat %%d\\n\", %s);\n",yyvsp[0].s);
- if (rdepth==2)
- printf("\tprintf(\"repeat %%d\\n\", %s[n]);\n",yyvsp[0].s);
- case 'i':
- case 'g':
- case 'o':
-
- if (rdepth==1)
- {
- printf("\t{ int n; for (n = 0; n < %s; n++) {\n", yyvsp[0].s);
- }
- if (rdepth == 2) {
- printf("\t{ int m; for (m = 0; m < %s[n]; m++) {\n", yyvsp[0].s);
- }
-
- break;
- }
-
- oldrepeat = repeat;
- repeat = yyvsp[0].s;
- ;
- break;}
-case 12:
-#line 188 "./sysinfo.y"
-{
- repeat = oldrepeat;
- oldrepeat =0;
- rdepth--;
- switch (writecode)
- {
- case 'i':
- case 'g':
- case 'o':
- case 'c':
- printf("\t}}\n");
- }
- ;
- break;}
-case 13:
-#line 205 "./sysinfo.y"
-{
- switch (writecode)
- {
- case 'i':
- case 'g':
- case 'o':
- case 'c':
- printf("\tif (%s) {\n", yyvsp[0].s);
- break;
- }
- ;
- break;}
-case 14:
-#line 218 "./sysinfo.y"
-{
- switch (writecode)
- {
- case 'i':
- case 'g':
- case 'o':
- case 'c':
- printf("\t}\n");
- }
- ;
- break;}
-case 15:
-#line 232 "./sysinfo.y"
-{name = yyvsp[0].s; ;
- break;}
-case 16:
-#line 234 "./sysinfo.y"
-{
- char *desc = yyvsp[-8].s;
- char *type = yyvsp[-6].s;
- int size = yyvsp[-5].i;
- char *id = yyvsp[-3].s;
-char *p = names[rdepth];
-char *ptr = pnames[rdepth];
- switch (writecode)
- {
- case 'g':
- if (size % 8)
- {
-
- printf("\twriteBITS(ptr->%s%s,raw,&idx,%d);\n",
- id,
- names[rdepth], size);
-
- }
- else {
- printf("\twrite%s(ptr->%s%s,raw,&idx,%d,file);\n",
- type,
- id,
- names[rdepth],size/8);
- }
- break;
- case 'i':
- {
-
- if (rdepth >= 1)
-
- {
- printf("if (!ptr->%s) ptr->%s = (%s*)xcalloc(%s, sizeof(ptr->%s[0]));\n",
- id,
- id,
- type,
- repeat,
- id);
- }
-
- if (rdepth == 2)
- {
- printf("if (!ptr->%s[n]) ptr->%s[n] = (%s**)xcalloc(%s[n], sizeof(ptr->%s[n][0]));\n",
- id,
- id,
- type,
- repeat,
- id);
- }
-
- }
-
- if (size % 8)
- {
- printf("\tptr->%s%s = getBITS(raw,&idx, %d,size);\n",
- id,
- names[rdepth],
- size);
- }
- else {
- printf("\tptr->%s%s = get%s(raw,&idx, %d,size);\n",
- id,
- names[rdepth],
- type,
- size/8);
- }
- break;
- case 'o':
- printf("\tput%s(raw,%d,%d,&idx,ptr->%s%s);\n", type,size/8,size%8,id,names[rdepth]);
- break;
- case 'd':
- if (repeat)
- printf("\t/* repeat %s */\n", repeat);
-
- if (type[0] == 'I') {
- printf("\tint %s%s; \t/* %s */\n",ptr,id, desc);
- }
- else if (type[0] =='C') {
- printf("\tchar %s*%s;\t /* %s */\n",ptr,id, desc);
- }
- else {
- printf("\tbarray %s%s;\t /* %s */\n",ptr,id, desc);
- }
- break;
- case 'c':
- printf("tabout();\n");
- printf("\tprintf(\"/*%-30s*/ ptr->%s = \");\n", desc, id);
-
- if (type[0] == 'I')
- printf("\tprintf(\"%%d\\n\",ptr->%s%s);\n", id,p);
- else if (type[0] == 'C')
- printf("\tprintf(\"%%s\\n\",ptr->%s%s);\n", id,p);
-
- else if (type[0] == 'B')
- {
- printf("\tpbarray(&ptr->%s%s);\n", id,p);
- }
- else abort();
- break;
- }
- ;
- break;}
-case 17:
-#line 339 "./sysinfo.y"
-{ yyval.s = yyvsp[0].s; ;
- break;}
-case 18:
-#line 340 "./sysinfo.y"
-{ yyval.s = "INT";;
- break;}
-case 19:
-#line 345 "./sysinfo.y"
-{ yyval.s = yyvsp[-1].s; ;
- break;}
-case 20:
-#line 350 "./sysinfo.y"
-{ yyval.i = yyvsp[-1].i * yyvsp[0].i; ;
- break;}
-case 21:
-#line 355 "./sysinfo.y"
-{ yyval.s = yyvsp[-1].s; ;
- break;}
-case 22:
-#line 356 "./sysinfo.y"
-{ yyval.s = "dummy";;
- break;}
-case 26:
-#line 364 "./sysinfo.y"
-{
- switch (writecode)
- {
- case 'd':
- printf("#define %s %s\n", yyvsp[-2].s,yyvsp[-1].s);
- break;
- case 'c':
- printf("if (ptr->%s%s == %s) { tabout(); printf(\"%s\\n\");}\n", name, names[rdepth],yyvsp[-1].s,yyvsp[-2].s);
- }
- ;
- break;}
-}
- /* the action file gets copied in in place of this dollarsign */
-#line 487 "/usr/unsupported/share/bison.simple"
-
- yyvsp -= yylen;
- yyssp -= yylen;
-#ifdef YYLSP_NEEDED
- yylsp -= yylen;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
- *++yyvsp = yyval;
-
-#ifdef YYLSP_NEEDED
- yylsp++;
- if (yylen == 0)
- {
- yylsp->first_line = yylloc.first_line;
- yylsp->first_column = yylloc.first_column;
- yylsp->last_line = (yylsp-1)->last_line;
- yylsp->last_column = (yylsp-1)->last_column;
- yylsp->text = 0;
- }
- else
- {
- yylsp->last_line = (yylsp+yylen-1)->last_line;
- yylsp->last_column = (yylsp+yylen-1)->last_column;
- }
-#endif
-
- /* Now "shift" the result of the reduction.
- Determine what state that goes to,
- based on the state we popped back to
- and the rule number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
- if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTBASE];
-
- goto yynewstate;
-
-yyerrlab: /* here on detecting error */
-
- if (! yyerrstatus)
- /* If not already recovering from an error, report this error. */
- {
- ++yynerrs;
-
-#ifdef YYERROR_VERBOSE
- yyn = yypact[yystate];
-
- if (yyn > YYFLAG && yyn < YYLAST)
- {
- int size = 0;
- char *msg;
- int x, count;
-
- count = 0;
- /* Start X at -yyn if nec to avoid negative indexes in yycheck. */
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- size += strlen(yytname[x]) + 15, count++;
- msg = (char *) malloc(size + 15);
- if (msg != 0)
- {
- strcpy(msg, "parse error");
-
- if (count < 5)
- {
- count = 0;
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- {
- strcat(msg, count == 0 ? ", expecting `" : " or `");
- strcat(msg, yytname[x]);
- strcat(msg, "'");
- count++;
- }
- }
- yyerror(msg);
- free(msg);
- }
- else
- yyerror ("parse error; also virtual memory exceeded");
- }
- else
-#endif /* YYERROR_VERBOSE */
- yyerror("parse error");
- }
-
- goto yyerrlab1;
-yyerrlab1: /* here on error raised explicitly by an action */
-
- if (yyerrstatus == 3)
- {
- /* if just tried and failed to reuse lookahead token after an error, discard it. */
-
- /* return failure if at end of input */
- if (yychar == YYEOF)
- YYABORT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
-#endif
-
- yychar = YYEMPTY;
- }
-
- /* Else will try to reuse lookahead token
- after shifting the error token. */
-
- yyerrstatus = 3; /* Each real token shifted decrements this */
-
- goto yyerrhandle;
-
-yyerrdefault: /* current state does not do anything special for the error token. */
-
-#if 0
- /* This is wrong; only states that explicitly want error tokens
- should shift them. */
- yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
- if (yyn) goto yydefault;
-#endif
-
-yyerrpop: /* pop the current state because it cannot handle the error token */
-
- if (yyssp == yyss) YYABORT;
- yyvsp--;
- yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
- yylsp--;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "Error: state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
-yyerrhandle:
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yyerrdefault;
-
- yyn += YYTERROR;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
- goto yyerrdefault;
-
- yyn = yytable[yyn];
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrpop;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrpop;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting error token, ");
-#endif
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- yystate = yyn;
- goto yynewstate;
-}
-#line 379 "./sysinfo.y"
-
-/* four modes
-
- -d write structure defintions for sysroff in host format
- -i write functions to swap into sysroff format in
- -o write functions to swap into sysroff format out
- -c write code to print info in human form */
-
-int yydebug;
-char writecode;
-
-int
-main(ac,av)
-int ac;
-char **av;
-{
- yydebug=0;
- if (ac > 1)
- writecode = av[1][1];
-if (writecode == 'd')
- {
- printf("typedef struct { unsigned char *data; int len; } barray; \n");
- printf("typedef int INT;\n");
- printf("typedef char * CHARS;\n");
-
- }
- yyparse();
-return 0;
-}
-
-int yyerror(s)
- char *s;
-{
- fprintf(stderr, "%s\n" , s);
-}
diff --git a/gnu/usr.bin/binutils/binutils/sysinfo.h b/gnu/usr.bin/binutils/binutils/sysinfo.h
deleted file mode 100644
index e8e2d25765e..00000000000
--- a/gnu/usr.bin/binutils/binutils/sysinfo.h
+++ /dev/null
@@ -1,13 +0,0 @@
-typedef union {
- int i;
- char *s;
-} YYSTYPE;
-#define COND 258
-#define REPEAT 259
-#define TYPE 260
-#define NAME 261
-#define NUMBER 262
-#define UNIT 263
-
-
-extern YYSTYPE yylval;
diff --git a/gnu/usr.bin/binutils/binutils/syslex.c b/gnu/usr.bin/binutils/binutils/syslex.c
deleted file mode 100644
index 338dd6c0b69..00000000000
--- a/gnu/usr.bin/binutils/binutils/syslex.c
+++ /dev/null
@@ -1,1651 +0,0 @@
-/* A lexical scanner generated by flex */
-
-/* Scanner skeleton version:
- * $Header: /home/cvs/src/gnu/usr.bin/binutils/binutils/Attic/syslex.c,v 1.1.1.1 1996/01/08 11:03:58 niklas Exp $
- */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 5
-
-#include <stdio.h>
-
-
-/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
-#ifdef c_plusplus
-#ifndef __cplusplus
-#define __cplusplus
-#endif
-#endif
-
-
-#ifdef __cplusplus
-
-#include <stdlib.h>
-#include <unistd.h>
-
-/* Use prototypes in function declarations. */
-#define YY_USE_PROTOS
-
-/* The "const" storage-class-modifier is valid. */
-#define YY_USE_CONST
-
-#else /* ! __cplusplus */
-
-#if __STDC__
-
-#define YY_USE_PROTOS
-#define YY_USE_CONST
-
-#endif /* __STDC__ */
-#endif /* ! __cplusplus */
-
-#ifdef __TURBOC__
- #pragma warn -rch
- #pragma warn -use
-#include <io.h>
-#include <stdlib.h>
-#define YY_USE_CONST
-#define YY_USE_PROTOS
-#endif
-
-#ifdef YY_USE_CONST
-#define yyconst const
-#else
-#define yyconst
-#endif
-
-
-#ifdef YY_USE_PROTOS
-#define YY_PROTO(proto) proto
-#else
-#define YY_PROTO(proto) ()
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an unsigned
- * integer for use as an array index. If the signed char is negative,
- * we want to instead treat it as an 8-bit unsigned char, hence the
- * double cast.
- */
-#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
-
-/* Enter a start condition. This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yy_start = 1 + 2 *
-
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state. The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yy_start - 1) / 2)
-#define YYSTATE YY_START
-
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin )
-
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#define YY_BUF_SIZE 16384
-
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-
-extern int yyleng;
-extern FILE *yyin, *yyout;
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
-/* The funky do-while in the following #define is used to turn the definition
- * int a single C statement (which needs a semi-colon terminator). This
- * avoids problems with code like:
- *
- * if ( condition_holds )
- * yyless( 5 );
- * else
- * do_something_else();
- *
- * Prior to using the do-while the compiler would get upset at the
- * "else" because it interpreted the "if" statement as being all
- * done when it reached the ';' after the yyless() call.
- */
-
-/* Return all but the first 'n' matched characters back to the input stream. */
-
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- *yy_cp = yy_hold_char; \
- yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- } \
- while ( 0 )
-
-#define unput(c) yyunput( c, yytext_ptr )
-
-/* The following is because we cannot portably get our hands on size_t
- * (without autoconf's help, which isn't available because we want
- * flex-generated scanners to compile on their own).
- */
-typedef unsigned int yy_size_t;
-
-
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- yy_size_t yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
- /* When an EOF's been seen but there's still some text to process
- * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- * shouldn't try reading from the input source any more. We might
- * still have a bunch of tokens to match, though, because of
- * possible backing-up.
- *
- * When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
- * just pointing yyin at a new input file.
- */
-#define YY_BUFFER_EOF_PENDING 2
- };
-
-static YY_BUFFER_STATE yy_current_buffer = 0;
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- */
-#define YY_CURRENT_BUFFER yy_current_buffer
-
-
-/* yy_hold_char holds the character lost when yytext is formed. */
-static char yy_hold_char;
-
-static int yy_n_chars; /* number of characters read into yy_ch_buf */
-
-
-int yyleng;
-
-/* Points to current character in buffer. */
-static char *yy_c_buf_p = (char *) 0;
-static int yy_init = 1; /* whether we need to initialize */
-static int yy_start = 0; /* start state number */
-
-/* Flag which is used to allow yywrap()'s to do buffer switches
- * instead of setting up a fresh yyin. A bit of a hack ...
- */
-static int yy_did_buffer_switch_on_eof;
-
-void yyrestart YY_PROTO(( FILE *input_file ));
-
-void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
-void yy_load_buffer_state YY_PROTO(( void ));
-YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
-void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
-void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-#define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
-
-YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
-YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *str ));
-YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
-
-static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
-static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
-static void yy_flex_free YY_PROTO(( void * ));
-
-#define yy_new_buffer yy_create_buffer
-
-#define yy_set_interactive(is_interactive) \
- { \
- if ( ! yy_current_buffer ) \
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
- yy_current_buffer->yy_is_interactive = is_interactive; \
- }
-
-#define yy_set_bol(at_bol) \
- { \
- if ( ! yy_current_buffer ) \
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
- yy_current_buffer->yy_at_bol = at_bol; \
- }
-
-#define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
-
-typedef unsigned char YY_CHAR;
-FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
-typedef int yy_state_type;
-extern char *yytext;
-#define yytext_ptr yytext
-
-static yy_state_type yy_get_previous_state YY_PROTO(( void ));
-static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
-static int yy_get_next_buffer YY_PROTO(( void ));
-static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
- yytext_ptr = yy_bp; \
- yyleng = (int) (yy_cp - yy_bp); \
- yy_hold_char = *yy_cp; \
- *yy_cp = '\0'; \
- yy_c_buf_p = yy_cp;
-
-#define YY_NUM_RULES 25
-#define YY_END_OF_BUFFER 26
-static yyconst short int yy_accept[81] =
- { 0,
- 0, 0, 26, 25, 7, 8, 5, 25, 1, 2,
- 11, 11, 6, 3, 4, 25, 25, 25, 25, 25,
- 25, 25, 0, 9, 11, 0, 6, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 10, 0, 0,
- 13, 0, 0, 0, 0, 16, 0, 0, 0, 0,
- 0, 12, 15, 0, 23, 0, 0, 0, 0, 0,
- 0, 14, 18, 0, 0, 0, 0, 0, 17, 0,
- 24, 0, 0, 0, 20, 22, 0, 21, 19, 0
- } ;
-
-static yyconst int yy_ec[256] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 4, 1, 5, 1, 1, 1, 1, 1, 6,
- 7, 1, 1, 1, 1, 1, 1, 8, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 1, 10, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 11, 1, 12, 1, 1, 1, 13, 14, 15, 16,
-
- 17, 18, 19, 20, 21, 1, 1, 22, 1, 23,
- 24, 25, 1, 26, 27, 28, 29, 30, 1, 31,
- 32, 33, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1
- } ;
-
-static yyconst int yy_meta[34] =
- { 0,
- 1, 1, 2, 1, 1, 1, 1, 3, 3, 1,
- 1, 1, 3, 3, 3, 3, 3, 3, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1
- } ;
-
-static yyconst short int yy_base[84] =
- { 0,
- 0, 0, 100, 101, 101, 101, 101, 94, 101, 101,
- 26, 28, 0, 101, 101, 82, 26, 18, 74, 79,
- 78, 81, 88, 101, 32, 0, 0, 76, 65, 62,
- 61, 75, 20, 59, 61, 66, 58, 0, 57, 56,
- 54, 63, 53, 62, 54, 101, 59, 48, 53, 46,
- 59, 101, 44, 43, 101, 41, 55, 46, 53, 44,
- 31, 101, 101, 39, 27, 21, 39, 19, 101, 35,
- 101, 33, 26, 29, 101, 101, 28, 101, 101, 101,
- 58, 61, 41
- } ;
-
-static yyconst short int yy_def[84] =
- { 0,
- 80, 1, 80, 80, 80, 80, 80, 81, 80, 80,
- 80, 80, 82, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 81, 80, 80, 83, 82, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 83, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 0,
- 80, 80, 80
- } ;
-
-static yyconst short int yy_nxt[135] =
- { 0,
- 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,
- 14, 15, 16, 17, 18, 4, 4, 4, 4, 4,
- 19, 4, 4, 4, 4, 20, 21, 4, 4, 22,
- 4, 4, 4, 25, 25, 25, 25, 32, 29, 25,
- 25, 33, 44, 38, 79, 78, 30, 77, 45, 76,
- 75, 74, 73, 72, 71, 70, 26, 31, 23, 23,
- 23, 27, 69, 27, 68, 67, 66, 65, 64, 63,
- 62, 61, 60, 59, 58, 57, 56, 55, 54, 53,
- 52, 51, 50, 49, 48, 47, 46, 43, 42, 41,
- 40, 39, 24, 37, 36, 35, 34, 28, 24, 80,
-
- 3, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80
- } ;
-
-static yyconst short int yy_chk[135] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 11, 11, 12, 12, 18, 17, 25,
- 25, 18, 33, 83, 77, 74, 17, 73, 33, 72,
- 70, 68, 67, 66, 65, 64, 11, 17, 81, 81,
- 81, 82, 61, 82, 60, 59, 58, 57, 56, 54,
- 53, 51, 50, 49, 48, 47, 45, 44, 43, 42,
- 41, 40, 39, 37, 36, 35, 34, 32, 31, 30,
- 29, 28, 23, 22, 21, 20, 19, 16, 8, 3,
-
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
- 80, 80, 80, 80
- } ;
-
-static yy_state_type yy_last_accepting_state;
-static char *yy_last_accepting_cpos;
-
-/* The intent behind this definition is that it'll catch
- * any uses of REJECT which flex missed.
- */
-#define REJECT reject_used_but_not_detected
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-char *yytext;
-#line 1 "./syslex.l"
-#define INITIAL 0
-#line 2 "./syslex.l"
-#include "sysinfo.h"
-char *word;
-int number;
-int unit;
-
-#ifndef yywrap
-static int yywrap () { return 1; }
-#endif
-#line 424 "lex.yy.c"
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap YY_PROTO(( void ));
-#else
-extern int yywrap YY_PROTO(( void ));
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-static void yyunput YY_PROTO(( int c, char *buf_ptr ));
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput YY_PROTO(( void ));
-#else
-static int input YY_PROTO(( void ));
-#endif
-#endif
-
-#if YY_STACK_USED
-static int yy_start_stack_ptr = 0;
-static int yy_start_stack_depth = 0;
-static int *yy_start_stack = 0;
-#ifndef YY_NO_PUSH_STATE
-static void yy_push_state YY_PROTO(( int new_state ));
-#endif
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state YY_PROTO(( void ));
-#endif
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state YY_PROTO(( void ));
-#endif
-
-#else
-#define YY_NO_PUSH_STATE 1
-#define YY_NO_POP_STATE 1
-#define YY_NO_TOP_STATE 1
-#endif
-
-#ifdef YY_MALLOC_DECL
-YY_MALLOC_DECL
-#else
-#if __STDC__
-#ifndef __cplusplus
-#include <stdlib.h>
-#endif
-#else
-/* Just try to get by without declaring the routines. This will fail
- * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
- * or sizeof(void*) != sizeof(int).
- */
-#endif
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#define YY_READ_BUF_SIZE 8192
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
-#endif
-
-/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
- if ( yy_current_buffer->yy_is_interactive ) \
- { \
- int c = '*', n; \
- for ( n = 0; n < max_size && \
- (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
- buf[n] = (char) c; \
- if ( c == '\n' ) \
- buf[n++] = (char) c; \
- if ( c == EOF && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- result = n; \
- } \
- else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
- && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" );
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL int yylex YY_PROTO(( void ))
-#endif
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK break;
-#endif
-
-#define YY_RULE_SETUP \
- YY_USER_ACTION
-
-YY_DECL
- {
- register yy_state_type yy_current_state;
- register char *yy_cp, *yy_bp;
- register int yy_act;
-
-#line 11 "./syslex.l"
-
-#line 573 "lex.yy.c"
-
- if ( yy_init )
- {
- yy_init = 0;
-
-#ifdef YY_USER_INIT
- YY_USER_INIT;
-#endif
-
- if ( ! yy_start )
- yy_start = 1; /* first start state */
-
- if ( ! yyin )
- yyin = stdin;
-
- if ( ! yyout )
- yyout = stdout;
-
- if ( ! yy_current_buffer )
- yy_current_buffer =
- yy_create_buffer( yyin, YY_BUF_SIZE );
-
- yy_load_buffer_state();
- }
-
- while ( 1 ) /* loops until end-of-file is reached */
- {
- yy_cp = yy_c_buf_p;
-
- /* Support of yytext. */
- *yy_cp = yy_hold_char;
-
- /* yy_bp points to the position in yy_ch_buf of the start of
- * the current run.
- */
- yy_bp = yy_cp;
-
- yy_current_state = yy_start;
-yy_match:
- do
- {
- register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 81 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- ++yy_cp;
- }
- while ( yy_base[yy_current_state] != 101 );
-
-yy_find_action:
- yy_act = yy_accept[yy_current_state];
- if ( yy_act == 0 )
- { /* have to back up */
- yy_cp = yy_last_accepting_cpos;
- yy_current_state = yy_last_accepting_state;
- yy_act = yy_accept[yy_current_state];
- }
-
- YY_DO_BEFORE_ACTION;
-
-
-do_action: /* This label is used only to access EOF actions. */
-
-
- switch ( yy_act )
- { /* beginning of action switch */
- case 0: /* must back up */
- /* undo the effects of YY_DO_BEFORE_ACTION */
- *yy_cp = yy_hold_char;
- yy_cp = yy_last_accepting_cpos;
- yy_current_state = yy_last_accepting_state;
- goto yy_find_action;
-
-case 1:
-YY_RULE_SETUP
-#line 12 "./syslex.l"
-{ return '(';}
- YY_BREAK
-case 2:
-YY_RULE_SETUP
-#line 13 "./syslex.l"
-{ return ')';}
- YY_BREAK
-case 3:
-YY_RULE_SETUP
-#line 14 "./syslex.l"
-{ return '[';}
- YY_BREAK
-case 4:
-YY_RULE_SETUP
-#line 15 "./syslex.l"
-{ return ']';}
- YY_BREAK
-case 5:
-YY_RULE_SETUP
-#line 16 "./syslex.l"
-{ ; }
- YY_BREAK
-case 6:
-YY_RULE_SETUP
-#line 17 "./syslex.l"
-{ ; }
- YY_BREAK
-case 7:
-YY_RULE_SETUP
-#line 18 "./syslex.l"
-{ ; }
- YY_BREAK
-case 8:
-YY_RULE_SETUP
-#line 19 "./syslex.l"
-{ ; }
- YY_BREAK
-case 9:
-YY_RULE_SETUP
-#line 20 "./syslex.l"
-{
-yylval.s = malloc(strlen (yytext));
-strcpy(yylval.s, yytext+1);
-yylval.s[strlen(yylval.s)-1] = 0;
- return NAME;
- }
- YY_BREAK
-case 10:
-YY_RULE_SETUP
-#line 27 "./syslex.l"
-{
- yylval.i = strtol(yytext,0,16);
- return NUMBER;
- }
- YY_BREAK
-case 11:
-YY_RULE_SETUP
-#line 32 "./syslex.l"
-{
- yylval.i = atoi(yytext);
- return NUMBER;
- }
- YY_BREAK
-case 12:
-YY_RULE_SETUP
-#line 38 "./syslex.l"
-{ yylval.i =1 ;return UNIT;}
- YY_BREAK
-case 13:
-YY_RULE_SETUP
-#line 39 "./syslex.l"
-{ yylval.i = 1; return UNIT;}
- YY_BREAK
-case 14:
-YY_RULE_SETUP
-#line 40 "./syslex.l"
-{ yylval.i= 8; return UNIT;}
- YY_BREAK
-case 15:
-YY_RULE_SETUP
-#line 41 "./syslex.l"
-{ yylval.i = 8; return UNIT;}
- YY_BREAK
-case 16:
-YY_RULE_SETUP
-#line 43 "./syslex.l"
-{ yylval.s = "INT"; return TYPE;}
- YY_BREAK
-case 17:
-YY_RULE_SETUP
-#line 44 "./syslex.l"
-{ yylval.s = "BARRAY"; return TYPE;}
- YY_BREAK
-case 18:
-YY_RULE_SETUP
-#line 45 "./syslex.l"
-{ yylval.s = "CHARS"; return TYPE;}
- YY_BREAK
-case 19:
-YY_RULE_SETUP
-#line 46 "./syslex.l"
-{ yylval.i = 0; return NUMBER;}
- YY_BREAK
-case 20:
-YY_RULE_SETUP
-#line 47 "./syslex.l"
-{ yylval.i = -4; return NUMBER;}
- YY_BREAK
-case 21:
-YY_RULE_SETUP
-#line 48 "./syslex.l"
-{ yylval.i = -2; return NUMBER; }
- YY_BREAK
-case 22:
-YY_RULE_SETUP
-#line 49 "./syslex.l"
-{ yylval.i = -1; return NUMBER; }
- YY_BREAK
-case 23:
-YY_RULE_SETUP
-#line 50 "./syslex.l"
-{ return COND;}
- YY_BREAK
-case 24:
-YY_RULE_SETUP
-#line 51 "./syslex.l"
-{ return REPEAT;}
- YY_BREAK
-case 25:
-YY_RULE_SETUP
-#line 52 "./syslex.l"
-ECHO;
- YY_BREAK
-#line 792 "lex.yy.c"
-case YY_STATE_EOF(INITIAL):
- yyterminate();
-
- case YY_END_OF_BUFFER:
- {
- /* Amount of text matched not including the EOB char. */
- int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
-
- /* Undo the effects of YY_DO_BEFORE_ACTION. */
- *yy_cp = yy_hold_char;
-
- if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
- {
- /* We're scanning a new file or input source. It's
- * possible that this happened because the user
- * just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
- * consistency between yy_current_buffer and our
- * globals. Here is the right place to do so, because
- * this is the first action (other than possibly a
- * back-up) that will match for the new input source.
- */
- yy_n_chars = yy_current_buffer->yy_n_chars;
- yy_current_buffer->yy_input_file = yyin;
- yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
- }
-
- /* Note that here we test for yy_c_buf_p "<=" to the position
- * of the first EOB in the buffer, since yy_c_buf_p will
- * already have been incremented past the NUL character
- * (since all states make transitions on EOB to the
- * end-of-buffer state). Contrast this with the test
- * in input().
- */
- if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- { /* This was really a NUL. */
- yy_state_type yy_next_state;
-
- yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state();
-
- /* Okay, we're now positioned to make the NUL
- * transition. We couldn't have
- * yy_get_previous_state() go ahead and do it
- * for us because it doesn't know how to deal
- * with the possibility of jamming (and we don't
- * want to build jamming into it because then it
- * will run more slowly).
- */
-
- yy_next_state = yy_try_NUL_trans( yy_current_state );
-
- yy_bp = yytext_ptr + YY_MORE_ADJ;
-
- if ( yy_next_state )
- {
- /* Consume the NUL. */
- yy_cp = ++yy_c_buf_p;
- yy_current_state = yy_next_state;
- goto yy_match;
- }
-
- else
- {
- yy_cp = yy_c_buf_p;
- goto yy_find_action;
- }
- }
-
- else switch ( yy_get_next_buffer() )
- {
- case EOB_ACT_END_OF_FILE:
- {
- yy_did_buffer_switch_on_eof = 0;
-
- if ( yywrap() )
- {
- /* Note: because we've taken care in
- * yy_get_next_buffer() to have set up
- * yytext, we can now set up
- * yy_c_buf_p so that if some total
- * hoser (like flex itself) wants to
- * call the scanner after we return the
- * YY_NULL, it'll still work - another
- * YY_NULL will get returned.
- */
- yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
-
- yy_act = YY_STATE_EOF(YY_START);
- goto do_action;
- }
-
- else
- {
- if ( ! yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
- }
- break;
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yy_c_buf_p =
- yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state();
-
- yy_cp = yy_c_buf_p;
- yy_bp = yytext_ptr + YY_MORE_ADJ;
- goto yy_match;
-
- case EOB_ACT_LAST_MATCH:
- yy_c_buf_p =
- &yy_current_buffer->yy_ch_buf[yy_n_chars];
-
- yy_current_state = yy_get_previous_state();
-
- yy_cp = yy_c_buf_p;
- yy_bp = yytext_ptr + YY_MORE_ADJ;
- goto yy_find_action;
- }
- break;
- }
-
- default:
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--no action found" );
- } /* end of action switch */
- } /* end of scanning one token */
- } /* end of yylex */
-
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- * EOB_ACT_LAST_MATCH -
- * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- * EOB_ACT_END_OF_FILE - end of file
- */
-
-static int yy_get_next_buffer()
- {
- register char *dest = yy_current_buffer->yy_ch_buf;
- register char *source = yytext_ptr;
- register int number_to_move, i;
- int ret_val;
-
- if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--end of buffer missed" );
-
- if ( yy_current_buffer->yy_fill_buffer == 0 )
- { /* Don't try to fill the buffer, so this is an EOF. */
- if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
- {
- /* We matched a singled characater, the EOB, so
- * treat this as a final EOF.
- */
- return EOB_ACT_END_OF_FILE;
- }
-
- else
- {
- /* We matched some text prior to the EOB, first
- * process it.
- */
- return EOB_ACT_LAST_MATCH;
- }
- }
-
- /* Try to read more data. */
-
- /* First move last chars to start of buffer. */
- number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
-
- for ( i = 0; i < number_to_move; ++i )
- *(dest++) = *(source++);
-
- if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
- /* don't do the read, it's not guaranteed to return an EOF,
- * just force an EOF
- */
- yy_n_chars = 0;
-
- else
- {
- int num_to_read =
- yy_current_buffer->yy_buf_size - number_to_move - 1;
-
- while ( num_to_read <= 0 )
- { /* Not enough room in the buffer - grow it. */
-#ifdef YY_USES_REJECT
- YY_FATAL_ERROR(
-"input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
-#else
-
- /* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = yy_current_buffer;
-
- int yy_c_buf_p_offset =
- (int) (yy_c_buf_p - b->yy_ch_buf);
-
- if ( b->yy_is_our_buffer )
- {
- int new_size = b->yy_buf_size * 2;
-
- if ( new_size <= 0 )
- b->yy_buf_size += b->yy_buf_size / 8;
- else
- b->yy_buf_size *= 2;
-
- b->yy_ch_buf = (char *)
- /* Include room in for 2 EOB chars. */
- yy_flex_realloc( (void *) b->yy_ch_buf,
- b->yy_buf_size + 2 );
- }
- else
- /* Can't grow it, we don't own it. */
- b->yy_ch_buf = 0;
-
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR(
- "fatal error - scanner input buffer overflow" );
-
- yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
- num_to_read = yy_current_buffer->yy_buf_size -
- number_to_move - 1;
-#endif
- }
-
- if ( num_to_read > YY_READ_BUF_SIZE )
- num_to_read = YY_READ_BUF_SIZE;
-
- /* Read in more data. */
- YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
- yy_n_chars, num_to_read );
- }
-
- if ( yy_n_chars == 0 )
- {
- if ( number_to_move == YY_MORE_ADJ )
- {
- ret_val = EOB_ACT_END_OF_FILE;
- yyrestart( yyin );
- }
-
- else
- {
- ret_val = EOB_ACT_LAST_MATCH;
- yy_current_buffer->yy_buffer_status =
- YY_BUFFER_EOF_PENDING;
- }
- }
-
- else
- ret_val = EOB_ACT_CONTINUE_SCAN;
-
- yy_n_chars += number_to_move;
- yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
- yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
-
- return ret_val;
- }
-
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-static yy_state_type yy_get_previous_state()
- {
- register yy_state_type yy_current_state;
- register char *yy_cp;
-
- yy_current_state = yy_start;
-
- for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
- {
- register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 81 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- }
-
- return yy_current_state;
- }
-
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- * next_state = yy_try_NUL_trans( current_state );
- */
-
-#ifdef YY_USE_PROTOS
-static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
-#else
-static yy_state_type yy_try_NUL_trans( yy_current_state )
-yy_state_type yy_current_state;
-#endif
- {
- register int yy_is_jam;
- register char *yy_cp = yy_c_buf_p;
-
- register YY_CHAR yy_c = 1;
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 81 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- yy_is_jam = (yy_current_state == 80);
-
- return yy_is_jam ? 0 : yy_current_state;
- }
-
-
-#ifndef YY_NO_UNPUT
-#ifdef YY_USE_PROTOS
-static void yyunput( int c, register char *yy_bp )
-#else
-static void yyunput( c, yy_bp )
-int c;
-register char *yy_bp;
-#endif
- {
- register char *yy_cp = yy_c_buf_p;
-
- /* undo effects of setting up yytext */
- *yy_cp = yy_hold_char;
-
- if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- { /* need to shift things up to make room */
- /* +2 for EOB chars. */
- register int number_to_move = yy_n_chars + 2;
- register char *dest = &yy_current_buffer->yy_ch_buf[
- yy_current_buffer->yy_buf_size + 2];
- register char *source =
- &yy_current_buffer->yy_ch_buf[number_to_move];
-
- while ( source > yy_current_buffer->yy_ch_buf )
- *--dest = *--source;
-
- yy_cp += (int) (dest - source);
- yy_bp += (int) (dest - source);
- yy_n_chars = yy_current_buffer->yy_buf_size;
-
- if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- YY_FATAL_ERROR( "flex scanner push-back overflow" );
- }
-
- *--yy_cp = (char) c;
-
-
- yytext_ptr = yy_bp;
- yy_hold_char = *yy_cp;
- yy_c_buf_p = yy_cp;
- }
-#endif /* ifndef YY_NO_UNPUT */
-
-
-#ifdef __cplusplus
-static int yyinput()
-#else
-static int input()
-#endif
- {
- int c;
-
- *yy_c_buf_p = yy_hold_char;
-
- if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- {
- /* yy_c_buf_p now points to the character we want to return.
- * If this occurs *before* the EOB characters, then it's a
- * valid NUL; if not, then we've hit the end of the buffer.
- */
- if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- /* This was really a NUL. */
- *yy_c_buf_p = '\0';
-
- else
- { /* need more input */
- yytext_ptr = yy_c_buf_p;
- ++yy_c_buf_p;
-
- switch ( yy_get_next_buffer() )
- {
- case EOB_ACT_END_OF_FILE:
- {
- if ( yywrap() )
- {
- yy_c_buf_p =
- yytext_ptr + YY_MORE_ADJ;
- return EOF;
- }
-
- if ( ! yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
-#ifdef __cplusplus
- return yyinput();
-#else
- return input();
-#endif
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
- break;
-
- case EOB_ACT_LAST_MATCH:
-#ifdef __cplusplus
- YY_FATAL_ERROR(
- "unexpected last match in yyinput()" );
-#else
- YY_FATAL_ERROR(
- "unexpected last match in input()" );
-#endif
- }
- }
- }
-
- c = *(unsigned char *) yy_c_buf_p; /* cast for 8-bit char's */
- *yy_c_buf_p = '\0'; /* preserve yytext */
- yy_hold_char = *++yy_c_buf_p;
-
-
- return c;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yyrestart( FILE *input_file )
-#else
-void yyrestart( input_file )
-FILE *input_file;
-#endif
- {
- if ( ! yy_current_buffer )
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
-
- yy_init_buffer( yy_current_buffer, input_file );
- yy_load_buffer_state();
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
-#else
-void yy_switch_to_buffer( new_buffer )
-YY_BUFFER_STATE new_buffer;
-#endif
- {
- if ( yy_current_buffer == new_buffer )
- return;
-
- if ( yy_current_buffer )
- {
- /* Flush out information for old buffer. */
- *yy_c_buf_p = yy_hold_char;
- yy_current_buffer->yy_buf_pos = yy_c_buf_p;
- yy_current_buffer->yy_n_chars = yy_n_chars;
- }
-
- yy_current_buffer = new_buffer;
- yy_load_buffer_state();
-
- /* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
- * to go ahead and always set it.
- */
- yy_did_buffer_switch_on_eof = 1;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_load_buffer_state( void )
-#else
-void yy_load_buffer_state()
-#endif
- {
- yy_n_chars = yy_current_buffer->yy_n_chars;
- yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
- yyin = yy_current_buffer->yy_input_file;
- yy_hold_char = *yy_c_buf_p;
- }
-
-
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
-#else
-YY_BUFFER_STATE yy_create_buffer( file, size )
-FILE *file;
-int size;
-#endif
- {
- YY_BUFFER_STATE b;
-
- b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- * we need to put in 2 end-of-buffer characters.
- */
- b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_is_our_buffer = 1;
-
- yy_init_buffer( b, file );
-
- return b;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_delete_buffer( YY_BUFFER_STATE b )
-#else
-void yy_delete_buffer( b )
-YY_BUFFER_STATE b;
-#endif
- {
- if ( ! b )
- return;
-
- if ( b == yy_current_buffer )
- yy_current_buffer = (YY_BUFFER_STATE) 0;
-
- if ( b->yy_is_our_buffer )
- yy_flex_free( (void *) b->yy_ch_buf );
-
- yy_flex_free( (void *) b );
- }
-
-
-#ifndef YY_ALWAYS_INTERACTIVE
-#ifndef YY_NEVER_INTERACTIVE
-extern int isatty YY_PROTO(( int ));
-#endif
-#endif
-
-#ifdef YY_USE_PROTOS
-void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
-#else
-void yy_init_buffer( b, file )
-YY_BUFFER_STATE b;
-FILE *file;
-#endif
-
-
- {
- yy_flush_buffer( b );
-
- b->yy_input_file = file;
- b->yy_fill_buffer = 1;
-
-#if YY_ALWAYS_INTERACTIVE
- b->yy_is_interactive = 1;
-#else
-#if YY_NEVER_INTERACTIVE
- b->yy_is_interactive = 0;
-#else
- b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-#endif
-#endif
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_flush_buffer( YY_BUFFER_STATE b )
-#else
-void yy_flush_buffer( b )
-YY_BUFFER_STATE b;
-#endif
-
- {
- b->yy_n_chars = 0;
-
- /* We always need two end-of-buffer characters. The first causes
- * a transition to the end-of-buffer state. The second causes
- * a jam in that state.
- */
- b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
- b->yy_buf_pos = &b->yy_ch_buf[0];
-
- b->yy_at_bol = 1;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- if ( b == yy_current_buffer )
- yy_load_buffer_state();
- }
-
-
-#ifndef YY_NO_SCAN_BUFFER
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
-#else
-YY_BUFFER_STATE yy_scan_buffer( base, size )
-char *base;
-yy_size_t size;
-#endif
- {
- YY_BUFFER_STATE b;
-
- if ( size < 2 ||
- base[size-2] != YY_END_OF_BUFFER_CHAR ||
- base[size-1] != YY_END_OF_BUFFER_CHAR )
- /* They forgot to leave room for the EOB's. */
- return 0;
-
- b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
- b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
- b->yy_buf_pos = b->yy_ch_buf = base;
- b->yy_is_our_buffer = 0;
- b->yy_input_file = 0;
- b->yy_n_chars = b->yy_buf_size;
- b->yy_is_interactive = 0;
- b->yy_at_bol = 1;
- b->yy_fill_buffer = 0;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- yy_switch_to_buffer( b );
-
- return b;
- }
-#endif
-
-
-#ifndef YY_NO_SCAN_STRING
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_string( yyconst char *str )
-#else
-YY_BUFFER_STATE yy_scan_string( str )
-yyconst char *str;
-#endif
- {
- int len;
- for ( len = 0; str[len]; ++len )
- ;
-
- return yy_scan_bytes( str, len );
- }
-#endif
-
-
-#ifndef YY_NO_SCAN_BYTES
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
-#else
-YY_BUFFER_STATE yy_scan_bytes( bytes, len )
-yyconst char *bytes;
-int len;
-#endif
- {
- YY_BUFFER_STATE b;
- char *buf;
- yy_size_t n;
- int i;
-
- /* Get memory for full buffer, including space for trailing EOB's. */
- n = len + 2;
- buf = (char *) yy_flex_alloc( n );
- if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
- for ( i = 0; i < len; ++i )
- buf[i] = bytes[i];
-
- buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
-
- b = yy_scan_buffer( buf, n );
- if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
- /* It's okay to grow etc. this buffer, and we should throw it
- * away when we're done.
- */
- b->yy_is_our_buffer = 1;
-
- return b;
- }
-#endif
-
-
-#ifndef YY_NO_PUSH_STATE
-#ifdef YY_USE_PROTOS
-static void yy_push_state( int new_state )
-#else
-static void yy_push_state( new_state )
-int new_state;
-#endif
- {
- if ( yy_start_stack_ptr >= yy_start_stack_depth )
- {
- yy_size_t new_size;
-
- yy_start_stack_depth += YY_START_STACK_INCR;
- new_size = yy_start_stack_depth * sizeof( int );
-
- if ( ! yy_start_stack )
- yy_start_stack = (int *) yy_flex_alloc( new_size );
-
- else
- yy_start_stack = (int *) yy_flex_realloc(
- (void *) yy_start_stack, new_size );
-
- if ( ! yy_start_stack )
- YY_FATAL_ERROR(
- "out of memory expanding start-condition stack" );
- }
-
- yy_start_stack[yy_start_stack_ptr++] = YY_START;
-
- BEGIN(new_state);
- }
-#endif
-
-
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state()
- {
- if ( --yy_start_stack_ptr < 0 )
- YY_FATAL_ERROR( "start-condition stack underflow" );
-
- BEGIN(yy_start_stack[yy_start_stack_ptr]);
- }
-#endif
-
-
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state()
- {
- return yy_start_stack[yy_start_stack_ptr - 1];
- }
-#endif
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-#ifdef YY_USE_PROTOS
-static void yy_fatal_error( yyconst char msg[] )
-#else
-static void yy_fatal_error( msg )
-char msg[];
-#endif
- {
- (void) fprintf( stderr, "%s\n", msg );
- exit( YY_EXIT_FAILURE );
- }
-
-
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- yytext[yyleng] = yy_hold_char; \
- yy_c_buf_p = yytext + n - YY_MORE_ADJ; \
- yy_hold_char = *yy_c_buf_p; \
- *yy_c_buf_p = '\0'; \
- yyleng = n; \
- } \
- while ( 0 )
-
-
-/* Internal utility routines. */
-
-#ifndef yytext_ptr
-#ifdef YY_USE_PROTOS
-static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
-#else
-static void yy_flex_strncpy( s1, s2, n )
-char *s1;
-yyconst char *s2;
-int n;
-#endif
- {
- register int i;
- for ( i = 0; i < n; ++i )
- s1[i] = s2[i];
- }
-#endif
-
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_alloc( yy_size_t size )
-#else
-static void *yy_flex_alloc( size )
-yy_size_t size;
-#endif
- {
- return (void *) malloc( size );
- }
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_realloc( void *ptr, yy_size_t size )
-#else
-static void *yy_flex_realloc( ptr, size )
-void *ptr;
-yy_size_t size;
-#endif
- {
- /* The cast to (char *) in the following accommodates both
- * implementations that use char* generic pointers, and those
- * that use void* generic pointers. It works with the latter
- * because both ANSI C and C++ allow castless assignment from
- * any pointer type to void*, and deal with argument conversions
- * as though doing an assignment.
- */
- return (void *) realloc( (char *) ptr, size );
- }
-
-#ifdef YY_USE_PROTOS
-static void yy_flex_free( void *ptr )
-#else
-static void yy_flex_free( ptr )
-void *ptr;
-#endif
- {
- free( ptr );
- }
-
-#if YY_MAIN
-int main()
- {
- yylex();
- return 0;
- }
-#endif
-#line 52 "./syslex.l"
diff --git a/gnu/usr.bin/binutils/config.sub b/gnu/usr.bin/binutils/config.sub
index f8b48838e33..4b163afac2d 100644
--- a/gnu/usr.bin/binutils/config.sub
+++ b/gnu/usr.bin/binutils/config.sub
@@ -822,7 +822,6 @@ case $os in
| -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \
| -hiux* | -386bsd* | -netbsd* | -freebsd* | -openbsd* \
| -riscix* \
- | -hiux* | -386bsd* | -netbsd* | -freebsd* | -riscix* \
| -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
diff --git a/gnu/usr.bin/binutils/config/mh-i386win32 b/gnu/usr.bin/binutils/config/mh-i386win32
deleted file mode 100644
index 6f6d998e7d7..00000000000
--- a/gnu/usr.bin/binutils/config/mh-i386win32
+++ /dev/null
@@ -1,26 +0,0 @@
-CC=i386-win32-gcc
-AR=i386-win32-ar
-ARFLAGS=rv
-RANLIB=i386-win32-ranlib
-BISON=byacc
-CC_FOR_BUILD=gcc
-HOST_CC=gcc
-HOST_CFLAGS=
-CFLAGS=-O2
-CXXFLAGS=-O2
-HOST_PREFIX=foo
-HOST_PREFIX_1=foo
-RANLIB=i386-win32-ranlib
-AR=i386-win32-ar
-GCC_FOR_TARGET=${target_alias}-gcc
-CXX_FOR_TARGET=${target_alias}-gcc
-CC_FOR_TARGET=${target_alias}-gcc
-AS_FOR_TARGET=${target_alias}-as
-DLLTOOL_FOR_TARGET=${target_alias}-dlltool
-AR_FOR_TARGET=${target_alias}-ar
-NM_FOR_TARGET=${target_alias}-nm
-RANLIB_FOR_TARGET=${target_alias}-ranlib
-LD_FOR_TARGET=${target_alias}-ld
-HOST_PREFIX=cross
-HOST_PREFIX_1=cross
-MAKEINFOFLAGS=--no-split
diff --git a/gnu/usr.bin/binutils/configure b/gnu/usr.bin/binutils/configure
index 267084884f5..fd009590fc3 100644
--- a/gnu/usr.bin/binutils/configure
+++ b/gnu/usr.bin/binutils/configure
@@ -80,7 +80,7 @@ subdirs=
target_alias=NOTARGET
target_makefile_frag=
undefs=NOUNDEFS
-version="$Revision: 1.1.1.2 $"
+version="$Revision: 1.2 $"
x11=default
### we might need to use some other shell than /bin/sh for running subshells
diff --git a/gnu/usr.bin/binutils/configure.bat b/gnu/usr.bin/binutils/configure.bat
deleted file mode 100644
index d76a37ecd9d..00000000000
--- a/gnu/usr.bin/binutils/configure.bat
+++ /dev/null
@@ -1,17 +0,0 @@
-@echo off
-
-chdir libiberty
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\bfd
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\opcodes
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\gprof
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\binutils
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\gas
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\ld
-call configure %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..
diff --git a/gnu/usr.bin/binutils/etc/configure.info b/gnu/usr.bin/binutils/etc/configure.info
deleted file mode 100644
index b1a3f01b5a8..00000000000
--- a/gnu/usr.bin/binutils/etc/configure.info
+++ /dev/null
@@ -1,64 +0,0 @@
-This is Info file configure.info, produced by Makeinfo-1.55 from the
-input file ./configure.texi.
-
-START-INFO-DIR-ENTRY
-* configure: (configure). Cygnus configure.
-END-INFO-DIR-ENTRY
-
- This document describes the Cygnus Support version of `configure'.
-
- Copyright (C) 1991, 1992, 1993 Cygnus Support Permission is granted
-to make and distribute verbatim copies of this manual provided the
-copyright notice and this permission notice are preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions, except that this permission notice may be stated in a
-translation approved by Cygnus Support.
-
-
-Indirect:
-configure.info-1: 968
-configure.info-2: 50440
-
-Tag Table:
-(Indirect)
-Node: Top968
-Node: What configure does1463
-Node: Invoking configure4783
-Node: Using configure11838
-Node: What configure really does13103
-Node: Build variables18380
-Node: Build directories20582
-Node: Makefile generation23984
-Node: config.guess25515
-Node: config.status26405
-Node: configure.in26962
-Node: configure variables28632
-Node: Minimal36798
-Node: Declarations37608
-Node: per-host38082
-Node: per-target38819
-Node: post-target39642
-Node: Example40225
-Node: Install locations40932
-Node: prefix41733
-Node: exec_prefix42626
-Node: Install details44431
-Node: Host49368
-Node: Target50004
-Node: Makefile fragments50440
-Node: Makefile extensions52056
-Node: Porting55783
-Node: Programs56235
-Node: Hosts and targets61089
-Node: Sites62752
-Node: Variables Index63452
-Node: Concept Index66624
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/etc/configure.info-1 b/gnu/usr.bin/binutils/etc/configure.info-1
deleted file mode 100644
index 52e8c46aae7..00000000000
--- a/gnu/usr.bin/binutils/etc/configure.info-1
+++ /dev/null
@@ -1,1174 +0,0 @@
-This is Info file configure.info, produced by Makeinfo-1.55 from the
-input file ./configure.texi.
-
-START-INFO-DIR-ENTRY
-* configure: (configure). Cygnus configure.
-END-INFO-DIR-ENTRY
-
- This document describes the Cygnus Support version of `configure'.
-
- Copyright (C) 1991, 1992, 1993 Cygnus Support Permission is granted
-to make and distribute verbatim copies of this manual provided the
-copyright notice and this permission notice are preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions, except that this permission notice may be stated in a
-translation approved by Cygnus Support.
-
-
-File: configure.info, Node: Top, Next: What configure does, Prev: (DIR), Up: (DIR)
-
-Cygnus configure
-****************
-
- This file documents the configuration system used and distributed by
-Cygnus Support.
-
-* Menu:
-
-* What configure does:: What configure does
-* Invoking configure:: Invoking configure--basic usage
-* Using configure:: More than you ever wanted to know
-* Porting:: How to use configure with new programs
-* Variables Index::
-* Concept Index::
-
-
-File: configure.info, Node: What configure does, Next: Invoking configure, Prev: Top, Up: Top
-
-What `configure' does
-*********************
-
- This manual documents Cygnus `configure', a program which helps to
-automate much of the setup activity associated with building large
-suites of programs, such the Cygnus Support Developer's Kit. This
-manual is therefore geared toward readers who are likely to face the
-problem of configuring software in source form before compiling and
-installing it. We assume you are an experienced programmer or system
-administrator. For further background on this topic, see *Note
-Apologia Configure: (cfg-paper)Some Basic Terms, by K. Richard Pixley.
-
- When `configure' runs, it does the following things:
-
-** creates build directories*
- When you run `configure' with the `--srcdir' option, it uses the
- current directory as the "build directory", creating under it a
- directory tree that parallels the directory structure of the
- source directory. If you don't specify a `srcdir', `configure'
- first assumes that the source code you wish to configure is in
- your current directory; if it finds no `configure.in' input file
- there, it searches in the directory `configure' itself lies in.
- (For details, see *Note Build directories: Build directories.)
-
-** generates `Makefile'*
- A `Makefile' template from the source directory, usually called
- `Makefile.in', is copied to an output file in the build directory
- which is most often named `Makefile'. `configure' places
- definitions for a number of standard `Makefile' macros at the
- beginning of the output file. If `--prefix=DIR' or
- `--exec_prefix=DIR' are specified on the `configure' command line,
- corresponding `Makefile' variables are set accordingly. If host,
- target, or site-specific `Makefile' fragments exist, these are
- inserted into the output file. (For details, see *Note `Makefile'
- generation: Makefile generation.)
-
-** generates `.gdbinit'*
- If the source directory contains a `.gdbinit' file and the build
- directory is not the same as the source directory, a `.gdbinit'
- file is created in the build directory. This `.gdbinit' file
- contains commands which allow the source directory to be read when
- debugging with the GNU debugger, `gdb'. (*Note Command Files:
- (gdb)Command Files.)
-
-** makes symbolic links*
- Most build directories require that some symbolic links with
- generic names are built pointing to specific files in the source
- directory. If the system where `configure' runs cannot support
- symbolic links, hard links are used instead. (For details, see
- *Note The `configure.in' input file: configure.in.)
-
-** generates `config.status'*
- `configure' creates a shell script named `config.status' in the
- build directory. This shell script, when run from the build
- directory (usually from within a `Makefile'), will reconfigure the
- build directory (but not its subdirectories). This is most often
- used to have a `Makefile' update itself automatically if a new
- source directory is available.
-
-** calls itself recursively*
- If the source directory has subdirectories that should also be
- configured, `configure' is called for each.
-
-
-File: configure.info, Node: Invoking configure, Next: Using configure, Prev: What configure does, Up: Top
-
-Invoking `configure'
-********************
-
- Cygnus `configure' is a shell script which resides in a source tree.
-The usual way to invoke `configure' is from the shell, as follows:
-
- eg$ ./configure HOSTTYPE
-
-This prepares the source in the current directory (`.') to be compiled
-for a HOSTTYPE environment. It assumes that you wish to build programs
-and files in the default "build directory" (also the current directory,
-`.'). If you do not specify a value for HOSTTYPE, Cygnus `configure'
-will attempt to discover this information by itself (*note Determining
-system information: config.guess.). For information on HOSTTYPE
-environments, *Note Host: Host.
-
- All GNU software is packaged with one or more `configure' script(s)
-(*note How Configuration Should Work: (standards)Configuration.). By
-using `configure' you prepare the source for your specific environment
-by selecting and using `Makefile' fragments and fragments of shell
-scripts, which are prepared in advance and stored with the source.
-
- `configure''s command-line options also allow you to specify other
-aspects of the source configuration:
-
- configure HOSTTYPE [--target=TARGET] [--srcdir=DIR] [--rm]
- [--site=SITE] [--prefix=DIR] [--exec-prefix=DIR]
- [--program-prefix=STRING] [--tmpdir=DIR]
- [--with-PACKAGE[=YES/NO]] [--without-PACKAGE]
- [--enable-FEATURE[=YES/NO]] [--disable-FEATURE]
- [--norecursion] [--nfp] [-s] [-v] [-V | --version] [--help]
-
-`--target=TARGET'
- Requests that the sources be configured to target the TARGET
- machine. If no target is specified explicitly, the target is
- assumed to be the same as the host (i.e., a "native"
- configuration). *Note Host: Host, and *Note Target: Target, for
- discussions of each.
-
-`--srcdir=DIR'
- Direct each generated `Makefile' to use the sources located in
- directory DIR. Use this option whenever you wish the object code
- to reside in a different place from the source code. The "build
- directory" is always assumed to be the directory you call
- `configure' from. See *Note Build directories: Build directories,
- for an example. If the source directory is not specified,
- `configure' assumes that the source is in your current directory.
- If `configure' finds no `configure.in' there, it searches in the
- same directory that the `configure' script itself lies in.
- Pathnames specified (Values for DIR) can be either absolute
- relative to the *build* directory.
-
-`--rm'
- *Remove* the configuration specified by HOSTTYPE and the other
- command-line options, rather than create it.
-
- *Note:* We recommend that you use `make distclean' rather than
- use this option; see *Note Invoking `make': (make)Invoking
- make, for details on `make distclean'.
-
-`--site=SITE'
- Generate the `Makefile' using site-specific `Makefile' fragments
- for SITE. *Note Adding information about local conventions:
- Makefile fragments.
-
-`--prefix=DIR'
- Configure the source to install programs and files under directory
- DIR.
-
- This option sets the variable `prefix'. Each generated `Makefile'
- will have its `prefix' variables set to this value. (*Note What
- `configure' really does: What configure really does.)
-
-`--exec-prefix=DIR'
- Configure the source to install "host dependent" files in DIR.
-
- This option sets the variable `exec_prefix'. Each generated
- `Makefile' will have its `exec_prefix' variables set to this value.
- (*Note What `configure' really does: What configure really does.)
-
-`--program-prefix=STRING'
- Configure the source to install certain programs using STRING as a
- prefix. This applies to programs which might be used for
- cross-compilation, such as the compiler and the binary utilities,
- and also to programs which have the same names as common Unix
- programs, such as `make'.
-
- This option sets the variable `program_prefix'. Each generated
- `Makefile' will have its `program_prefix' variables set to this
- value. (*Note What `configure' really does: What configure really
- does.)
-
-`--tmpdir=TMPDIR'
- Use the directory TMPDIR for `configure''s temporary files. The
- default is the value of the environment variable `TMPDIR', or
- `/tmp' if the environment variable is not set.
-
-`--with-PACKAGE[=YES/NO]'
-`--without-PACKAGE'
- Indicate that PACKAGE is present, or not present, depending on
- YES/NO. If YES/NO is nonexistent, its value is assumed to be
- `yes'. `--without-PACKAGE' is equivalent to `--with-PACKAGE=no'.
-
- For example, if you wish to configure the program `gcc' for a Sun
- SPARCstation running SunOS 4.x, and you want `gcc' to use the GNU
- linker `ld', you can configure `gcc' using
-
- eg$ configure --with-gnu-ld sun4
-
- *Note What `configure' really does: What configure really does, for
- details. See the installation or release notes for your
- particular package for details on which other PACKAGE options are
- recognized.
-
-`--enable-FEATURE[=YES/NO]'
-`--disable-FEATURE'
- Include FEATURE, or not, depending on YES/NO. If YES/NO is
- nonexistent, its value is assumed to be `yes'.
- `--disable-FEATURE' is equivalent to `--enable-FEATURE=no'.
-
- *Note What `configure' really does: What configure really does, for
- details. See the installation or release notes for your
- particular package for details on which other FEATURE options are
- recognized.
-
-`--norecursion'
- Configure only this directory; ignore any subdirectories. This is
- used by the executable shell script `config.status' to reconfigure
- only the current directory; it is most often used
- non-interactively, when `make' is invoked. (*Note
- `config.status': config.status.)
-
-`--nfp'
- Assume that the intended HOSTTYPE has no floating point unit.
-
-`-s'
- Suppress status output. This option is used internally by
- `configure' when calling itself recursively in subdirectories. You
- can override this option with the `--verbose' option.
-
-`-v'
-`--verbose'
- Print status lines for each directory configured. Normally, only
- the status lines for the initial working directory are printed.
-
-`--version'
-`-V'
- Print the `configure' version number.
-
-`--help'
- Print a short summary of how to invoke `configure'.
-
- *Note:* You may introduce options with a single dash, `-', rather
-than two dashes, `--'. However, you may not be able to truncate long
-option names when using a single dash. When using two dashes, options
-may be abbreviated as long as each option can be uniquely identified.
-For example,
- eg$ configure --s=/u/me/src HOSTTYPE
-
-is ambiguous, as `--s' could refer to either `--site' or `--srcdir'.
-However,
- eg$ configure --src=/u/me/src HOSTTYPE
-
-is a valid abbreviation.
-
-
-File: configure.info, Node: Using configure, Next: Porting, Prev: Invoking configure, Up: Top
-
-Using `configure'
-*****************
-
- `configure' prepares source directories for building programs in
-them. "Configuring" is the process of preparing software to compile
-correctly on a given "host", for a given "target".
-
- `configure' subsequently writes a configured `Makefile' from a
-pre-built template; `configure' uses variables that have been set in the
-configuring process to determine the values of some variables in the
-`Makefile'. Because of this we will refer to both `configure'
-variables and `Makefile' variables. This convention allows us to
-determine where the variable should be set initially, in either
-`configure.in' or `Makefile.in'.
-
-* Menu:
-
-* What configure really does:: What configure really does
-* configure.in:: The configure.in input file
-* Install locations:: Where to install things once they are built
-* Host:: Telling configure what will source will be built
-* Target:: Telling configure what the source will target
-* Makefile fragments:: Adding information about local conventions
-* Makefile extensions:: Extensions to the GNU coding standards
-
-
-File: configure.info, Node: What configure really does, Next: configure.in, Up: Using configure
-
-What `configure' really does
-============================
-
- Cygnus `configure' is a shell script that sets up an environment in
-which your programs will compile correctly for your machine and
-operating system, and will install in proper places. `configure'
-accomplishes this task by doing the following:
-
- * it generates a `Makefile' from a custom template called
- `Makefile.in' in each relevant source directory;
-
- * it customizes the build process to your specifications; you set
- certain variables for `configure', either on the command line or
- in the file `configure.in', which subsequently sets variables in
- each generated `Makefile' to be used by `make' when actually
- building the software;
-
- * it creates "build directories", places for your code to be compiled
- in before being installed;
-
- * it generates a `.gdbinit' in the build directory, if needed, to
- communicate to `gdb' where to find the program's source code;
-
- * it generates a shell script called `config.status' which is used
- most often by the `Makefile' to reconfigure itself;
-
- * it recurses in subdirectories, setting up entire trees so that
- they build correctly; if `configure' finds another `configure'
- script further down in a given source tree, it knows to use this
- script and not recur.
-
- For the sake of safety (i.e., in order to prevent broken
-installations), the GNU coding standards call for software to be
-"configured" in such a way that an end user trying to build a given
-package will be able to do so by affecting a finite number of
-variables. All GNU software comes with an executable `configure' shell
-script which sets up an environment within a build directory which will
-correctly compile your new package for your host (or, alternatively,
-whatever host you specify to `configure'). For further background on
-this topic, see *Note Apologia Configure: (cfg-paper)Some Basic Terms,
-by K. Richard Pixley.
-
- Use `configure' to set for the build process:
-
- * correct values for certain variables;
-
- * which type of host you wish to configure a given package for
- (*note Host: Host.);
-
- * where you want to install this package (by using `prefix',
- `exec-prefix' and `program-prefix'; *note Full descriptions of all
- installation directories: Install details.);
-
- * optionally, which type of machine you wish to "target" this
- package's output to (*note Target: Target.);
-
- * which other GNU packages are already installed and available to
- this particular build (by using the `--with-PACKAGE' option; *note
- Invoking `configure': Invoking configure.);
-
- * where to place temporary files (by using the `--tmpdir=DIR'
- option; *note Invoking `configure': Invoking configure.);
-
- * whether to recur in subdirectories (changeable through the
- `--norecursion' option; *note Invoking `configure': Invoking
- configure.).
-
- `configure' uses a few other files to complete its tasks. These are
-discussed in detail where noted.
-
-`configure.in'
- Input file for `configure'. Shell script fragments reside here.
- *Note The `configure.in' input file: configure.in.
-
-`Makefile.in'
- Template which `configure' uses to build a file called `Makefile'
- in the "build directory". *Note `Makefile' generation: Makefile
- generation.
-
-`config.sub'
- Shell script used by `configure' to expand referents to the
- HOSTTYPE argument into a single specification of the form
- CPU-VENDOR-OS. For instance, on the command line you can specify
-
- eg$ ./configure sun4
-
- to configure for a Sun SPARCstation running SunOS 4.x. `configure'
- consults `config.sub' to find that the three-part specification
- for this is
-
- sparc-sun-sunos4.1.1
-
- which notes the CPU as `sparc', the MANUFACTURER as `sun' (Sun
- Microsystems), and the OS (operating system) as `sunos4.1.1', the
- SunOS 4.1.1 release. *Note Variables available to `configure':
- configure variables.
-
-`config.guess'
- If you do not put the HOSTTYPE argument on the command line,
- `configure' uses the `config.guess' shell script to make an
- analysis of your machine (it assumes that you wish to configure
- your software for the type of machine on which you are running).
- The output of `config.guess' is a three-part identifier as
- described above.
-
-`config.status'
- The final step in configuring a directory is to create a shell
- script, `config.status'. The main purpose of this file is to
- allow the `Makefile' for the current directory to rebuild itself,
- if necessary. *Note `config.status': config.status.
-
-`config/*'
- `configure' uses three types of `Makefile' "fragments", which
- reside in the directory `SRCDIR/config/'. *Note Adding
- information about local conventions: Makefile fragments.
-
-* Menu:
-
-* Build variables:: Variable-spaghetti made simple
-* Build directories:: Build directories described well
-* Makefile generation:: To build a Makefile
-* config.guess:: Be vewwy quiet, I'm hunting system information
-* config.status:: To rebuild a Makefile
-
-
-File: configure.info, Node: Build variables, Next: Build directories, Up: What configure really does
-
-Build variables
----------------
-
- There are several variables in the build process which you can
-control through build programs such as `make'. These include machine
-definitions, local conventions, installation locations, locations for
-temporary files, etc. This data is accessible through certain
-variables which are configurable in the build process; we refer to them
-as "build variables".
-
- For lists of build variables which you can affect by using
-`configure', see *Note Variables available to `configure.in': configure
-variables, and *Note Full descriptions of all installation directories:
-Install details.
-
- Generally, build variables, which are used by the `Makefile' to
-determine various aspects of the build and installation processes, are
-changeable with command-line options to `configure'. In most large
-suites of programs, like the Cygnus Support Developer's Kit, the
-individual programs reside in several subdirectories of a single source
-code "tree". All of these subdirectories need to be configured with
-information relative to the "build directory", which is not known until
-`configure' is run. Unless specified otherwise, `configure'
-recursively configures every subdirectory in the source tree.
-
- Build variables are passed from `configure' directly into the
-`Makefile', and use the same names (except that dashes are transformed
-into underbars; for example, when you specify the option
-`--exec-prefix' on the command line, the `Makefile' variable
-`exec_prefix' is set). In other words, if you specify
-
- eg$ ./configure --prefix=/usr/gnu/local ... HOSTTYPE
-
-on the command line, `configure' sets an variable called `prefix' to
-`/usr/gnu/local', and passes this into the `Makefile' in the same
-manner. After this command, each `Makefile' generated by `configure'
-will contain a line that reads:
-
- prefix = /usr/gnu/local
-
- For a list of the `Makefile' variables `configure' can change, and
-instructions on how to change them, see *Note Variables available to
-`configure.in': configure variables, and *Note Invoking `configure':
-Invoking configure.
-
-
-File: configure.info, Node: Build directories, Next: Makefile generation, Prev: Build variables, Up: What configure really does
-
-Build directories
------------------
-
- By default, `configure' builds a `Makefile' and symbolic links in the
-same directory as the source files. This default works for many cases,
-but it has limitations. For instance, using this approach, you can
-only build object code for one host at a time.
-
- We refer to each directory where `configure' builds a `Makefile' as
-a "build directory".
-
- The build directory for any given build is always the directory from
-which you call `configure', or `.' relative to your prompt. The default
-"source directory", the place `configure' looks to find source code, is
-also `.'. For instance, if we have a directory `/gnu-stuff/src/' that
-is the top branch of a tree of GNU source code we wish to configure,
-then the program we will use to configure this code is
-`/gnu-stuff/src/configure', as follows. (Assume for the sake of
-argument that our machine is a sun4.)
-
- eg$ cd /gnu-stuff/src
- eg$ ./configure sun4
- Created "Makefile" in /gnu-stuff/src
- eg$
-
- We just configured the code in `/gnu-stuff/src' to run on a Sun
-SPARCstation using SunOS 4.x by creating a `Makefile' in
-`/gnu-stuff/src'. By default, we also specified that when this code is
-built, the object code should reside in the same directory,
-`/gnu-stuff/src'.
-
- However, if we wanted to build this code for more than one host, we
-would be in trouble, because the new configuration would write over the
-old one, destroying it in the process. What we can do is to make a new
-"build directory" and configure from there. Running `configure' from
-the new directory will place a correct `Makefile' and a `config.status'
-in this new file. That is all `configure' does; we must run `make' to
-generate any object code.
-
- The new `Makefile' in `/gnu-stuff/sun4-obj', created from the
-template file `/gnu-stuff/src/Makefile.in', contains all the information
-needed to build the program.
-
- eg$ mkdir /gnu-stuff/sun4-obj
- eg$ cd /gnu-stuff/sun4-obj
- eg$ ../src/configure --srcdir=../src sun4
- Created "Makefile" in /gnu-stuff/sun4-obj
- eg$ ls
- Makefile config.status
- eg$ make all info install install-info clean
- COMPILATION MESSAGES...
- eg$ mkdir /gnu-stuff/solaris2
- eg$ cd /gnu-stuff/solaris2
- eg$ ../src/configure --srcdir=../src sol2
- Created "Makefile" in /gnu-stuff/solaris2
- eg$ ls
- Makefile config.status
- eg$ make all info install install-info clean
- COMPILATION MESSAGES...
-
- We can repeat this for other configurations of the same software
-simply by making a new build directory and reconfiguring from inside
-it. If you do not specify the HOSTTYPE argument, `configure' will
-attempt to figure out what kind of machine and operating system you
-happen to be using. *Note Determining system information:
-config.guess. Of course, this may not always be the configuration you
-wish to build.
-
- *Caution:* If you build more than one configuration for a single
-program, remember that you must also specify a different `--prefix' for
-each configuration at configure-time. Otherwise, both configurations
-will be installed in the same default location (`/usr/local'); the
-configuration to be installed last would overwrite previously installed
-configurations.
-
-
-File: configure.info, Node: Makefile generation, Next: config.guess, Prev: Build directories, Up: What configure really does
-
-`Makefile' generation
----------------------
-
- Cygnus `configure' creates a file called `Makefile' in the build
-directory which can be used with `make' to automatically build a given
-program or package. `configure' also builds a `Makefile' for each
-relevant subdirectory for a given program or package (irrelevant
-subdirectories would be those which contain no code which needs
-configuring, and which therefore have no `configure' input file
-`configure.in' and no `Makefile' template `Makefile.in'). *Note `make'
-Invocation: (make)Running, for details on using `make' to compile your
-source code.
-
- Each `Makefile' contains variables which have been configured for a
-specific build. These build variables are determined when `configure'
-is run. All build variables have defaults. By default, `configure'
-generates a `Makefile' which specifies:
-
- * a "native" build, which is to occur
-
- * in the current directory, and which will be installed
-
- * in the default installation directory (`/usr/local') when the code
- is compiled with `make'.
-
-Variables are changeable through command-line options to `configure'
-(*note Invoking `configure': Invoking configure.).
-
- If you are porting a new program and intend to use `configure', see
-*Note Porting with `configure': Porting, as well as *Note Writing
-Makefiles: (make)Makefiles, and *Note Makefile Conventions:
-(standards)Makefiles.
-
-
-File: configure.info, Node: config.guess, Next: config.status, Prev: Makefile generation, Up: What configure really does
-
-Determining system information
-------------------------------
-
- The shell script `config.guess' is called when you do not specify a
-HOSTTYPE on the command line to `configure'. `config.guess' acquires
-available system information from your local machine through the shell
-command `uname'. It compares this information to a database and
-attempts to determine a usable three-part system identifier (known as a
-"triple") to use as your HOSTTYPE. *Note What `configure' really does:
-What configure really does, to see how this information is used.
-
- *Note:* If you do not specify a HOSTTYPE on the command line,
-`configure' will attempt to configure your software to run on the
-machine you happen to be using. This may not be the configuration you
-desire.
-
-
-File: configure.info, Node: config.status, Prev: config.guess, Up: What configure really does
-
-`config.status'
----------------
-
- The final step in configuring a directory is to create an executable
-shell script, `config.status'. The main purpose of this file is to
-allow the `Makefile' for the current directory to rebuild itself, if
-necessary. It is usually run from within the `Makefile'. *Note
-Extensions to the GNU coding standards: Makefile extensions.
-
- `config.status' also contains a record of the `configure' session
-which created it.
-
-
-File: configure.info, Node: configure.in, Next: Install locations, Prev: What configure really does, Up: Using configure
-
-The `configure.in' input file
-=============================
-
- A `configure.in' file for Cygnus `configure' consists of a
-"per-invocation" section, followed by a "per-host" section, followed by
-a "per-target" section, optionally followed by a "post-target" section.
-Each section is a shell script fragment, which is executed by the
-`configure' shell script at an appropriate time. Values are passed
-among `configure' and the shell fragments through a set of shell
-variables. When each section is being interpreted by the shell, the
-shell's current directory is the build directory, and any files created
-by the section (or referred to by the section) will be relative to the
-build directory. To reference files in other places (such as the
-source directory), prepend a shell variable such as `$(srcdir)/' to the
-desired file name.
-
- The beginning of the `configure.in' file begins the "per-invocation"
-section.
-
- A line beginning with `# per-host:' begins the "per-host" section.
-
- A line beginning with `# per-target:' begins the "per-target"
-section.
-
- If it exists, the "post-target" section begins with `# post-target:'.
-
-* Menu:
-
-* configure variables:: Variables available to configure.in
-* Minimal:: A minimal configure.in
-* Declarations:: For each invocation
-* per-host:: Host-specific instructions
-* per-target:: Target-specific instructions
-* post-target:: Instructions to be executed after target info
-* Example:: An example configure.in
-
-
-File: configure.info, Node: configure variables, Next: Minimal, Up: configure.in
-
-Variables available to `configure.in'
--------------------------------------
-
- The following variables pass information between the standard parts
-of `configure' and the shell-script fragments in `configure.in':
-
-`srctrigger'
- Contains the name of a source file that is expected to live in the
- source directory. You must usually set this in the
- "per-invocation" section of `configure.in'. `configure' tests to
- see that this file exists. If the file does not exist,
- `configure' prints an error message. This is used as a sanity
- check that `configure.in' matches the source directory.
-
-`srcname'
- Contains the name of the source collection contained in the source
- directory. You must usually set this in the "per-invocation"
- section of `configure.in'. If the file named in `srctrigger' does
- not exist, `configure' uses the value of `srcname' when it prints
- the error message.
-
-`configdirs'
- Contains the names of any subdirectories in which `configure'
- should recurse. You must usually set this in the "per-invocation"
- section of `configure.in'. If `Makefile.in' contains a line
- starting with `SUBDIRS =', then it will be replaced with an
- assignment to `SUBDIRS' using the value of `configdirs' (if
- `subdirs' is empty). This can be used to determine which
- directories to configure and build depending on the host and
- target configurations. Use `configdirs' (instead of the `subdirs'
- variable described below) if you want to be able to partition the
- subdirectories, or use independent `Makefile' fragments. Each
- subdirectory can be independent, and independently reconfigured.
-
-`subdirs'
- Contains the names of any subdirectories where `configure' should
- create a `Makefile' (in addition to the current directory),
- *without* recursively running `configure'. Use `subdirs' (instead
- of the `configdirs' variable described above) if you want to
- configure all of the directories as a unit. Since there is a
- single invocation of `configure' that configures many directories,
- all the directories can use the same `Makefile' fragments, and the
- same `configure.in'.
-
-`host'
- Contains the full configuration name for the host (generated by
- the script `config.sub' from the name that you entered). This is
- a three-part name (commonly referred to as a "triple") of the form
- CPU-VENDOR-OS.
-
- There are separate variables `host_cpu', `host_vendor', and
- `host_os' that you can use to test each of the three parts; this
- variable is useful, however, for error messages, and for testing
- combinations of the three components.
-
-`host_cpu'
- Contains the first element of the canonical triple representing
- the host as returned by `config.sub'. This is occasionally used to
- distinguish between minor variations of a particular vendor's
- operating system and sometimes to determine variations in binary
- format between the host and the target.
-
-`host_vendor'
- Contains the second element of the canonical triple representing
- the host as returned by `config.sub'. This is usually used to
- distinguish among the numerous variations of *common* operating
- systems.
-
-`host_os'
- Contains the the third element of the canonical triple
- representing the host as returned by `config.sub'.
-
-`target'
- Contains the full configuration name (generated by the script
- `config.sub' from the name that you entered) for the target. Like
- the host, this is a three-part name of the form CPU-VENDOR-OS.
-
- There are separate variables `target_cpu', `target_vendor', and
- `target_os' that you can use to test each of the three parts; this
- variable is useful, however, for error messages, and for testing
- combinations of the three components.
-
-`target_cpu'
- Contains the first element of the canonical triple representing
- the target as returned by `config.sub'. This variable is used
- heavily by programs which are involved in building other programs,
- like the compiler, assembler, linker, etc. Most programs will not
- need the `target' variables at all, but this one could conceivably
- be used to build a program, for instance, that operated on binary
- data files whose byte order or alignment differ from the system
- where the program is running.
-
-`target_vendor'
- Contains the second element of the canonical triple representing
- the target as returned by `config.sub'. This is usually used to
- distinguish among the numerous variations of *common* operating
- systems or object file formats. It is sometimes used to switch
- between different flavors of user interfaces.
-
-`target_os'
- Contains the the third element of the canonical triple
- representing the target as returned by `config.sub'. This
- variable is used by development tools to distinguish between
- subtle variations in object file formats that some vendors use
- across operating system releases. It might also be use to decide
- which libraries to build or what user interface the tool should
- provide.
-
-`floating_point'
- Set to `no' if you invoked `configure' with the `--nfp'
- command-line option, otherwise it is empty. This is a request to
- target machines with "no floating point" unit, even if the targets
- ordinarily have floating point units available.
-
-`gas'
- Set to `true' if you invoked `configure' with the `--with-gnu-as'
- command line option, otherwise it is empty. This is a request to
- assume that the specified HOSTTYPE machine has GNU `as' available
- even if it ordinarily does not.
-
-`srcdir'
- Set to the name of the directory containing the source for this
- program. This will be different from `.' if you have specified the
- `--srcdir=DIR' option. `srcdir' can indicate either an absolute
- path or a path relative to the build directory.
-
-`package_makefile_frag'
- If set in `configure.in', this variable should be the name a file
- relative to `srcdir' to be included in the resulting `Makefile'.
- If the named file does not exist, `configure' will print a warning
- message. This variable is not set by `configure'.
-
-`host_makefile_frag'
- If set in `configure.in', this variable should be the name a file
- relative to `srcdir' to be included in the resulting `Makefile'.
- If the named file does not exist, `configure' will print a warning
- message. This variable is not set by `configure'.
-
-`target_makefile_frag'
- If set in `configure.in', this variable should be the name of a
- file, relative to `srcdir', to be included in the resulting
- `Makefile'. If the named file does not exist, `configure' will
- print a warning message. This variable is not set by `configure'.
-
-`site_makefile_frag'
- Set to a file name representing to the default `Makefile' fragment
- for this host. It may be set in `configure.in' to override this
- default. Normally `site_makefile_frag' is empty, but will have a
- value if you specify `--site=SITE' on the command line.
-
-`Makefile'
- Set to the name of the generated `Makefile'. Normally this value
- is precisely `Makefile', but some programs may want something else.
-
-`removing'
- Normally empty but will be set to some non-null value if you
- specified `--rm' on the command line. That is, if `removing' is
- not empty, then `configure' is *removing* a configuration rather
- than creating one.
-
-`files'
- If this variable is not empty following the "per-target" section,
- then each word in its value will be the target of a symbolic link
- named in the corresponding word from the `links' variable.
-
-`links'
- If the `files' variable is not empty following the "per-target"
- section, then `configure' creates symbolic links with the first
- word of `links' pointing to the first word of `files', the second
- word of `links' pointing to the second word of `files', and so on.
-
-
-File: configure.info, Node: Minimal, Next: Declarations, Prev: configure variables, Up: configure.in
-
-A minimal `configure.in'
-------------------------
-
- A minimal `configure.in' consists of four lines.
-
- srctrigger=foo.c
- srcname="source for the foo program"
- # per-host:
- # per-target:
-
- The `# per-host:' and `# per-target:' lines divide the file into the
-three required sections. The `srctrigger' line names a file.
-`configure' checks to see that this file exists in the source directory
-before configuring. If the `srctrigger' file does not exist,
-`configure' uses the value of `srcname' to print an error message about
-not finding the source.
-
- This particular example uses no links, and only the default host,
-target, and site-specific `Makefile' fragments if they exist.
-
-
-File: configure.info, Node: Declarations, Next: per-host, Prev: Minimal, Up: configure.in
-
-For each invocation
--------------------
-
- `configure' invokes the entire shell script fragment from the start
-of `configure.in' up to a line beginning with `# per-host:' immediately
-after parsing command line arguments. The variables `srctrigger' and
-`srcname' *must* be set here.
-
- You might also want to set the variables `configdirs' and
-`package_makefile_frag' here.
-
-
-File: configure.info, Node: per-host, Next: per-target, Prev: Declarations, Up: configure.in
-
-Host-specific instructions
---------------------------
-
- The "per-host" section of `configure.in' starts with the line that
-begins with `# per-host:' and ends before a line beginning with
-`# per-target:'. `configure' invokes the commands in the "per-host"
-section when determining host-specific information.
-
- This section usually contains a big `case' statement using the
-variable `host' to determine appropriate values for
-`host_makefile_frag' and `files', although `files' is not usually set
-here. Usually, it is set at the end of the "per-target" section after
-determining the names of the target specific configuration files.
-
-
-File: configure.info, Node: per-target, Next: post-target, Prev: per-host, Up: configure.in
-
-Target-specific instructions
-----------------------------
-
- The "per-target" section of `configure.in' starts with the line that
-begins with `# per-target:' and ends before the line that begins with
-`# post-target:', if there is such a line. Otherwise the "per-target"
-section extends to the end of the file. `configure' invokes the
-commands in the "per-target" section when determining target-specific
-information, and before building any files, directories, or links.
-
- This section usually contains a big `case' statement using the
-variable `target' to determine appropriate values for
-`target_makefile_frag' and `files'. The last lines in the "per-target"
-section normally set the variables `files' and `links'.
-
-
-File: configure.info, Node: post-target, Next: Example, Prev: per-target, Up: configure.in
-
-Instructions to be executed after target info
----------------------------------------------
-
- The "post-target" section is optional. If it exists, the
-`post-target' section starts with a line beginning with
-`# Post-target:' and extends to the end of the file. If it exists,
-`configure' invokes this section once for each target after building
-all files, directories, or links.
-
- This section is seldom needed, but you can use it to edit the
-`Makefile' generated by `configure'.
-
-
-File: configure.info, Node: Example, Prev: post-target, Up: configure.in
-
-An example `configure.in'
--------------------------
-
- Here is a small example of a `configure.in' file.
-
- # This file is a collection of shell script fragments
- # used to tailor a template configure script as
- # appropriate for this directory. For more information,
- # see configure.texi.
-
- configdirs=
- srctrigger=warshall.c
- srcname="bison"
-
- # per-host:
- case "${host}" in
- m88k-motorola-*)
- host_makefile_frag=config/mh-delta88
- ;;
- esac
-
- # per-target:
- files="bison_in.hairy"
- links="bison.hairy"
-
- # post-target:
-
-
-File: configure.info, Node: Install locations, Next: Host, Prev: configure.in, Up: Using configure
-
-Install locations
-=================
-
- Using the default configuration, `make install' creates a single
-tree of files, some of which are programs. The location of this tree
-is determined by the value of the variable `prefix'. The default value
-of `prefix' is `/usr/local'. This is often correct for native tools
-installed on only one host.
-
-* Menu:
-
-* prefix:: Changing the default install directory
-* exec_prefix:: How to separate host independent files
- from host dependent files when
- installing for multiple hosts
-* Install details:: Full descriptions of all installation subdirectories
-
-
-File: configure.info, Node: prefix, Next: exec_prefix, Up: Install locations
-
-Changing the default install directory
---------------------------------------
-
- In the default configuration, all files are installed in
-subdirectories of `/usr/local'. The location is determined by the
-value of the `configure' variable `prefix'; in turn, this determines the
-value of the `Makefile' variable of the same name (`prefix').
-
- You can also set the value of the `Makefile' variable `prefix'
-explicitly each time you invoke `make' if you are so inclined. However,
-because many programs have this location compiled in, you must specify
-the `prefix' value consistently on each invocation of `make', or you
-will end up with a broken installation.
-
- To make this easier, the value of the `configure' variable `prefix'
-can be set on the command line to `configure' using the option
-`--prefix='.
-
-
-File: configure.info, Node: exec_prefix, Next: Install details, Prev: prefix, Up: Install locations
-
-Installing for multiple hosts
------------------------------
-
- By default, host dependent files are installed in subdirectories of
-`$(exec_prefix)'. The location is determined by the value of the
-`configure' variable `exec_prefix', which determines the value of the
-`Makefile' variable `exec_prefix'. This makes it easier to install for
-a single host, and simplifies changing the default location for the
-install tree. The default doesn't allow for multiple hosts to
-effectively share host independent files, however.
-
- To configure so that multiple hosts can share common files, use
-something like:
-
- configure HOST1 -prefix=/usr/gnu -exec_prefix=/usr/gnu/H-host1
- make all info install install-info clean
-
- configure HOST2 -prefix=/usr/gnu -exec_prefix=/usr/gnu/H-host2
- make all info install install-info
-
- The first line configures the source for HOST1 to place host-specific
-programs in subdirectories of `/usr/gnu/H-HOST1'.
-
- The second line builds and installs all programs for HOST1,
-including both host-independent and host-specific files, as well as
-removing the host-specific object files from of the build directory.
-
- The third line reconfigures the source for HOST2 to place host
-specific programs in subdirectories of `/usr/gnu/H-HOST2'.
-
- The fourth line builds and installs all programs for HOST2. Host
-specific files are installed in new directories, but the host
-independent files are installed *on top of* the host independent files
-installed for HOST1. This results in a single copy of the host
-independent files, suitable for use by both hosts.
-
- *Note Extensions to the GNU coding standards: Makefile extensions,
-for more information.
-
-
-File: configure.info, Node: Install details, Prev: exec_prefix, Up: Install locations
-
-Full descriptions of all installation subdirectories
-----------------------------------------------------
-
- During any install, a number of standard directories are created.
-Their names are determined by `Makefile' variables. Some of the
-defaults for `Makefile' variables can be changed at configuration time
-using command line options to `configure'. For more information on the
-standard directories or the `Makefile' variables, please refer to *Note
-Makefile Conventions: (standards)Makefiles. See also *Note Extensions
-to the GNU coding standards: Makefile extensions.
-
- Note that `configure' does not create the directory indicated by the
-variable `srcdir' at any time. `$(srcdir)' is not an installation
-directory.
-
- You can override all `Makefile' variables on the command line to
-`make'. (*Note Overriding Variables: (make)Overriding.) If you do so,
-you will need to specify the value precisely the same way for each
-invocation of `make', or you risk ending up with a broken installation.
-This is because many programs have the locations of other programs or
-files compiled into them. If you find yourself overriding any of the
-variables frequently, you should consider site dependent `Makefile'
-fragments. See also *Note Adding site info: Sites.
-
- During `make install', a number of standard directories are created
-and populated. The following `Makefile' variables define them. Those
-whose defaults are set by corresponding `configure' variables are marked
-"`Makefile' and `configure'".
-
-`prefix (`Makefile' and `configure')'
- The root of the installation tree. You can set its `Makefile'
- default with the `--prefix=' command line option to `configure'
- (*note Invoking `configure': Invoking configure.). The default
- value for `prefix' is `/usr/local'.
-
-`bindir'
- A directory for binary programs that users can run. The default
- value for `bindir' depends on `prefix'; `bindir' is normally
- changed only indirectly through `prefix'. The default value for
- `bindir' is `$(prefix)/bin'.
-
-`exec_prefix (`Makefile' and `configure')'
- A directory for host dependent files. You can specify the
- `Makefile' default value by using the `--exec_prefix=' option to
- `configure'. (*Note Invoking `configure': Invoking configure.)
- The default value for `exec_prefix' is `$(prefix)'.
-
-`libdir'
- A directory for libraries and support programs. The default value
- for `libdir' depends on `prefix'; `libdir' is normally changed only
- indirectly through `prefix'. The default value for `libdir' is
- `$(prefix)/lib'.
-
-`mandir'
- A directory for `man' format documentation ("man pages"). The
- default value for `mandir' depends on `prefix'; `mandir' is
- normally changed only indirectly through `prefix'. The default
- value for `mandir' is `$(prefix)/man'.
-
-`manNdir'
- These are eight variables named `man1dir', `man2dir', etc. They
- name the specific directories for each man page section. For
- example, `man1dir' by default holds the filename `$(mandir)/man1';
- this directory contains `emacs.1' (the man page for GNU Emacs).
- Similarly, `man5dir' contains the value `$(mandir)/man5',
- indicating the directory which holds `rcsfile.5' (the man page
- describing the `rcs' data file format). The default value for any
- of the `manNdir' variables depends indirectly on `prefix', and is
- normally changed only through `prefix'. The default value for
- `manNdir' is `$(mandir)/manN'.
-
-`manNext'
- *Not supported by Cygnus `configure'*. The `GNU Coding Standards'
- do not call for `man1ext', `man2ext', so the intended use for
- `manext' is apparently not parallel to `mandir'. Its use is not
- clear. (See also *Note Extensions to the GNU coding standards:
- Makefile extensions.)
-
-`infodir'
- A directory for `info' format documentation. The default value for
- `infodir' depends indirectly on `prefix'; `infodir' is normally
- changed only through `prefix'. The default value for `infodir' is
- `$(prefix)/info'.
-
-`docdir'
- A directory for any documentation that is in a format other than
- those used by `info' or `man'. The default value for `docdir'
- depends indirectly on `prefix'; `docdir' is normally changed only
- through `prefix'. The default value for `docdir' is
- `$(datadir)/doc'. *This variable is an extension to the GNU
- coding standards*. (See also *Note Extensions to the GNU coding
- standards: Makefile extensions.)
-
-`includedir'
- A directory for the header files accompanying the libraries
- installed in `libdir'. The default value for `includedir' depends
- on `prefix'; `includedir' is normally changed only indirectly
- through `prefix'. The default value for `includedir' is
- `$(prefix)/include'.
-
-
-File: configure.info, Node: Host, Next: Target, Prev: Install locations, Up: Using configure
-
-Host
-====
-
- The arguments to `configure' are "hosttypes". By "hosttype" we mean
-the "environment" in which the source will be compiled. This need not
-necessarily be the same as the physical machine involved, although it
-usually is.
-
- For example, if some obscure machine had the GNU `POSIX' emulation
-libraries available, it would be possible to configure most GNU source
-for a `POSIX' system and build it on the obscure host.
-
- For more on this topic, see *Note On Configuring Development Tools:
-(cfg-paper)Host Environments.
-
-
-File: configure.info, Node: Target, Next: Makefile fragments, Prev: Host, Up: Using configure
-
-Target
-======
-
- For building native development tools, or most of the other GNU
-tools, you need not worry about the target. The "target" of a
-configuration defaults to the same as the "host".
-
- For building cross development tools, please see *Note On
-Configuring Development Tools: (cfg-paper)Building Development
-Environments.
-
diff --git a/gnu/usr.bin/binutils/etc/configure.info-2 b/gnu/usr.bin/binutils/etc/configure.info-2
deleted file mode 100644
index 022d187f819..00000000000
--- a/gnu/usr.bin/binutils/etc/configure.info-2
+++ /dev/null
@@ -1,572 +0,0 @@
-This is Info file configure.info, produced by Makeinfo-1.55 from the
-input file ./configure.texi.
-
-START-INFO-DIR-ENTRY
-* configure: (configure). Cygnus configure.
-END-INFO-DIR-ENTRY
-
- This document describes the Cygnus Support version of `configure'.
-
- Copyright (C) 1991, 1992, 1993 Cygnus Support Permission is granted
-to make and distribute verbatim copies of this manual provided the
-copyright notice and this permission notice are preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions, except that this permission notice may be stated in a
-translation approved by Cygnus Support.
-
-
-File: configure.info, Node: Makefile fragments, Next: Makefile extensions, Prev: Target, Up: Using configure
-
-Adding information about local conventions
-==========================================
-
- If you find that a tool does not get configured to your liking, or if
-`configure''s conventions differ from your local conventions, you should
-probably consider "site-specific `Makefile' fragments". See also *Note
-Adding site info: Sites.
-
- These are probably not the right choice for options that can be set
-from the `configure' command line or for differences that are host or
-target dependent.
-
- Cygnus `configure' uses three types of `Makefile' fragments. In a
-generated `Makefile' they appear in the order: "target fragment", "host
-fragment", and "site fragment". This allows host fragments to override
-target fragments, and site fragments to override both.
-
- Host-specific `Makefile' fragments conventionally reside in the
-`./config/' subdirectory with names of the form `mh-HOSTTYPE'. They
-are used for hosts that require odd options to the standard compiler and
-for compile time options based on the host configuration.
-
- Target-specific `Makefile' fragments conventionally reside in the
-`./config/' subdirectory with names of the form `mt-TARGET'. They are
-used for target dependent compile time options.
-
- Site specific `Makefile' fragments conventionally reside in the
-`./config/' subdirectory with names of the form `ms-SITE'. They are
-used to override host- and target-independent compile time options.
-Note that you can also override these options on the `make' invocation
-line.
-
-
-File: configure.info, Node: Makefile extensions, Prev: Makefile fragments, Up: Using configure
-
-Extensions to the GNU coding standards
-======================================
-
- The following additions to the GNU coding standards are required for
-Cygnus `configure' to work properly.
-
- * The `Makefile' must contain exactly one line starting with `####'.
- This line should follow any default macro definitions but precede
- any rules. Host, target, and site-specific `Makefile' fragments
- will be inserted immediately after this line. If the line is
- missing, the fragments will not be inserted.
-
- * Cygnus adds the following targets to each `Makefile'. Their
- existence is not required for Cygnus `configure', but they are
- documented here for completeness.
-
- `info'
- Build all info files from texinfo source.
-
- `install-info'
- Install all info files.
-
- `clean-info'
- Remove all info files and any intermediate files that can be
- generated from texinfo source.
-
- `Makefile'
- Calls `./config.status' to rebuild the `Makefile' in this
- directory.
-
- * The following `Makefile' targets have revised semantics:
-
- `install'
- Should *not* depend on the target `all'. If the program is
- not already built, `make install' should fail. This allows
- you to install programs even when `make' would otherwise
- determine them to be out of date. This can happen, for
- example, when the result of a `make all' is transported via
- tape to another machine for installation.
-
- `clean'
- Should remove any file that can be regenerated by the
- `Makefile', excepting only the `Makefile' itself, and any
- links created by `configure'. That is, `make all clean'
- should return all directories to their original condition.
- If this is not done, then the command sequence
-
- configure HOST1 ; make all install clean ;
- configure HOST2 ; make all install
-
- will fail because of intermediate files intended for HOST1.
-
- * Cygnus adds the following macros to all `Makefile.in' files, but
- you are not required to use them to run Cygnus `configure'.
-
- `docdir'
- The directory in which to install any documentation that is
- not either a `man' page or an `info' file. For `man' pages,
- see `mandir'; for `info', see `infodir'.
-
- `includedir'
- The directory in which to install any header files that
- should be made available to users. This is distinct from the
- `gcc' include directory, which is intended for `gcc' only.
- Files in `includedir' may be used by `cc' as well.
-
- * The following macros have revised semantics. Most of them describe
- installation directories; see also *Note Full description of all
- installation subdirectories: Install details.
-
- `datadir'
- is used for host independent data files.
-
- `mandir'
- The default path for `mandir' depends on `prefix'.
-
- `infodir'
- The default path for `infodir' depends on `prefix'.
-
- `BISON'
- is assumed to have a `yacc' calling convention. To use GNU
- `bison', use `BISON=bison -y'.
-
- * Each Cygnus `Makefile' also conforms to one additional restriction:
-
- When libraries are installed, the line containing the call to
- `INSTALL_DATA' should always be followed by a line containing a
- call to `RANLIB' on the installed library. This is to accommodate
- systems that use `ranlib'. Systems that do not use `ranlib' can
- set `RANLIB' to "`echo'" in a host specific `Makefile' fragment.
-
-
-File: configure.info, Node: Porting, Next: Variables Index, Prev: Using configure, Up: Top
-
-Porting with `configure'
-************************
-
- This section explains how to add programs, host and target
-configuration names, and site-specific information to Cygnus
-`configure'.
-
-* Menu:
-
-* Programs:: Adding configure to new programs
-* Hosts and targets:: Adding hosts and targets
-* Sites:: Adding site info
-
-
-File: configure.info, Node: Programs, Next: Hosts and targets, Up: Porting
-
-Adding `configure' to new programs
-==================================
-
- If you are writing a new program, you probably shouldn't worry about
-porting or configuration issues until it is running reasonably on some
-host. Then refer back to this section.
-
- If your program currently has a `configure' script that meets the GNU
-standards (*note How Configuration Should Work:
-(standards)Configuration., please do not add Cygnus `configure'. It
-should be possible to add this program without change to a Cygnus
-`configure' style source tree.
-
- If the program is not target dependent, please consider using
-`autoconf' instead of Cygnus `configure'. `autoconf' is available from
-the Free Software Foundation; it is a program which generates an
-executable shell script called `configure' by automatically finding
-information on the system to be configured on and embedding this
-information in the shell script. `configure' scripts generated by
-`autoconf' require no arguments, and accept the same options as Cygnus
-`configure'. For detailed instructions on using `autoconf', see *Note
-How to organize and produce Autoconf scripts: (autoconf)Making
-configure Scripts.
-
- To add Cygnus `configure' to an existing program, do the following:
-
-*Make sure the `Makefile' conforms to the GNU standard
- The coding standard for writing a GNU `Makefile' is described in
- *Note Makefile Conventions: (standards)Makefiles. For technical
- information on writing a `Makefile', see *Note Writing Makefiles:
- (make)Makefiles.
-
-*Add Cygnus extensions to the `Makefile'
- These are described in *Note Extensions to the GNU coding
- standards: Makefile extensions.
-
-*Collect package specific definitions in a single file
- Many packages are best configured using a common `Makefile'
- fragment which is included by all of the makefiles in the
- different directories of the package. In order to accomplish
- this, set the variable `package_makefile_fragment' to the name of
- the file. It will be inserted into the final `Makefile' before
- the target-specific fragment.
-
-*Move host support from `Makefile' to fragments
- This usually involves finding sections of the `Makefile' that say
- things like "uncomment these lines for host HOSTTYPE" and moving
- them to a new file called `./config/mh-HOSTTYPE'. For more
- information, see *Note Adding hosts and targets: Hosts and targets.
-
-*Choose defaults
- If the program has compile-time options that determine the way the
- program should behave, choose reasonable defaults and make these
- `Makefile' variables. Be sure the variables are assigned their
- default values before the `####' line so that site-specific
- `Makefile' fragments can override them (*note Extensions to the
- GNU coding standards: Makefile extensions.).
-
-*Locate configuration files
- If there is configuration information in header files or source
- files, separate it in such a way that the files have generic
- names. Then move the specific instances of those files into the
- `./config/' subdirectory.
-
-*Separate host and target information
- Some programs already have this information separated. If yours
- does not, you will need to separate these two kinds of
- configuration information. "Host specific" information is the
- information needed to compile the program. "Target specific"
- information is information on the format of data files that the
- program will read or write. This information should live in
- separate files in the `./config/' subdirectory with names that
- reflect the configuration for which they are intended.
-
- At this point you might skip this step and simply move on. If you
- do, you should end up with a program that can be configured only
- to build "native" tools, that is, tools for which the host system
- is also the target system. Later, you could attempt to build a
- cross tool and separate out the target-specific information by
- figuring out what went wrong. This is often simpler than combing
- through all of the source code.
-
-*Write `configure.in'
- Usually this involves writing shell script fragments to map from
- canonical configuration names into the names of the configuration
- files. These files will then be linked at configure time from the
- specific instances of those files in `./config' to files in the
- build directory with more generic names. (See also *Note Build
- directories: Build directories.) The format of `configure.in' is
- described in *Note The `configure.in' input file: configure.in.
-
-*Rename `Makefile' to `Makefile.in'
- At this point you should have a program that can be configured using
-Cygnus `configure'.
-
-
-File: configure.info, Node: Hosts and targets, Next: Sites, Prev: Programs, Up: Porting
-
-Adding hosts and targets
-========================
-
- To add a host or target to a program that already uses Cygnus
-`configure', do the following.
-
- * Make sure the new configuration name is represented in
- `config.sub'. If not, add it. For more details, see the comments
- in the shell script `config.sub'.
-
- * If you are adding a host configuration, look in `configure.in', in
- the "per-host" section. Make sure that your configuration name is
- represented in the mapping from host configuration names to
- configuration files. If not, add it. Also see *Note The
- `configure.in' input file: configure.in.
-
- * If you are adding a target configuration, look in `configure.in',
- in the "per-target" section. Make sure that your configuration
- name is represented in the mapping from target configuration names
- to configuration files. If not, add it. Also see *Note The
- `configure.in' input file: configure.in.
-
- * Look in `configure.in' for the variables `files', `links',
- `host_makefile_frag', and `target_makefile_frag'. The values
- assigned to these variables are the names of the configuration
- files, (relative to `srcdir') that the program uses. Make sure
- that copies of the files exist for your host. If not, create
- them. See also *Note Variables available to `configure.in':
- configure variables.
-
- This should be enough to `configure' for a new host or target
-configuration name. Getting the program to compile and run properly
-represents the hardest work of any port.
-
-
-File: configure.info, Node: Sites, Prev: Hosts and targets, Up: Porting
-
-Adding site info
-================
-
- If some of the `Makefile' defaults are not right for your site, you
-can build site-specific `Makefile' fragments. To do this, do the
-following.
-
- * Choose a name for your site. It must currently be less than
- eleven characters.
-
- * If the program source does not have a `./config/' subdirectory,
- create it.
-
- * Create a file called `./config/ms-SITE' where SITE is the name of
- your site. In it, set whatever `Makefile' variables you need to
- override to match your site's conventions.
-
- * Configure the program with:
-
- configure ... --site=SITE
-
-
-File: configure.info, Node: Variables Index, Next: Concept Index, Prev: Porting, Up: Top
-
-Variable Index
-**************
-
-* Menu:
-
-* bindir: Install details.
-* configdirs: configure variables.
-* disable-FEATURE: Invoking configure.
-* docdir: Install details.
-* enable-FEATURE: Invoking configure.
-* exec-prefix: Invoking configure.
-* exec_prefix: exec_prefix.
-* exec_prefix: Install details.
-* files: configure variables.
-* floating_point: configure variables.
-* gas: configure variables.
-* host: configure variables.
-* host_cpu: configure variables.
-* host_makefile_frag: configure variables.
-* host_os: configure variables.
-* host_vendor: configure variables.
-* includedir: Install details.
-* infodir: Install details.
-* libdir: Install details.
-* links: configure variables.
-* Makefile: configure variables.
-* manNdir: Install details.
-* manNext: Install details.
-* mandir: Install details.
-* nfp: Invoking configure.
-* norecursion: Invoking configure.
-* package_makefile_frag: configure variables.
-* prefix: prefix.
-* prefix: Install details.
-* prefix: Invoking configure.
-* program-prefix: Invoking configure.
-* removing: configure variables.
-* rm: Invoking configure.
-* site: Invoking configure.
-* site_makefile_frag: configure variables.
-* srcdir: configure variables.
-* srcdir: What configure does.
-* srcdir: Invoking configure.
-* srcname: configure variables.
-* srctrigger: configure variables.
-* subdirs: configure variables.
-* target: Invoking configure.
-* target: configure variables.
-* target_cpu: configure variables.
-* target_makefile_frag: configure variables.
-* target_os: configure variables.
-* target_vendor: configure variables.
-* tmpdir: Invoking configure.
-* verbose: Invoking configure.
-* with-PACKAGE: Invoking configure.
-* without-PACKAGE: Invoking configure.
-
-
-File: configure.info, Node: Concept Index, Prev: Variables Index, Up: Top
-
-Concept Index
-*************
-
-* Menu:
-
-* -disable-FEATURE: Invoking configure.
-* -enable-FEATURE: Invoking configure.
-* -exec-prefix: Invoking configure.
-* -help: Invoking configure.
-* -nfp: Invoking configure.
-* -norecursion: Invoking configure.
-* -prefix: Invoking configure.
-* -program-prefix: Invoking configure.
-* -rm: Invoking configure.
-* -site: Invoking configure.
-* -srcdir: Invoking configure.
-* -target: Invoking configure.
-* -tmpdir: Invoking configure.
-* -verbose: Invoking configure.
-* -version: Invoking configure.
-* -with-PACKAGE: Invoking configure.
-* -without-PACKAGE: Invoking configure.
-* -s: Invoking configure.
-* -v: Invoking configure.
-* .gdbinit: What configure does.
-* autoconf: Programs.
-* bindir: Install details.
-* config.guess: config.guess.
-* config.guess definition: What configure really does.
-* config.status: config.status.
-* config.status: What configure does.
-* config.status definition: What configure really does.
-* config.sub definition: What configure really does.
-* config/ subdirectory: What configure really does.
-* configdirs: configure variables.
-* configure.in: configure.in.
-* configure.in definition: What configure really does.
-* configure back end: What configure really does.
-* configure details: What configure really does.
-* disable-FEATURE option: Invoking configure.
-* docdir: Install details.
-* enable-FEATURE option: Invoking configure.
-* exec-prefix option: Invoking configure.
-* exec_prefix: Install details.
-* floating_point: configure variables.
-* help option: Invoking configure.
-* host: configure variables.
-* includedir: Install details.
-* infodir: Install details.
-* libdir: Install details.
-* Makefile.in definition: What configure really does.
-* Makefile extensions: Makefile extensions.
-* Makefile fragments: Makefile fragments.
-* Makefile generation: Makefile generation.
-* Makefile generation: What configure does.
-* manNdir: Install details.
-* manNext: Install details.
-* mandir: Install details.
-* nfp option: Invoking configure.
-* nfp option: configure variables.
-* norecursion option: Invoking configure.
-* prefix: Install details.
-* prefix option: Invoking configure.
-* prefix option: prefix.
-* program-prefix option: Invoking configure.
-* rm option: Invoking configure.
-* rm option: configure variables.
-* site option: Invoking configure.
-* srcdir: configure variables.
-* srcdir: What configure does.
-* srcdir option: Invoking configure.
-* srcname: configure variables.
-* srctrigger: configure variables.
-* subdirs: configure variables.
-* s option: Invoking configure.
-* target: configure variables.
-* target option: Invoking configure.
-* tmpdir option: Invoking configure.
-* verbose option: Invoking configure.
-* v option: Invoking configure.
-* with-PACKAGE option: Invoking configure.
-* with-gnu-as option: configure variables.
-* without-PACKAGE option: Invoking configure.
-* configure.in interface: configure variables.
-* host shell-script fragment: per-host.
-* per-host section: per-host.
-* per-host section: configure.in.
-* per-invocation section: configure.in.
-* per-invocation section: Declarations.
-* per-target section: configure.in.
-* per-target section: per-target.
-* post-target section: configure.in.
-* post-target section: post-target.
-* Abbreviating option names: Invoking configure.
-* Adding configure to new programs: Programs.
-* Adding hosts and targets: Hosts and targets.
-* Adding local info: Makefile fragments.
-* Adding site info: Sites.
-* Adding site info: Makefile fragments.
-* Behind the scenes: What configure really does.
-* BISON: Makefile extensions.
-* Build directories: What configure does.
-* Build directories: Build directories.
-* Build variables: Build variables.
-* Building for multiple hosts: Build directories.
-* Building for multiple targets: Build directories.
-* Canonical "triple": configure variables.
-* Canonical "triple": configure variables.
-* Changing the install directory: prefix.
-* clean: Makefile extensions.
-* clean-info: Makefile extensions.
-* Coding standards extensions: Makefile extensions.
-* configure variables: configure variables.
-* Configuring for multiple hosts: exec_prefix.
-* Cygnus extensions: Makefile extensions.
-* Cygnus Support Developer's Kit: What configure does.
-* Cygnus Support Developer's Kit: Build variables.
-* datadir: Makefile extensions.
-* Declarations section: Declarations.
-* Default configuration: Makefile generation.
-* Detailed usage: Using configure.
-* docdir: Makefile extensions.
-* Example configure.in: Example.
-* Example session: Build directories.
-* Example session: Build directories.
-* Example session: exec_prefix.
-* Example session: Build variables.
-* Example session: Makefile extensions.
-* Example session: What configure really does.
-* Example session: Sites.
-* Example session: Invoking configure.
-* Example session: Invoking configure.
-* For each invocation: Declarations.
-* Host: Host.
-* Host-specific instructions: per-host.
-* Hosts and targets: Hosts and targets.
-* includedir: Makefile extensions.
-* info: Makefile extensions.
-* infodir: Makefile extensions.
-* install: Makefile extensions.
-* Install details: Install details.
-* Install locations: Install locations.
-* install-info: Makefile extensions.
-* Installation subdirectories: Install details.
-* Installing host-independent files: exec_prefix.
-* Introduction: What configure does.
-* Invoking configure: Invoking configure.
-* Local conventions: Makefile fragments.
-* Makefile: Makefile extensions.
-* mandir: Makefile extensions.
-* Minimal configure.in example: Minimal.
-* Object directories: Build directories.
-* Other files: What configure really does.
-* Overview: What configure does.
-* Porting with configure: Porting.
-* Post-target shell-script fragment: post-target.
-* Recursion: What configure does.
-* Sample configure.in: Example.
-* Sharing host-independent files: exec_prefix.
-* Sites: Sites.
-* Subdirectories: Install details.
-* Symbolic links: What configure does.
-* Symbolic links: configure variables.
-* Symbolic links: configure variables.
-* Target: Target.
-* target shell-script fragment: per-target.
-* Target-specific instructions: per-target.
-* The exec_prefix directory: exec_prefix.
-* Truncating option names: Invoking configure.
-* Usage: Invoking configure.
-* Usage: Invoking configure.
-* Usage: detailed: Using configure.
-* Using configure: Using configure.
-* Variables: Build variables.
-* Verbose Output: Invoking configure.
-* version: Invoking configure.
-* version: Invoking configure.
-* What configure does: What configure does.
-* What configure really does: What configure really does.
-* Where to install: Install locations.
-
-
diff --git a/gnu/usr.bin/binutils/etc/standards.info b/gnu/usr.bin/binutils/etc/standards.info
deleted file mode 100644
index 92b0dc90c04..00000000000
--- a/gnu/usr.bin/binutils/etc/standards.info
+++ /dev/null
@@ -1,59 +0,0 @@
-This is Info file standards.info, produced by Makeinfo-1.55 from the
-input file ./standards.texi.
-
-START-INFO-DIR-ENTRY
-* Standards: (standards). GNU coding standards.
-END-INFO-DIR-ENTRY
-
- GNU Coding Standards Copyright (C) 1992, 1993, 1994 Free Software
-Foundation
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions, except that this permission notice may be stated in a
-translation approved by the Free Software Foundation.
-
-
-Indirect:
-standards.info-1: 950
-standards.info-2: 49237
-
-Tag Table:
-(Indirect)
-Node: Top950
-Node: Reading Non-Free Code2051
-Node: Contributions3777
-Node: Change Logs5375
-Node: Compatibility9091
-Node: Makefile Conventions10730
-Node: Makefile Basics11087
-Node: Utilities in Makefiles12978
-Node: Standard Targets14414
-Node: Command Variables21523
-Node: Directory Variables24353
-Node: Configuration30825
-Node: Source Language37849
-Node: Formatting38979
-Node: Comments42269
-Node: Syntactic Conventions45055
-Node: Names47947
-Node: Using Extensions49237
-Node: System Functions50978
-Node: Semantics55781
-Node: Errors58747
-Node: Libraries59950
-Node: Portability61174
-Node: User Interfaces64461
-Node: Documentation79291
-Node: Releases83225
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/etc/standards.info-1 b/gnu/usr.bin/binutils/etc/standards.info-1
deleted file mode 100644
index 38184e4a1bb..00000000000
--- a/gnu/usr.bin/binutils/etc/standards.info-1
+++ /dev/null
@@ -1,1225 +0,0 @@
-This is Info file standards.info, produced by Makeinfo-1.55 from the
-input file ./standards.texi.
-
-START-INFO-DIR-ENTRY
-* Standards: (standards). GNU coding standards.
-END-INFO-DIR-ENTRY
-
- GNU Coding Standards Copyright (C) 1992, 1993, 1994 Free Software
-Foundation
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions, except that this permission notice may be stated in a
-translation approved by the Free Software Foundation.
-
-
-File: standards.info, Node: Top, Next: Reading Non-Free Code, Prev: (dir), Up: (dir)
-
-Version
-*******
-
- Last updated 28 March 1994.
-
-* Menu:
-
-* Reading Non-Free Code:: Referring to Proprietary Programs
-* Contributions:: Accepting Contributions
-* Change Logs:: Recording Changes
-* Compatibility:: Compatibility with Other Implementations
-* Makefile Conventions:: Makefile Conventions
-* Configuration:: How Configuration Should Work
-* Source Language:: Using Languages Other Than C
-* Formatting:: Formatting Your Source Code
-* Comments:: Commenting Your Work
-* Syntactic Conventions:: Clean Use of C Constructs
-* Names:: Naming Variables and Functions
-* Using Extensions:: Using Non-standard Features
-* System Functions:: Portability and "standard" library functions
-* Semantics:: Program Behavior for All Programs
-* Errors:: Formatting Error Messages
-* Libraries:: Library Behavior
-* Portability:: Portability As It Applies to GNU
-* User Interfaces:: Standards for Command Line Interfaces
-* Documentation:: Documenting Programs
-* Releases:: Making Releases
-
-
-File: standards.info, Node: Reading Non-Free Code, Next: Contributions, Prev: Top, Up: Top
-
-Referring to Proprietary Programs
-*********************************
-
- Don't in any circumstances refer to Unix source code for or during
-your work on GNU! (Or to any other proprietary programs.)
-
- If you have a vague recollection of the internals of a Unix program,
-this does not absolutely mean you can't write an imitation of it, but
-do try to organize the imitation internally along different lines,
-because this is likely to make the details of the Unix version
-irrelevant and dissimilar to your results.
-
- For example, Unix utilities were generally optimized to minimize
-memory use; if you go for speed instead, your program will be very
-different. You could keep the entire input file in core and scan it
-there instead of using stdio. Use a smarter algorithm discovered more
-recently than the Unix program. Eliminate use of temporary files. Do
-it in one pass instead of two (we did this in the assembler).
-
- Or, on the contrary, emphasize simplicity instead of speed. For some
-applications, the speed of today's computers makes simpler algorithms
-adequate.
-
- Or go for generality. For example, Unix programs often have static
-tables or fixed-size strings, which make for arbitrary limits; use
-dynamic allocation instead. Make sure your program handles NULs and
-other funny characters in the input files. Add a programming language
-for extensibility and write part of the program in that language.
-
- Or turn some parts of the program into independently usable
-libraries. Or use a simple garbage collector instead of tracking
-precisely when to free memory, or use a new GNU facility such as
-obstacks.
-
-
-File: standards.info, Node: Contributions, Next: Change Logs, Prev: Reading Non-Free Code, Up: Top
-
-Accepting Contributions
-***********************
-
- If someone else sends you a piece of code to add to the program you
-are working on, we need legal papers to use it--the same sort of legal
-papers we will need to get from you. *Each* significant contributor to
-a program must sign some sort of legal papers in order for us to have
-clear title to the program. The main author alone is not enough.
-
- So, before adding in any contributions from other people, tell us so
-we can arrange to get the papers. Then wait until we tell you that we
-have received the signed papers, before you actually use the
-contribution.
-
- This applies both before you release the program and afterward. If
-you receive diffs to fix a bug, and they make significant change, we
-need legal papers for it.
-
- You don't need papers for changes of a few lines here or there, since
-they are not significant for copyright purposes. Also, you don't need
-papers if all you get from the suggestion is some ideas, not actual code
-which you use. For example, if you write a different solution to the
-problem, you don't need to get papers.
-
- I know this is frustrating; it's frustrating for us as well. But if
-you don't wait, you are going out on a limb--for example, what if the
-contributor's employer won't sign a disclaimer? You might have to take
-that code out again!
-
- The very worst thing is if you forget to tell us about the other
-contributor. We could be very embarrassed in court some day as a
-result.
-
-
-File: standards.info, Node: Change Logs, Next: Compatibility, Prev: Contributions, Up: Top
-
-Change Logs
-***********
-
- Keep a change log for each directory, describing the changes made to
-source files in that directory. The purpose of this is so that people
-investigating bugs in the future will know about the changes that might
-have introduced the bug. Often a new bug can be found by looking at
-what was recently changed. More importantly, change logs can help
-eliminate conceptual inconsistencies between different parts of a
-program; they can give you a history of how the conflicting concepts
-arose.
-
- Use the Emacs command `M-x add-change' to start a new entry in the
-change log. An entry should have an asterisk, the name of the changed
-file, and then in parentheses the name of the changed functions,
-variables or whatever, followed by a colon. Then describe the changes
-you made to that function or variable.
-
- Separate unrelated entries with blank lines. When two entries
-represent parts of the same change, so that they work together, then
-don't put blank lines between them. Then you can omit the file name
-and the asterisk when successive entries are in the same file.
-
- Here are some examples:
-
- * register.el (insert-register): Return nil.
- (jump-to-register): Likewise.
-
- * sort.el (sort-subr): Return nil.
-
- * tex-mode.el (tex-bibtex-file, tex-file, tex-region):
- Restart the tex shell if process is gone or stopped.
- (tex-shell-running): New function.
-
- * expr.c (store_one_arg): Round size up for move_block_to_reg.
- (expand_call): Round up when emitting USE insns.
- * stmt.c (assign_parms): Round size up for move_block_from_reg.
-
- It's important to name the changed function or variable in full.
-Don't abbreviate them; don't combine them. Subsequent maintainers will
-often search for a function name to find all the change log entries that
-pertain to it; if you abbreviate the name, they won't find it when they
-search. For example, some people are tempted to abbreviate groups of
-function names by writing `* register.el ({insert,jump-to}-register)';
-this is not a good idea, since searching for `jump-to-register' or
-`insert-register' would not find the entry.
-
- There's no need to describe the full purpose of the changes or how
-they work together. It is better to put such explanations in comments
-in the code. That's why just "New function" is enough; there is a
-comment with the function in the source to explain what it does.
-
- However, sometimes it is useful to write one line to describe the
-overall purpose of a large batch of changes.
-
- You can think of the change log as a conceptual "undo list" which
-explains how earlier versions were different from the current version.
-People can see the current version; they don't need the change log to
-tell them what is in it. What they want from a change log is a clear
-explanation of how the earlier version differed.
-
- When you change the calling sequence of a function in a simple
-fashion, and you change all the callers of the function, there is no
-need to make individual entries for all the callers. Just write in the
-entry for the function being called, "All callers changed."
-
- When you change just comments or doc strings, it is enough to write
-an entry for the file, without mentioning the functions. Write just,
-"Doc fix." There's no need to keep a change log for documentation
-files. This is because documentation is not susceptible to bugs that
-are hard to fix. Documentation does not consist of parts that must
-interact in a precisely engineered fashion; to correct an error, you
-need not know the history of the erroneous passage.
-
-
-File: standards.info, Node: Compatibility, Next: Makefile Conventions, Prev: Change Logs, Up: Top
-
-Compatibility with Other Implementations
-****************************************
-
- With certain exceptions, utility programs and libraries for GNU
-should be upward compatible with those in Berkeley Unix, and upward
-compatible with ANSI C if ANSI C specifies their behavior, and upward
-compatible with POSIX if POSIX specifies their behavior.
-
- When these standards conflict, it is useful to offer compatibility
-modes for each of them.
-
- ANSI C and POSIX prohibit many kinds of extensions. Feel free to
-make the extensions anyway, and include a `--ansi' or `--compatible'
-option to turn them off. However, if the extension has a significant
-chance of breaking any real programs or scripts, then it is not really
-upward compatible. Try to redesign its interface.
-
- Many GNU programs suppress extensions that conflict with POSIX if the
-environment variable `POSIXLY_CORRECT' is defined (even if it is
-defined with a null value). Please make your program recognize this
-variable if appropriate.
-
- When a feature is used only by users (not by programs or command
-files), and it is done poorly in Unix, feel free to replace it
-completely with something totally different and better. (For example,
-vi is replaced with Emacs.) But it is nice to offer a compatible
-feature as well. (There is a free vi clone, so we offer it.)
-
- Additional useful features not in Berkeley Unix are welcome.
-Additional programs with no counterpart in Unix may be useful, but our
-first priority is usually to duplicate what Unix already has.
-
-
-File: standards.info, Node: Makefile Conventions, Next: Configuration, Prev: Compatibility, Up: Top
-
-Makefile Conventions
-********************
-
- This chapter describes conventions for writing the Makefiles for GNU
-programs.
-
-* Menu:
-
-* Makefile Basics::
-* Utilities in Makefiles::
-* Standard Targets::
-* Command Variables::
-* Directory Variables::
-
-
-File: standards.info, Node: Makefile Basics, Next: Utilities in Makefiles, Up: Makefile Conventions
-
-General Conventions for Makefiles
-=================================
-
- Every Makefile should contain this line:
-
- SHELL = /bin/sh
-
-to avoid trouble on systems where the `SHELL' variable might be
-inherited from the environment. (This is never a problem with GNU
-`make'.)
-
- Don't assume that `.' is in the path for command execution. When
-you need to run programs that are a part of your package during the
-make, please make sure that it uses `./' if the program is built as
-part of the make or `$(srcdir)/' if the file is an unchanging part of
-the source code. Without one of these prefixes, the current search
-path is used.
-
- The distinction between `./' and `$(srcdir)/' is important when
-using the `--srcdir' option to `configure'. A rule of the form:
-
- foo.1 : foo.man sedscript
- sed -e sedscript foo.man > foo.1
-
-will fail when the current directory is not the source directory,
-because `foo.man' and `sedscript' are not in the current directory.
-
- When using GNU `make', relying on `VPATH' to find the source file
-will work in the case where there is a single dependency file, since
-the `make' automatic variable `$<' will represent the source file
-wherever it is. (Many versions of `make' set `$<' only in implicit
-rules.) A makefile target like
-
- foo.o : bar.c
- $(CC) -I. -I$(srcdir) $(CFLAGS) -c bar.c -o foo.o
-
-should instead be written as
-
- foo.o : bar.c
- $(CC) $(CFLAGS) $< -o $@
-
-in order to allow `VPATH' to work correctly. When the target has
-multiple dependencies, using an explicit `$(srcdir)' is the easiest way
-to make the rule work well. For example, the target above for `foo.1'
-is best written as:
-
- foo.1 : foo.man sedscript
- sed -s $(srcdir)/sedscript $(srcdir)/foo.man > foo.1
-
-
-File: standards.info, Node: Utilities in Makefiles, Next: Standard Targets, Prev: Makefile Basics, Up: Makefile Conventions
-
-Utilities in Makefiles
-======================
-
- Write the Makefile commands (and any shell scripts, such as
-`configure') to run in `sh', not in `csh'. Don't use any special
-features of `ksh' or `bash'.
-
- The `configure' script and the Makefile rules for building and
-installation should not use any utilities directly except these:
-
- cat cmp cp echo egrep expr grep
- ln mkdir mv pwd rm rmdir sed test touch
-
- Stick to the generally supported options for these programs. For
-example, don't use `mkdir -p', convenient as it may be, because most
-systems don't support it.
-
- The Makefile rules for building and installation can also use
-compilers and related programs, but should do so via `make' variables
-so that the user can substitute alternatives. Here are some of the
-programs we mean:
-
- ar bison cc flex install ld lex
- make makeinfo ranlib texi2dvi yacc
-
- When you use `ranlib', you should test whether it exists, and run it
-only if it exists, so that the distribution will work on systems that
-don't have `ranlib'.
-
- If you use symbolic links, you should implement a fallback for
-systems that don't have symbolic links.
-
- It is ok to use other utilities in Makefile portions (or scripts)
-intended only for particular systems where you know those utilities to
-exist.
-
-
-File: standards.info, Node: Standard Targets, Next: Command Variables, Prev: Utilities in Makefiles, Up: Makefile Conventions
-
-Standard Targets for Users
-==========================
-
- All GNU programs should have the following targets in their
-Makefiles:
-
-`all'
- Compile the entire program. This should be the default target.
- This target need not rebuild any documentation files; Info files
- should normally be included in the distribution, and DVI files
- should be made only when explicitly asked for.
-
-`install'
- Compile the program and copy the executables, libraries, and so on
- to the file names where they should reside for actual use. If
- there is a simple test to verify that a program is properly
- installed, this target should run that test.
-
- The commands should create all the directories in which files are
- to be installed, if they don't already exist. This includes the
- directories specified as the values of the variables `prefix' and
- `exec_prefix', as well as all subdirectories that are needed. One
- way to do this is by means of an `installdirs' target as described
- below.
-
- Use `-' before any command for installing a man page, so that
- `make' will ignore any errors. This is in case there are systems
- that don't have the Unix man page documentation system installed.
-
- The way to install Info files is to copy them into `$(infodir)'
- with `$(INSTALL_DATA)' (*note Command Variables::.), and then run
- the `install-info' program if it is present. `install-info' is a
- script that edits the Info `dir' file to add or update the menu
- entry for the given Info file; it will be part of the Texinfo
- package. Here is a sample rule to install an Info file:
-
- $(infodir)/foo.info: foo.info
- # There may be a newer info file in . than in srcdir.
- -if test -f foo.info; then d=.; \
- else d=$(srcdir); fi; \
- $(INSTALL_DATA) $$d/foo.info $@; \
- # Run install-info only if it exists.
- # Use `if' instead of just prepending `-' to the
- # line so we notice real errors from install-info.
- # We use `$(SHELL) -c' because some shells do not
- # fail gracefully when there is an unknown command.
- if $(SHELL) -c 'install-info --version' \
- >/dev/null 2>&1; then \
- install-info --infodir=$(infodir) $$d/foo.info; \
- else true; fi
-
-`uninstall'
- Delete all the installed files that the `install' target would
- create (but not the noninstalled files such as `make all' would
- create).
-
-`clean'
- Delete all files from the current directory that are normally
- created by building the program. Don't delete the files that
- record the configuration. Also preserve files that could be made
- by building, but normally aren't because the distribution comes
- with them.
-
- Delete `.dvi' files here if they are not part of the distribution.
-
-`distclean'
- Delete all files from the current directory that are created by
- configuring or building the program. If you have unpacked the
- source and built the program without creating any other files,
- `make distclean' should leave only the files that were in the
- distribution.
-
-`mostlyclean'
- Like `clean', but may refrain from deleting a few files that people
- normally don't want to recompile. For example, the `mostlyclean'
- target for GCC does not delete `libgcc.a', because recompiling it
- is rarely necessary and takes a lot of time.
-
-`realclean'
- Delete everything from the current directory that can be
- reconstructed with this Makefile. This typically includes
- everything deleted by `distclean', plus more: C source files
- produced by Bison, tags tables, Info files, and so on.
-
- One exception, however: `make realclean' should not delete
- `configure' even if `configure' can be remade using a rule in the
- Makefile. More generally, `make realclean' should not delete
- anything that needs to exist in order to run `configure' and then
- begin to build the program.
-
-`TAGS'
- Update a tags table for this program.
-
-`info'
- Generate any Info files needed. The best way to write the rules
- is as follows:
-
- info: foo.info
-
- foo.info: foo.texi chap1.texi chap2.texi
- $(MAKEINFO) $(srcdir)/foo.texi
-
- You must define the variable `MAKEINFO' in the Makefile. It should
- run the `makeinfo' program, which is part of the Texinfo
- distribution.
-
-`dvi'
- Generate DVI files for all TeXinfo documentation. For example:
-
- dvi: foo.dvi
-
- foo.dvi: foo.texi chap1.texi chap2.texi
- $(TEXI2DVI) $(srcdir)/foo.texi
-
- You must define the variable `TEXI2DVI' in the Makefile. It should
- run the program `texi2dvi', which is part of the Texinfo
- distribution. Alternatively, write just the dependencies, and
- allow GNU Make to provide the command.
-
-`dist'
- Create a distribution tar file for this program. The tar file
- should be set up so that the file names in the tar file start with
- a subdirectory name which is the name of the package it is a
- distribution for. This name can include the version number.
-
- For example, the distribution tar file of GCC version 1.40 unpacks
- into a subdirectory named `gcc-1.40'.
-
- The easiest way to do this is to create a subdirectory
- appropriately named, use `ln' or `cp' to install the proper files
- in it, and then `tar' that subdirectory.
-
- The `dist' target should explicitly depend on all non-source files
- that are in the distribution, to make sure they are up to date in
- the distribution. *Note Making Releases: (standards)Releases.
-
-`check'
- Perform self-tests (if any). The user must build the program
- before running the tests, but need not install the program; you
- should write the self-tests so that they work when the program is
- built but not installed.
-
- The following targets are suggested as conventional names, for
-programs in which they are useful.
-
-`installcheck'
- Perform installation tests (if any). The user must build and
- install the program before running the tests. You should not
- assume that `$(bindir)' is in the search path.
-
-`installdirs'
- It's useful to add a target named `installdirs' to create the
- directories where files are installed, and their parent
- directories. There is a script called `mkinstalldirs' which is
- convenient for this; find it in the Texinfo package.You can use a
- rule like this:
-
- # Make sure all installation directories (e.g. $(bindir))
- # actually exist by making them if necessary.
- installdirs: mkinstalldirs
- $(srcdir)/mkinstalldirs $(bindir) $(datadir) \
- $(libdir) $(infodir) \
- $(mandir)
-
-
-File: standards.info, Node: Command Variables, Next: Directory Variables, Prev: Standard Targets, Up: Makefile Conventions
-
-Variables for Specifying Commands
-=================================
-
- Makefiles should provide variables for overriding certain commands,
-options, and so on.
-
- In particular, you should run most utility programs via variables.
-Thus, if you use Bison, have a variable named `BISON' whose default
-value is set with `BISON = bison', and refer to it with `$(BISON)'
-whenever you need to use Bison.
-
- File management utilities such as `ln', `rm', `mv', and so on, need
-not be referred to through variables in this way, since users don't
-need to replace them with other programs.
-
- Each program-name variable should come with an options variable that
-is used to supply options to the program. Append `FLAGS' to the
-program-name variable name to get the options variable name--for
-example, `BISONFLAGS'. (The name `CFLAGS' is an exception to this
-rule, but we keep it because it is standard.) Use `CPPFLAGS' in any
-compilation command that runs the preprocessor, and use `LDFLAGS' in
-any compilation command that does linking as well as in any direct use
-of `ld'.
-
- If there are C compiler options that *must* be used for proper
-compilation of certain files, do not include them in `CFLAGS'. Users
-expect to be able to specify `CFLAGS' freely themselves. Instead,
-arrange to pass the necessary options to the C compiler independently
-of `CFLAGS', by writing them explicitly in the compilation commands or
-by defining an implicit rule, like this:
-
- CFLAGS = -g
- ALL_CFLAGS = -I. $(CFLAGS)
- .c.o:
- $(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $<
-
- Do include the `-g' option in `CFLAGS', because that is not
-*required* for proper compilation. You can consider it a default that
-is only recommended. If the package is set up so that it is compiled
-with GCC by default, then you might as well include `-O' in the default
-value of `CFLAGS' as well.
-
- Put `CFLAGS' last in the compilation command, after other variables
-containing compiler options, so the user can use `CFLAGS' to override
-the others.
-
- Every Makefile should define the variable `INSTALL', which is the
-basic command for installing a file into the system.
-
- Every Makefile should also define the variables `INSTALL_PROGRAM'
-and `INSTALL_DATA'. (The default for each of these should be
-`$(INSTALL)'.) Then it should use those variables as the commands for
-actual installation, for executables and nonexecutables respectively.
-Use these variables as follows:
-
- $(INSTALL_PROGRAM) foo $(bindir)/foo
- $(INSTALL_DATA) libfoo.a $(libdir)/libfoo.a
-
-Always use a file name, not a directory name, as the second argument of
-the installation commands. Use a separate command for each file to be
-installed.
-
-
-File: standards.info, Node: Directory Variables, Prev: Command Variables, Up: Makefile Conventions
-
-Variables for Installation Directories
-======================================
-
- Installation directories should always be named by variables, so it
-is easy to install in a nonstandard place. The standard names for these
-variables are:
-
-`prefix'
- A prefix used in constructing the default values of the variables
- listed below. The default value of `prefix' should be `/usr/local'
- (at least for now).
-
-`exec_prefix'
- A prefix used in constructing the default values of some of the
- variables listed below. The default value of `exec_prefix' should
- be `$(prefix)'.
-
- Generally, `$(exec_prefix)' is used for directories that contain
- machine-specific files (such as executables and subroutine
- libraries), while `$(prefix)' is used directly for other
- directories.
-
-`bindir'
- The directory for installing executable programs that users can
- run. This should normally be `/usr/local/bin', but write it as
- `$(exec_prefix)/bin'.
-
-`libdir'
- The directory for installing executable files to be run by the
- program rather than by users. Object files and libraries of
- object code should also go in this directory. The idea is that
- this directory is used for files that pertain to a specific
- machine architecture, but need not be in the path for commands.
- The value of `libdir' should normally be `/usr/local/lib', but
- write it as `$(exec_prefix)/lib'.
-
-`datadir'
- The directory for installing read-only data files which the
- programs refer to while they run. This directory is used for
- files which are independent of the type of machine being used.
- This should normally be `/usr/local/lib', but write it as
- `$(prefix)/lib'.
-
-`statedir'
- The directory for installing data files which the programs modify
- while they run. These files should be independent of the type of
- machine being used, and it should be possible to share them among
- machines at a network installation. This should normally be
- `/usr/local/lib', but write it as `$(prefix)/lib'.
-
-`includedir'
- The directory for installing header files to be included by user
- programs with the C `#include' preprocessor directive. This
- should normally be `/usr/local/include', but write it as
- `$(prefix)/include'.
-
- Most compilers other than GCC do not look for header files in
- `/usr/local/include'. So installing the header files this way is
- only useful with GCC. Sometimes this is not a problem because some
- libraries are only really intended to work with GCC. But some
- libraries are intended to work with other compilers. They should
- install their header files in two places, one specified by
- `includedir' and one specified by `oldincludedir'.
-
-`oldincludedir'
- The directory for installing `#include' header files for use with
- compilers other than GCC. This should normally be `/usr/include'.
-
- The Makefile commands should check whether the value of
- `oldincludedir' is empty. If it is, they should not try to use
- it; they should cancel the second installation of the header files.
-
- A package should not replace an existing header in this directory
- unless the header came from the same package. Thus, if your Foo
- package provides a header file `foo.h', then it should install the
- header file in the `oldincludedir' directory if either (1) there
- is no `foo.h' there or (2) the `foo.h' that exists came from the
- Foo package.
-
- To tell whether `foo.h' came from the Foo package, put a magic
- string in the file--part of a comment--and grep for that string.
-
-`mandir'
- The directory for installing the man pages (if any) for this
- package. It should include the suffix for the proper section of
- the manual--usually `1' for a utility. It will normally be
- `/usr/local/man/man1', but you should write it as
- `$(prefix)/man/man1'.
-
-`man1dir'
- The directory for installing section 1 man pages.
-
-`man2dir'
- The directory for installing section 2 man pages.
-
-`...'
- Use these names instead of `mandir' if the package needs to
- install man pages in more than one section of the manual.
-
- *Don't make the primary documentation for any GNU software be a
- man page. Write a manual in Texinfo instead. Man pages are just
- for the sake of people running GNU software on Unix, which is a
- secondary application only.*
-
-`manext'
- The file name extension for the installed man page. This should
- contain a period followed by the appropriate digit; it should
- normally be `.1'.
-
-`man1ext'
- The file name extension for installed section 1 man pages.
-
-`man2ext'
- The file name extension for installed section 2 man pages.
-
-`...'
- Use these names instead of `manext' if the package needs to
- install man pages in more than one section of the manual.
-
-`infodir'
- The directory for installing the Info files for this package. By
- default, it should be `/usr/local/info', but it should be written
- as `$(prefix)/info'.
-
-`srcdir'
- The directory for the sources being compiled. The value of this
- variable is normally inserted by the `configure' shell script.
-
- For example:
-
- # Common prefix for installation directories.
- # NOTE: This directory must exist when you start the install.
- prefix = /usr/local
- exec_prefix = $(prefix)
- # Where to put the executable for the command `gcc'.
- bindir = $(exec_prefix)/bin
- # Where to put the directories used by the compiler.
- libdir = $(exec_prefix)/lib
- # Where to put the Info files.
- infodir = $(prefix)/info
-
- If your program installs a large number of files into one of the
-standard user-specified directories, it might be useful to group them
-into a subdirectory particular to that program. If you do this, you
-should write the `install' rule to create these subdirectories.
-
- Do not expect the user to include the subdirectory name in the value
-of any of the variables listed above. The idea of having a uniform set
-of variable names for installation directories is to enable the user to
-specify the exact same values for several different GNU packages. In
-order for this to be useful, all the packages must be designed so that
-they will work sensibly when the user does so.
-
-
-File: standards.info, Node: Configuration, Next: Source Language, Prev: Makefile Conventions, Up: Top
-
-How Configuration Should Work
-*****************************
-
- Each GNU distribution should come with a shell script named
-`configure'. This script is given arguments which describe the kind of
-machine and system you want to compile the program for.
-
- The `configure' script must record the configuration options so that
-they affect compilation.
-
- One way to do this is to make a link from a standard name such as
-`config.h' to the proper configuration file for the chosen system. If
-you use this technique, the distribution should *not* contain a file
-named `config.h'. This is so that people won't be able to build the
-program without configuring it first.
-
- Another thing that `configure' can do is to edit the Makefile. If
-you do this, the distribution should *not* contain a file named
-`Makefile'. Instead, include a file `Makefile.in' which contains the
-input used for editing. Once again, this is so that people won't be
-able to build the program without configuring it first.
-
- If `configure' does write the `Makefile', then `Makefile' should
-have a target named `Makefile' which causes `configure' to be rerun,
-setting up the same configuration that was set up last time. The files
-that `configure' reads should be listed as dependencies of `Makefile'.
-
- All the files which are output from the `configure' script should
-have comments at the beginning explaining that they were generated
-automatically using `configure'. This is so that users won't think of
-trying to edit them by hand.
-
- The `configure' script should write a file named `config.status'
-which describes which configuration options were specified when the
-program was last configured. This file should be a shell script which,
-if run, will recreate the same configuration.
-
- The `configure' script should accept an option of the form
-`--srcdir=DIRNAME' to specify the directory where sources are found (if
-it is not the current directory). This makes it possible to build the
-program in a separate directory, so that the actual source directory is
-not modified.
-
- If the user does not specify `--srcdir', then `configure' should
-check both `.' and `..' to see if it can find the sources. If it finds
-the sources in one of these places, it should use them from there.
-Otherwise, it should report that it cannot find the sources, and should
-exit with nonzero status.
-
- Usually the easy way to support `--srcdir' is by editing a
-definition of `VPATH' into the Makefile. Some rules may need to refer
-explicitly to the specified source directory. To make this possible,
-`configure' can add to the Makefile a variable named `srcdir' whose
-value is precisely the specified directory.
-
- The `configure' script should also take an argument which specifies
-the type of system to build the program for. This argument should look
-like this:
-
- CPU-COMPANY-SYSTEM
-
- For example, a Sun 3 might be `m68k-sun-sunos4.1'.
-
- The `configure' script needs to be able to decode all plausible
-alternatives for how to describe a machine. Thus, `sun3-sunos4.1'
-would be a valid alias. So would `sun3-bsd4.2', since SunOS is
-basically BSD and no other BSD system is used on a Sun. For many
-programs, `vax-dec-ultrix' would be an alias for `vax-dec-bsd', simply
-because the differences between Ultrix and BSD are rarely noticeable,
-but a few programs might need to distinguish them.
-
- There is a shell script called `config.sub' that you can use as a
-subroutine to validate system types and canonicalize aliases.
-
- Other options are permitted to specify in more detail the software
-or hardware present on the machine, and include or exclude optional
-parts of the package:
-
-`--enable-FEATURE[=PARAMETER]'
- Configure the package to build and install an optional user-level
- facility called FEATURE. This allows users to choose which
- optional features to include. Giving an optional PARAMETER of
- `no' should omit FEATURE, if it is built by default.
-
- No `--enable' option should *ever* cause one feature to replace
- another. No `--enable' option should ever substitute one useful
- behavior for another useful behavior. The only proper use for
- `--enable' is for questions of whether to build part of the program
- or exclude it.
-
-`--with-PACKAGE'
- The package PACKAGE will be installed, so configure this package
- to work with PACKAGE.
-
- Possible values of PACKAGE include `x', `x-toolkit', `gnu-as' (or
- `gas'), `gnu-ld', `gnu-libc', and `gdb'.
-
- Do not use a `--with' option to specify the file name to use to
- find certain files. That is outside the scope of what `--with'
- options are for.
-
-`--nfp'
- The target machine has no floating point processor.
-
-`--gas'
- The target machine assembler is GAS, the GNU assembler. This is
- obsolete; users should use `--with-gnu-as' instead.
-
-`--x'
- The target machine has the X Window System installed. This is
- obsolete; users should use `--with-x' instead.
-
- All `configure' scripts should accept all of these "detail" options,
-whether or not they make any difference to the particular package at
-hand. In particular, they should accept any option that starts with
-`--with-' or `--enable-'. This is so users will be able to configure
-an entire GNU source tree at once with a single set of options.
-
- You will note that the categories `--with-' and `--enable-' are
-narrow: they *do not* provide a place for any sort of option you might
-think of. That is deliberate. We want to limit the possible
-configuration options in GNU software. We do not want GNU programs to
-have idiosyncratic configuration options.
-
- Packages that perform part of compilation may support
-cross-compilation. In such a case, the host and target machines for
-the program may be different. The `configure' script should normally
-treat the specified type of system as both the host and the target,
-thus producing a program which works for the same type of machine that
-it runs on.
-
- The way to build a cross-compiler, cross-assembler, or what have
-you, is to specify the option `--host=HOSTTYPE' when running
-`configure'. This specifies the host system without changing the type
-of target system. The syntax for HOSTTYPE is the same as described
-above.
-
- Bootstrapping a cross-compiler requires compiling it on a machine
-other than the host it will run on. Compilation packages accept a
-configuration option `--build=HOSTTYPE' for specifying the
-configuration on which you will compile them, in case that is different
-from the host.
-
- Programs for which cross-operation is not meaningful need not accept
-the `--host' option, because configuring an entire operating system for
-cross-operation is not a meaningful thing.
-
- Some programs have ways of configuring themselves automatically. If
-your program is set up to do this, your `configure' script can simply
-ignore most of its arguments.
-
-
-File: standards.info, Node: Source Language, Next: Formatting, Prev: Configuration, Up: Top
-
-Using Languages Other Than C
-****************************
-
- Using a language other than C is like using a non-standard feature:
-it will cause trouble for users. Even if GCC supports the other
-language, users may find it inconvenient to have to install the
-compiler for that other language in order to build your program. So
-please write in C.
-
- There are three exceptions for this rule:
-
- * It is okay to use a special language if the same program contains
- an interpreter for that language.
-
- Thus, it is not a problem that GNU Emacs contains code written in
- Emacs Lisp, because it comes with a Lisp interpreter.
-
- * It is okay to use another language in a tool specifically intended
- for use with that language.
-
- This is okay because the only people who want to build the tool
- will be those who have installed the other language anyway.
-
- * If an application is not of extremely widespread interest, then
- perhaps it's not important if the application is inconvenient to
- install.
-
-
-File: standards.info, Node: Formatting, Next: Comments, Prev: Source Language, Up: Top
-
-Formatting Your Source Code
-***************************
-
- It is important to put the open-brace that starts the body of a C
-function in column zero, and avoid putting any other open-brace or
-open-parenthesis or open-bracket in column zero. Several tools look
-for open-braces in column zero to find the beginnings of C functions.
-These tools will not work on code not formatted that way.
-
- It is also important for function definitions to start the name of
-the function in column zero. This helps people to search for function
-definitions, and may also help certain tools recognize them. Thus, the
-proper format is this:
-
- static char *
- concat (s1, s2) /* Name starts in column zero here */
- char *s1, *s2;
- { /* Open brace in column zero here */
- ...
- }
-
-or, if you want to use ANSI C, format the definition like this:
-
- static char *
- concat (char *s1, char *s2)
- {
- ...
- }
-
- In ANSI C, if the arguments don't fit nicely on one line, split it
-like this:
-
- int
- lots_of_args (int an_integer, long a_long, short a_short,
- double a_double, float a_float)
- ...
-
- For the body of the function, we prefer code formatted like this:
-
- if (x < foo (y, z))
- haha = bar[4] + 5;
- else
- {
- while (z)
- {
- haha += foo (z, z);
- z--;
- }
- return ++x + bar ();
- }
-
- We find it easier to read a program when it has spaces before the
-open-parentheses and after the commas. Especially after the commas.
-
- When you split an expression into multiple lines, split it before an
-operator, not after one. Here is the right way:
-
- if (foo_this_is_long && bar > win (x, y, z)
- && remaining_condition)
-
- Try to avoid having two operators of different precedence at the same
-level of indentation. For example, don't write this:
-
- mode = (inmode[j] == VOIDmode
- || GET_MODE_SIZE (outmode[j]) > GET_MODE_SIZE (inmode[j])
- ? outmode[j] : inmode[j]);
-
- Instead, use extra parentheses so that the indentation shows the
-nesting:
-
- mode = ((inmode[j] == VOIDmode
- || (GET_MODE_SIZE (outmode[j]) > GET_MODE_SIZE (inmode[j])))
- ? outmode[j] : inmode[j]);
-
- Insert extra parentheses so that Emacs will indent the code properly.
-For example, the following indentation looks nice if you do it by hand,
-but Emacs would mess it up:
-
- v = rup->ru_utime.tv_sec*1000 + rup->ru_utime.tv_usec/1000
- + rup->ru_stime.tv_sec*1000 + rup->ru_stime.tv_usec/1000;
-
- But adding a set of parentheses solves the problem:
-
- v = (rup->ru_utime.tv_sec*1000 + rup->ru_utime.tv_usec/1000
- + rup->ru_stime.tv_sec*1000 + rup->ru_stime.tv_usec/1000);
-
- Format do-while statements like this:
-
- do
- {
- a = foo (a);
- }
- while (a > 0);
-
- Please use formfeed characters (control-L) to divide the program into
-pages at logical places (but not within a function). It does not matter
-just how long the pages are, since they do not have to fit on a printed
-page. The formfeeds should appear alone on lines by themselves.
-
-
-File: standards.info, Node: Comments, Next: Syntactic Conventions, Prev: Formatting, Up: Top
-
-Commenting Your Work
-********************
-
- Every program should start with a comment saying briefly what it is
-for. Example: `fmt - filter for simple filling of text'.
-
- Please put a comment on each function saying what the function does,
-what sorts of arguments it gets, and what the possible values of
-arguments mean and are used for. It is not necessary to duplicate in
-words the meaning of the C argument declarations, if a C type is being
-used in its customary fashion. If there is anything nonstandard about
-its use (such as an argument of type `char *' which is really the
-address of the second character of a string, not the first), or any
-possible values that would not work the way one would expect (such as,
-that strings containing newlines are not guaranteed to work), be sure
-to say so.
-
- Also explain the significance of the return value, if there is one.
-
- Please put two spaces after the end of a sentence in your comments,
-so that the Emacs sentence commands will work. Also, please write
-complete sentences and capitalize the first word. If a lower-case
-identifer comes at the beginning of a sentence, don't capitalize it!
-Changing the spelling makes it a different identifier. If you don't
-like starting a sentence with a lower case letter, write the sentence
-differently (e.g., "The identifier lower-case is ...").
-
- The comment on a function is much clearer if you use the argument
-names to speak about the argument values. The variable name itself
-should be lower case, but write it in upper case when you are speaking
-about the value rather than the variable itself. Thus, "the inode
-number NODE_NUM" rather than "an inode".
-
- There is usually no purpose in restating the name of the function in
-the comment before it, because the reader can see that for himself.
-There might be an exception when the comment is so long that the
-function itself would be off the bottom of the screen.
-
- There should be a comment on each static variable as well, like this:
-
- /* Nonzero means truncate lines in the display;
- zero means continue them. */
- int truncate_lines;
-
- Every `#endif' should have a comment, except in the case of short
-conditionals (just a few lines) that are not nested. The comment should
-state the condition of the conditional that is ending, *including its
-sense*. `#else' should have a comment describing the condition *and
-sense* of the code that follows. For example:
-
- #ifdef foo
- ...
- #else /* not foo */
- ...
- #endif /* not foo */
-
-but, by contrast, write the comments this way for a `#ifndef':
-
- #ifndef foo
- ...
- #else /* foo */
- ...
- #endif /* foo */
-
-
-File: standards.info, Node: Syntactic Conventions, Next: Names, Prev: Comments, Up: Top
-
-Clean Use of C Constructs
-*************************
-
- Please explicitly declare all arguments to functions. Don't omit
-them just because they are `int's.
-
- Declarations of external functions and functions to appear later in
-the source file should all go in one place near the beginning of the
-file (somewhere before the first function definition in the file), or
-else should go in a header file. Don't put `extern' declarations inside
-functions.
-
- It used to be common practice to use the same local variables (with
-names like `tem') over and over for different values within one
-function. Instead of doing this, it is better declare a separate local
-variable for each distinct purpose, and give it a name which is
-meaningful. This not only makes programs easier to understand, it also
-facilitates optimization by good compilers. You can also move the
-declaration of each local variable into the smallest scope that includes
-all its uses. This makes the program even cleaner.
-
- Don't use local variables or parameters that shadow global
-identifiers.
-
- Don't declare multiple variables in one declaration that spans lines.
-Start a new declaration on each line, instead. For example, instead of
-this:
-
- int foo,
- bar;
-
-write either this:
-
- int foo, bar;
-
-or this:
-
- int foo;
- int bar;
-
-(If they are global variables, each should have a comment preceding it
-anyway.)
-
- When you have an `if'-`else' statement nested in another `if'
-statement, always put braces around the `if'-`else'. Thus, never write
-like this:
-
- if (foo)
- if (bar)
- win ();
- else
- lose ();
-
-always like this:
-
- if (foo)
- {
- if (bar)
- win ();
- else
- lose ();
- }
-
- If you have an `if' statement nested inside of an `else' statement,
-either write `else if' on one line, like this,
-
- if (foo)
- ...
- else if (bar)
- ...
-
-with its `then'-part indented like the preceding `then'-part, or write
-the nested `if' within braces like this:
-
- if (foo)
- ...
- else
- {
- if (bar)
- ...
- }
-
- Don't declare both a structure tag and variables or typedefs in the
-same declaration. Instead, declare the structure tag separately and
-then use it to declare the variables or typedefs.
-
- Try to avoid assignments inside `if'-conditions. For example, don't
-write this:
-
- if ((foo = (char *) malloc (sizeof *foo)) == 0)
- fatal ("virtual memory exhausted");
-
-instead, write this:
-
- foo = (char *) malloc (sizeof *foo);
- if (foo == 0)
- fatal ("virtual memory exhausted");
-
- Don't make the program ugly to placate `lint'. Please don't insert
-any casts to `void'. Zero without a cast is perfectly fine as a null
-pointer constant.
-
-
-File: standards.info, Node: Names, Next: Using Extensions, Prev: Syntactic Conventions, Up: Top
-
-Naming Variables and Functions
-******************************
-
- Please use underscores to separate words in a name, so that the Emacs
-word commands can be useful within them. Stick to lower case; reserve
-upper case for macros and `enum' constants, and for name-prefixes that
-follow a uniform convention.
-
- For example, you should use names like `ignore_space_change_flag';
-don't use names like `iCantReadThis'.
-
- Variables that indicate whether command-line options have been
-specified should be named after the meaning of the option, not after
-the option-letter. A comment should state both the exact meaning of
-the option and its letter. For example,
-
- /* Ignore changes in horizontal whitespace (-b). */
- int ignore_space_change_flag;
-
- When you want to define names with constant integer values, use
-`enum' rather than `#define'. GDB knows about enumeration constants.
-
- Use file names of 14 characters or less, to avoid creating gratuitous
-problems on System V. You can use the program `doschk' to test for
-this. `doschk' also tests for potential name conflicts if the files
-were loaded onto an MS-DOS file system--something you may or may not
-care about.
-
diff --git a/gnu/usr.bin/binutils/etc/standards.info-2 b/gnu/usr.bin/binutils/etc/standards.info-2
deleted file mode 100644
index 119f28149f4..00000000000
--- a/gnu/usr.bin/binutils/etc/standards.info-2
+++ /dev/null
@@ -1,1462 +0,0 @@
-This is Info file standards.info, produced by Makeinfo-1.55 from the
-input file ./standards.texi.
-
-START-INFO-DIR-ENTRY
-* Standards: (standards). GNU coding standards.
-END-INFO-DIR-ENTRY
-
- GNU Coding Standards Copyright (C) 1992, 1993, 1994 Free Software
-Foundation
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions, except that this permission notice may be stated in a
-translation approved by the Free Software Foundation.
-
-
-File: standards.info, Node: Using Extensions, Next: System Functions, Prev: Names, Up: Top
-
-Using Non-standard Features
-***************************
-
- Many GNU facilities that already exist support a number of convenient
-extensions over the comparable Unix facilities. Whether to use these
-extensions in implementing your program is a difficult question.
-
- On the one hand, using the extensions can make a cleaner program.
-On the other hand, people will not be able to build the program unless
-the other GNU tools are available. This might cause the program to
-work on fewer kinds of machines.
-
- With some extensions, it might be easy to provide both alternatives.
-For example, you can define functions with a "keyword" `INLINE' and
-define that as a macro to expand into either `inline' or nothing,
-depending on the compiler.
-
- In general, perhaps it is best not to use the extensions if you can
-straightforwardly do without them, but to use the extensions if they
-are a big improvement.
-
- An exception to this rule are the large, established programs (such
-as Emacs) which run on a great variety of systems. Such programs would
-be broken by use of GNU extensions.
-
- Another exception is for programs that are used as part of
-compilation: anything that must be compiled with other compilers in
-order to bootstrap the GNU compilation facilities. If these require
-the GNU compiler, then no one can compile them without having them
-installed already. That would be no good.
-
- Since most computer systems do not yet implement ANSI C, using the
-ANSI C features is effectively using a GNU extension, so the same
-considerations apply. (Except for ANSI features that we discourage,
-such as trigraphs--don't ever use them.)
-
-
-File: standards.info, Node: System Functions, Next: Semantics, Prev: Using Extensions, Up: Top
-
-Calling System Functions
-************************
-
- C implementations differ substantially. ANSI C reduces but does not
-eliminate the incompatibilities; meanwhile, many users wish to compile
-GNU software with pre-ANSI compilers. This chapter gives
-recommendations for how to use the more or less standard C library
-functions to avoid unnecessary loss of portability.
-
- * Don't use the value of `sprintf'. It returns the number of
- characters written on some systems, but not on all systems.
-
- * Don't declare system functions explicitly.
-
- Almost any declaration for a system function is wrong on some
- system. To minimize conflicts, leave it to the system header
- files to declare system functions. If the headers don't declare a
- function, let it remain undeclared.
-
- While it may seem unclean to use a function without declaring it,
- in practice this works fine for most system library functions on
- the systems where this really happens. The problem is only
- theoretical. By contrast, actual declarations have frequently
- caused actual conflicts.
-
- * If you must declare a system function, don't specify the argument
- types. Use an old-style declaration, not an ANSI prototype. The
- more you specify about the function, the more likely a conflict.
-
- * In particular, don't unconditionally declare `malloc' or `realloc'.
-
- Most GNU programs use those functions just once, in functions
- conventionally named `xmalloc' and `xrealloc'. These functions
- call `malloc' and `realloc', respectively, and check the results.
-
- Because `xmalloc' and `xrealloc' are defined in your program, you
- can declare them in other files without any risk of type conflict.
-
- On most systems, `int' is the same length as a pointer; thus, the
- calls to `malloc' and `realloc' work fine. For the few
- exceptional systems (mostly 64-bit machines), you can use
- *conditionalized* declarations of `malloc' and `realloc'--or put
- these declarations in configuration files specific to those
- systems.
-
- * The string functions require special treatment. Some Unix systems
- have a header file `string.h'; other have `strings.h'. Neither
- file name is portable. There are two things you can do: use
- Autoconf to figure out which file to include, or don't include
- either file.
-
- * If you don't include either strings file, you can't get
- declarations for the string functions from the header file in the
- usual way.
-
- That causes less of a problem than you might think. The newer ANSI
- string functions are off-limits anyway because many systems still
- don't support them. The string functions you can use are these:
-
- strcpy strncpy strcat strncat
- strlen strcmp strncmp
- strchr strrchr
-
- The copy and concatenate functions work fine without a declaration
- as long as you don't use their values. Using their values without
- a declaration fails on systems where the width of a pointer
- differs from the width of `int', and perhaps in other cases. It
- is trivial to avoid using their values, so do that.
-
- The compare functions and `strlen' work fine without a declaration
- on most systems, possibly all the ones that GNU software runs on.
- You may find it necessary to declare them *conditionally* on a few
- systems.
-
- The search functions must be declared to return `char *'. Luckily,
- there is no variation in the data type they return. But there is
- variation in their names. Some systems give these functions the
- names `index' and `rindex'; other systems use the names `strchr'
- and `strrchr'. Some systems support both pairs of names, but
- neither pair works on all systems.
-
- You should pick a single pair of names and use it throughout your
- program. (Nowadays, it is better to choose `strchr' and
- `strrchr'.) Declare both of those names as functions returning
- `char *'. On systems which don't support those names, define them
- as macros in terms of the other pair. For example, here is what
- to put at the beginning of your file (or in a header) if you want
- to use the names `strchr' and `strrchr' throughout:
-
- #ifndef HAVE_STRCHR
- #define strchr index
- #endif
- #ifndef HAVE_STRRCHR
- #define strrchr rindex
- #endif
-
- char *strchr ();
- char *strrchr ();
-
- Here we assume that `HAVE_STRCHR' and `HAVE_STRRCHR' are macros
-defined in systems where the corresponding functions exist. One way to
-get them properly defined is to use Autoconf.
-
-
-File: standards.info, Node: Semantics, Next: Errors, Prev: System Functions, Up: Top
-
-Program Behavior for All Programs
-*********************************
-
- Avoid arbitrary limits on the length or number of *any* data
-structure, including filenames, lines, files, and symbols, by allocating
-all data structures dynamically. In most Unix utilities, "long lines
-are silently truncated". This is not acceptable in a GNU utility.
-
- Utilities reading files should not drop NUL characters, or any other
-nonprinting characters *including those with codes above 0177*. The
-only sensible exceptions would be utilities specifically intended for
-interface to certain types of printers that can't handle those
-characters.
-
- Check every system call for an error return, unless you know you
-wish to ignore errors. Include the system error text (from `perror' or
-equivalent) in *every* error message resulting from a failing system
-call, as well as the name of the file if any and the name of the
-utility. Just "cannot open foo.c" or "stat failed" is not sufficient.
-
- Check every call to `malloc' or `realloc' to see if it returned
-zero. Check `realloc' even if you are making the block smaller; in a
-system that rounds block sizes to a power of 2, `realloc' may get a
-different block if you ask for less space.
-
- In Unix, `realloc' can destroy the storage block if it returns zero.
-GNU `realloc' does not have this bug: if it fails, the original block
-is unchanged. Feel free to assume the bug is fixed. If you wish to
-run your program on Unix, and wish to avoid lossage in this case, you
-can use the GNU `malloc'.
-
- You must expect `free' to alter the contents of the block that was
-freed. Anything you want to fetch from the block, you must fetch before
-calling `free'.
-
- Use `getopt_long' to decode arguments, unless the argument syntax
-makes this unreasonable.
-
- When static storage is to be written in during program execution, use
-explicit C code to initialize it. Reserve C initialized declarations
-for data that will not be changed.
-
- Try to avoid low-level interfaces to obscure Unix data structures
-(such as file directories, utmp, or the layout of kernel memory), since
-these are less likely to work compatibly. If you need to find all the
-files in a directory, use `readdir' or some other high-level interface.
-These will be supported compatibly by GNU.
-
- By default, the GNU system will provide the signal handling
-functions of BSD and of POSIX. So GNU software should be written to use
-these.
-
- In error checks that detect "impossible" conditions, just abort.
-There is usually no point in printing any message. These checks
-indicate the existence of bugs. Whoever wants to fix the bugs will have
-to read the source code and run a debugger. So explain the problem with
-comments in the source. The relevant data will be in variables, which
-are easy to examine with the debugger, so there is no point moving them
-elsewhere.
-
-
-File: standards.info, Node: Errors, Next: Libraries, Prev: Semantics, Up: Top
-
-Formatting Error Messages
-*************************
-
- Error messages from compilers should look like this:
-
- SOURCE-FILE-NAME:LINENO: MESSAGE
-
- Error messages from other noninteractive programs should look like
-this:
-
- PROGRAM:SOURCE-FILE-NAME:LINENO: MESSAGE
-
-when there is an appropriate source file, or like this:
-
- PROGRAM: MESSAGE
-
-when there is no relevant source file.
-
- In an interactive program (one that is reading commands from a
-terminal), it is better not to include the program name in an error
-message. The place to indicate which program is running is in the
-prompt or with the screen layout. (When the same program runs with
-input from a source other than a terminal, it is not interactive and
-would do best to print error messages using the noninteractive style.)
-
- The string MESSAGE should not begin with a capital letter when it
-follows a program name and/or filename. Also, it should not end with a
-period.
-
- Error messages from interactive programs, and other messages such as
-usage messages, should start with a capital letter. But they should not
-end with a period.
-
-
-File: standards.info, Node: Libraries, Next: Portability, Prev: Errors, Up: Top
-
-Library Behavior
-****************
-
- Try to make library functions reentrant. If they need to do dynamic
-storage allocation, at least try to avoid any nonreentrancy aside from
-that of `malloc' itself.
-
- Here are certain name conventions for libraries, to avoid name
-conflicts.
-
- Choose a name prefix for the library, more than two characters long.
-All external function and variable names should start with this prefix.
-In addition, there should only be one of these in any given library
-member. This usually means putting each one in a separate source file.
-
- An exception can be made when two external symbols are always used
-together, so that no reasonable program could use one without the
-other; then they can both go in the same file.
-
- External symbols that are not documented entry points for the user
-should have names beginning with `_'. They should also contain the
-chosen name prefix for the library, to prevent collisions with other
-libraries. These can go in the same files with user entry points if
-you like.
-
- Static functions and variables can be used as you like and need not
-fit any naming convention.
-
-
-File: standards.info, Node: Portability, Next: User Interfaces, Prev: Libraries, Up: Top
-
-Portability As It Applies to GNU
-********************************
-
- Much of what is called "portability" in the Unix world refers to
-porting to different Unix versions. This is a secondary consideration
-for GNU software, because its primary purpose is to run on top of one
-and only one kernel, the GNU kernel, compiled with one and only one C
-compiler, the GNU C compiler. The amount and kinds of variation among
-GNU systems on different cpu's will be like the variation among Berkeley
-4.3 systems on different cpu's.
-
- All users today run GNU software on non-GNU systems. So supporting a
-variety of non-GNU systems is desirable; simply not paramount. The
-easiest way to achieve portability to a reasonable range of systems is
-to use Autoconf. It's unlikely that your program needs to know more
-information about the host machine than Autoconf can provide, simply
-because most of the programs that need such knowledge have already been
-written.
-
- It is difficult to be sure exactly what facilities the GNU kernel
-will provide, since it isn't finished yet. Therefore, assume you can
-use anything in 4.3; just avoid using the format of semi-internal data
-bases (e.g., directories) when there is a higher-level alternative
-(`readdir').
-
- You can freely assume any reasonably standard facilities in the C
-language, libraries or kernel, because we will find it necessary to
-support these facilities in the full GNU system, whether or not we have
-already done so. The fact that there may exist kernels or C compilers
-that lack these facilities is irrelevant as long as the GNU kernel and
-C compiler support them.
-
- It remains necessary to worry about differences among cpu types, such
-as the difference in byte ordering and alignment restrictions. It's
-unlikely that 16-bit machines will ever be supported by GNU, so there
-is no point in spending any time to consider the possibility that an
-int will be less than 32 bits.
-
- You can assume that all pointers have the same format, regardless of
-the type they point to, and that this is really an integer. There are
-some weird machines where this isn't true, but they aren't important;
-don't waste time catering to them. Besides, eventually we will put
-function prototypes into all GNU programs, and that will probably make
-your program work even on weird machines.
-
- Since some important machines (including the 68000) are big-endian,
-it is important not to assume that the address of an `int' object is
-also the address of its least-significant byte. Thus, don't make the
-following mistake:
-
- int c;
- ...
- while ((c = getchar()) != EOF)
- write(file_descriptor, &c, 1);
-
- You can assume that it is reasonable to use a meg of memory. Don't
-strain to reduce memory usage unless it can get to that level. If your
-program creates complicated data structures, just make them in core and
-give a fatal error if malloc returns zero.
-
- If a program works by lines and could be applied to arbitrary
-user-supplied input files, it should keep only a line in memory, because
-this is not very hard and users will want to be able to operate on input
-files that are bigger than will fit in core all at once.
-
-
-File: standards.info, Node: User Interfaces, Next: Documentation, Prev: Portability, Up: Top
-
-Standards for Command Line Interfaces
-*************************************
-
- Please don't make the behavior of a utility depend on the name used
-to invoke it. It is useful sometimes to make a link to a utility with
-a different name, and that should not change what it does.
-
- Instead, use a run time option or a compilation switch or both to
-select among the alternate behaviors.
-
- Likewise, please don't make the behavior of the program depend on the
-type of output device it is used with. Device independence is an
-important principle of the system's design; do not compromise it merely
-to save someone from typing an option now and then.
-
- If you think one behavior is most useful when the output is to a
-terminal, and another is most useful when the output is a file or a
-pipe, then it is usually best to make the default behavior the one that
-is useful with output to a terminal, and have an option for the other
-behavior.
-
- Compatibility requires certain programs to depend on the type of
-output device. It would be disastrous if `ls' or `sh' did not do so in
-the way all users expect. In some of these cases, we supplement the
-program with a preferred alternate version that does not depend on the
-output device type. For example, we provide a `dir' program much like
-`ls' except that its default output format is always multi-column
-format.
-
- It is a good idea to follow the POSIX guidelines for the
-command-line options of a program. The easiest way to do this is to use
-`getopt' to parse them. Note that the GNU version of `getopt' will
-normally permit options anywhere among the arguments unless the special
-argument `--' is used. This is not what POSIX specifies; it is a GNU
-extension.
-
- Please define long-named options that are equivalent to the
-single-letter Unix-style options. We hope to make GNU more user
-friendly this way. This is easy to do with the GNU function
-`getopt_long'.
-
- One of the advantages of long-named options is that they can be
-consistent from program to program. For example, users should be able
-to expect the "verbose" option of any GNU program which has one, to be
-spelled precisely `--verbose'. To achieve this uniformity, look at the
-table of common long-option names when you choose the option names for
-your program. The table appears below.
-
- If you use names not already in the table, please send
-`gnu@prep.ai.mit.edu' a list of them, with their meanings, so we can
-update the table.
-
- It is usually a good idea for file names given as ordinary arguments
-to be input files only; any output files would be specified using
-options (preferably `-o'). Even if you allow an output file name as an
-ordinary argument for compatibility, try to provide a suitable option
-as well. This will lead to more consistency among GNU utilities, so
-that there are fewer idiosyncracies for users to remember.
-
- Programs should support an option `--version' which prints the
-program's version number on standard output and exits successfully, and
-an option `--help' which prints option usage information on standard
-output and exits successfully. These options should inhibit the normal
-function of the command; they should do nothing except print the
-requested information.
-
-`auto-check'
- `-a' in `recode'.
-
-`auto-reference'
- `-A' in `ptx'.
-
-`after-date'
- `-N' in `tar'.
-
-`all'
- `-a' in `du', `ls', `nm', `stty', `uname', and `unexpand'.
-
-`all-text'
- `-a' in `diff'.
-
-`almost-all'
- `-A' in `ls'.
-
-`append'
- `-a' in `etags', `tee', `time'; `-r' in `tar'.
-
-`archive'
- `-a' in `cp'.
-
-`arglength'
- `-l' in `m4'.
-
-`ascii'
- `-a' in `diff'.
-
-`assume-new'
- `-W' in Make.
-
-`assume-old'
- `-o' in Make.
-
-`backward-search'
- `-B' in etags.
-
-`batch'
- Used in GDB.
-
-`baud'
- Used in GDB.
-
-`before'
- `-b' in `tac'.
-
-`binary'
- `-b' in `cpio' and `diff'.
-
-`block-size'
- Used in `cpio' and `tar'.
-
-`blocks'
- `-b' in `head' and `tail'.
-
-`break-file'
- `-b' in `ptx'.
-
-`brief'
- Used in various programs to make output shorter.
-
-`bytes'
- `-c' in `head', `split', and `tail'.
-
-`c++'
- `-C' in `etags'.
-
-`catenate'
- `-A' in `tar'.
-
-`cd'
- Used in various programs to specify the directory to use.
-
-`changes'
- `-c' in `chgrp' and `chown'.
-
-`classify'
- `-F' in `ls'.
-
-`colons'
- `-c' in `recode'.
-
-`command'
- `-c' in `su'; `-x' in GDB.
-
-`compare'
- `-d' in `tar'.
-
-`compress'
- `-Z' in `tar'.
-
-`concatenate'
- `-A' in `tar'.
-
-`confirmation'
- `-w' in `tar'.
-
-`context'
- Used in `diff'.
-
-`copyright'
- `-C' in `ptx' and `recode'.
-
-`core'
- Used in GDB.
-
-`count'
- `-q' in `who'.
-
-`count-links'
- `-l' in `du'.
-
-`create'
- Used in `tar' and `cpio'.
-
-`cxref'
- `-x' in `etags'.
-
-`date'
- `-d' in `touch'.
-
-`debug'
- `-d' in Make and `m4'; `-t' in Bison.
-
-`define'
- `-D' in `m4'.
-
-`defines'
- `-d' in Bison and `etags'.
-
-`delete'
- `-D' in `tar'.
-
-`dereference'
- `-L' in `chgrp', `chown', `cpio', `du', `ls', and `tar'.
-
-`dereference-args'
- `-D' in `du'.
-
-`diacritics'
- `-d' in `recode'.
-
-`dictionary-order'
- `-d' in `look'.
-
-`diff'
- `-d' in `tar'.
-
-`digits'
- `-n' in `csplit'.
-
-`directory'
- Specify the directory to use, in various programs. In `ls', it
- means to show directories themselves rather than their contents.
- In `rm' and `ln', it means to not treat links to directories
- specially.
-
-`discard-all'
- `-x' in `strip'.
-
-`discard-locals'
- `-X' in `strip'.
-
-`diversions'
- `-N' in `m4'.
-
-`dry-run'
- `-n' in Make.
-
-`ed'
- `-e' in `diff'.
-
-`elide-empty-files'
- `-z' in `csplit'.
-
-`entire-new-file'
- `-N' in `diff'.
-
-`environment-overrides'
- `-e' in Make.
-
-`eof'
- `-e' in `xargs'.
-
-`epoch'
- Used in GDB.
-
-`error-limit'
- Used in Makeinfo.
-
-`error-output'
- `-o' in `m4'.
-
-`escape'
- `-b' in `ls'.
-
-`exclude-from'
- `-X' in `tar'.
-
-`exec'
- Used in GDB.
-
-`exit'
- `-x' in `xargs'.
-
-`expand-tabs'
- `-t' in `diff'.
-
-`expression'
- `-e' in `sed'.
-
-`extern-only'
- `-g' in `nm'.
-
-`extract'
- `-i' in `cpio'; `-x' in `tar'.
-
-`faces'
- `-f' in `finger'.
-
-`fast'
- `-f' in `su'.
-
-`file'
- `-f' in `info', Make, `mt', and `tar'; `-n' in `sed'; `-r' in
- `touch'.
-
-`file-prefix'
- `-b' in Bison.
-
-`file-type'
- `-F' in `ls'.
-
-`files-from'
- `-T' in `tar'.
-
-`fill-column'
- Used in Makeinfo.
-
-`flag-truncation'
- `-F' in `ptx'.
-
-`fixed-output-files'
- `-y' in Bison.
-
-`follow'
- `-f' in `tail'.
-
-`footnote-style'
- Used in Makeinfo.
-
-`force'
- `-f' in `cp', `ln', `mv', and `rm'.
-
-`format'
- Used in `ls', `time', and `ptx'.
-
-`forward-search'
- `-F' in `etags'.
-
-`fullname'
- Used in GDB.
-
-`gap-size'
- `-g' in `ptx'.
-
-`get'
- `-x' in `tar'.
-
-`graphic'
- `-i' in `ul'.
-
-`graphics'
- `-g' in `recode'.
-
-`group'
- `-g' in `install'.
-
-`gzip'
- `-z' in `tar'.
-
-`hashsize'
- `-H' in `m4'.
-
-`header'
- `-h' in `objdump' and `recode'
-
-`heading'
- `-H' in `who'.
-
-`help'
- Used to ask for brief usage information.
-
-`hide-control-chars'
- `-q' in `ls'.
-
-`idle'
- `-u' in `who'.
-
-`ifdef'
- `-D' in `diff'.
-
-`ignore'
- `-I' in `ls'; `-x' in `recode'.
-
-`ignore-all-space'
- `-w' in `diff'.
-
-`ignore-backups'
- `-B' in `ls'.
-
-`ignore-blank-lines'
- `-B' in `diff'.
-
-`ignore-case'
- `-f' in `look' and `ptx'; `-i' in `diff'.
-
-`ignore-errors'
- `-i' in Make.
-
-`ignore-file'
- `-i' in `ptx'.
-
-`ignore-indentation'
- `-S' in `etags'.
-
-`ignore-init-file'
- `-f' in Oleo.
-
-`ignore-interrupts'
- `-i' in `tee'.
-
-`ignore-matching-lines'
- `-I' in `diff'.
-
-`ignore-space-change'
- `-b' in `diff'.
-
-`ignore-zeros'
- `-i' in `tar'.
-
-`include'
- `-i' in `etags'; `-I' in `m4'.
-
-`include-dir'
- `-I' in Make.
-
-`incremental'
- `-G' in `tar'.
-
-`info'
- `-i', `-l', and `-m' in Finger.
-
-`initial'
- `-i' in `expand'.
-
-`initial-tab'
- `-T' in `diff'.
-
-`inode'
- `-i' in `ls'.
-
-`interactive'
- `-i' in `cp', `ln', `mv', `rm'; `-e' in `m4'; `-p' in `xargs';
- `-w' in `tar'.
-
-`jobs'
- `-j' in Make.
-
-`just-print'
- `-n' in Make.
-
-`keep-going'
- `-k' in Make.
-
-`keep-files'
- `-k' in `csplit'.
-
-`kilobytes'
- `-k' in `du' and `ls'.
-
-`line-bytes'
- `-C' in `split'.
-
-`lines'
- Used in `split', `head', and `tail'.
-
-`link'
- `-l' in `cpio'.
-
-`list'
- `-t' in `cpio'; `-l' in `recode'.
-
-`list'
- `-t' in `tar'.
-
-`literal'
- `-N' in `ls'.
-
-`load-average'
- `-l' in Make.
-
-`login'
- Used in `su'.
-
-`machine'
- No listing of which programs already use this; someone should
- check to see if any actually do and tell `gnu@prep.ai.mit.edu'.
-
-`macro-name'
- `-M' in `ptx'.
-
-`mail'
- `-m' in `hello' and `uname'.
-
-`make-directories'
- `-d' in `cpio'.
-
-`makefile'
- `-f' in Make.
-
-`mapped'
- Used in GDB.
-
-`max-args'
- `-n' in `xargs'.
-
-`max-chars'
- `-n' in `xargs'.
-
-`max-lines'
- `-l' in `xargs'.
-
-`max-load'
- `-l' in Make.
-
-`max-procs'
- `-P' in `xargs'.
-
-`mesg'
- `-T' in `who'.
-
-`message'
- `-T' in `who'.
-
-`minimal'
- `-d' in `diff'.
-
-`mode'
- `-m' in `install', `mkdir', and `mkfifo'.
-
-`modification-time'
- `-m' in `tar'.
-
-`multi-volume'
- `-M' in `tar'.
-
-`name-prefix'
- `-a' in Bison.
-
-`new-file'
- `-W' in Make.
-
-`no-builtin-rules'
- `-r' in Make.
-
-`no-create'
- `-c' in `touch'.
-
-`no-defines'
- `-D' in `etags'.
-
-`no-dereference'
- `-d' in `cp'.
-
-`no-keep-going'
- `-S' in Make.
-
-`no-lines'
- `-l' in Bison.
-
-`no-prof'
- `-e' in `gprof'.
-
-`no-sort'
- `-p' in `nm'.
-
-`no-split'
- Used in Makeinfo.
-
-`no-static'
- `-a' in `gprof'.
-
-`no-time'
- `-E' in `gprof'.
-
-`no-validate'
- Used in Makeinfo.
-
-`no-warn'
- Used in various programs to inhibit warnings.
-
-`node'
- `-n' in `info'.
-
-`nodename'
- `-n' in `uname'.
-
-`nonmatching'
- `-f' in `cpio'.
-
-`nstuff'
- `-n' in `objdump'.
-
-`null'
- `-0' in `xargs'.
-
-`number'
- `-n' in `cat'.
-
-`number-nonblank'
- `-b' in `cat'.
-
-`numeric-sort'
- `-n' in `nm'.
-
-`numeric-uid-gid'
- `-n' in `cpio' and `ls'.
-
-`nx'
- Used in GDB.
-
-`old-archive'
- `-o' in `tar'.
-
-`old-file'
- `-o' in Make.
-
-`one-file-system'
- `-l' in `tar', `cp', and `du'.
-
-`only-file'
- `-o' in `ptx'.
-
-`only-prof'
- `-f' in `gprof'.
-
-`only-time'
- `-F' in `gprof'.
-
-`output'
- In various programs, specify the output file name.
-
-`override'
- `-o' in `rm'.
-
-`owner'
- `-o' in `install'.
-
-`paginate'
- `-l' in `diff'.
-
-`paragraph-indent'
- Used in Makeinfo.
-
-`parents'
- `-p' in `mkdir' and `rmdir'.
-
-`pass-all'
- `-p' in `ul'.
-
-`pass-through'
- `-p' in `cpio'.
-
-`port'
- `-P' in `finger'.
-
-`portability'
- `-c' in `cpio' and `tar'.
-
-`prefix-builtins'
- `-P' in `m4'.
-
-`prefix'
- `-f' in `csplit'.
-
-`preserve'
- Used in `tar' and `cp'.
-
-`preserve-environment'
- `-p' in `su'.
-
-`preserve-modification-time'
- `-m' in `cpio'.
-
-`preserve-order'
- `-s' in `tar'.
-
-`preserve-permissions'
- `-p' in `tar'.
-
-`print'
- `-l' in `diff'.
-
-`print-chars'
- `-L' in `cmp'.
-
-`print-data-base'
- `-p' in Make.
-
-`print-directory'
- `-w' in Make.
-
-`print-file-name'
- `-o' in `nm'.
-
-`print-symdefs'
- `-s' in `nm'.
-
-`question'
- `-q' in Make.
-
-`quiet'
- Used in many programs to inhibit the usual output. *Note:* every
- program accepting `--quiet' should accept `--silent' as a synonym.
-
-`quote-name'
- `-Q' in `ls'.
-
-`rcs'
- `-n' in `diff'.
-
-`read-full-blocks'
- `-B' in `tar'.
-
-`readnow'
- Used in GDB.
-
-`recon'
- `-n' in Make.
-
-`record-number'
- `-R' in `tar'.
-
-`recursive'
- Used in `chgrp', `chown', `cp', `ls', `diff', and `rm'.
-
-`reference-limit'
- Used in Makeinfo.
-
-`references'
- `-r' in `ptx'.
-
-`regex'
- `-r' in `tac'.
-
-`release'
- `-r' in `uname'.
-
-`relocation'
- `-r' in `objdump'.
-
-`rename'
- `-r' in `cpio'.
-
-`replace'
- `-i' in `xargs'.
-
-`report-identical-files'
- `-s' in `diff'.
-
-`reset-access-time'
- `-a' in `cpio'.
-
-`reverse'
- `-r' in `ls' and `nm'.
-
-`reversed-ed'
- `-f' in `diff'.
-
-`right-side-defs'
- `-R' in `ptx'.
-
-`same-order'
- `-s' in `tar'.
-
-`same-permissions'
- `-p' in `tar'.
-
-`save'
- `-g' in `stty'.
-
-`se'
- Used in GDB.
-
-`sentence-regexp'
- `-S' in `ptx'.
-
-`separate-dirs'
- `-S' in `du'.
-
-`separator'
- `-s' in `tac'.
-
-`sequence'
- Used by `recode' to chose files or pipes for sequencing passes.
-
-`shell'
- `-s' in `su'.
-
-`show-all'
- `-A' in `cat'.
-
-`show-c-function'
- `-p' in `diff'.
-
-`show-ends'
- `-E' in `cat'.
-
-`show-function-line'
- `-F' in `diff'.
-
-`show-tabs'
- `-T' in `cat'.
-
-`silent'
- Used in many programs to inhibit the usual output. *Note:* every
- program accepting `--silent' should accept `--quiet' as a synonym.
-
-`size'
- `-s' in `ls'.
-
-`sort'
- Used in `ls'.
-
-`sparse'
- `-S' in `tar'.
-
-`speed-large-files'
- `-H' in `diff'.
-
-`squeeze-blank'
- `-s' in `cat'.
-
-`starting-file'
- Used in `tar' and `diff' to specify which file within a directory
- to start processing with.
-
-`stop'
- `-S' in Make.
-
-`strict'
- `-s' in `recode'.
-
-`strip'
- `-s' in `install'.
-
-`strip-all'
- `-s' in `strip'.
-
-`strip-debug'
- `-S' in `strip'.
-
-`suffix'
- `-S' in `cp', `ln', `mv'.
-
-`suffix-format'
- `-b' in `csplit'.
-
-`sum'
- `-s' in `gprof'.
-
-`summarize'
- `-s' in `du'.
-
-`symbolic'
- `-s' in `ln'.
-
-`symbols'
- Used in GDB and `objdump'.
-
-`synclines'
- `-s' in `m4'.
-
-`sysname'
- `-s' in `uname'.
-
-`tabs'
- `-t' in `expand' and `unexpand'.
-
-`tabsize'
- `-T' in `ls'.
-
-`terminal'
- `-T' in `tput' and `ul'.
-
-`text'
- `-a' in `diff'.
-
-`time'
- Used in `ls' and `touch'.
-
-`to-stdout'
- `-O' in `tar'.
-
-`total'
- `-c' in `du'.
-
-`touch'
- `-t' in Make, `ranlib', and `recode'.
-
-`trace'
- `-t' in `m4'.
-
-`traditional'
- `-t' in `hello'; `-G' in `m4' and `ptx'.
-
-`tty'
- Used in GDB.
-
-`typedefs'
- `-t' in `etags'.
-
-`typedefs-and-c++'
- `-T' in `etags'.
-
-`typeset-mode'
- `-t' in `ptx'.
-
-`uncompress'
- `-z' in `tar'.
-
-`unconditional'
- `-u' in `cpio'.
-
-`undefine'
- `-U' in `m4'.
-
-`undefined-only'
- `-u' in `nm'.
-
-`update'
- `-u' in `cp', `etags', `mv', `tar'.
-
-`verbose'
- Print more information about progress. Many programs support this.
-
-`verify'
- `-W' in `tar'.
-
-`version'
- Print the version number.
-
-`version-control'
- `-V' in `cp', `ln', `mv'.
-
-`vgrind'
- `-v' in `etags'.
-
-`volume'
- `-V' in `tar'.
-
-`what-if'
- `-W' in Make.
-
-`width'
- `-w' in `ls' and `ptx'.
-
-`word-regexp'
- `-W' in `ptx'.
-
-`writable'
- `-T' in `who'.
-
-`zeros'
- `-z' in `gprof'.
-
-
-File: standards.info, Node: Documentation, Next: Releases, Prev: User Interfaces, Up: Top
-
-Documenting Programs
-********************
-
- Please use Texinfo for documenting GNU programs. See the Texinfo
-manual, either the hardcopy or the version in the GNU Emacs Info
-subsystem (`C-h i'). See existing GNU Texinfo files (e.g., those under
-the `man/' directory in the GNU Emacs distribution) for examples.
-
- The title page of the manual should state the version of the program
-which the manual applies to. The Top node of the manual should also
-contain this information. If the manual is changing more frequently
-than or independent of the program, also state a version number for the
-manual in both of these places.
-
- The manual should document all command-line arguments and all
-commands. It should give examples of their use. But don't organize
-the manual as a list of features. Instead, organize it by the concepts
-a user will have before reaching that point in the manual. Address the
-goals that a user will have in mind, and explain how to accomplish
-them. Don't use Unix man pages as a model for how to write GNU
-documentation; they are a bad example to follow.
-
- The manual should have a node named `PROGRAM Invocation' or
-`Invoking PROGRAM', where PROGRAM stands for the name of the program
-being described, as you would type it in the shell to run the program.
-This node (together with its subnodes, if any) should describe the
-program's command line arguments and how to run it (the sort of
-information people would look in a man page for). Start with an
-`@example' containing a template for all the options and arguments that
-the program uses.
-
- Alternatively, put a menu item in some menu whose item name fits one
-of the above patterns. This identifies the node which that item points
-to as the node for this purpose, regardless of the node's actual name.
-
- There will be automatic features for specifying a program name and
-quickly reading just this part of its manual.
-
- If one manual describes several programs, it should have such a node
-for each program described.
-
- In addition to its manual, the package should have a file named
-`NEWS' which contains a list of user-visible changes worth mentioning.
-In each new release, add items to the front of the file and identify
-the version they pertain to. Don't discard old items; leave them in
-the file after the newer items. This way, a user upgrading from any
-previous version can see what is new.
-
- If the `NEWS' file gets very long, move some of the older items into
-a file named `ONEWS' and put a note at the end referring the user to
-that file.
-
- Please do not use the term "pathname" that is used in Unix
-documentation; use "file name" (two words) instead. We use the term
-"path" only for search paths, which are lists of file names.
-
- It is ok to supply a man page for the program as well as a Texinfo
-manual if you wish to. But keep in mind that supporting a man page
-requires continual effort, each time the program is changed. Any time
-you spend on the man page is time taken away from more useful things you
-could contribute.
-
- Thus, even if a user volunteers to donate a man page, you may find
-this gift costly to accept. Unless you have time on your hands, it may
-be better to refuse the man page unless the same volunteer agrees to
-take full responsibility for maintaining it--so that you can wash your
-hands of it entirely. If the volunteer ceases to do the job, then
-don't feel obliged to pick it up yourself; it may be better to withdraw
-the man page until another volunteer offers to carry on with it.
-
- Alternatively, if you expect the discrepancies to be small enough
-that the man page remains useful, put a prominent note near the
-beginning of the man page explaining that you don't maintain it and
-that the Texinfo manual is more authoritative, and describing how to
-access the Texinfo documentation.
-
-
-File: standards.info, Node: Releases, Prev: Documentation, Up: Top
-
-Making Releases
-***************
-
- Package the distribution of Foo version 69.96 in a gzipped tar file
-named `foo-69.96.tar.gz'. It should unpack into a subdirectory named
-`foo-69.96'.
-
- Building and installing the program should never modify any of the
-files contained in the distribution. This means that all the files
-that form part of the program in any way must be classified into "source
-files" and "non-source files". Source files are written by humans and
-never changed automatically; non-source files are produced from source
-files by programs under the control of the Makefile.
-
- Naturally, all the source files must be in the distribution. It is
-okay to include non-source files in the distribution, provided they are
-up-to-date and machine-independent, so that building the distribution
-normally will never modify them. We commonly include non-source files
-produced by Bison, Lex, TeX, and Makeinfo; this helps avoid unnecessary
-dependencies between our distributions, so that users can install
-whichever packages they want to install.
-
- Non-source files that might actually be modified by building and
-installing the program should *never* be included in the distribution.
-So if you do distribute non-source files, always make sure they are up
-to date when you make a new distribution.
-
- Make sure that the directory into which the distribution unpacks (as
-well as any subdirectories) are all world-writable (octal mode 777).
-This is so that old versions of `tar' which preserve the ownership and
-permissions of the files from the tar archive will be able to extract
-all the files even if the user is unprivileged.
-
- Make sure that all the files in the distribution are world-readable.
-
- Make sure that no file name in the distribution is more than 14
-characters long. Likewise, no file created by building the program
-should have a name longer than 14 characters. The reason for this is
-that some systems adhere to a foolish interpretation of the POSIX
-standard, and refuse to open a longer name, rather than truncating as
-they did in the past.
-
- Don't include any symbolic links in the distribution itself. If the
-tar file contains symbolic links, then people cannot even unpack it on
-systems that don't support symbolic links. Also, don't use multiple
-names for one file in different directories, because certain file
-systems cannot handle this and that prevents unpacking the distribution.
-
- Try to make sure that all the file names will be unique on MS-DOG. A
-name on MS-DOG consists of up to 8 characters, optionally followed by a
-period and up to three characters. MS-DOG will truncate extra
-characters both before and after the period. Thus, `foobarhacker.c'
-and `foobarhacker.o' are not ambiguous; they are truncated to
-`foobarha.c' and `foobarha.o', which are distinct.
-
- Include in your distribution a copy of the `texinfo.tex' you used to
-test print any `*.texinfo' files.
-
- Likewise, if your program uses small GNU software packages like
-regex, getopt, obstack, or termcap, include them in the distribution
-file. Leaving them out would make the distribution file a little
-smaller at the expense of possible inconvenience to a user who doesn't
-know what other files to get.
-
-
diff --git a/gnu/usr.bin/binutils/gas/config/te-delta88.h b/gnu/usr.bin/binutils/gas/config/te-delta88.h
deleted file mode 100644
index adcd6b7f7b6..00000000000
--- a/gnu/usr.bin/binutils/gas/config/te-delta88.h
+++ /dev/null
@@ -1,13 +0,0 @@
-/* This file is te-delta88.h. */
-
-#define TE_DELTA88 1
-
-#define COFF_NOLOAD_PROBLEM 1
-
-/* Added these, because if we don't know what we're targetting we may
- need an assembler version of libgcc, and that will use local
- labels. */
-#define LOCAL_LABELS_DOLLAR 1
-#define LOCAL_LABELS_FB 1
-
-#include "obj-format.h"
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info b/gnu/usr.bin/binutils/gas/doc/as.info
deleted file mode 100644
index 5c763a10d26..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info
+++ /dev/null
@@ -1,262 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-Indirect:
-as.info-1: 872
-as.info-2: 49314
-as.info-3: 99231
-as.info-4: 145608
-as.info-5: 194806
-as.info-6: 226869
-
-Tag Table:
-(Indirect)
-Node: Top872
-Node: Overview1498
-Node: Manual9206
-Node: GNU Assembler10145
-Node: Object Formats11320
-Node: Command Line11767
-Node: Input Files12849
-Node: Object14753
-Node: Errors15700
-Node: Invoking16897
-Node: a18485
-Node: D19574
-Node: f19794
-Node: I20297
-Node: K20836
-Node: L21135
-Node: M21961
-Node: o26258
-Node: R26705
-Node: statistics27721
-Node: v28104
-Node: W28364
-Node: Z28946
-Node: Syntax29461
-Node: Preprocessing30051
-Node: Whitespace31611
-Node: Comments32001
-Node: Symbol Intro33818
-Node: Statements34501
-Node: Constants36747
-Node: Characters37373
-Node: Strings37866
-Node: Chars40029
-Node: Numbers40770
-Node: Integers41301
-Node: Bignums41944
-Node: Flonums42287
-Node: Sections43925
-Node: Secs Background44288
-Node: Ld Sections49314
-Node: As Sections51700
-Node: Sub-Sections52591
-Node: bss55589
-Node: Symbols56173
-Node: Labels56820
-Node: Setting Symbols57546
-Node: Symbol Names57912
-Node: Dot60868
-Node: Symbol Attributes61310
-Node: Symbol Value62042
-Node: Symbol Type63078
-Node: a.out Symbols63457
-Node: Symbol Desc63707
-Node: Symbol Other63989
-Node: COFF Symbols64145
-Node: SOM Symbols64774
-Node: Expressions65207
-Node: Empty Exprs65955
-Node: Integer Exprs66297
-Node: Arguments66687
-Node: Operators67784
-Node: Prefix Ops68110
-Node: Infix Ops68429
-Node: Pseudo Ops69921
-Node: Abort73495
-Node: ABORT73896
-Node: Align74158
-Node: App-File75629
-Node: Ascii76166
-Node: Asciz76471
-Node: Balign76711
-Node: Byte77355
-Node: Comm77588
-Node: Data78257
-Node: Def78567
-Node: Desc78935
-Node: Dim79429
-Node: Double79820
-Node: Eject80151
-Node: Else80319
-Node: Endef80608
-Node: Endif80930
-Node: Equ81181
-Node: Extern81485
-Node: File81737
-Node: Fill82388
-Node: Float83345
-Node: Global83681
-Node: hword84424
-Node: Ident84745
-Node: If85045
-Node: Include85899
-Node: Int86439
-Node: Irp86808
-Node: Irpc87602
-Node: Lcomm88421
-Node: Lflags89014
-Node: Line89201
-Node: Ln90224
-Node: List90368
-Node: Long90965
-Node: Macro91135
-Node: Nolist93522
-Node: Octa93940
-Node: Org94266
-Node: P2align95541
-Node: Psize96237
-Node: Quad96910
-Node: Rept97350
-Node: Sbttl97756
-Node: Scl98114
-Node: Section98610
-Node: Set99231
-Node: Short99784
-Node: Single100098
-Node: Size100435
-Node: Space100831
-Node: Stab101683
-Node: String103679
-Node: Tag104095
-Node: Text104603
-Node: Title104915
-Node: Type105287
-Node: Val105663
-Node: Word106018
-Node: Deprecated107851
-Node: Machine Dependencies108085
-Node: Vax-Dependent109551
-Node: Vax-Opts110059
-Node: VAX-float112349
-Node: VAX-directives112970
-Node: VAX-opcodes113819
-Node: VAX-branch114197
-Node: VAX-operands116692
-Node: VAX-no117444
-Node: AMD29K-Dependent117670
-Node: AMD29K Options118076
-Node: AMD29K Syntax118250
-Node: AMD29K-Macros118514
-Node: AMD29K-Chars118765
-Node: AMD29K-Regs119028
-Node: AMD29K Floating Point120292
-Node: AMD29K Directives120498
-Node: AMD29K Opcodes121906
-Node: H8/300-Dependent122242
-Node: H8/300 Options122648
-Node: H8/300 Syntax122829
-Node: H8/300-Chars123116
-Node: H8/300-Regs123400
-Node: H8/300-Addressing124304
-Node: H8/300 Floating Point125330
-Node: H8/300 Directives125646
-Node: H8/300 Opcodes126166
-Node: H8/500-Dependent134519
-Node: H8/500 Options134923
-Node: H8/500 Syntax135104
-Node: H8/500-Chars135391
-Node: H8/500-Regs135682
-Node: H8/500-Addressing136438
-Node: H8/500 Floating Point137055
-Node: H8/500 Directives137371
-Node: H8/500 Opcodes137690
-Node: HPPA-Dependent142803
-Node: HPPA Notes143223
-Node: HPPA Options143970
-Node: HPPA Syntax144154
-Node: HPPA Floating Point145413
-Node: HPPA Directives145608
-Node: HPPA Opcodes152199
-Node: SH-Dependent152447
-Node: SH Options152829
-Node: SH Syntax152994
-Node: SH-Chars153253
-Node: SH-Regs153532
-Node: SH-Addressing154131
-Node: SH Floating Point155025
-Node: SH Directives155321
-Node: SH Opcodes155526
-Node: i960-Dependent159773
-Node: Options-i960160163
-Node: Floating Point-i960164044
-Node: Directives-i960164301
-Node: Opcodes for i960166321
-Node: callj-i960166927
-Node: Compare-and-branch-i960167402
-Node: M68K-Dependent169291
-Node: M68K-Opts169746
-Node: M68K-Syntax173117
-Node: M68K-Moto-Syntax174945
-Node: M68K-Float177523
-Node: M68K-Directives178225
-Node: M68K-opcodes178820
-Node: M68K-Branch179032
-Node: M68K-Chars181847
-Node: Sparc-Dependent182202
-Node: Sparc-Opts182522
-Node: Sparc-Float183463
-Node: Sparc-Directives183645
-Node: i386-Dependent184863
-Node: i386-Options185509
-Node: i386-Syntax185653
-Node: i386-Opcodes187603
-Node: i386-Regs189722
-Node: i386-prefixes190863
-Node: i386-Memory192532
-Node: i386-jumps194806
-Node: i386-Float195876
-Node: i386-16bit197866
-Node: i386-Notes200258
-Node: Z8000-Dependent201099
-Node: Z8000 Options202060
-Node: Z8000 Syntax202235
-Node: Z8000-Chars202511
-Node: Z8000-Regs202729
-Node: Z8000-Addressing203501
-Node: Z8000 Directives204444
-Node: Z8000 Opcodes206042
-Node: MIPS-Dependent215978
-Node: MIPS Opts216652
-Node: MIPS Object219233
-Node: MIPS Stabs220788
-Node: MIPS ISA221499
-Node: Acknowledgements222393
-Node: Index226869
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info-1 b/gnu/usr.bin/binutils/gas/doc/as.info-1
deleted file mode 100644
index 5656a943d74..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info-1
+++ /dev/null
@@ -1,1338 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: as.info, Node: Top, Next: Overview, Prev: (DIR), Up: (DIR)
-
-Using as
-********
-
- This file is a user guide to the GNU assembler `as'.
-
-* Menu:
-
-* Overview:: Overview
-* Invoking:: Command-Line Options
-* Syntax:: Syntax
-* Sections:: Sections and Relocation
-* Symbols:: Symbols
-* Expressions:: Expressions
-* Pseudo Ops:: Assembler Directives
-* Machine Dependencies:: Machine Dependent Features
-* Acknowledgements:: Who Did What
-* Index:: Index
-
-
-File: as.info, Node: Overview, Next: Invoking, Prev: Top, Up: Top
-
-Overview
-********
-
- Here is a brief summary of how to invoke `as'. For details, *note
-Comand-Line Options: Invoking..
-
- as [ -a[dhlns][=file] ] [ -D ] [ --defsym SYM=VAL ]
- [ -f ] [ --help ] [ -I DIR ] [ -J ] [ -K ] [ -L ]
- [ -o OBJFILE ] [ -R ] [ --statistics ] [ -v ] [ -version ]
- [ --version ] [ -W ] [ -w ] [ -x ] [ -Z ]
- [ -Av6 | -Av7 | -Av8 | -Av9 | -Asparclite | -bump ]
- [ -ACA | -ACA_A | -ACB | -ACC | -AKA | -AKB | -AKC | -AMC ]
- [ -b ] [ -no-relax ]
- [ -l ] [ -m68000 | -m68010 | -m68020 | ... ]
- [ -nocpp ] [ -EL ] [ -EB ] [ -G NUM ] [ -mcpu=CPU ]
- [ -mips1 ] [ -mips2 ] [ -mips3 ] [ -m4650 ] [ -no-m4650 ]
- [ --trap ] [ --break ]
- [ --emulation=NAME ]
- [ -- | FILES ... ]
-
-`-a[dhlns]'
- Turn on listings, in any of a variety of ways:
-
- `-ad'
- omit debugging directives
-
- `-ah'
- include high-level source
-
- `-al'
- include assembly
-
- `-an'
- omit forms processing
-
- `-as'
- include symbols
-
- `=file'
- set the name of the listing file
-
- You may combine these options; for example, use `-aln' for assembly
- listing without forms processing. The `=file' option, if used,
- must be the last one. By itself, `-a' defaults to `-ahls'--that
- is, all listings turned on.
-
-`-D'
- Ignored. This option is accepted for script compatibility with
- calls to other assemblers.
-
-`--defsym SYM=VALUE'
- Define the symbol SYM to be VALUE before assembling the input file.
- vALUE must be an integer constant. As in C, a leading `0x'
- indicates a hexadecimal value, and a leading `0' indicates an
- octal value.
-
-`-f'
- "fast"--skip whitespace and comment preprocessing (assume source is
- compiler output).
-
-`--help'
- Print a summary of the command line options and exit.
-
-`-I DIR'
- Add directory DIR to the search list for `.include' directives.
-
-`-J'
- Don't warn about signed overflow.
-
-`-K'
- Issue warnings when difference tables altered for long
- displacements.
-
-`-L'
- Keep (in the symbol table) local symbols, starting with `L'.
-
-`-o OBJFILE'
- Name the object-file output from `as' OBJFILE.
-
-`-R'
- Fold the data section into the text section.
-
-`--statistics'
- Print the maximum space (in bytes) and total time (in seconds)
- used by assembly.
-
-`-v'
-`-version'
- Print the `as' version.
-
-`--version'
- Print the `as' version and exit.
-
-`-W'
- Suppress warning messages.
-
-`-w'
- Ignored.
-
-`-x'
- Ignored.
-
-`-Z'
- Generate an object file even after errors.
-
-`-- | FILES ...'
- Standard input, or source files to assemble.
-
- The following options are available when as is configured for the
-Intel 80960 processor.
-
-`-ACA | -ACA_A | -ACB | -ACC | -AKA | -AKB | -AKC | -AMC'
- Specify which variant of the 960 architecture is the target.
-
-`-b'
- Add code to collect statistics about branches taken.
-
-`-no-relax'
- Do not alter compare-and-branch instructions for long
- displacements; error if necessary.
-
- The following options are available when as is configured for the
-Motorola 68000 series.
-
-`-l'
- Shorten references to undefined symbols, to one word instead of
- two.
-
-`-m68000 | -m68008 | -m68010 | -m68020 | -m68030 | -m68040'
-`| -m68302 | -m68331 | -m68332 | -m68333 | -m68340 | -mcpu32'
- Specify what processor in the 68000 family is the target. The
- default is normally the 68020, but this can be changed at
- configuration time.
-
-`-m68881 | -m68882 | -mno-68881 | -mno-68882'
- The target machine does (or does not) have a floating-point
- coprocessor. The default is to assume a coprocessor for 68020,
- 68030, and cpu32. Although the basic 68000 is not compatible with
- the 68881, a combination of the two can be specified, since it's
- possible to do emulation of the coprocessor instructions with the
- main processor.
-
-`-m68851 | -mno-68851'
- The target machine does (or does not) have a memory-management
- unit coprocessor. The default is to assume an MMU for 68020 and
- up.
-
- The following options are available when `as' is configured for the
-SPARC architecture:
-
-`-Av6 | -Av7 | -Av8 | -Av9 | -Asparclite'
- Explicitly select a variant of the SPARC architecture.
-
-`-bump'
- Warn when the assembler switches to another architecture.
-
- The following options are available when as is configured for a MIPS
-processor.
-
-`-G NUM'
- This option sets the largest size of an object that can be
- referenced implicitly with the `gp' register. It is only accepted
- for targets that use ECOFF format, such as a DECstation running
- Ultrix. The default value is 8.
-
-`-EB'
- Generate "big endian" format output.
-
-`-EL'
- Generate "little endian" format output.
-
-`-mips1'
-`-mips2'
-`-mips3'
- Generate code for a particular MIPS Instruction Set Architecture
- level. `-mips1' corresponds to the R2000 and R3000 processors,
- `-mips2' to the R6000 processor, and `-mips3' to the R4000
- processor.
-
-`-m4650'
-`-no-m4650'
- Generate code for the MIPS R4650 chip. This tells the assembler
- to accept the `mad' and `madu' instruction, and to not schedule
- `nop' instructions around accesses to the `HI' and `LO' registers.
- `-no-m4650' turns off this option.
-
-`-mcpu=CPU'
- Generate code for a particular MIPS cpu. This has little effect
- on the assembler, but it is passed by `gcc'.
-
-`--emulation=NAME'
- This option causes `as' to emulated `as' configured for some other
- target, in all respects, including output format (choosing between
- ELF and ECOFF only), handling of pseudo-opcodes which may generate
- debugging information or store symbol table information, and
- default endianness. The available configuration names are:
- `mipsecoff', `mipself', `mipslecoff', `mipsbecoff', `mipslelf',
- `mipsbelf'. The first two do not alter the default endianness
- from that of the primary target for which the assembler was
- configured; the others change the default to little- or big-endian
- as indicated by the `b' or `l' in the name. Using `-EB' or `-EL'
- will override the endianness selection in any case.
-
- This option is currently supported only when the primary target
- `as' is configured for is a MIPS ELF or ECOFF target.
- Furthermore, the primary target or others specified with
- `--enable-targets=...' at configuration time must include support
- for the other format, if both are to be available. For example,
- the Irix 5 configuration includes support for both.
-
- Eventually, this option will support more configurations, with more
- fine-grained control over the assembler's behavior, and will be
- supported for more processors.
-
-`-nocpp'
- `as' ignores this option. It is accepted for compatibility with
- the native tools.
-
-`--trap'
-`--no-trap'
-`--break'
-`--no-break'
- Control how to deal with multiplication overflow and division by
- zero. `--trap' or `--no-break' (which are synonyms) take a trap
- exception (and only work for Instruction Set Architecture level 2
- and higher); `--break' or `--no-trap' (also synonyms, and the
- default) take a break exception.
-
-* Menu:
-
-* Manual:: Structure of this Manual
-* GNU Assembler:: as, the GNU Assembler
-* Object Formats:: Object File Formats
-* Command Line:: Command Line
-* Input Files:: Input Files
-* Object:: Output (Object) File
-* Errors:: Error and Warning Messages
-
-
-File: as.info, Node: Manual, Next: GNU Assembler, Up: Overview
-
-Structure of this Manual
-========================
-
- This manual is intended to describe what you need to know to use GNU
-`as'. We cover the syntax expected in source files, including notation
-for symbols, constants, and expressions; the directives that `as'
-understands; and of course how to invoke `as'.
-
- This manual also describes some of the machine-dependent features of
-various flavors of the assembler.
-
- On the other hand, this manual is *not* intended as an introduction
-to programming in assembly language--let alone programming in general!
-In a similar vein, we make no attempt to introduce the machine
-architecture; we do *not* describe the instruction set, standard
-mnemonics, registers or addressing modes that are standard to a
-particular architecture. You may want to consult the manufacturer's
-machine architecture manual for this information.
-
-
-File: as.info, Node: GNU Assembler, Next: Object Formats, Prev: Manual, Up: Overview
-
-as, the GNU Assembler
-=====================
-
- GNU `as' is really a family of assemblers. If you use (or have
-used) the GNU assembler on one architecture, you should find a fairly
-similar environment when you use it on another architecture. Each
-version has much in common with the others, including object file
-formats, most assembler directives (often called "pseudo-ops") and
-assembler syntax.
-
- `as' is primarily intended to assemble the output of the GNU C
-compiler `gcc' for use by the linker `ld'. Nevertheless, we've tried
-to make `as' assemble correctly everything that other assemblers for
-the same machine would assemble. Any exceptions are documented
-explicitly (*note Machine Dependencies::.). This doesn't mean `as'
-always uses the same syntax as another assembler for the same
-architecture; for example, we know of several incompatible versions of
-680x0 assembly language syntax.
-
- Unlike older assemblers, `as' is designed to assemble a source
-program in one pass of the source file. This has a subtle impact on the
-`.org' directive (*note `.org': Org.).
-
-
-File: as.info, Node: Object Formats, Next: Command Line, Prev: GNU Assembler, Up: Overview
-
-Object File Formats
-===================
-
- The GNU assembler can be configured to produce several alternative
-object file formats. For the most part, this does not affect how you
-write assembly language programs; but directives for debugging symbols
-are typically different in different file formats. *Note Symbol
-Attributes: Symbol Attributes.
-
-
-File: as.info, Node: Command Line, Next: Input Files, Prev: Object Formats, Up: Overview
-
-Command Line
-============
-
- After the program name `as', the command line may contain options
-and file names. Options may appear in any order, and may be before,
-after, or between file names. The order of file names is significant.
-
- `--' (two hyphens) by itself names the standard input file
-explicitly, as one of the files for `as' to assemble.
-
- Except for `--' any command line argument that begins with a hyphen
-(`-') is an option. Each option changes the behavior of `as'. No
-option changes the way another option works. An option is a `-'
-followed by one or more letters; the case of the letter is important.
-All options are optional.
-
- Some options expect exactly one file name to follow them. The file
-name may either immediately follow the option's letter (compatible with
-older assemblers) or it may be the next command argument (GNU
-standard). These two command lines are equivalent:
-
- as -o my-object-file.o mumble.s
- as -omy-object-file.o mumble.s
-
-
-File: as.info, Node: Input Files, Next: Object, Prev: Command Line, Up: Overview
-
-Input Files
-===========
-
- We use the phrase "source program", abbreviated "source", to
-describe the program input to one run of `as'. The program may be in
-one or more files; how the source is partitioned into files doesn't
-change the meaning of the source.
-
- The source program is a concatenation of the text in all the files,
-in the order specified.
-
- Each time you run `as' it assembles exactly one source program. The
-source program is made up of one or more files. (The standard input is
-also a file.)
-
- You give `as' a command line that has zero or more input file names.
-The input files are read (from left file name to right). A command
-line argument (in any position) that has no special meaning is taken to
-be an input file name.
-
- If you give `as' no file names it attempts to read one input file
-from the `as' standard input, which is normally your terminal. You may
-have to type ctl-D to tell `as' there is no more program to assemble.
-
- Use `--' if you need to explicitly name the standard input file in
-your command line.
-
- If the source is empty, `as' produces a small, empty object file.
-
-Filenames and Line-numbers
---------------------------
-
- There are two ways of locating a line in the input file (or files)
-and either may be used in reporting error messages. One way refers to
-a line number in a physical file; the other refers to a line number in a
-"logical" file. *Note Error and Warning Messages: Errors.
-
- "Physical files" are those files named in the command line given to
-`as'.
-
- "Logical files" are simply names declared explicitly by assembler
-directives; they bear no relation to physical files. Logical file names
-help error messages reflect the original source file, when `as' source
-is itself synthesized from other files. *Note `.app-file': App-File.
-
-
-File: as.info, Node: Object, Next: Errors, Prev: Input Files, Up: Overview
-
-Output (Object) File
-====================
-
- Every time you run `as' it produces an output file, which is your
-assembly language program translated into numbers. This file is the
-object file. Its default name is `a.out', or `b.out' when `as' is
-configured for the Intel 80960. You can give it another name by using
-the `-o' option. Conventionally, object file names end with `.o'. The
-default name is used for historical reasons: older assemblers were
-capable of assembling self-contained programs directly into a runnable
-program. (For some formats, this isn't currently possible, but it can
-be done for the `a.out' format.)
-
- The object file is meant for input to the linker `ld'. It contains
-assembled program code, information to help `ld' integrate the
-assembled program into a runnable file, and (optionally) symbolic
-information for the debugger.
-
-
-File: as.info, Node: Errors, Prev: Object, Up: Overview
-
-Error and Warning Messages
-==========================
-
- `as' may write warnings and error messages to the standard error
-file (usually your terminal). This should not happen when a compiler
-runs `as' automatically. Warnings report an assumption made so that
-`as' could keep assembling a flawed program; errors report a grave
-problem that stops the assembly.
-
- Warning messages have the format
-
- file_name:NNN:Warning Message Text
-
-(where NNN is a line number). If a logical file name has been given
-(*note `.app-file': App-File.) it is used for the filename, otherwise
-the name of the current input file is used. If a logical line number
-was given (*note `.line': Line.) then it is used to calculate the
-number printed, otherwise the actual line in the current source file is
-printed. The message text is intended to be self explanatory (in the
-grand Unix tradition).
-
- Error messages have the format
- file_name:NNN:FATAL:Error Message Text
- The file name and line number are derived as for warning messages.
-The actual message text may be rather less explanatory because many of
-them aren't supposed to happen.
-
-
-File: as.info, Node: Invoking, Next: Syntax, Prev: Overview, Up: Top
-
-Command-Line Options
-********************
-
- This chapter describes command-line options available in *all*
-versions of the GNU assembler; *note Machine Dependencies::., for
-options specific to particular machine architectures.
-
- If you are invoking `as' via the GNU C compiler (version 2), you can
-use the `-Wa' option to pass arguments through to the assembler. The
-assembler arguments must be separated from each other (and the `-Wa')
-by commas. For example:
-
- gcc -c -g -O -Wa,-alh,-L file.c
-
-emits a listing to standard output with high-level and assembly source.
-
- Usually you do not need to use this `-Wa' mechanism, since many
-compiler command-line options are automatically passed to the assembler
-by the compiler. (You can call the GNU compiler driver with the `-v'
-option to see precisely what options it passes to each compilation
-pass, including the assembler.)
-
-* Menu:
-
-* a:: -a[dhlns] enable listings
-* D:: -D for compatibility
-* f:: -f to work faster
-* I:: -I for .include search path
-
-* K:: -K for difference tables
-
-* L:: -L to retain local labels
-* M:: -M or -mri to assemble in MRI compatibility mode
-* o:: -o to name the object file
-* R:: -R to join data and text sections
-* statistics:: -statistics to see statistics about assembly
-* v:: -v to announce version
-* W:: -W to suppress warnings
-* Z:: -Z to make object file even after errors
-
-
-File: as.info, Node: a, Next: D, Up: Invoking
-
-Enable Listings: `-a[dhlns]'
-============================
-
- These options enable listing output from the assembler. By itself,
-`-a' requests high-level, assembly, and symbols listing. You can use
-other letters to select specific options for the list: `-ah' requests a
-high-level language listing, `-al' requests an output-program assembly
-listing, and `-as' requests a symbol table listing. High-level
-listings require that a compiler debugging option like `-g' be used,
-and that assembly listings (`-al') be requested also.
-
- Use the `-ad' option to omit debugging directives from the listing.
-
- Once you have specified one of these options, you can further control
-listing output and its appearance using the directives `.list',
-`.nolist', `.psize', `.eject', `.title', and `.sbttl'. The `-an'
-option turns off all forms processing. If you do not request listing
-output with one of the `-a' options, the listing-control directives
-have no effect.
-
- The letters after `-a' may be combined into one option, *e.g.*,
-`-aln'.
-
-
-File: as.info, Node: D, Next: f, Prev: a, Up: Invoking
-
-`-D'
-====
-
- This option has no effect whatsoever, but it is accepted to make it
-more likely that scripts written for other assemblers also work with
-`as'.
-
-
-File: as.info, Node: f, Next: I, Prev: D, Up: Invoking
-
-Work Faster: `-f'
-=================
-
- `-f' should only be used when assembling programs written by a
-(trusted) compiler. `-f' stops the assembler from doing whitespace and
-comment preprocessing on the input file(s) before assembling them.
-*Note Preprocessing: Preprocessing.
-
- *Warning:* if you use `-f' when the files actually need to be
- preprocessed (if they contain comments, for example), `as' does
- not work correctly.
-
-
-File: as.info, Node: I, Next: K, Prev: f, Up: Invoking
-
-`.include' search path: `-I' PATH
-=================================
-
- Use this option to add a PATH to the list of directories `as'
-searches for files specified in `.include' directives (*note
-`.include': Include.). You may use `-I' as many times as necessary to
-include a variety of paths. The current working directory is always
-searched first; after that, `as' searches any `-I' directories in the
-same order as they were specified (left to right) on the command line.
-
-
-File: as.info, Node: K, Next: L, Prev: I, Up: Invoking
-
-Difference Tables: `-K'
-=======================
-
- `as' sometimes alters the code emitted for directives of the form
-`.word SYM1-SYM2'; *note `.word': Word.. You can use the `-K' option
-if you want a warning issued when this is done.
-
-
-File: as.info, Node: L, Next: M, Prev: K, Up: Invoking
-
-Include Local Labels: `-L'
-==========================
-
- Labels beginning with `L' (upper case only) are called "local
-labels". *Note Symbol Names::. Normally you do not see such labels when
-debugging, because they are intended for the use of programs (like
-compilers) that compose assembler programs, not for your notice.
-Normally both `as' and `ld' discard such labels, so you do not normally
-debug with them.
-
- This option tells `as' to retain those `L...' symbols in the object
-file. Usually if you do this you also tell the linker `ld' to preserve
-symbols whose names begin with `L'.
-
- By default, a local label is any label beginning with `L', but each
-target is allowed to redefine the local label prefix. On the HPPA
-local labels begin with `L$'.
-
-
-File: as.info, Node: M, Next: o, Prev: L, Up: Invoking
-
-Assemble in MRI Compatibility Mode: `-M'
-========================================
-
- The `-M' or `--mri' option selects MRI compatibility mode. This
-changes the syntax and pseudo-op handling of `as' to make it compatible
-with the `ASM68K' or the `ASM960' (depending upon the configured
-target) assembler from Microtec Research. The exact nature of the MRI
-syntax will not be documented here; see the MRI manuals for more
-information. The purpose of this option is to permit assembling
-existing MRI assembler code using `as'.
-
- The MRI compatibility is not complete. Certain operations of the
-MRI assembler depend upon its object file format, and can not be
-supported using other object file formats. Supporting these would
-require enhancing each object file format individually. These are:
-
- * global symbols in common section
-
- The m68k MRI assembler supports common sections which are merged
- by the linker. Other object file formats do not support this.
- `as' handles common sections by treating them as a single common
- symbol. It permits local symbols to be defined within a common
- section, but it can not support global symbols, since it has no
- way to describe them.
-
- * complex relocations
-
- The MRI assemblers support relocations against a negated section
- address, and relocations which combine the start addresses of two
- or more sections. These are not support by other object file
- formats.
-
- * `END' pseudo-op specifying start address
-
- The MRI `END' pseudo-op permits the specification of a start
- address. This is not supported by other object file formats. The
- start address may instead be specified using the `-e' option to
- the linker, or in a linker script.
-
- * `IDNT', `.ident' and `NAME' pseudo-ops
-
- The MRI `IDNT', `.ident' and `NAME' pseudo-ops assign a module
- name to the output file. This is not supported by other object
- file formats.
-
- * `ORG' pseudo-op
-
- The m68k MRI `ORG' pseudo-op begins an absolute section at a given
- address. This differs from the usual `as' `.org' pseudo-op, which
- changes the location within the current section. Absolute
- sections are not supported by other object file formats. The
- address of a section may be assigned within a linker script.
-
- There are some other features of the MRI assembler which are not
-supported by `as', typically either because they are difficult or
-because they seem of little consequence. Some of these may be
-supported in future releases.
-
- * EBCDIC strings
-
- EBCDIC strings are not supported.
-
- * packed binary coded decimal
-
- Packed binary coded decimal is not supported. This means that the
- `DC.P' and `DCB.P' pseudo-ops are not supported.
-
- * `FEQU' pseudo-op
-
- The m68k `FEQU' pseudo-op is not supported.
-
- * `NOOBJ' pseudo-op
-
- The m68k `NOOBJ' pseudo-op is not supported.
-
- * `OPT' branch control options
-
- The m68k `OPT' branch control options--`B', `BRS', `BRB', `BRL',
- and `BRW'--are ignored. `as' automatically relaxes all branches,
- whether forward or backward, to an appropriate size, so these
- options serve no purpose.
-
- * `OPT' list control options
-
- The following m68k `OPT' list control options are ignored: `C',
- `CEX', `CL', `CRE', `E', `G', `I', `M', `MEX', `MC', `MD', `X'.
-
- * other `OPT' options
-
- The following m68k `OPT' options are ignored: `NEST', `O', `OLD',
- `OP', `P', `PCO', `PCR', `PCS', `R'.
-
- * `OPT' `D' option is default
-
- The m68k `OPT' `D' option is the default, unlike the MRI assembler.
- `OPT NOD' may be used to turn it off.
-
- * `XREF' pseudo-op.
-
- The m68k `XREF' pseudo-op is ignored.
-
- * `.debug' pseudo-op
-
- The i960 `.debug' pseudo-op is not supported.
-
- * `.extended' pseudo-op
-
- The i960 `.extended' pseudo-op is not supported.
-
- * `.list' pseudo-op.
-
- The various options of the i960 `.list' pseudo-op are not
- supported.
-
- * `.optimize' pseudo-op
-
- The i960 `.optimize' pseudo-op is not supported.
-
- * `.output' pseudo-op
-
- The i960 `.output' pseudo-op is not supported.
-
- * `.setreal' pseudo-op
-
- The i960 `.setreal' pseudo-op is not supported.
-
-
-File: as.info, Node: o, Next: R, Prev: M, Up: Invoking
-
-Name the Object File: `-o'
-==========================
-
- There is always one object file output when you run `as'. By
-default it has the name `a.out' (or `b.out', for Intel 960 targets
-only). You use this option (which takes exactly one filename) to give
-the object file a different name.
-
- Whatever the object file is called, `as' overwrites any existing
-file of the same name.
-
-
-File: as.info, Node: R, Next: statistics, Prev: o, Up: Invoking
-
-Join Data and Text Sections: `-R'
-=================================
-
- `-R' tells `as' to write the object file as if all data-section data
-lives in the text section. This is only done at the very last moment:
-your binary data are the same, but data section parts are relocated
-differently. The data section part of your object file is zero bytes
-long because all its bytes are appended to the text section. (*Note
-Sections and Relocation: Sections.)
-
- When you specify `-R' it would be possible to generate shorter
-address displacements (because we do not have to cross between text and
-data section). We refrain from doing this simply for compatibility with
-older versions of `as'. In future, `-R' may work this way.
-
- When `as' is configured for COFF output, this option is only useful
-if you use sections named `.text' and `.data'.
-
- `-R' is not supported for any of the HPPA targets. Using `-R'
-generates a warning from `as'.
-
-
-File: as.info, Node: statistics, Next: v, Prev: R, Up: Invoking
-
-Display Assembly Statistics: `--statistics'
-===========================================
-
- Use `--statistics' to display two statistics about the resources
-used by `as': the maximum amount of space allocated during the assembly
-(in bytes), and the total execution time taken for the assembly (in CPU
-seconds).
-
-
-File: as.info, Node: v, Next: W, Prev: statistics, Up: Invoking
-
-Announce Version: `-v'
-======================
-
- You can find out what version of as is running by including the
-option `-v' (which you can also spell as `-version') on the command
-line.
-
-
-File: as.info, Node: W, Next: Z, Prev: v, Up: Invoking
-
-Suppress Warnings: `-W'
-=======================
-
- `as' should never give a warning or error message when assembling
-compiler output. But programs written by people often cause `as' to
-give a warning that a particular assumption was made. All such
-warnings are directed to the standard error file. If you use this
-option, no warnings are issued. This option only affects the warning
-messages: it does not change any particular of how `as' assembles your
-file. Errors, which stop the assembly, are still reported.
-
-
-File: as.info, Node: Z, Prev: W, Up: Invoking
-
-Generate Object File in Spite of Errors: `-Z'
-=============================================
-
- After an error message, `as' normally produces no output. If for
-some reason you are interested in object file output even after `as'
-gives an error message on your program, use the `-Z' option. If there
-are any errors, `as' continues anyways, and writes an object file after
-a final warning message of the form `N errors, M warnings, generating
-bad object file.'
-
-
-File: as.info, Node: Syntax, Next: Sections, Prev: Invoking, Up: Top
-
-Syntax
-******
-
- This chapter describes the machine-independent syntax allowed in a
-source file. `as' syntax is similar to what many other assemblers use;
-it is inspired by the BSD 4.2 assembler, except that `as' does not
-assemble Vax bit-fields.
-
-* Menu:
-
-* Preprocessing:: Preprocessing
-* Whitespace:: Whitespace
-* Comments:: Comments
-* Symbol Intro:: Symbols
-* Statements:: Statements
-* Constants:: Constants
-
-
-File: as.info, Node: Preprocessing, Next: Whitespace, Up: Syntax
-
-Preprocessing
-=============
-
- The `as' internal preprocessor:
- * adjusts and removes extra whitespace. It leaves one space or tab
- before the keywords on a line, and turns any other whitespace on
- the line into a single space.
-
- * removes all comments, replacing them with a single space, or an
- appropriate number of newlines.
-
- * converts character constants into the appropriate numeric values.
-
- It does not do macro processing, include file handling, or anything
-else you may get from your C compiler's preprocessor. You can do
-include file processing with the `.include' directive (*note
-`.include': Include.). You can use the GNU C compiler driver to get
-other "CPP" style preprocessing, by giving the input file a `.S'
-suffix. *Note Options Controlling the Kind of Output:
-(gcc.info)Overall Options.
-
- Excess whitespace, comments, and character constants cannot be used
-in the portions of the input text that are not preprocessed.
-
- If the first line of an input file is `#NO_APP' or if you use the
-`-f' option, whitespace and comments are not removed from the input
-file. Within an input file, you can ask for whitespace and comment
-removal in specific portions of the by putting a line that says `#APP'
-before the text that may contain whitespace or comments, and putting a
-line that says `#NO_APP' after this text. This feature is mainly
-intend to support `asm' statements in compilers whose output is
-otherwise free of comments and whitespace.
-
-
-File: as.info, Node: Whitespace, Next: Comments, Prev: Preprocessing, Up: Syntax
-
-Whitespace
-==========
-
- "Whitespace" is one or more blanks or tabs, in any order.
-Whitespace is used to separate symbols, and to make programs neater for
-people to read. Unless within character constants (*note Character
-Constants: Characters.), any whitespace means the same as exactly one
-space.
-
-
-File: as.info, Node: Comments, Next: Symbol Intro, Prev: Whitespace, Up: Syntax
-
-Comments
-========
-
- There are two ways of rendering comments to `as'. In both cases the
-comment is equivalent to one space.
-
- Anything from `/*' through the next `*/' is a comment. This means
-you may not nest these comments.
-
- /*
- The only way to include a newline ('\n') in a comment
- is to use this sort of comment.
- */
-
- /* This sort of comment does not nest. */
-
- Anything from the "line comment" character to the next newline is
-considered a comment and is ignored. The line comment character is `#'
-on the Vax; `#' on the i960; `!' on the SPARC; `|' on the 680x0; `;'
-for the AMD 29K family; `;' for the H8/300 family; `!' for the H8/500
-family; `;' for the HPPA; `!' for the Hitachi SH; `!' for the Z8000;
-see *Note Machine Dependencies::.
-
- On some machines there are two different line comment characters.
-One character only begins a comment if it is the first non-whitespace
-character on a line, while the other always begins a comment.
-
- To be compatible with past assemblers, lines that begin with `#'
-have a special interpretation. Following the `#' should be an absolute
-expression (*note Expressions::.): the logical line number of the *next*
-line. Then a string (*note Strings: Strings.) is allowed: if present
-it is a new logical file name. The rest of the line, if any, should be
-whitespace.
-
- If the first non-whitespace characters on the line are not numeric,
-the line is ignored. (Just like a comment.)
-
- # This is an ordinary comment.
- # 42-6 "new_file_name" # New logical file name
- # This is logical line # 36.
- This feature is deprecated, and may disappear from future versions
-of `as'.
-
-
-File: as.info, Node: Symbol Intro, Next: Statements, Prev: Comments, Up: Syntax
-
-Symbols
-=======
-
- A "symbol" is one or more characters chosen from the set of all
-letters (both upper and lower case), digits and the three characters
-`_.$'. On most machines, you can also use `$' in symbol names;
-exceptions are noted in *Note Machine Dependencies::. No symbol may
-begin with a digit. Case is significant. There is no length limit:
-all characters are significant. Symbols are delimited by characters
-not in that set, or by the beginning of a file (since the source
-program must end with a newline, the end of a file is not a possible
-symbol delimiter). *Note Symbols::.
-
-
-File: as.info, Node: Statements, Next: Constants, Prev: Symbol Intro, Up: Syntax
-
-Statements
-==========
-
- A "statement" ends at a newline character (`\n') or line separator
-character. (The line separator is usually `;', unless this conflicts
-with the comment character; *note Machine Dependencies::..) The
-newline or separator character is considered part of the preceding
-statement. Newlines and separators within character constants are an
-exception: they do not end statements.
-
- It is an error to end any statement with end-of-file: the last
-character of any input file should be a newline.
-
- You may write a statement on more than one line if you put a
-backslash (`\') immediately in front of any newlines within the
-statement. When `as' reads a backslashed newline both characters are
-ignored. You can even put backslashed newlines in the middle of symbol
-names without changing the meaning of your source program.
-
- An empty statement is allowed, and may include whitespace. It is
-ignored.
-
- A statement begins with zero or more labels, optionally followed by a
-key symbol which determines what kind of statement it is. The key
-symbol determines the syntax of the rest of the statement. If the
-symbol begins with a dot `.' then the statement is an assembler
-directive: typically valid for any computer. If the symbol begins with
-a letter the statement is an assembly language "instruction": it
-assembles into a machine language instruction. Different versions of
-`as' for different computers recognize different instructions. In
-fact, the same symbol may represent a different instruction in a
-different computer's assembly language.
-
- A label is a symbol immediately followed by a colon (`:').
-Whitespace before a label or after a colon is permitted, but you may not
-have whitespace between a label's symbol and its colon. *Note Labels::.
-
- For HPPA targets, labels need not be immediately followed by a
-colon, but the definition of a label must begin in column zero. This
-also implies that only one label may be defined on each line.
-
- label: .directive followed by something
- another_label: # This is an empty statement.
- instruction operand_1, operand_2, ...
-
-
-File: as.info, Node: Constants, Prev: Statements, Up: Syntax
-
-Constants
-=========
-
- A constant is a number, written so that its value is known by
-inspection, without knowing any context. Like this:
- .byte 74, 0112, 092, 0x4A, 0X4a, 'J, '\J # All the same value.
- .ascii "Ring the bell\7" # A string constant.
- .octa 0x123456789abcdef0123456789ABCDEF0 # A bignum.
- .float 0f-314159265358979323846264338327\
- 95028841971.693993751E-40 # - pi, a flonum.
-
-* Menu:
-
-* Characters:: Character Constants
-* Numbers:: Number Constants
-
-
-File: as.info, Node: Characters, Next: Numbers, Up: Constants
-
-Character Constants
--------------------
-
- There are two kinds of character constants. A "character" stands
-for one character in one byte and its value may be used in numeric
-expressions. String constants (properly called string *literals*) are
-potentially many bytes and their values may not be used in arithmetic
-expressions.
-
-* Menu:
-
-* Strings:: Strings
-* Chars:: Characters
-
-
-File: as.info, Node: Strings, Next: Chars, Up: Characters
-
-Strings
-.......
-
- A "string" is written between double-quotes. It may contain
-double-quotes or null characters. The way to get special characters
-into a string is to "escape" these characters: precede them with a
-backslash `\' character. For example `\\' represents one backslash:
-the first `\' is an escape which tells `as' to interpret the second
-character literally as a backslash (which prevents `as' from
-recognizing the second `\' as an escape character). The complete list
-of escapes follows.
-
-`\b'
- Mnemonic for backspace; for ASCII this is octal code 010.
-
-`\f'
- Mnemonic for FormFeed; for ASCII this is octal code 014.
-
-`\n'
- Mnemonic for newline; for ASCII this is octal code 012.
-
-`\r'
- Mnemonic for carriage-Return; for ASCII this is octal code 015.
-
-`\t'
- Mnemonic for horizontal Tab; for ASCII this is octal code 011.
-
-`\ DIGIT DIGIT DIGIT'
- An octal character code. The numeric code is 3 octal digits. For
- compatibility with other Unix systems, 8 and 9 are accepted as
- digits: for example, `\008' has the value 010, and `\009' the
- value 011.
-
-`\`x' HEX-DIGIT HEX-DIGIT'
- A hex character code. The numeric code is 2 hexadecimal digits.
- Either upper or lower case `x' works.
-
-`\\'
- Represents one `\' character.
-
-`\"'
- Represents one `"' character. Needed in strings to represent this
- character, because an unescaped `"' would end the string.
-
-`\ ANYTHING-ELSE'
- Any other character when escaped by `\' gives a warning, but
- assembles as if the `\' was not present. The idea is that if you
- used an escape sequence you clearly didn't want the literal
- interpretation of the following character. However `as' has no
- other interpretation, so `as' knows it is giving you the wrong
- code and warns you of the fact.
-
- Which characters are escapable, and what those escapes represent,
-varies widely among assemblers. The current set is what we think the
-BSD 4.2 assembler recognizes, and is a subset of what most C compilers
-recognize. If you are in doubt, do not use an escape sequence.
-
-
-File: as.info, Node: Chars, Prev: Strings, Up: Characters
-
-Characters
-..........
-
- A single character may be written as a single quote immediately
-followed by that character. The same escapes apply to characters as to
-strings. So if you want to write the character backslash, you must
-write `'\\' where the first `\' escapes the second `\'. As you can
-see, the quote is an acute accent, not a grave accent. A newline
-immediately following an acute accent is taken as a literal character
-and does not count as the end of a statement. The value of a character
-constant in a numeric expression is the machine's byte-wide code for
-that character. `as' assumes your character code is ASCII: `'A' means
-65, `'B' means 66, and so on.
-
-
-File: as.info, Node: Numbers, Prev: Characters, Up: Constants
-
-Number Constants
-----------------
-
- `as' distinguishes three kinds of numbers according to how they are
-stored in the target machine. *Integers* are numbers that would fit
-into an `int' in the C language. *Bignums* are integers, but they are
-stored in more than 32 bits. *Flonums* are floating point numbers,
-described below.
-
-* Menu:
-
-* Integers:: Integers
-* Bignums:: Bignums
-* Flonums:: Flonums
-
-
-File: as.info, Node: Integers, Next: Bignums, Up: Numbers
-
-Integers
-........
-
- A binary integer is `0b' or `0B' followed by zero or more of the
-binary digits `01'.
-
- An octal integer is `0' followed by zero or more of the octal digits
-(`01234567').
-
- A decimal integer starts with a non-zero digit followed by zero or
-more digits (`0123456789').
-
- A hexadecimal integer is `0x' or `0X' followed by one or more
-hexadecimal digits chosen from `0123456789abcdefABCDEF'.
-
- Integers have the usual values. To denote a negative integer, use
-the prefix operator `-' discussed under expressions (*note Prefix
-Operators: Prefix Ops.).
-
-
-File: as.info, Node: Bignums, Next: Flonums, Prev: Integers, Up: Numbers
-
-Bignums
-.......
-
- A "bignum" has the same syntax and semantics as an integer except
-that the number (or its negative) takes more than 32 bits to represent
-in binary. The distinction is made because in some places integers are
-permitted while bignums are not.
-
-
-File: as.info, Node: Flonums, Prev: Bignums, Up: Numbers
-
-Flonums
-.......
-
- A "flonum" represents a floating point number. The translation is
-indirect: a decimal floating point number from the text is converted by
-`as' to a generic binary floating point number of more than sufficient
-precision. This generic floating point number is converted to a
-particular computer's floating point format (or formats) by a portion
-of `as' specialized to that computer.
-
- A flonum is written by writing (in order)
- * The digit `0'. (`0' is optional on the HPPA.)
-
- * A letter, to tell `as' the rest of the number is a flonum. `e' is
- recommended. Case is not important.
-
- On the H8/300, H8/500, Hitachi SH, and AMD 29K architectures, the
- letter must be one of the letters `DFPRSX' (in upper or lower
- case).
-
- On the Intel 960 architecture, the letter must be one of the
- letters `DFT' (in upper or lower case).
-
- On the HPPA architecture, the letter must be `E' (upper case only).
-
- * An optional sign: either `+' or `-'.
-
- * An optional "integer part": zero or more decimal digits.
-
- * An optional "fractional part": `.' followed by zero or more
- decimal digits.
-
- * An optional exponent, consisting of:
-
- * An `E' or `e'.
-
- * Optional sign: either `+' or `-'.
-
- * One or more decimal digits.
-
- At least one of the integer part or the fractional part must be
-present. The floating point number has the usual base-10 value.
-
- `as' does all processing using integers. Flonums are computed
-independently of any floating point hardware in the computer running
-`as'.
-
-
-File: as.info, Node: Sections, Next: Symbols, Prev: Syntax, Up: Top
-
-Sections and Relocation
-***********************
-
-* Menu:
-
-* Secs Background:: Background
-* Ld Sections:: ld Sections
-* As Sections:: as Internal Sections
-* Sub-Sections:: Sub-Sections
-* bss:: bss Section
-
-
-File: as.info, Node: Secs Background, Next: Ld Sections, Up: Sections
-
-Background
-==========
-
- Roughly, a section is a range of addresses, with no gaps; all data
-"in" those addresses is treated the same for some particular purpose.
-For example there may be a "read only" section.
-
- The linker `ld' reads many object files (partial programs) and
-combines their contents to form a runnable program. When `as' emits an
-object file, the partial program is assumed to start at address 0.
-`ld' assigns the final addresses for the partial program, so that
-different partial programs do not overlap. This is actually an
-oversimplification, but it suffices to explain how `as' uses sections.
-
- `ld' moves blocks of bytes of your program to their run-time
-addresses. These blocks slide to their run-time addresses as rigid
-units; their length does not change and neither does the order of bytes
-within them. Such a rigid unit is called a *section*. Assigning
-run-time addresses to sections is called "relocation". It includes the
-task of adjusting mentions of object-file addresses so they refer to
-the proper run-time addresses. For the H8/300 and H8/500, and for the
-Hitachi SH, `as' pads sections if needed to ensure they end on a word
-(sixteen bit) boundary.
-
- An object file written by `as' has at least three sections, any of
-which may be empty. These are named "text", "data" and "bss" sections.
-
- When it generates COFF output, `as' can also generate whatever other
-named sections you specify using the `.section' directive (*note
-`.section': Section.). If you do not use any directives that place
-output in the `.text' or `.data' sections, these sections still exist,
-but are empty.
-
- When `as' generates SOM or ELF output for the HPPA, `as' can also
-generate whatever other named sections you specify using the `.space'
-and `.subspace' directives. See `HP9000 Series 800 Assembly Language
-Reference Manual' (HP 92432-90001) for details on the `.space' and
-`.subspace' assembler directives.
-
- Additionally, `as' uses different names for the standard text, data,
-and bss sections when generating SOM output. Program text is placed
-into the `$CODE$' section, data into `$DATA$', and BSS into `$BSS$'.
-
- Within the object file, the text section starts at address `0', the
-data section follows, and the bss section follows the data section.
-
- When generating either SOM or ELF output files on the HPPA, the text
-section starts at address `0', the data section at address `0x4000000',
-and the bss section follows the data section.
-
- To let `ld' know which data changes when the sections are relocated,
-and how to change that data, `as' also writes to the object file
-details of the relocation needed. To perform relocation `ld' must
-know, each time an address in the object file is mentioned:
- * Where in the object file is the beginning of this reference to an
- address?
-
- * How long (in bytes) is this reference?
-
- * Which section does the address refer to? What is the numeric
- value of
- (ADDRESS) - (START-ADDRESS OF SECTION)?
-
- * Is the reference to an address "Program-Counter relative"?
-
- In fact, every address `as' ever uses is expressed as
- (SECTION) + (OFFSET INTO SECTION)
-
-Further, most expressions `as' computes have this section-relative
-nature. (For some object formats, such as SOM for the HPPA, some
-expressions are symbol-relative instead.)
-
- In this manual we use the notation {SECNAME N} to mean "offset N
-into section SECNAME."
-
- Apart from text, data and bss sections you need to know about the
-"absolute" section. When `ld' mixes partial programs, addresses in the
-absolute section remain unchanged. For example, address `{absolute 0}'
-is "relocated" to run-time address 0 by `ld'. Although the linker
-never arranges two partial programs' data sections with overlapping
-addresses after linking, *by definition* their absolute sections must
-overlap. Address `{absolute 239}' in one part of a program is always
-the same address when the program is running as address `{absolute
-239}' in any other part of the program.
-
- The idea of sections is extended to the "undefined" section. Any
-address whose section is unknown at assembly time is by definition
-rendered {undefined U}--where U is filled in later. Since numbers are
-always defined, the only way to generate an undefined address is to
-mention an undefined symbol. A reference to a named common block would
-be such a symbol: its value is unknown at assembly time so it has
-section *undefined*.
-
- By analogy the word *section* is used to describe groups of sections
-in the linked program. `ld' puts all partial programs' text sections
-in contiguous addresses in the linked program. It is customary to
-refer to the *text section* of a program, meaning all the addresses of
-all partial programs' text sections. Likewise for data and bss
-sections.
-
- Some sections are manipulated by `ld'; others are invented for use
-of `as' and have no meaning except during assembly.
-
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info-2 b/gnu/usr.bin/binutils/gas/doc/as.info-2
deleted file mode 100644
index a29e5991ee2..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info-2
+++ /dev/null
@@ -1,1464 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: as.info, Node: Ld Sections, Next: As Sections, Prev: Secs Background, Up: Sections
-
-ld Sections
-===========
-
- `ld' deals with just four kinds of sections, summarized below.
-
-*named sections*
-*text section*
-*data section*
- These sections hold your program. `as' and `ld' treat them as
- separate but equal sections. Anything you can say of one section
- is true another. When the program is running, however, it is
- customary for the text section to be unalterable. The text
- section is often shared among processes: it contains instructions,
- constants and the like. The data section of a running program is
- usually alterable: for example, C variables would be stored in the
- data section.
-
-*bss section*
- This section contains zeroed bytes when your program begins
- running. It is used to hold unitialized variables or common
- storage. The length of each partial program's bss section is
- important, but because it starts out containing zeroed bytes there
- is no need to store explicit zero bytes in the object file. The
- bss section was invented to eliminate those explicit zeros from
- object files.
-
-*absolute section*
- Address 0 of this section is always "relocated" to runtime address
- 0. This is useful if you want to refer to an address that `ld'
- must not change when relocating. In this sense we speak of
- absolute addresses being "unrelocatable": they do not change
- during relocation.
-
-*undefined section*
- This "section" is a catch-all for address references to objects
- not in the preceding sections.
-
- An idealized example of three relocatable sections follows. The
-example uses the traditional section names `.text' and `.data'. Memory
-addresses are on the horizontal axis.
-
- +-----+----+--+
- partial program # 1: |ttttt|dddd|00|
- +-----+----+--+
-
- text data bss
- seg. seg. seg.
-
- +---+---+---+
- partial program # 2: |TTT|DDD|000|
- +---+---+---+
-
- +--+---+-----+--+----+---+-----+~~
- linked program: | |TTT|ttttt| |dddd|DDD|00000|
- +--+---+-----+--+----+---+-----+~~
-
- addresses: 0 ...
-
-
-File: as.info, Node: As Sections, Next: Sub-Sections, Prev: Ld Sections, Up: Sections
-
-as Internal Sections
-====================
-
- These sections are meant only for the internal use of `as'. They
-have no meaning at run-time. You do not really need to know about these
-sections for most purposes; but they can be mentioned in `as' warning
-messages, so it might be helpful to have an idea of their meanings to
-`as'. These sections are used to permit the value of every expression
-in your assembly language program to be a section-relative address.
-
-ASSEMBLER-INTERNAL-LOGIC-ERROR!
- An internal assembler logic error has been found. This means
- there is a bug in the assembler.
-
-expr section
- The assembler stores complex expression internally as combinations
- of symbols. When it needs to represent an expression as a symbol,
- it puts it in the expr section.
-
-
-File: as.info, Node: Sub-Sections, Next: bss, Prev: As Sections, Up: Sections
-
-Sub-Sections
-============
-
- Assembled bytes conventionally fall into two sections: text and data.
-You may have separate groups of data in named sections that you want to
-end up near to each other in the object file, even though they are not
-contiguous in the assembler source. `as' allows you to use
-"subsections" for this purpose. Within each section, there can be
-numbered subsections with values from 0 to 8192. Objects assembled
-into the same subsection go into the object file together with other
-objects in the same subsection. For example, a compiler might want to
-store constants in the text section, but might not want to have them
-interspersed with the program being assembled. In this case, the
-compiler could issue a `.text 0' before each section of code being
-output, and a `.text 1' before each group of constants being output.
-
- Subsections are optional. If you do not use subsections, everything
-goes in subsection number zero.
-
- Each subsection is zero-padded up to a multiple of four bytes.
-(Subsections may be padded a different amount on different flavors of
-`as'.)
-
- Subsections appear in your object file in numeric order, lowest
-numbered to highest. (All this to be compatible with other people's
-assemblers.) The object file contains no representation of subsections;
-`ld' and other programs that manipulate object files see no trace of
-them. They just see all your text subsections as a text section, and
-all your data subsections as a data section.
-
- To specify which subsection you want subsequent statements assembled
-into, use a numeric argument to specify it, in a `.text EXPRESSION' or
-a `.data EXPRESSION' statement. When generating COFF output, you can
-also use an extra subsection argument with arbitrary named sections:
-`.section NAME, EXPRESSION'. EXPRESSION should be an absolute
-expression. (*Note Expressions::.) If you just say `.text' then
-`.text 0' is assumed. Likewise `.data' means `.data 0'. Assembly
-begins in `text 0'. For instance:
- .text 0 # The default subsection is text 0 anyway.
- .ascii "This lives in the first text subsection. *"
- .text 1
- .ascii "But this lives in the second text subsection."
- .data 0
- .ascii "This lives in the data section,"
- .ascii "in the first data subsection."
- .text 0
- .ascii "This lives in the first text section,"
- .ascii "immediately following the asterisk (*)."
-
- Each section has a "location counter" incremented by one for every
-byte assembled into that section. Because subsections are merely a
-convenience restricted to `as' there is no concept of a subsection
-location counter. There is no way to directly manipulate a location
-counter--but the `.align' directive changes it, and any label
-definition captures its current value. The location counter of the
-section where statements are being assembled is said to be the "active"
-location counter.
-
-
-File: as.info, Node: bss, Prev: Sub-Sections, Up: Sections
-
-bss Section
-===========
-
- The bss section is used for local common variable storage. You may
-allocate address space in the bss section, but you may not dictate data
-to load into it before your program executes. When your program starts
-running, all the contents of the bss section are zeroed bytes.
-
- Addresses in the bss section are allocated with special directives;
-you may not assemble anything directly into the bss section. Hence
-there are no bss subsections. *Note `.comm': Comm, *note `.lcomm':
-Lcomm..
-
-
-File: as.info, Node: Symbols, Next: Expressions, Prev: Sections, Up: Top
-
-Symbols
-*******
-
- Symbols are a central concept: the programmer uses symbols to name
-things, the linker uses symbols to link, and the debugger uses symbols
-to debug.
-
- *Warning:* `as' does not place symbols in the object file in the
- same order they were declared. This may break some debuggers.
-
-* Menu:
-
-* Labels:: Labels
-* Setting Symbols:: Giving Symbols Other Values
-* Symbol Names:: Symbol Names
-* Dot:: The Special Dot Symbol
-* Symbol Attributes:: Symbol Attributes
-
-
-File: as.info, Node: Labels, Next: Setting Symbols, Up: Symbols
-
-Labels
-======
-
- A "label" is written as a symbol immediately followed by a colon
-`:'. The symbol then represents the current value of the active
-location counter, and is, for example, a suitable instruction operand.
-You are warned if you use the same symbol to represent two different
-locations: the first definition overrides any other definitions.
-
- On the HPPA, the usual form for a label need not be immediately
-followed by a colon, but instead must start in column zero. Only one
-label may be defined on a single line. To work around this, the HPPA
-version of `as' also provides a special directive `.label' for defining
-labels more flexibly.
-
-
-File: as.info, Node: Setting Symbols, Next: Symbol Names, Prev: Labels, Up: Symbols
-
-Giving Symbols Other Values
-===========================
-
- A symbol can be given an arbitrary value by writing a symbol,
-followed by an equals sign `=', followed by an expression (*note
-Expressions::.). This is equivalent to using the `.set' directive.
-*Note `.set': Set.
-
-
-File: as.info, Node: Symbol Names, Next: Dot, Prev: Setting Symbols, Up: Symbols
-
-Symbol Names
-============
-
- Symbol names begin with a letter or with one of `._'. On most
-machines, you can also use `$' in symbol names; exceptions are noted in
-*Note Machine Dependencies::. That character may be followed by any
-string of digits, letters, dollar signs (unless otherwise noted in
-*Note Machine Dependencies::), and underscores. For the AMD 29K
-family, `?' is also allowed in the body of a symbol name, though not at
-its beginning.
-
- Case of letters is significant: `foo' is a different symbol name
-than `Foo'.
-
- Each symbol has exactly one name. Each name in an assembly language
-program refers to exactly one symbol. You may use that symbol name any
-number of times in a program.
-
-Local Symbol Names
-------------------
-
- Local symbols help compilers and programmers use names temporarily.
-There are ten local symbol names, which are re-used throughout the
-program. You may refer to them using the names `0' `1' ... `9'. To
-define a local symbol, write a label of the form `N:' (where N
-represents any digit). To refer to the most recent previous definition
-of that symbol write `Nb', using the same digit as when you defined the
-label. To refer to the next definition of a local label, write
-`Nf'--where N gives you a choice of 10 forward references. The `b'
-stands for "backwards" and the `f' stands for "forwards".
-
- Local symbols are not emitted by the current GNU C compiler.
-
- There is no restriction on how you can use these labels, but
-remember that at any point in the assembly you can refer to at most 10
-prior local labels and to at most 10 forward local labels.
-
- Local symbol names are only a notation device. They are immediately
-transformed into more conventional symbol names before the assembler
-uses them. The symbol names stored in the symbol table, appearing in
-error messages and optionally emitted to the object file have these
-parts:
-
-`L'
- All local labels begin with `L'. Normally both `as' and `ld'
- forget symbols that start with `L'. These labels are used for
- symbols you are never intended to see. If you use the `-L' option
- then `as' retains these symbols in the object file. If you also
- instruct `ld' to retain these symbols, you may use them in
- debugging.
-
-`DIGIT'
- If the label is written `0:' then the digit is `0'. If the label
- is written `1:' then the digit is `1'. And so on up through `9:'.
-
-A'
- This unusual character is included so you do not accidentally
- invent a symbol of the same name. The character has ASCII value
- `\001'.
-
-`*ordinal number*'
- This is a serial number to keep the labels distinct. The first
- `0:' gets the number `1'; The 15th `0:' gets the number `15';
- *etc.*. Likewise for the other labels `1:' through `9:'.
-
- For instance, the first `1:' is named `LA1', the 44th `3:' is named
-`LA44'.
-
-
-File: as.info, Node: Dot, Next: Symbol Attributes, Prev: Symbol Names, Up: Symbols
-
-The Special Dot Symbol
-======================
-
- The special symbol `.' refers to the current address that `as' is
-assembling into. Thus, the expression `melvin: .long .' defines
-`melvin' to contain its own address. Assigning a value to `.' is
-treated the same as a `.org' directive. Thus, the expression `.=.+4'
-is the same as saying `.space 4'.
-
-
-File: as.info, Node: Symbol Attributes, Prev: Dot, Up: Symbols
-
-Symbol Attributes
-=================
-
- Every symbol has, as well as its name, the attributes "Value" and
-"Type". Depending on output format, symbols can also have auxiliary
-attributes.
-
- If you use a symbol without defining it, `as' assumes zero for all
-these attributes, and probably won't warn you. This makes the symbol
-an externally defined symbol, which is generally what you would want.
-
-* Menu:
-
-* Symbol Value:: Value
-* Symbol Type:: Type
-
-
-* a.out Symbols:: Symbol Attributes: `a.out'
-
-* COFF Symbols:: Symbol Attributes for COFF
-
-* SOM Symbols:: Symbol Attributes for SOM
-
-
-File: as.info, Node: Symbol Value, Next: Symbol Type, Up: Symbol Attributes
-
-Value
------
-
- The value of a symbol is (usually) 32 bits. For a symbol which
-labels a location in the text, data, bss or absolute sections the value
-is the number of addresses from the start of that section to the label.
-Naturally for text, data and bss sections the value of a symbol changes
-as `ld' changes section base addresses during linking. Absolute
-symbols' values do not change during linking: that is why they are
-called absolute.
-
- The value of an undefined symbol is treated in a special way. If it
-is 0 then the symbol is not defined in this assembler source file, and
-`ld' tries to determine its value from other files linked into the same
-program. You make this kind of symbol simply by mentioning a symbol
-name without defining it. A non-zero value represents a `.comm' common
-declaration. The value is how much common storage to reserve, in bytes
-(addresses). The symbol refers to the first address of the allocated
-storage.
-
-
-File: as.info, Node: Symbol Type, Next: a.out Symbols, Prev: Symbol Value, Up: Symbol Attributes
-
-Type
-----
-
- The type attribute of a symbol contains relocation (section)
-information, any flag settings indicating that a symbol is external, and
-(optionally), other information for linkers and debuggers. The exact
-format depends on the object-code output format in use.
-
-
-File: as.info, Node: a.out Symbols, Next: COFF Symbols, Prev: Symbol Type, Up: Symbol Attributes
-
-Symbol Attributes: `a.out'
---------------------------
-
-* Menu:
-
-* Symbol Desc:: Descriptor
-* Symbol Other:: Other
-
-
-File: as.info, Node: Symbol Desc, Next: Symbol Other, Up: a.out Symbols
-
-Descriptor
-..........
-
- This is an arbitrary 16-bit value. You may establish a symbol's
-descriptor value by using a `.desc' statement (*note `.desc': Desc.).
-A descriptor value means nothing to `as'.
-
-
-File: as.info, Node: Symbol Other, Prev: Symbol Desc, Up: a.out Symbols
-
-Other
-.....
-
- This is an arbitrary 8-bit value. It means nothing to `as'.
-
-
-File: as.info, Node: COFF Symbols, Next: SOM Symbols, Prev: a.out Symbols, Up: Symbol Attributes
-
-Symbol Attributes for COFF
---------------------------
-
- The COFF format supports a multitude of auxiliary symbol attributes;
-like the primary symbol attributes, they are set between `.def' and
-`.endef' directives.
-
-Primary Attributes
-..................
-
- The symbol name is set with `.def'; the value and type,
-respectively, with `.val' and `.type'.
-
-Auxiliary Attributes
-....................
-
- The `as' directives `.dim', `.line', `.scl', `.size', and `.tag' can
-generate auxiliary symbol table information for COFF.
-
-
-File: as.info, Node: SOM Symbols, Prev: COFF Symbols, Up: Symbol Attributes
-
-Symbol Attributes for SOM
--------------------------
-
- The SOM format for the HPPA supports a multitude of symbol
-attributes set with the `.EXPORT' and `.IMPORT' directives.
-
- The attributes are described in `HP9000 Series 800 Assembly Language
-Reference Manual' (HP 92432-90001) under the `IMPORT' and `EXPORT'
-assembler directive documentation.
-
-
-File: as.info, Node: Expressions, Next: Pseudo Ops, Prev: Symbols, Up: Top
-
-Expressions
-***********
-
- An "expression" specifies an address or numeric value. Whitespace
-may precede and/or follow an expression.
-
- The result of an expression must be an absolute number, or else an
-offset into a particular section. If an expression is not absolute,
-and there is not enough information when `as' sees the expression to
-know its section, a second pass over the source program might be
-necessary to interpret the expression--but the second pass is currently
-not implemented. `as' aborts with an error message in this situation.
-
-* Menu:
-
-* Empty Exprs:: Empty Expressions
-* Integer Exprs:: Integer Expressions
-
-
-File: as.info, Node: Empty Exprs, Next: Integer Exprs, Up: Expressions
-
-Empty Expressions
-=================
-
- An empty expression has no value: it is just whitespace or null.
-Wherever an absolute expression is required, you may omit the
-expression, and `as' assumes a value of (absolute) 0. This is
-compatible with other assemblers.
-
-
-File: as.info, Node: Integer Exprs, Prev: Empty Exprs, Up: Expressions
-
-Integer Expressions
-===================
-
- An "integer expression" is one or more *arguments* delimited by
-*operators*.
-
-* Menu:
-
-* Arguments:: Arguments
-* Operators:: Operators
-* Prefix Ops:: Prefix Operators
-* Infix Ops:: Infix Operators
-
-
-File: as.info, Node: Arguments, Next: Operators, Up: Integer Exprs
-
-Arguments
----------
-
- "Arguments" are symbols, numbers or subexpressions. In other
-contexts arguments are sometimes called "arithmetic operands". In this
-manual, to avoid confusing them with the "instruction operands" of the
-machine language, we use the term "argument" to refer to parts of
-expressions only, reserving the word "operand" to refer only to machine
-instruction operands.
-
- Symbols are evaluated to yield {SECTION NNN} where SECTION is one of
-text, data, bss, absolute, or undefined. NNN is a signed, 2's
-complement 32 bit integer.
-
- Numbers are usually integers.
-
- A number can be a flonum or bignum. In this case, you are warned
-that only the low order 32 bits are used, and `as' pretends these 32
-bits are an integer. You may write integer-manipulating instructions
-that act on exotic constants, compatible with other assemblers.
-
- Subexpressions are a left parenthesis `(' followed by an integer
-expression, followed by a right parenthesis `)'; or a prefix operator
-followed by an argument.
-
-
-File: as.info, Node: Operators, Next: Prefix Ops, Prev: Arguments, Up: Integer Exprs
-
-Operators
----------
-
- "Operators" are arithmetic functions, like `+' or `%'. Prefix
-operators are followed by an argument. Infix operators appear between
-their arguments. Operators may be preceded and/or followed by
-whitespace.
-
-
-File: as.info, Node: Prefix Ops, Next: Infix Ops, Prev: Operators, Up: Integer Exprs
-
-Prefix Operator
----------------
-
- `as' has the following "prefix operators". They each take one
-argument, which must be absolute.
-
-`-'
- "Negation". Two's complement negation.
-
-`~'
- "Complementation". Bitwise not.
-
-
-File: as.info, Node: Infix Ops, Prev: Prefix Ops, Up: Integer Exprs
-
-Infix Operators
----------------
-
- "Infix operators" take two arguments, one on either side. Operators
-have precedence, but operations with equal precedence are performed left
-to right. Apart from `+' or `-', both arguments must be absolute, and
-the result is absolute.
-
- 1. Highest Precedence
-
- `*'
- "Multiplication".
-
- `/'
- "Division". Truncation is the same as the C operator `/'
-
- `%'
- "Remainder".
-
- `<'
- `<<'
- "Shift Left". Same as the C operator `<<'.
-
- `>'
- `>>'
- "Shift Right". Same as the C operator `>>'.
-
- 2. Intermediate precedence
-
- `|'
- "Bitwise Inclusive Or".
-
- `&'
- "Bitwise And".
-
- `^'
- "Bitwise Exclusive Or".
-
- `!'
- "Bitwise Or Not".
-
- 3. Lowest Precedence
-
- `+'
- "Addition". If either argument is absolute, the result has
- the section of the other argument. You may not add together
- arguments from different sections.
-
- `-'
- "Subtraction". If the right argument is absolute, the result
- has the section of the left argument. If both arguments are
- in the same section, the result is absolute. You may not
- subtract arguments from different sections.
-
- In short, it's only meaningful to add or subtract the *offsets* in an
-address; you can only have a defined section in one of the two
-arguments.
-
-
-File: as.info, Node: Pseudo Ops, Next: Machine Dependencies, Prev: Expressions, Up: Top
-
-Assembler Directives
-********************
-
- All assembler directives have names that begin with a period (`.').
-The rest of the name is letters, usually in lower case.
-
- This chapter discusses directives that are available regardless of
-the target machine configuration for the GNU assembler. Some machine
-configurations provide additional directives. *Note Machine
-Dependencies::.
-
-* Menu:
-
-* Abort:: `.abort'
-
-* ABORT:: `.ABORT'
-
-* Align:: `.align ABS-EXPR , ABS-EXPR'
-* App-File:: `.app-file STRING'
-* Ascii:: `.ascii "STRING"'...
-* Asciz:: `.asciz "STRING"'...
-* Balign:: `.balign ABS-EXPR , ABS-EXPR'
-* Byte:: `.byte EXPRESSIONS'
-* Comm:: `.comm SYMBOL , LENGTH '
-* Data:: `.data SUBSECTION'
-
-* Def:: `.def NAME'
-
-* Desc:: `.desc SYMBOL, ABS-EXPRESSION'
-
-* Dim:: `.dim'
-
-* Double:: `.double FLONUMS'
-* Eject:: `.eject'
-* Else:: `.else'
-
-* Endef:: `.endef'
-
-* Endif:: `.endif'
-* Equ:: `.equ SYMBOL, EXPRESSION'
-* Extern:: `.extern'
-
-* File:: `.file STRING'
-
-* Fill:: `.fill REPEAT , SIZE , VALUE'
-* Float:: `.float FLONUMS'
-* Global:: `.global SYMBOL', `.globl SYMBOL'
-* hword:: `.hword EXPRESSIONS'
-* Ident:: `.ident'
-* If:: `.if ABSOLUTE EXPRESSION'
-* Include:: `.include "FILE"'
-* Int:: `.int EXPRESSIONS'
-* Irp:: `.irp SYMBOL,VALUES'...
-* Irpc:: `.irpc SYMBOL,VALUES'...
-* Lcomm:: `.lcomm SYMBOL , LENGTH'
-* Lflags:: `.lflags'
-
-* Line:: `.line LINE-NUMBER'
-
-* Ln:: `.ln LINE-NUMBER'
-* List:: `.list'
-* Long:: `.long EXPRESSIONS'
-
-* Macro:: `.macro NAME ARGS'...
-
-* Nolist:: `.nolist'
-* Octa:: `.octa BIGNUMS'
-* Org:: `.org NEW-LC , FILL'
-* P2align:: `.p2align ABS-EXPR , ABS-EXPR'
-* Psize:: `.psize LINES, COLUMNS'
-* Quad:: `.quad BIGNUMS'
-* Rept:: `.rept COUNT'
-* Sbttl:: `.sbttl "SUBHEADING"'
-
-* Scl:: `.scl CLASS'
-
-* Section:: `.section NAME, SUBSECTION'
-
-* Set:: `.set SYMBOL, EXPRESSION'
-* Short:: `.short EXPRESSIONS'
-* Single:: `.single FLONUMS'
-
-* Size:: `.size'
-
-* Space:: `.space SIZE , FILL'
-
-* Stab:: `.stabd, .stabn, .stabs'
-
-* String:: `.string "STR"'
-
-* Tag:: `.tag STRUCTNAME'
-
-* Text:: `.text SUBSECTION'
-* Title:: `.title "HEADING"'
-
-* Type:: `.type INT'
-* Val:: `.val ADDR'
-
-* Word:: `.word EXPRESSIONS'
-* Deprecated:: Deprecated Directives
-
-
-File: as.info, Node: Abort, Next: ABORT, Up: Pseudo Ops
-
-`.abort'
-========
-
- This directive stops the assembly immediately. It is for
-compatibility with other assemblers. The original idea was that the
-assembly language source would be piped into the assembler. If the
-sender of the source quit, it could use this directive tells `as' to
-quit also. One day `.abort' will not be supported.
-
-
-File: as.info, Node: ABORT, Next: Align, Prev: Abort, Up: Pseudo Ops
-
-`.ABORT'
-========
-
- When producing COFF output, `as' accepts this directive as a synonym
-for `.abort'.
-
- When producing `b.out' output, `as' accepts this directive, but
-ignores it.
-
-
-File: as.info, Node: Align, Next: App-File, Prev: ABORT, Up: Pseudo Ops
-
-`.align ABS-EXPR , ABS-EXPR'
-============================
-
- Pad the location counter (in the current subsection) to a particular
-storage boundary. The first expression (which must be absolute) is the
-alignment required, as described below. The second expression (also
-absolute) gives the value to be stored in the padding bytes. It (and
-the comma) may be omitted. If it is omitted, the padding bytes are
-zero.
-
- The way the required alignment is specified varies from system to
-system. For the a29k, hppa, m86k, m88k, w65, sparc, and Hitachi SH,
-and i386 using ELF format, the first expression is the alignment
-request in bytes. For example `.align 8' advances the location counter
-until it is a multiple of 8. If the location counter is already a
-multiple of 8, no change is needed.
-
- For other systems, including the i386 using a.out format, it is the
-number of low-order zero bits the location counter must have after
-advancement. For example `.align 3' advances the location counter
-until it a multiple of 8. If the location counter is already a
-multiple of 8, no change is needed.
-
- This inconsistency is due to the different behaviors of the various
-native assemblers for these systems which GAS must emulate. GAS also
-provides `.balign' and `.p2align' directives, described later, which
-have a consistent behavior across all architectures (but are specific
-to GAS).
-
-
-File: as.info, Node: App-File, Next: Ascii, Prev: Align, Up: Pseudo Ops
-
-`.app-file STRING'
-==================
-
- `.app-file' (which may also be spelled `.file') tells `as' that we
-are about to start a new logical file. STRING is the new file name.
-In general, the filename is recognized whether or not it is surrounded
-by quotes `"'; but if you wish to specify an empty file name is
-permitted, you must give the quotes-`""'. This statement may go away in
-future: it is only recognized to be compatible with old `as' programs.
-
-
-File: as.info, Node: Ascii, Next: Asciz, Prev: App-File, Up: Pseudo Ops
-
-`.ascii "STRING"'...
-====================
-
- `.ascii' expects zero or more string literals (*note Strings::.)
-separated by commas. It assembles each string (with no automatic
-trailing zero byte) into consecutive addresses.
-
-
-File: as.info, Node: Asciz, Next: Balign, Prev: Ascii, Up: Pseudo Ops
-
-`.asciz "STRING"'...
-====================
-
- `.asciz' is just like `.ascii', but each string is followed by a
-zero byte. The "z" in `.asciz' stands for "zero".
-
-
-File: as.info, Node: Balign, Next: Byte, Prev: Asciz, Up: Pseudo Ops
-
-`.balign ABS-EXPR , ABS-EXPR'
-=============================
-
- Pad the location counter (in the current subsection) to a particular
-storage boundary. The first expression (which must be absolute) is the
-alignment request in bytes. For example `.balign 8' advances the
-location counter until it is a multiple of 8. If the location counter
-is already a multiple of 8, no change is needed.
-
- The second expression (also absolute) gives the value to be stored in
-the padding bytes. It (and the comma) may be omitted. If it is
-omitted, the padding bytes are zero.
-
-
-File: as.info, Node: Byte, Next: Comm, Prev: Balign, Up: Pseudo Ops
-
-`.byte EXPRESSIONS'
-===================
-
- `.byte' expects zero or more expressions, separated by commas. Each
-expression is assembled into the next byte.
-
-
-File: as.info, Node: Comm, Next: Data, Prev: Byte, Up: Pseudo Ops
-
-`.comm SYMBOL , LENGTH '
-========================
-
- `.comm' declares a named common area in the bss section. Normally
-`ld' reserves memory addresses for it during linking, so no partial
-program defines the location of the symbol. Use `.comm' to tell `ld'
-that it must be at least LENGTH bytes long. `ld' allocates space for
-each `.comm' symbol that is at least as long as the longest `.comm'
-request in any of the partial programs linked. LENGTH is an absolute
-expression.
-
- The syntax for `.comm' differs slightly on the HPPA. The syntax is
-`SYMBOL .comm, LENGTH'; SYMBOL is optional.
-
-
-File: as.info, Node: Data, Next: Def, Prev: Comm, Up: Pseudo Ops
-
-`.data SUBSECTION'
-==================
-
- `.data' tells `as' to assemble the following statements onto the end
-of the data subsection numbered SUBSECTION (which is an absolute
-expression). If SUBSECTION is omitted, it defaults to zero.
-
-
-File: as.info, Node: Def, Next: Desc, Prev: Data, Up: Pseudo Ops
-
-`.def NAME'
-===========
-
- Begin defining debugging information for a symbol NAME; the
-definition extends until the `.endef' directive is encountered.
-
- This directive is only observed when `as' is configured for COFF
-format output; when producing `b.out', `.def' is recognized, but
-ignored.
-
-
-File: as.info, Node: Desc, Next: Dim, Prev: Def, Up: Pseudo Ops
-
-`.desc SYMBOL, ABS-EXPRESSION'
-==============================
-
- This directive sets the descriptor of the symbol (*note Symbol
-Attributes::.) to the low 16 bits of an absolute expression.
-
- The `.desc' directive is not available when `as' is configured for
-COFF output; it is only for `a.out' or `b.out' object format. For the
-sake of compatibility, `as' accepts it, but produces no output, when
-configured for COFF.
-
-
-File: as.info, Node: Dim, Next: Double, Prev: Desc, Up: Pseudo Ops
-
-`.dim'
-======
-
- This directive is generated by compilers to include auxiliary
-debugging information in the symbol table. It is only permitted inside
-`.def'/`.endef' pairs.
-
- `.dim' is only meaningful when generating COFF format output; when
-`as' is generating `b.out', it accepts this directive but ignores it.
-
-
-File: as.info, Node: Double, Next: Eject, Prev: Dim, Up: Pseudo Ops
-
-`.double FLONUMS'
-=================
-
- `.double' expects zero or more flonums, separated by commas. It
-assembles floating point numbers. The exact kind of floating point
-numbers emitted depends on how `as' is configured. *Note Machine
-Dependencies::.
-
-
-File: as.info, Node: Eject, Next: Else, Prev: Double, Up: Pseudo Ops
-
-`.eject'
-========
-
- Force a page break at this point, when generating assembly listings.
-
-
-File: as.info, Node: Else, Next: Endef, Prev: Eject, Up: Pseudo Ops
-
-`.else'
-=======
-
- `.else' is part of the `as' support for conditional assembly; *note
-`.if': If.. It marks the beginning of a section of code to be
-assembled if the condition for the preceding `.if' was false.
-
-
-File: as.info, Node: Endef, Next: Endif, Prev: Else, Up: Pseudo Ops
-
-`.endef'
-========
-
- This directive flags the end of a symbol definition begun with
-`.def'.
-
- `.endef' is only meaningful when generating COFF format output; if
-`as' is configured to generate `b.out', it accepts this directive but
-ignores it.
-
-
-File: as.info, Node: Endif, Next: Equ, Prev: Endef, Up: Pseudo Ops
-
-`.endif'
-========
-
- `.endif' is part of the `as' support for conditional assembly; it
-marks the end of a block of code that is only assembled conditionally.
-*Note `.if': If.
-
-
-File: as.info, Node: Equ, Next: Extern, Prev: Endif, Up: Pseudo Ops
-
-`.equ SYMBOL, EXPRESSION'
-=========================
-
- This directive sets the value of SYMBOL to EXPRESSION. It is
-synonymous with `.set'; *note `.set': Set..
-
- The syntax for `equ' on the HPPA is `SYMBOL .equ EXPRESSION'.
-
-
-File: as.info, Node: Extern, Next: File, Prev: Equ, Up: Pseudo Ops
-
-`.extern'
-=========
-
- `.extern' is accepted in the source program--for compatibility with
-other assemblers--but it is ignored. `as' treats all undefined symbols
-as external.
-
-
-File: as.info, Node: File, Next: Fill, Prev: Extern, Up: Pseudo Ops
-
-`.file STRING'
-==============
-
- `.file' (which may also be spelled `.app-file') tells `as' that we
-are about to start a new logical file. STRING is the new file name.
-In general, the filename is recognized whether or not it is surrounded
-by quotes `"'; but if you wish to specify an empty file name, you must
-give the quotes-`""'. This statement may go away in future: it is only
-recognized to be compatible with old `as' programs. In some
-configurations of `as', `.file' has already been removed to avoid
-conflicts with other assemblers. *Note Machine Dependencies::.
-
-
-File: as.info, Node: Fill, Next: Float, Prev: File, Up: Pseudo Ops
-
-`.fill REPEAT , SIZE , VALUE'
-=============================
-
- RESULT, SIZE and VALUE are absolute expressions. This emits REPEAT
-copies of SIZE bytes. REPEAT may be zero or more. SIZE may be zero or
-more, but if it is more than 8, then it is deemed to have the value 8,
-compatible with other people's assemblers. The contents of each REPEAT
-bytes is taken from an 8-byte number. The highest order 4 bytes are
-zero. The lowest order 4 bytes are VALUE rendered in the byte-order of
-an integer on the computer `as' is assembling for. Each SIZE bytes in
-a repetition is taken from the lowest order SIZE bytes of this number.
-Again, this bizarre behavior is compatible with other people's
-assemblers.
-
- SIZE and VALUE are optional. If the second comma and VALUE are
-absent, VALUE is assumed zero. If the first comma and following tokens
-are absent, SIZE is assumed to be 1.
-
-
-File: as.info, Node: Float, Next: Global, Prev: Fill, Up: Pseudo Ops
-
-`.float FLONUMS'
-================
-
- This directive assembles zero or more flonums, separated by commas.
-It has the same effect as `.single'. The exact kind of floating point
-numbers emitted depends on how `as' is configured. *Note Machine
-Dependencies::.
-
-
-File: as.info, Node: Global, Next: hword, Prev: Float, Up: Pseudo Ops
-
-`.global SYMBOL', `.globl SYMBOL'
-=================================
-
- `.global' makes the symbol visible to `ld'. If you define SYMBOL in
-your partial program, its value is made available to other partial
-programs that are linked with it. Otherwise, SYMBOL takes its
-attributes from a symbol of the same name from another file linked into
-the same program.
-
- Both spellings (`.globl' and `.global') are accepted, for
-compatibility with other assemblers.
-
- On the HPPA, `.global' is not always enough to make it accessible to
-other partial programs. You may need the HPPA-only `.EXPORT' directive
-as well. *Note HPPA Assembler Directives: HPPA Directives.
-
-
-File: as.info, Node: hword, Next: Ident, Prev: Global, Up: Pseudo Ops
-
-`.hword EXPRESSIONS'
-====================
-
- This expects zero or more EXPRESSIONS, and emits a 16 bit number for
-each.
-
- This directive is a synonym for `.short'; depending on the target
-architecture, it may also be a synonym for `.word'.
-
-
-File: as.info, Node: Ident, Next: If, Prev: hword, Up: Pseudo Ops
-
-`.ident'
-========
-
- This directive is used by some assemblers to place tags in object
-files. `as' simply accepts the directive for source-file compatibility
-with such assemblers, but does not actually emit anything for it.
-
-
-File: as.info, Node: If, Next: Include, Prev: Ident, Up: Pseudo Ops
-
-`.if ABSOLUTE EXPRESSION'
-=========================
-
- `.if' marks the beginning of a section of code which is only
-considered part of the source program being assembled if the argument
-(which must be an ABSOLUTE EXPRESSION) is non-zero. The end of the
-conditional section of code must be marked by `.endif' (*note `.endif':
-Endif.); optionally, you may include code for the alternative
-condition, flagged by `.else' (*note `.else': Else..
-
- The following variants of `.if' are also supported:
-`.ifdef SYMBOL'
- Assembles the following section of code if the specified SYMBOL
- has been defined.
-
-`.ifndef SYMBOL'
-`ifnotdef SYMBOL'
- Assembles the following section of code if the specified SYMBOL
- has not been defined. Both spelling variants are equivalent.
-
-
-File: as.info, Node: Include, Next: Int, Prev: If, Up: Pseudo Ops
-
-`.include "FILE"'
-=================
-
- This directive provides a way to include supporting files at
-specified points in your source program. The code from FILE is
-assembled as if it followed the point of the `.include'; when the end
-of the included file is reached, assembly of the original file
-continues. You can control the search paths used with the `-I'
-command-line option (*note Command-Line Options: Invoking.). Quotation
-marks are required around FILE.
-
-
-File: as.info, Node: Int, Next: Irp, Prev: Include, Up: Pseudo Ops
-
-`.int EXPRESSIONS'
-==================
-
- Expect zero or more EXPRESSIONS, of any section, separated by commas.
-For each expression, emit a number that, at run time, is the value of
-that expression. The byte order and bit size of the number depends on
-what kind of target the assembly is for.
-
-
-File: as.info, Node: Irp, Next: Irpc, Prev: Int, Up: Pseudo Ops
-
-`.irp SYMBOL,VALUES'...
-=======================
-
- Evaluate a sequence of statements assigning different values to
-SYMBOL. The sequence of statements starts at the `.irp' directive, and
-is terminated by an `.endr' directive. For each VALUE, SYMBOL is set
-to VALUE, and the sequence of statements is assembled. If no VALUE is
-listed, the sequence of statements is assembled once, with SYMBOL set
-to the null string. To refer to SYMBOL within the sequence of
-statements, use \SYMBOL.
-
- For example, assembling
-
- .irp param,1,2,3
- move d\param,sp@-
- .endr
-
- is equivalent to assembling
-
- move d1,sp@-
- move d2,sp@-
- move d3,sp@-
-
-
-File: as.info, Node: Irpc, Next: Lcomm, Prev: Irp, Up: Pseudo Ops
-
-`.irpc SYMBOL,VALUES'...
-========================
-
- Evaluate a sequence of statements assigning different values to
-SYMBOL. The sequence of statements starts at the `.irpc' directive,
-and is terminated by an `.endr' directive. For each character in VALUE,
-SYMBOL is set to the character, and the sequence of statements is
-assembled. If no VALUE is listed, the sequence of statements is
-assembled once, with SYMBOL set to the null string. To refer to SYMBOL
-within the sequence of statements, use \SYMBOL.
-
- For example, assembling
-
- .irpc param,123
- move d\param,sp@-
- .endr
-
- is equivalent to assembling
-
- move d1,sp@-
- move d2,sp@-
- move d3,sp@-
-
-
-File: as.info, Node: Lcomm, Next: Lflags, Prev: Irpc, Up: Pseudo Ops
-
-`.lcomm SYMBOL , LENGTH'
-========================
-
- Reserve LENGTH (an absolute expression) bytes for a local common
-denoted by SYMBOL. The section and value of SYMBOL are those of the
-new local common. The addresses are allocated in the bss section, so
-that at run-time the bytes start off zeroed. SYMBOL is not declared
-global (*note `.global': Global.), so is normally not visible to `ld'.
-
- The syntax for `.lcomm' differs slightly on the HPPA. The syntax is
-`SYMBOL .lcomm, LENGTH'; SYMBOL is optional.
-
-
-File: as.info, Node: Lflags, Next: Line, Prev: Lcomm, Up: Pseudo Ops
-
-`.lflags'
-=========
-
- `as' accepts this directive, for compatibility with other
-assemblers, but ignores it.
-
-
-File: as.info, Node: Line, Next: Ln, Prev: Lflags, Up: Pseudo Ops
-
-`.line LINE-NUMBER'
-===================
-
- Change the logical line number. LINE-NUMBER must be an absolute
-expression. The next line has that logical line number. Therefore any
-other statements on the current line (after a statement separator
-character) are reported as on logical line number LINE-NUMBER - 1. One
-day `as' will no longer support this directive: it is recognized only
-for compatibility with existing assembler programs.
-
- *Warning:* In the AMD29K configuration of as, this command is not
-available; use the synonym `.ln' in that context.
-
- Even though this is a directive associated with the `a.out' or
-`b.out' object-code formats, `as' still recognizes it when producing
-COFF output, and treats `.line' as though it were the COFF `.ln' *if*
-it is found outside a `.def'/`.endef' pair.
-
- Inside a `.def', `.line' is, instead, one of the directives used by
-compilers to generate auxiliary symbol information for debugging.
-
-
-File: as.info, Node: Ln, Next: List, Prev: Line, Up: Pseudo Ops
-
-`.ln LINE-NUMBER'
-=================
-
- `.ln' is a synonym for `.line'.
-
-
-File: as.info, Node: List, Next: Long, Prev: Ln, Up: Pseudo Ops
-
-`.list'
-=======
-
- Control (in conjunction with the `.nolist' directive) whether or not
-assembly listings are generated. These two directives maintain an
-internal counter (which is zero initially). `.list' increments the
-counter, and `.nolist' decrements it. Assembly listings are generated
-whenever the counter is greater than zero.
-
- By default, listings are disabled. When you enable them (with the
-`-a' command line option; *note Command-Line Options: Invoking.), the
-initial value of the listing counter is one.
-
-
-File: as.info, Node: Long, Next: Macro, Prev: List, Up: Pseudo Ops
-
-`.long EXPRESSIONS'
-===================
-
- `.long' is the same as `.int', *note `.int': Int..
-
-
-File: as.info, Node: Macro, Next: Nolist, Prev: Long, Up: Pseudo Ops
-
-`.macro'
-========
-
- The commands `.macro' and `.endm' allow you to define macros that
-generate assembly output. For example, this definition specifies a
-macro `sum' that puts a sequence of numbers into memory:
-
- .macro sum from=0, to=5
- .long \from
- .if \to-\from
- sum "(\from+1)",\to
- .endif
- .endm
-
-With that definition, `SUM 0,5' is equivalent to this assembly input:
-
- .long 0
- .long 1
- .long 2
- .long 3
- .long 4
- .long 5
-
-`.macro MACNAME'
-`.macro MACNAME MACARGS ...'
- Begin the definition of a macro called MACNAME. If your macro
- definition requires arguments, specify their names after the macro
- name, separated by commas or spaces. You can supply a default
- value for any macro argument by following the name with `=DEFLT'.
- For example, these are all valid `.macro' statements:
-
- `.macro comm'
- Begin the definition of a macro called `comm', which takes no
- arguments.
-
- `.macro plus1 p, p1'
- `.macro plus1 p p1'
- Either statement begins the definition of a macro called
- `plus1', which takes two arguments; within the macro
- definition, write `\p' or `\p1' to evaluate the arguments.
-
- `.macro reserve_str p1=0 p2'
- Begin the definition of a macro called `reserve_str', with two
- arguments. The first argument has a default value, but not
- the second. After the definition is complete, you can call
- the macro either as `reserve_str A,B' (with `\p1' evaluating
- to A and `\p2' evaluating to B), or as `reserve_str ,B' (with
- `\p1' evaluating as the default, in this case `0', and `\p2'
- evaluating to B).
-
- When you call a macro, you can specify the argument values either
- by position, or by keyword. For example, `sum 9,17' is equivalent
- to `sum to=17, from=9'.
-
-`.endm'
- Mark the end of a macro definition.
-
-`.exitm'
- Exit early from the current macro definition.
-
-`\@'
- `as' maintains a counter of how many macros it has executed in
- this pseudo-variable; you can copy that number to your output with
- `\@', but *only within a macro definition*.
-
-
-File: as.info, Node: Nolist, Next: Octa, Prev: Macro, Up: Pseudo Ops
-
-`.nolist'
-=========
-
- Control (in conjunction with the `.list' directive) whether or not
-assembly listings are generated. These two directives maintain an
-internal counter (which is zero initially). `.list' increments the
-counter, and `.nolist' decrements it. Assembly listings are generated
-whenever the counter is greater than zero.
-
-
-File: as.info, Node: Octa, Next: Org, Prev: Nolist, Up: Pseudo Ops
-
-`.octa BIGNUMS'
-===============
-
- This directive expects zero or more bignums, separated by commas.
-For each bignum, it emits a 16-byte integer.
-
- The term "octa" comes from contexts in which a "word" is two bytes;
-hence *octa*-word for 16 bytes.
-
-
-File: as.info, Node: Org, Next: P2align, Prev: Octa, Up: Pseudo Ops
-
-`.org NEW-LC , FILL'
-====================
-
- Advance the location counter of the current section to NEW-LC.
-nEW-LC is either an absolute expression or an expression with the same
-section as the current subsection. That is, you can't use `.org' to
-cross sections: if NEW-LC has the wrong section, the `.org' directive
-is ignored. To be compatible with former assemblers, if the section of
-NEW-LC is absolute, `as' issues a warning, then pretends the section of
-NEW-LC is the same as the current subsection.
-
- `.org' may only increase the location counter, or leave it
-unchanged; you cannot use `.org' to move the location counter backwards.
-
- Because `as' tries to assemble programs in one pass, NEW-LC may not
-be undefined. If you really detest this restriction we eagerly await a
-chance to share your improved assembler.
-
- Beware that the origin is relative to the start of the section, not
-to the start of the subsection. This is compatible with other people's
-assemblers.
-
- When the location counter (of the current subsection) is advanced,
-the intervening bytes are filled with FILL which should be an absolute
-expression. If the comma and FILL are omitted, FILL defaults to zero.
-
-
-File: as.info, Node: P2align, Next: Psize, Prev: Org, Up: Pseudo Ops
-
-`.p2align ABS-EXPR , ABS-EXPR'
-==============================
-
- Pad the location counter (in the current subsection) to a particular
-storage boundary. The first expression (which must be absolute) is the
-number of low-order zero bits the location counter must have after
-advancement. For example `.p2align 3' advances the location counter
-until it a multiple of 8. If the location counter is already a
-multiple of 8, no change is needed.
-
- The second expression (also absolute) gives the value to be stored in
-the padding bytes. It (and the comma) may be omitted. If it is
-omitted, the padding bytes are zero.
-
-
-File: as.info, Node: Psize, Next: Quad, Prev: P2align, Up: Pseudo Ops
-
-`.psize LINES , COLUMNS'
-========================
-
- Use this directive to declare the number of lines--and, optionally,
-the number of columns--to use for each page, when generating listings.
-
- If you do not use `.psize', listings use a default line-count of 60.
-You may omit the comma and COLUMNS specification; the default width is
-200 columns.
-
- `as' generates formfeeds whenever the specified number of lines is
-exceeded (or whenever you explicitly request one, using `.eject').
-
- If you specify LINES as `0', no formfeeds are generated save those
-explicitly specified with `.eject'.
-
-
-File: as.info, Node: Quad, Next: Rept, Prev: Psize, Up: Pseudo Ops
-
-`.quad BIGNUMS'
-===============
-
- `.quad' expects zero or more bignums, separated by commas. For each
-bignum, it emits an 8-byte integer. If the bignum won't fit in 8
-bytes, it prints a warning message; and just takes the lowest order 8
-bytes of the bignum.
-
- The term "quad" comes from contexts in which a "word" is two bytes;
-hence *quad*-word for 8 bytes.
-
-
-File: as.info, Node: Rept, Next: Sbttl, Prev: Quad, Up: Pseudo Ops
-
-`.rept COUNT'
-=============
-
- Repeat the sequence of lines between the `.rept' directive and the
-next `.endr' directive COUNT times.
-
- For example, assembling
-
- .rept 3
- .long 0
- .endr
-
- is equivalent to assembling
-
- .long 0
- .long 0
- .long 0
-
-
-File: as.info, Node: Sbttl, Next: Scl, Prev: Rept, Up: Pseudo Ops
-
-`.sbttl "SUBHEADING"'
-=====================
-
- Use SUBHEADING as the title (third line, immediately after the title
-line) when generating assembly listings.
-
- This directive affects subsequent pages, as well as the current page
-if it appears within ten lines of the top of a page.
-
-
-File: as.info, Node: Scl, Next: Section, Prev: Sbttl, Up: Pseudo Ops
-
-`.scl CLASS'
-============
-
- Set the storage-class value for a symbol. This directive may only be
-used inside a `.def'/`.endef' pair. Storage class may flag whether a
-symbol is static or external, or it may record further symbolic
-debugging information.
-
- The `.scl' directive is primarily associated with COFF output; when
-configured to generate `b.out' output format, `as' accepts this
-directive but ignores it.
-
-
-File: as.info, Node: Section, Next: Set, Prev: Scl, Up: Pseudo Ops
-
-`.section NAME, SUBSECTION'
-===========================
-
- Assemble the following code into end of subsection numbered
-SUBSECTION in the COFF named section NAME. If you omit SUBSECTION,
-`as' uses subsection number zero. `.section .text' is equivalent to
-the `.text' directive; `.section .data' is equivalent to the `.data'
-directive. This directive is only supported for targets that actually
-support arbitrarily named sections; on `a.out' targets, for example, it
-is not accepted, even with a standard `a.out' section name as its
-parameter.
-
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info-3 b/gnu/usr.bin/binutils/gas/doc/as.info-3
deleted file mode 100644
index 3c708b530ba..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info-3
+++ /dev/null
@@ -1,1393 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: as.info, Node: Set, Next: Short, Prev: Section, Up: Pseudo Ops
-
-`.set SYMBOL, EXPRESSION'
-=========================
-
- Set the value of SYMBOL to EXPRESSION. This changes SYMBOL's value
-and type to conform to EXPRESSION. If SYMBOL was flagged as external,
-it remains flagged. (*Note Symbol Attributes::.)
-
- You may `.set' a symbol many times in the same assembly.
-
- If you `.set' a global symbol, the value stored in the object file
-is the last value stored into it.
-
- The syntax for `set' on the HPPA is `SYMBOL .set EXPRESSION'.
-
-
-File: as.info, Node: Short, Next: Single, Prev: Set, Up: Pseudo Ops
-
-`.short EXPRESSIONS'
-====================
-
- `.short' is normally the same as `.word'. *Note `.word': Word.
-
- In some configurations, however, `.short' and `.word' generate
-numbers of different lengths; *note Machine Dependencies::..
-
-
-File: as.info, Node: Single, Next: Size, Prev: Short, Up: Pseudo Ops
-
-`.single FLONUMS'
-=================
-
- This directive assembles zero or more flonums, separated by commas.
-It has the same effect as `.float'. The exact kind of floating point
-numbers emitted depends on how `as' is configured. *Note Machine
-Dependencies::.
-
-
-File: as.info, Node: Size, Next: Space, Prev: Single, Up: Pseudo Ops
-
-`.size'
-=======
-
- This directive is generated by compilers to include auxiliary
-debugging information in the symbol table. It is only permitted inside
-`.def'/`.endef' pairs.
-
- `.size' is only meaningful when generating COFF format output; when
-`as' is generating `b.out', it accepts this directive but ignores it.
-
-
-File: as.info, Node: Space, Next: Stab, Prev: Size, Up: Pseudo Ops
-
-`.space SIZE , FILL'
-====================
-
- This directive emits SIZE bytes, each of value FILL. Both SIZE and
-FILL are absolute expressions. If the comma and FILL are omitted, FILL
-is assumed to be zero.
-
- *Warning:* `.space' has a completely different meaning for HPPA
- targets; use `.block' as a substitute. See `HP9000 Series 800
- Assembly Language Reference Manual' (HP 92432-90001) for the
- meaning of the `.space' directive. *Note HPPA Assembler
- Directives: HPPA Directives, for a summary.
-
- On the AMD 29K, this directive is ignored; it is accepted for
-compatibility with other AMD 29K assemblers.
-
- *Warning:* In most versions of the GNU assembler, the directive
- `.space' has the effect of `.block' *Note Machine Dependencies::.
-
-
-File: as.info, Node: Stab, Next: String, Prev: Space, Up: Pseudo Ops
-
-`.stabd, .stabn, .stabs'
-========================
-
- There are three directives that begin `.stab'. All emit symbols
-(*note Symbols::.), for use by symbolic debuggers. The symbols are not
-entered in the `as' hash table: they cannot be referenced elsewhere in
-the source file. Up to five fields are required:
-
-STRING
- This is the symbol's name. It may contain any character except
- `\000', so is more general than ordinary symbol names. Some
- debuggers used to code arbitrarily complex structures into symbol
- names using this field.
-
-TYPE
- An absolute expression. The symbol's type is set to the low 8
- bits of this expression. Any bit pattern is permitted, but `ld'
- and debuggers choke on silly bit patterns.
-
-OTHER
- An absolute expression. The symbol's "other" attribute is set to
- the low 8 bits of this expression.
-
-DESC
- An absolute expression. The symbol's descriptor is set to the low
- 16 bits of this expression.
-
-VALUE
- An absolute expression which becomes the symbol's value.
-
- If a warning is detected while reading a `.stabd', `.stabn', or
-`.stabs' statement, the symbol has probably already been created; you
-get a half-formed symbol in your object file. This is compatible with
-earlier assemblers!
-
-`.stabd TYPE , OTHER , DESC'
- The "name" of the symbol generated is not even an empty string.
- It is a null pointer, for compatibility. Older assemblers used a
- null pointer so they didn't waste space in object files with empty
- strings.
-
- The symbol's value is set to the location counter, relocatably.
- When your program is linked, the value of this symbol is the
- address of the location counter when the `.stabd' was assembled.
-
-`.stabn TYPE , OTHER , DESC , VALUE'
- The name of the symbol is set to the empty string `""'.
-
-`.stabs STRING , TYPE , OTHER , DESC , VALUE'
- All five fields are specified.
-
-
-File: as.info, Node: String, Next: Tag, Prev: Stab, Up: Pseudo Ops
-
-`.string' "STR"
-===============
-
- Copy the characters in STR to the object file. You may specify more
-than one string to copy, separated by commas. Unless otherwise
-specified for a particular machine, the assembler marks the end of each
-string with a 0 byte. You can use any of the escape sequences
-described in *Note Strings: Strings.
-
-
-File: as.info, Node: Tag, Next: Text, Prev: String, Up: Pseudo Ops
-
-`.tag STRUCTNAME'
-=================
-
- This directive is generated by compilers to include auxiliary
-debugging information in the symbol table. It is only permitted inside
-`.def'/`.endef' pairs. Tags are used to link structure definitions in
-the symbol table with instances of those structures.
-
- `.tag' is only used when generating COFF format output; when `as' is
-generating `b.out', it accepts this directive but ignores it.
-
-
-File: as.info, Node: Text, Next: Title, Prev: Tag, Up: Pseudo Ops
-
-`.text SUBSECTION'
-==================
-
- Tells `as' to assemble the following statements onto the end of the
-text subsection numbered SUBSECTION, which is an absolute expression.
-If SUBSECTION is omitted, subsection number zero is used.
-
-
-File: as.info, Node: Title, Next: Type, Prev: Text, Up: Pseudo Ops
-
-`.title "HEADING"'
-==================
-
- Use HEADING as the title (second line, immediately after the source
-file name and pagenumber) when generating assembly listings.
-
- This directive affects subsequent pages, as well as the current page
-if it appears within ten lines of the top of a page.
-
-
-File: as.info, Node: Type, Next: Val, Prev: Title, Up: Pseudo Ops
-
-`.type INT'
-===========
-
- This directive, permitted only within `.def'/`.endef' pairs, records
-the integer INT as the type attribute of a symbol table entry.
-
- `.type' is associated only with COFF format output; when `as' is
-configured for `b.out' output, it accepts this directive but ignores it.
-
-
-File: as.info, Node: Val, Next: Word, Prev: Type, Up: Pseudo Ops
-
-`.val ADDR'
-===========
-
- This directive, permitted only within `.def'/`.endef' pairs, records
-the address ADDR as the value attribute of a symbol table entry.
-
- `.val' is used only for COFF output; when `as' is configured for
-`b.out', it accepts this directive but ignores it.
-
-
-File: as.info, Node: Word, Next: Deprecated, Prev: Val, Up: Pseudo Ops
-
-`.word EXPRESSIONS'
-===================
-
- This directive expects zero or more EXPRESSIONS, of any section,
-separated by commas.
-
- The size of the number emitted, and its byte order, depend on what
-target computer the assembly is for.
-
- *Warning: Special Treatment to support Compilers*
-
- Machines with a 32-bit address space, but that do less than 32-bit
-addressing, require the following special treatment. If the machine of
-interest to you does 32-bit addressing (or doesn't require it; *note
-Machine Dependencies::.), you can ignore this issue.
-
- In order to assemble compiler output into something that works, `as'
-occasionlly does strange things to `.word' directives. Directives of
-the form `.word sym1-sym2' are often emitted by compilers as part of
-jump tables. Therefore, when `as' assembles a directive of the form
-`.word sym1-sym2', and the difference between `sym1' and `sym2' does
-not fit in 16 bits, `as' creates a "secondary jump table", immediately
-before the next label. This secondary jump table is preceded by a
-short-jump to the first byte after the secondary table. This
-short-jump prevents the flow of control from accidentally falling into
-the new table. Inside the table is a long-jump to `sym2'. The
-original `.word' contains `sym1' minus the address of the long-jump to
-`sym2'.
-
- If there were several occurrences of `.word sym1-sym2' before the
-secondary jump table, all of them are adjusted. If there was a `.word
-sym3-sym4', that also did not fit in sixteen bits, a long-jump to
-`sym4' is included in the secondary jump table, and the `.word'
-directives are adjusted to contain `sym3' minus the address of the
-long-jump to `sym4'; and so on, for as many entries in the original
-jump table as necessary.
-
-
-File: as.info, Node: Deprecated, Prev: Word, Up: Pseudo Ops
-
-Deprecated Directives
-=====================
-
- One day these directives won't work. They are included for
-compatibility with older assemblers.
-.abort
-.app-file
-.line
-
-File: as.info, Node: Machine Dependencies, Next: Acknowledgements, Prev: Pseudo Ops, Up: Top
-
-Machine Dependent Features
-**************************
-
- The machine instruction sets are (almost by definition) different on
-each machine where `as' runs. Floating point representations vary as
-well, and `as' often supports a few additional directives or
-command-line options for compatibility with other assemblers on a
-particular platform. Finally, some versions of `as' support special
-pseudo-instructions for branch optimization.
-
- This chapter discusses most of these differences, though it does not
-include details on any machine's instruction set. For details on that
-subject, see the hardware manufacturer's manual.
-
-* Menu:
-
-
-* Vax-Dependent:: VAX Dependent Features
-
-* AMD29K-Dependent:: AMD 29K Dependent Features
-
-* H8/300-Dependent:: Hitachi H8/300 Dependent Features
-
-* H8/500-Dependent:: Hitachi H8/500 Dependent Features
-
-* HPPA-Dependent:: HPPA Dependent Features
-
-* SH-Dependent:: Hitachi SH Dependent Features
-
-* i960-Dependent:: Intel 80960 Dependent Features
-
-* M68K-Dependent:: M680x0 Dependent Features
-
-* Sparc-Dependent:: SPARC Dependent Features
-
-* Z8000-Dependent:: Z8000 Dependent Features
-
-* MIPS-Dependent:: MIPS Dependent Features
-
-* i386-Dependent:: 80386 Dependent Features
-
-
-File: as.info, Node: Vax-Dependent, Next: AMD29K-Dependent, Up: Machine Dependencies
-
-VAX Dependent Features
-======================
-
-* Menu:
-
-* Vax-Opts:: VAX Command-Line Options
-* VAX-float:: VAX Floating Point
-* VAX-directives:: Vax Machine Directives
-* VAX-opcodes:: VAX Opcodes
-* VAX-branch:: VAX Branch Improvement
-* VAX-operands:: VAX Operands
-* VAX-no:: Not Supported on VAX
-
-
-File: as.info, Node: Vax-Opts, Next: VAX-float, Up: Vax-Dependent
-
-VAX Command-Line Options
-------------------------
-
- The Vax version of `as' accepts any of the following options, gives
-a warning message that the option was ignored and proceeds. These
-options are for compatibility with scripts designed for other people's
-assemblers.
-
-``-D' (Debug)'
-``-S' (Symbol Table)'
-``-T' (Token Trace)'
- These are obsolete options used to debug old assemblers.
-
-``-d' (Displacement size for JUMPs)'
- This option expects a number following the `-d'. Like options
- that expect filenames, the number may immediately follow the `-d'
- (old standard) or constitute the whole of the command line
- argument that follows `-d' (GNU standard).
-
-``-V' (Virtualize Interpass Temporary File)'
- Some other assemblers use a temporary file. This option commanded
- them to keep the information in active memory rather than in a
- disk file. `as' always does this, so this option is redundant.
-
-``-J' (JUMPify Longer Branches)'
- Many 32-bit computers permit a variety of branch instructions to
- do the same job. Some of these instructions are short (and fast)
- but have a limited range; others are long (and slow) but can
- branch anywhere in virtual memory. Often there are 3 flavors of
- branch: short, medium and long. Some other assemblers would emit
- short and medium branches, unless told by this option to emit
- short and long branches.
-
-``-t' (Temporary File Directory)'
- Some other assemblers may use a temporary file, and this option
- takes a filename being the directory to site the temporary file.
- Since `as' does not use a temporary disk file, this option makes
- no difference. `-t' needs exactly one filename.
-
- The Vax version of the assembler accepts two options when compiled
-for VMS. They are `-h', and `-+'. The `-h' option prevents `as' from
-modifying the symbol-table entries for symbols that contain lowercase
-characters (I think). The `-+' option causes `as' to print warning
-messages if the FILENAME part of the object file, or any symbol name is
-larger than 31 characters. The `-+' option also inserts some code
-following the `_main' symbol so that the object file is compatible with
-Vax-11 "C".
-
-
-File: as.info, Node: VAX-float, Next: VAX-directives, Prev: Vax-Opts, Up: Vax-Dependent
-
-VAX Floating Point
-------------------
-
- Conversion of flonums to floating point is correct, and compatible
-with previous assemblers. Rounding is towards zero if the remainder is
-exactly half the least significant bit.
-
- `D', `F', `G' and `H' floating point formats are understood.
-
- Immediate floating literals (*e.g.* `S`$6.9') are rendered
-correctly. Again, rounding is towards zero in the boundary case.
-
- The `.float' directive produces `f' format numbers. The `.double'
-directive produces `d' format numbers.
-
-
-File: as.info, Node: VAX-directives, Next: VAX-opcodes, Prev: VAX-float, Up: Vax-Dependent
-
-Vax Machine Directives
-----------------------
-
- The Vax version of the assembler supports four directives for
-generating Vax floating point constants. They are described in the
-table below.
-
-`.dfloat'
- This expects zero or more flonums, separated by commas, and
- assembles Vax `d' format 64-bit floating point constants.
-
-`.ffloat'
- This expects zero or more flonums, separated by commas, and
- assembles Vax `f' format 32-bit floating point constants.
-
-`.gfloat'
- This expects zero or more flonums, separated by commas, and
- assembles Vax `g' format 64-bit floating point constants.
-
-`.hfloat'
- This expects zero or more flonums, separated by commas, and
- assembles Vax `h' format 128-bit floating point constants.
-
-
-File: as.info, Node: VAX-opcodes, Next: VAX-branch, Prev: VAX-directives, Up: Vax-Dependent
-
-VAX Opcodes
------------
-
- All DEC mnemonics are supported. Beware that `case...' instructions
-have exactly 3 operands. The dispatch table that follows the `case...'
-instruction should be made with `.word' statements. This is compatible
-with all unix assemblers we know of.
-
-
-File: as.info, Node: VAX-branch, Next: VAX-operands, Prev: VAX-opcodes, Up: Vax-Dependent
-
-VAX Branch Improvement
-----------------------
-
- Certain pseudo opcodes are permitted. They are for branch
-instructions. They expand to the shortest branch instruction that
-reaches the target. Generally these mnemonics are made by substituting
-`j' for `b' at the start of a DEC mnemonic. This feature is included
-both for compatibility and to help compilers. If you do not need this
-feature, avoid these opcodes. Here are the mnemonics, and the code
-they can expand into.
-
-`jbsb'
- `Jsb' is already an instruction mnemonic, so we chose `jbsb'.
- (byte displacement)
- `bsbb ...'
-
- (word displacement)
- `bsbw ...'
-
- (long displacement)
- `jsb ...'
-
-`jbr'
-`jr'
- Unconditional branch.
- (byte displacement)
- `brb ...'
-
- (word displacement)
- `brw ...'
-
- (long displacement)
- `jmp ...'
-
-`jCOND'
- COND may be any one of the conditional branches `neq', `nequ',
- `eql', `eqlu', `gtr', `geq', `lss', `gtru', `lequ', `vc', `vs',
- `gequ', `cc', `lssu', `cs'. COND may also be one of the bit tests
- `bs', `bc', `bss', `bcs', `bsc', `bcc', `bssi', `bcci', `lbs',
- `lbc'. NOTCOND is the opposite condition to COND.
- (byte displacement)
- `bCOND ...'
-
- (word displacement)
- `bNOTCOND foo ; brw ... ; foo:'
-
- (long displacement)
- `bNOTCOND foo ; jmp ... ; foo:'
-
-`jacbX'
- X may be one of `b d f g h l w'.
- (word displacement)
- `OPCODE ...'
-
- (long displacement)
- OPCODE ..., foo ;
- brb bar ;
- foo: jmp ... ;
- bar:
-
-`jaobYYY'
- YYY may be one of `lss leq'.
-
-`jsobZZZ'
- ZZZ may be one of `geq gtr'.
- (byte displacement)
- `OPCODE ...'
-
- (word displacement)
- OPCODE ..., foo ;
- brb bar ;
- foo: brw DESTINATION ;
- bar:
-
- (long displacement)
- OPCODE ..., foo ;
- brb bar ;
- foo: jmp DESTINATION ;
- bar:
-
-`aobleq'
-`aoblss'
-`sobgeq'
-`sobgtr'
- (byte displacement)
- `OPCODE ...'
-
- (word displacement)
- OPCODE ..., foo ;
- brb bar ;
- foo: brw DESTINATION ;
- bar:
-
- (long displacement)
- OPCODE ..., foo ;
- brb bar ;
- foo: jmp DESTINATION ;
- bar:
-
-
-File: as.info, Node: VAX-operands, Next: VAX-no, Prev: VAX-branch, Up: Vax-Dependent
-
-VAX Operands
-------------
-
- The immediate character is `$' for Unix compatibility, not `#' as
-DEC writes it.
-
- The indirect character is `*' for Unix compatibility, not `@' as DEC
-writes it.
-
- The displacement sizing character is ``' (an accent grave) for Unix
-compatibility, not `^' as DEC writes it. The letter preceding ``' may
-have either case. `G' is not understood, but all other letters (`b i l
-s w') are understood.
-
- Register names understood are `r0 r1 r2 ... r15 ap fp sp pc'. Upper
-and lower case letters are equivalent.
-
- For instance
- tstb *w`$4(r5)
-
- Any expression is permitted in an operand. Operands are comma
-separated.
-
-
-File: as.info, Node: VAX-no, Prev: VAX-operands, Up: Vax-Dependent
-
-Not Supported on VAX
---------------------
-
- Vax bit fields can not be assembled with `as'. Someone can add the
-required code if they really need it.
-
-
-File: as.info, Node: AMD29K-Dependent, Next: H8/300-Dependent, Prev: Vax-Dependent, Up: Machine Dependencies
-
-AMD 29K Dependent Features
-==========================
-
-* Menu:
-
-* AMD29K Options:: Options
-* AMD29K Syntax:: Syntax
-* AMD29K Floating Point:: Floating Point
-* AMD29K Directives:: AMD 29K Machine Directives
-* AMD29K Opcodes:: Opcodes
-
-
-File: as.info, Node: AMD29K Options, Next: AMD29K Syntax, Up: AMD29K-Dependent
-
-Options
--------
-
- `as' has no additional command-line options for the AMD 29K family.
-
-
-File: as.info, Node: AMD29K Syntax, Next: AMD29K Floating Point, Prev: AMD29K Options, Up: AMD29K-Dependent
-
-Syntax
-------
-
-* Menu:
-
-* AMD29K-Macros:: Macros
-* AMD29K-Chars:: Special Characters
-* AMD29K-Regs:: Register Names
-
-
-File: as.info, Node: AMD29K-Macros, Next: AMD29K-Chars, Up: AMD29K Syntax
-
-Macros
-......
-
- The macro syntax used on the AMD 29K is like that described in the
-AMD 29K Family Macro Assembler Specification. Normal `as' macros
-should still work.
-
-
-File: as.info, Node: AMD29K-Chars, Next: AMD29K-Regs, Prev: AMD29K-Macros, Up: AMD29K Syntax
-
-Special Characters
-..................
-
- `;' is the line comment character.
-
- The character `?' is permitted in identifiers (but may not begin an
-identifier).
-
-
-File: as.info, Node: AMD29K-Regs, Prev: AMD29K-Chars, Up: AMD29K Syntax
-
-Register Names
-..............
-
- General-purpose registers are represented by predefined symbols of
-the form `GRNNN' (for global registers) or `LRNNN' (for local
-registers), where NNN represents a number between `0' and `127',
-written with no leading zeros. The leading letters may be in either
-upper or lower case; for example, `gr13' and `LR7' are both valid
-register names.
-
- You may also refer to general-purpose registers by specifying the
-register number as the result of an expression (prefixed with `%%' to
-flag the expression as a register number):
- %%EXPRESSION
-
---where EXPRESSION must be an absolute expression evaluating to a
-number between `0' and `255'. The range [0, 127] refers to global
-registers, and the range [128, 255] to local registers.
-
- In addition, `as' understands the following protected
-special-purpose register names for the AMD 29K family:
-
- vab chd pc0
- ops chc pc1
- cps rbp pc2
- cfg tmc mmu
- cha tmr lru
-
- These unprotected special-purpose register names are also recognized:
- ipc alu fpe
- ipa bp inte
- ipb fc fps
- q cr exop
-
-
-File: as.info, Node: AMD29K Floating Point, Next: AMD29K Directives, Prev: AMD29K Syntax, Up: AMD29K-Dependent
-
-Floating Point
---------------
-
- The AMD 29K family uses IEEE floating-point numbers.
-
-
-File: as.info, Node: AMD29K Directives, Next: AMD29K Opcodes, Prev: AMD29K Floating Point, Up: AMD29K-Dependent
-
-AMD 29K Machine Directives
---------------------------
-
-`.block SIZE , FILL'
- This directive emits SIZE bytes, each of value FILL. Both SIZE
- and FILL are absolute expressions. If the comma and FILL are
- omitted, FILL is assumed to be zero.
-
- In other versions of the GNU assembler, this directive is called
- `.space'.
-
-`.cputype'
- This directive is ignored; it is accepted for compatibility with
- other AMD 29K assemblers.
-
-`.file'
- This directive is ignored; it is accepted for compatibility with
- other AMD 29K assemblers.
-
- *Warning:* in other versions of the GNU assembler, `.file' is
- used for the directive called `.app-file' in the AMD 29K
- support.
-
-`.line'
- This directive is ignored; it is accepted for compatibility with
- other AMD 29K assemblers.
-
-`.sect'
- This directive is ignored; it is accepted for compatibility with
- other AMD 29K assemblers.
-
-`.use SECTION NAME'
- Establishes the section and subsection for the following code;
- SECTION NAME may be one of `.text', `.data', `.data1', or `.lit'.
- With one of the first three SECTION NAME options, `.use' is
- equivalent to the machine directive SECTION NAME; the remaining
- case, `.use .lit', is the same as `.data 200'.
-
-
-File: as.info, Node: AMD29K Opcodes, Prev: AMD29K Directives, Up: AMD29K-Dependent
-
-Opcodes
--------
-
- `as' implements all the standard AMD 29K opcodes. No additional
-pseudo-instructions are needed on this family.
-
- For information on the 29K machine instruction set, see `Am29000
-User's Manual', Advanced Micro Devices, Inc.
-
-
-File: as.info, Node: H8/300-Dependent, Next: H8/500-Dependent, Prev: AMD29K-Dependent, Up: Machine Dependencies
-
-H8/300 Dependent Features
-=========================
-
-* Menu:
-
-* H8/300 Options:: Options
-* H8/300 Syntax:: Syntax
-* H8/300 Floating Point:: Floating Point
-* H8/300 Directives:: H8/300 Machine Directives
-* H8/300 Opcodes:: Opcodes
-
-
-File: as.info, Node: H8/300 Options, Next: H8/300 Syntax, Up: H8/300-Dependent
-
-Options
--------
-
- `as' has no additional command-line options for the Hitachi H8/300
-family.
-
-
-File: as.info, Node: H8/300 Syntax, Next: H8/300 Floating Point, Prev: H8/300 Options, Up: H8/300-Dependent
-
-Syntax
-------
-
-* Menu:
-
-* H8/300-Chars:: Special Characters
-* H8/300-Regs:: Register Names
-* H8/300-Addressing:: Addressing Modes
-
-
-File: as.info, Node: H8/300-Chars, Next: H8/300-Regs, Up: H8/300 Syntax
-
-Special Characters
-..................
-
- `;' is the line comment character.
-
- `$' can be used instead of a newline to separate statements.
-Therefore *you may not use `$' in symbol names* on the H8/300.
-
-
-File: as.info, Node: H8/300-Regs, Next: H8/300-Addressing, Prev: H8/300-Chars, Up: H8/300 Syntax
-
-Register Names
-..............
-
- You can use predefined symbols of the form `rNh' and `rNl' to refer
-to the H8/300 registers as sixteen 8-bit general-purpose registers. N
-is a digit from `0' to `7'); for instance, both `r0h' and `r7l' are
-valid register names.
-
- You can also use the eight predefined symbols `rN' to refer to the
-H8/300 registers as 16-bit registers (you must use this form for
-addressing).
-
- On the H8/300H, you can also use the eight predefined symbols `erN'
-(`er0' ... `er7') to refer to the 32-bit general purpose registers.
-
- The two control registers are called `pc' (program counter; a 16-bit
-register, except on the H8/300H where it is 24 bits) and `ccr'
-(condition code register; an 8-bit register). `r7' is used as the
-stack pointer, and can also be called `sp'.
-
-
-File: as.info, Node: H8/300-Addressing, Prev: H8/300-Regs, Up: H8/300 Syntax
-
-Addressing Modes
-................
-
- as understands the following addressing modes for the H8/300:
-`rN'
- Register direct
-
-`@rN'
- Register indirect
-
-`@(D, rN)'
-`@(D:16, rN)'
-`@(D:24, rN)'
- Register indirect: 16-bit or 24-bit displacement D from register
- N. (24-bit displacements are only meaningful on the H8/300H.)
-
-`@rN+'
- Register indirect with post-increment
-
-`@-rN'
- Register indirect with pre-decrement
-
-``@'AA'
-``@'AA:8'
-``@'AA:16'
-``@'AA:24'
- Absolute address `aa'. (The address size `:24' only makes sense
- on the H8/300H.)
-
-`#XX'
-`#XX:8'
-`#XX:16'
-`#XX:32'
- Immediate data XX. You may specify the `:8', `:16', or `:32' for
- clarity, if you wish; but `as' neither requires this nor uses
- it--the data size required is taken from context.
-
-``@'`@'AA'
-``@'`@'AA:8'
- Memory indirect. You may specify the `:8' for clarity, if you
- wish; but `as' neither requires this nor uses it.
-
-
-File: as.info, Node: H8/300 Floating Point, Next: H8/300 Directives, Prev: H8/300 Syntax, Up: H8/300-Dependent
-
-Floating Point
---------------
-
- The H8/300 family has no hardware floating point, but the `.float'
-directive generates IEEE floating-point numbers for compatibility with
-other development tools.
-
-
-File: as.info, Node: H8/300 Directives, Next: H8/300 Opcodes, Prev: H8/300 Floating Point, Up: H8/300-Dependent
-
-H8/300 Machine Directives
--------------------------
-
- `as' has only one machine-dependent directive for the H8/300:
-
-`.h8300h'
- Recognize and emit additional instructions for the H8/300H
- variant, and also make `.int' emit 32-bit numbers rather than the
- usual (16-bit) for the H8/300 family.
-
- On the H8/300 family (including the H8/300H) `.word' directives
-generate 16-bit numbers.
-
-
-File: as.info, Node: H8/300 Opcodes, Prev: H8/300 Directives, Up: H8/300-Dependent
-
-Opcodes
--------
-
- For detailed information on the H8/300 machine instruction set, see
-`H8/300 Series Programming Manual' (Hitachi ADE-602-025). For
-information specific to the H8/300H, see `H8/300H Series Programming
-Manual' (Hitachi).
-
- `as' implements all the standard H8/300 opcodes. No additional
-pseudo-instructions are needed on this family.
-
- The following table summarizes the H8/300 opcodes, and their
-arguments. Entries marked `*' are opcodes used only on the H8/300H.
-
- Legend:
- Rs source register
- Rd destination register
- abs absolute address
- imm immediate data
- disp:N N-bit displacement from a register
- pcrel:N N-bit displacement relative to program counter
-
- add.b #imm,rd * andc #imm,ccr
- add.b rs,rd band #imm,rd
- add.w rs,rd band #imm,@rd
- * add.w #imm,rd band #imm,@abs:8
- * add.l rs,rd bra pcrel:8
- * add.l #imm,rd * bra pcrel:16
- adds #imm,rd bt pcrel:8
- addx #imm,rd * bt pcrel:16
- addx rs,rd brn pcrel:8
- and.b #imm,rd * brn pcrel:16
- and.b rs,rd bf pcrel:8
- * and.w rs,rd * bf pcrel:16
- * and.w #imm,rd bhi pcrel:8
- * and.l #imm,rd * bhi pcrel:16
- * and.l rs,rd bls pcrel:8
-
- * bls pcrel:16 bld #imm,rd
- bcc pcrel:8 bld #imm,@rd
- * bcc pcrel:16 bld #imm,@abs:8
- bhs pcrel:8 bnot #imm,rd
- * bhs pcrel:16 bnot #imm,@rd
- bcs pcrel:8 bnot #imm,@abs:8
- * bcs pcrel:16 bnot rs,rd
- blo pcrel:8 bnot rs,@rd
- * blo pcrel:16 bnot rs,@abs:8
- bne pcrel:8 bor #imm,rd
- * bne pcrel:16 bor #imm,@rd
- beq pcrel:8 bor #imm,@abs:8
- * beq pcrel:16 bset #imm,rd
- bvc pcrel:8 bset #imm,@rd
- * bvc pcrel:16 bset #imm,@abs:8
- bvs pcrel:8 bset rs,rd
- * bvs pcrel:16 bset rs,@rd
- bpl pcrel:8 bset rs,@abs:8
- * bpl pcrel:16 bsr pcrel:8
- bmi pcrel:8 bsr pcrel:16
- * bmi pcrel:16 bst #imm,rd
- bge pcrel:8 bst #imm,@rd
- * bge pcrel:16 bst #imm,@abs:8
- blt pcrel:8 btst #imm,rd
- * blt pcrel:16 btst #imm,@rd
- bgt pcrel:8 btst #imm,@abs:8
- * bgt pcrel:16 btst rs,rd
- ble pcrel:8 btst rs,@rd
- * ble pcrel:16 btst rs,@abs:8
- bclr #imm,rd bxor #imm,rd
- bclr #imm,@rd bxor #imm,@rd
- bclr #imm,@abs:8 bxor #imm,@abs:8
- bclr rs,rd cmp.b #imm,rd
- bclr rs,@rd cmp.b rs,rd
- bclr rs,@abs:8 cmp.w rs,rd
- biand #imm,rd cmp.w rs,rd
- biand #imm,@rd * cmp.w #imm,rd
- biand #imm,@abs:8 * cmp.l #imm,rd
- bild #imm,rd * cmp.l rs,rd
- bild #imm,@rd daa rs
- bild #imm,@abs:8 das rs
- bior #imm,rd dec.b rs
- bior #imm,@rd * dec.w #imm,rd
- bior #imm,@abs:8 * dec.l #imm,rd
- bist #imm,rd divxu.b rs,rd
- bist #imm,@rd * divxu.w rs,rd
- bist #imm,@abs:8 * divxs.b rs,rd
- bixor #imm,rd * divxs.w rs,rd
- bixor #imm,@rd eepmov
- bixor #imm,@abs:8 * eepmovw
-
- * exts.w rd mov.w rs,@abs:16
- * exts.l rd * mov.l #imm,rd
- * extu.w rd * mov.l rs,rd
- * extu.l rd * mov.l @rs,rd
- inc rs * mov.l @(disp:16,rs),rd
- * inc.w #imm,rd * mov.l @(disp:24,rs),rd
- * inc.l #imm,rd * mov.l @rs+,rd
- jmp @rs * mov.l @abs:16,rd
- jmp abs * mov.l @abs:24,rd
- jmp @@abs:8 * mov.l rs,@rd
- jsr @rs * mov.l rs,@(disp:16,rd)
- jsr abs * mov.l rs,@(disp:24,rd)
- jsr @@abs:8 * mov.l rs,@-rd
- ldc #imm,ccr * mov.l rs,@abs:16
- ldc rs,ccr * mov.l rs,@abs:24
- * ldc @abs:16,ccr movfpe @abs:16,rd
- * ldc @abs:24,ccr movtpe rs,@abs:16
- * ldc @(disp:16,rs),ccr mulxu.b rs,rd
- * ldc @(disp:24,rs),ccr * mulxu.w rs,rd
- * ldc @rs+,ccr * mulxs.b rs,rd
- * ldc @rs,ccr * mulxs.w rs,rd
- * mov.b @(disp:24,rs),rd neg.b rs
- * mov.b rs,@(disp:24,rd) * neg.w rs
- mov.b @abs:16,rd * neg.l rs
- mov.b rs,rd nop
- mov.b @abs:8,rd not.b rs
- mov.b rs,@abs:8 * not.w rs
- mov.b rs,rd * not.l rs
- mov.b #imm,rd or.b #imm,rd
- mov.b @rs,rd or.b rs,rd
- mov.b @(disp:16,rs),rd * or.w #imm,rd
- mov.b @rs+,rd * or.w rs,rd
- mov.b @abs:8,rd * or.l #imm,rd
- mov.b rs,@rd * or.l rs,rd
- mov.b rs,@(disp:16,rd) orc #imm,ccr
- mov.b rs,@-rd pop.w rs
- mov.b rs,@abs:8 * pop.l rs
- mov.w rs,@rd push.w rs
- * mov.w @(disp:24,rs),rd * push.l rs
- * mov.w rs,@(disp:24,rd) rotl.b rs
- * mov.w @abs:24,rd * rotl.w rs
- * mov.w rs,@abs:24 * rotl.l rs
- mov.w rs,rd rotr.b rs
- mov.w #imm,rd * rotr.w rs
- mov.w @rs,rd * rotr.l rs
- mov.w @(disp:16,rs),rd rotxl.b rs
- mov.w @rs+,rd * rotxl.w rs
- mov.w @abs:16,rd * rotxl.l rs
- mov.w rs,@(disp:16,rd) rotxr.b rs
- mov.w rs,@-rd * rotxr.w rs
-
- * rotxr.l rs * stc ccr,@(disp:24,rd)
- bpt * stc ccr,@-rd
- rte * stc ccr,@abs:16
- rts * stc ccr,@abs:24
- shal.b rs sub.b rs,rd
- * shal.w rs sub.w rs,rd
- * shal.l rs * sub.w #imm,rd
- shar.b rs * sub.l rs,rd
- * shar.w rs * sub.l #imm,rd
- * shar.l rs subs #imm,rd
- shll.b rs subx #imm,rd
- * shll.w rs subx rs,rd
- * shll.l rs * trapa #imm
- shlr.b rs xor #imm,rd
- * shlr.w rs xor rs,rd
- * shlr.l rs * xor.w #imm,rd
- sleep * xor.w rs,rd
- stc ccr,rd * xor.l #imm,rd
- * stc ccr,@rs * xor.l rs,rd
- * stc ccr,@(disp:16,rd) xorc #imm,ccr
-
- Four H8/300 instructions (`add', `cmp', `mov', `sub') are defined
-with variants using the suffixes `.b', `.w', and `.l' to specify the
-size of a memory operand. `as' supports these suffixes, but does not
-require them; since one of the operands is always a register, `as' can
-deduce the correct size.
-
- For example, since `r0' refers to a 16-bit register,
- mov r0,@foo
-is equivalent to
- mov.w r0,@foo
-
- If you use the size suffixes, `as' issues a warning when the suffix
-and the register size do not match.
-
-
-File: as.info, Node: H8/500-Dependent, Next: HPPA-Dependent, Prev: H8/300-Dependent, Up: Machine Dependencies
-
-H8/500 Dependent Features
-=========================
-
-* Menu:
-
-* H8/500 Options:: Options
-* H8/500 Syntax:: Syntax
-* H8/500 Floating Point:: Floating Point
-* H8/500 Directives:: H8/500 Machine Directives
-* H8/500 Opcodes:: Opcodes
-
-
-File: as.info, Node: H8/500 Options, Next: H8/500 Syntax, Up: H8/500-Dependent
-
-Options
--------
-
- `as' has no additional command-line options for the Hitachi H8/500
-family.
-
-
-File: as.info, Node: H8/500 Syntax, Next: H8/500 Floating Point, Prev: H8/500 Options, Up: H8/500-Dependent
-
-Syntax
-------
-
-* Menu:
-
-* H8/500-Chars:: Special Characters
-* H8/500-Regs:: Register Names
-* H8/500-Addressing:: Addressing Modes
-
-
-File: as.info, Node: H8/500-Chars, Next: H8/500-Regs, Up: H8/500 Syntax
-
-Special Characters
-..................
-
- `!' is the line comment character.
-
- `;' can be used instead of a newline to separate statements.
-
- Since `$' has no special meaning, you may use it in symbol names.
-
-
-File: as.info, Node: H8/500-Regs, Next: H8/500-Addressing, Prev: H8/500-Chars, Up: H8/500 Syntax
-
-Register Names
-..............
-
- You can use the predefined symbols `r0', `r1', `r2', `r3', `r4',
-`r5', `r6', and `r7' to refer to the H8/500 registers.
-
- The H8/500 also has these control registers:
-
-`cp'
- code pointer
-
-`dp'
- data pointer
-
-`bp'
- base pointer
-
-`tp'
- stack top pointer
-
-`ep'
- extra pointer
-
-`sr'
- status register
-
-`ccr'
- condition code register
-
- All registers are 16 bits long. To represent 32 bit numbers, use two
-adjacent registers; for distant memory addresses, use one of the segment
-pointers (`cp' for the program counter; `dp' for `r0'-`r3'; `ep' for
-`r4' and `r5'; and `tp' for `r6' and `r7'.
-
-
-File: as.info, Node: H8/500-Addressing, Prev: H8/500-Regs, Up: H8/500 Syntax
-
-Addressing Modes
-................
-
- as understands the following addressing modes for the H8/500:
-`RN'
- Register direct
-
-`@RN'
- Register indirect
-
-`@(d:8, RN)'
- Register indirect with 8 bit signed displacement
-
-`@(d:16, RN)'
- Register indirect with 16 bit signed displacement
-
-`@-RN'
- Register indirect with pre-decrement
-
-`@RN+'
- Register indirect with post-increment
-
-`@AA:8'
- 8 bit absolute address
-
-`@AA:16'
- 16 bit absolute address
-
-`#XX:8'
- 8 bit immediate
-
-`#XX:16'
- 16 bit immediate
-
-
-File: as.info, Node: H8/500 Floating Point, Next: H8/500 Directives, Prev: H8/500 Syntax, Up: H8/500-Dependent
-
-Floating Point
---------------
-
- The H8/500 family has no hardware floating point, but the `.float'
-directive generates IEEE floating-point numbers for compatibility with
-other development tools.
-
-
-File: as.info, Node: H8/500 Directives, Next: H8/500 Opcodes, Prev: H8/500 Floating Point, Up: H8/500-Dependent
-
-H8/500 Machine Directives
--------------------------
-
- `as' has no machine-dependent directives for the H8/500. However,
-on this platform the `.int' and `.word' directives generate 16-bit
-numbers.
-
-
-File: as.info, Node: H8/500 Opcodes, Prev: H8/500 Directives, Up: H8/500-Dependent
-
-Opcodes
--------
-
- For detailed information on the H8/500 machine instruction set, see
-`H8/500 Series Programming Manual' (Hitachi M21T001).
-
- `as' implements all the standard H8/500 opcodes. No additional
-pseudo-instructions are needed on this family.
-
- The following table summarizes H8/500 opcodes and their operands:
-
- Legend:
- abs8 8-bit absolute address
- abs16 16-bit absolute address
- abs24 24-bit absolute address
- crb `ccr', `br', `ep', `dp', `tp', `dp'
- disp8 8-bit displacement
- ea `rn', `@rn', `@(d:8, rn)', `@(d:16, rn)',
- `@-rn', `@rn+', `@aa:8', `@aa:16',
- `#xx:8', `#xx:16'
- ea_mem `@rn', `@(d:8, rn)', `@(d:16, rn)',
- `@-rn', `@rn+', `@aa:8', `@aa:16'
- ea_noimm `rn', `@rn', `@(d:8, rn)', `@(d:16, rn)',
- `@-rn', `@rn+', `@aa:8', `@aa:16'
- fp r6
- imm4 4-bit immediate data
- imm8 8-bit immediate data
- imm16 16-bit immediate data
- pcrel8 8-bit offset from program counter
- pcrel16 16-bit offset from program counter
- qim `-2', `-1', `1', `2'
- rd any register
- rs a register distinct from rd
- rlist comma-separated list of registers in parentheses;
- register ranges `rd-rs' are allowed
- sp stack pointer (`r7')
- sr status register
- sz size; `.b' or `.w'. If omitted, default `.w'
-
- ldc[.b] ea,crb bcc[.w] pcrel16
- ldc[.w] ea,sr bcc[.b] pcrel8
- add[:q] sz qim,ea_noimm bhs[.w] pcrel16
- add[:g] sz ea,rd bhs[.b] pcrel8
- adds sz ea,rd bcs[.w] pcrel16
- addx sz ea,rd bcs[.b] pcrel8
- and sz ea,rd blo[.w] pcrel16
- andc[.b] imm8,crb blo[.b] pcrel8
- andc[.w] imm16,sr bne[.w] pcrel16
- bpt bne[.b] pcrel8
- bra[.w] pcrel16 beq[.w] pcrel16
- bra[.b] pcrel8 beq[.b] pcrel8
- bt[.w] pcrel16 bvc[.w] pcrel16
- bt[.b] pcrel8 bvc[.b] pcrel8
- brn[.w] pcrel16 bvs[.w] pcrel16
- brn[.b] pcrel8 bvs[.b] pcrel8
- bf[.w] pcrel16 bpl[.w] pcrel16
- bf[.b] pcrel8 bpl[.b] pcrel8
- bhi[.w] pcrel16 bmi[.w] pcrel16
- bhi[.b] pcrel8 bmi[.b] pcrel8
- bls[.w] pcrel16 bge[.w] pcrel16
- bls[.b] pcrel8 bge[.b] pcrel8
-
- blt[.w] pcrel16 mov[:g][.b] imm8,ea_mem
- blt[.b] pcrel8 mov[:g][.w] imm16,ea_mem
- bgt[.w] pcrel16 movfpe[.b] ea,rd
- bgt[.b] pcrel8 movtpe[.b] rs,ea_noimm
- ble[.w] pcrel16 mulxu sz ea,rd
- ble[.b] pcrel8 neg sz ea
- bclr sz imm4,ea_noimm nop
- bclr sz rs,ea_noimm not sz ea
- bnot sz imm4,ea_noimm or sz ea,rd
- bnot sz rs,ea_noimm orc[.b] imm8,crb
- bset sz imm4,ea_noimm orc[.w] imm16,sr
- bset sz rs,ea_noimm pjmp abs24
- bsr[.b] pcrel8 pjmp @rd
- bsr[.w] pcrel16 pjsr abs24
- btst sz imm4,ea_noimm pjsr @rd
- btst sz rs,ea_noimm prtd imm8
- clr sz ea prtd imm16
- cmp[:e][.b] imm8,rd prts
- cmp[:i][.w] imm16,rd rotl sz ea
- cmp[:g].b imm8,ea_noimm rotr sz ea
- cmp[:g][.w] imm16,ea_noimm rotxl sz ea
- Cmp[:g] sz ea,rd rotxr sz ea
- dadd rs,rd rtd imm8
- divxu sz ea,rd rtd imm16
- dsub rs,rd rts
- exts[.b] rd scb/f rs,pcrel8
- extu[.b] rd scb/ne rs,pcrel8
- jmp @rd scb/eq rs,pcrel8
- jmp @(imm8,rd) shal sz ea
- jmp @(imm16,rd) shar sz ea
- jmp abs16 shll sz ea
- jsr @rd shlr sz ea
- jsr @(imm8,rd) sleep
- jsr @(imm16,rd) stc[.b] crb,ea_noimm
- jsr abs16 stc[.w] sr,ea_noimm
- ldm @sp+,(rlist) stm (rlist),@-sp
- link fp,imm8 sub sz ea,rd
- link fp,imm16 subs sz ea,rd
- mov[:e][.b] imm8,rd subx sz ea,rd
- mov[:i][.w] imm16,rd swap[.b] rd
- mov[:l][.w] abs8,rd tas[.b] ea
- mov[:l].b abs8,rd trapa imm4
- mov[:s][.w] rs,abs8 trap/vs
- mov[:s].b rs,abs8 tst sz ea
- mov[:f][.w] @(disp8,fp),rd unlk fp
- mov[:f][.w] rs,@(disp8,fp) xch[.w] rs,rd
- mov[:f].b @(disp8,fp),rd xor sz ea,rd
- mov[:f].b rs,@(disp8,fp) xorc.b imm8,crb
- mov[:g] sz rs,ea_mem xorc.w imm16,sr
- mov[:g] sz ea,rd
-
-
-File: as.info, Node: HPPA-Dependent, Next: SH-Dependent, Prev: H8/500-Dependent, Up: Machine Dependencies
-
-HPPA Dependent Features
-=======================
-
-* Menu:
-
-* HPPA Notes:: Notes
-* HPPA Options:: Options
-* HPPA Syntax:: Syntax
-* HPPA Floating Point:: Floating Point
-* HPPA Directives:: HPPA Machine Directives
-* HPPA Opcodes:: Opcodes
-
-
-File: as.info, Node: HPPA Notes, Next: HPPA Options, Up: HPPA-Dependent
-
-Notes
------
-
- As a back end for GNU CC `as' has been throughly tested and should
-work extremely well. We have tested it only minimally on hand written
-assembly code and no one has tested it much on the assembly output from
-the HP compilers.
-
- The format of the debugging sections has changed since the original
-`as' port (version 1.3X) was released; therefore, you must rebuild all
-HPPA objects and libraries with the new assembler so that you can debug
-the final executable.
-
- The HPPA `as' port generates a small subset of the relocations
-available in the SOM and ELF object file formats. Additional relocation
-support will be added as it becomes necessary.
-
-
-File: as.info, Node: HPPA Options, Next: HPPA Syntax, Prev: HPPA Notes, Up: HPPA-Dependent
-
-Options
--------
-
- `as' has no machine-dependent command-line options for the HPPA.
-
-
-File: as.info, Node: HPPA Syntax, Next: HPPA Floating Point, Prev: HPPA Options, Up: HPPA-Dependent
-
-Syntax
-------
-
- The assembler syntax closely follows the HPPA instruction set
-reference manual; assembler directives and general syntax closely
-follow the HPPA assembly language reference manual, with a few
-noteworthy differences.
-
- First, a colon may immediately follow a label definition. This is
-simply for compatibility with how most assembly language programmers
-write code.
-
- Some obscure expression parsing problems may affect hand written
-code which uses the `spop' instructions, or code which makes significant
-use of the `!' line separator.
-
- `as' is much less forgiving about missing arguments and other
-similar oversights than the HP assembler. `as' notifies you of missing
-arguments as syntax errors; this is regarded as a feature, not a bug.
-
- Finally, `as' allows you to use an external symbol without
-explicitly importing the symbol. *Warning:* in the future this will be
-an error for HPPA targets.
-
- Special characters for HPPA targets include:
-
- `;' is the line comment character.
-
- `!' can be used instead of a newline to separate statements.
-
- Since `$' has no special meaning, you may use it in symbol names.
-
-
-File: as.info, Node: HPPA Floating Point, Next: HPPA Directives, Prev: HPPA Syntax, Up: HPPA-Dependent
-
-Floating Point
---------------
-
- The HPPA family uses IEEE floating-point numbers.
-
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info-4 b/gnu/usr.bin/binutils/gas/doc/as.info-4
deleted file mode 100644
index 734ac137dd6..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info-4
+++ /dev/null
@@ -1,1388 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: as.info, Node: HPPA Directives, Next: HPPA Opcodes, Prev: HPPA Floating Point, Up: HPPA-Dependent
-
-HPPA Assembler Directives
--------------------------
-
- `as' for the HPPA supports many additional directives for
-compatibility with the native assembler. This section describes them
-only briefly. For detailed information on HPPA-specific assembler
-directives, see `HP9000 Series 800 Assembly Language Reference Manual'
-(HP 92432-90001).
-
- `as' does *not* support the following assembler directives described
-in the HP manual:
-
- .endm .liston
- .enter .locct
- .leave .macro
- .listoff
-
- Beyond those implemented for compatibility, `as' supports one
-additional assembler directive for the HPPA: `.param'. It conveys
-register argument locations for static functions. Its syntax closely
-follows the `.export' directive.
-
- These are the additional directives in `as' for the HPPA:
-
-`.block N'
-`.blockz N'
- Reserve N bytes of storage, and initialize them to zero.
-
-`.call'
- Mark the beginning of a procedure call. Only the special case
- with *no arguments* is allowed.
-
-`.callinfo [ PARAM=VALUE, ... ] [ FLAG, ... ]'
- Specify a number of parameters and flags that define the
- environment for a procedure.
-
- PARAM may be any of `frame' (frame size), `entry_gr' (end of
- general register range), `entry_fr' (end of float register range),
- `entry_sr' (end of space register range).
-
- The values for FLAG are `calls' or `caller' (proc has
- subroutines), `no_calls' (proc does not call subroutines),
- `save_rp' (preserve return pointer), `save_sp' (proc preserves
- stack pointer), `no_unwind' (do not unwind this proc), `hpux_int'
- (proc is interrupt routine).
-
-`.code'
- Assemble into the standard section called `$TEXT$', subsection
- `$CODE$'.
-
-`.copyright "STRING"'
- In the SOM object format, insert STRING into the object code,
- marked as a copyright string.
-
-`.copyright "STRING"'
- In the ELF object format, insert STRING into the object code,
- marked as a version string.
-
-`.enter'
- Not yet supported; the assembler rejects programs containing this
- directive.
-
-`.entry'
- Mark the beginning of a procedure.
-
-`.exit'
- Mark the end of a procedure.
-
-`.export NAME [ ,TYP ] [ ,PARAM=R ]'
- Make a procedure NAME available to callers. TYP, if present, must
- be one of `absolute', `code' (ELF only, not SOM), `data', `entry',
- `data', `entry', `millicode', `plabel', `pri_prog', or `sec_prog'.
-
- PARAM, if present, provides either relocation information for the
- procedure arguments and result, or a privilege level. PARAM may be
- `argwN' (where N ranges from `0' to `3', and indicates one of four
- one-word arguments); `rtnval' (the procedure's result); or
- `priv_lev' (privilege level). For arguments or the result, R
- specifies how to relocate, and must be one of `no' (not
- relocatable), `gr' (argument is in general register), `fr' (in
- floating point register), or `fu' (upper half of float register).
- For `priv_lev', R is an integer.
-
-`.half N'
- Define a two-byte integer constant N; synonym for the portable
- `as' directive `.short'.
-
-`.import NAME [ ,TYP ]'
- Converse of `.export'; make a procedure available to call. The
- arguments use the same conventions as the first two arguments for
- `.export'.
-
-`.label NAME'
- Define NAME as a label for the current assembly location.
-
-`.leave'
- Not yet supported; the assembler rejects programs containing this
- directive.
-
-`.origin LC'
- Advance location counter to LC. Synonym for the `{No Value For
- "as"}' portable directive `.org'.
-
-`.param NAME [ ,TYP ] [ ,PARAM=R ]'
- Similar to `.export', but used for static procedures.
-
-`.proc'
- Use preceding the first statement of a procedure.
-
-`.procend'
- Use following the last statement of a procedure.
-
-`LABEL .reg EXPR'
- Synonym for `.equ'; define LABEL with the absolute expression EXPR
- as its value.
-
-`.space SECNAME [ ,PARAMS ]'
- Switch to section SECNAME, creating a new section by that name if
- necessary. You may only use PARAMS when creating a new section,
- not when switching to an existing one. SECNAME may identify a
- section by number rather than by name.
-
- If specified, the list PARAMS declares attributes of the section,
- identified by keywords. The keywords recognized are `spnum=EXP'
- (identify this section by the number EXP, an absolute expression),
- `sort=EXP' (order sections according to this sort key when linking;
- EXP is an absolute expression), `unloadable' (section contains no
- loadable data), `notdefined' (this section defined elsewhere), and
- `private' (data in this section not available to other programs).
-
-`.spnum SECNAM'
- Allocate four bytes of storage, and initialize them with the
- section number of the section named SECNAM. (You can define the
- section number with the HPPA `.space' directive.)
-
-`.string "STR"'
- Copy the characters in the string STR to the object file. *Note
- Strings: Strings, for information on escape sequences you can use
- in `as' strings.
-
- *Warning!* The HPPA version of `.string' differs from the usual
- `as' definition: it does *not* write a zero byte after copying STR.
-
-`.stringz "STR"'
- Like `.string', but appends a zero byte after copying STR to object
- file.
-
-`.subspa NAME [ ,PARAMS ]'
-`.nsubspa NAME [ ,PARAMS ]'
- Similar to `.space', but selects a subsection NAME within the
- current section. You may only specify PARAMS when you create a
- subsection (in the first instance of `.subspa' for this NAME).
-
- If specified, the list PARAMS declares attributes of the
- subsection, identified by keywords. The keywords recognized are
- `quad=EXPR' ("quadrant" for this subsection), `align=EXPR'
- (alignment for beginning of this subsection; a power of two),
- `access=EXPR' (value for "access rights" field), `sort=EXPR'
- (sorting order for this subspace in link), `code_only' (subsection
- contains only code), `unloadable' (subsection cannot be loaded
- into memory), `common' (subsection is common block), `dup_comm'
- (initialized data may have duplicate names), or `zero' (subsection
- is all zeros, do not write in object file).
-
- `.nsubspa' always creates a new subspace with the given name, even
- if one with the same name already exists.
-
-`.version "STR"'
- Write STR as version identifier in object code.
-
-
-File: as.info, Node: HPPA Opcodes, Prev: HPPA Directives, Up: HPPA-Dependent
-
-Opcodes
--------
-
- For detailed information on the HPPA machine instruction set, see
-`PA-RISC Architecture and Instruction Set Reference Manual' (HP
-09740-90039).
-
-
-File: as.info, Node: SH-Dependent, Next: i960-Dependent, Prev: HPPA-Dependent, Up: Machine Dependencies
-
-Hitachi SH Dependent Features
-=============================
-
-* Menu:
-
-* SH Options:: Options
-* SH Syntax:: Syntax
-* SH Floating Point:: Floating Point
-* SH Directives:: SH Machine Directives
-* SH Opcodes:: Opcodes
-
-
-File: as.info, Node: SH Options, Next: SH Syntax, Up: SH-Dependent
-
-Options
--------
-
- `as' has no additional command-line options for the Hitachi SH
-family.
-
-
-File: as.info, Node: SH Syntax, Next: SH Floating Point, Prev: SH Options, Up: SH-Dependent
-
-Syntax
-------
-
-* Menu:
-
-* SH-Chars:: Special Characters
-* SH-Regs:: Register Names
-* SH-Addressing:: Addressing Modes
-
-
-File: as.info, Node: SH-Chars, Next: SH-Regs, Up: SH Syntax
-
-Special Characters
-..................
-
- `!' is the line comment character.
-
- You can use `;' instead of a newline to separate statements.
-
- Since `$' has no special meaning, you may use it in symbol names.
-
-
-File: as.info, Node: SH-Regs, Next: SH-Addressing, Prev: SH-Chars, Up: SH Syntax
-
-Register Names
-..............
-
- You can use the predefined symbols `r0', `r1', `r2', `r3', `r4',
-`r5', `r6', `r7', `r8', `r9', `r10', `r11', `r12', `r13', `r14', and
-`r15' to refer to the SH registers.
-
- The SH also has these control registers:
-
-`pr'
- procedure register (holds return address)
-
-`pc'
- program counter
-
-`mach'
-`macl'
- high and low multiply accumulator registers
-
-`sr'
- status register
-
-`gbr'
- global base register
-
-`vbr'
- vector base register (for interrupt vectors)
-
-
-File: as.info, Node: SH-Addressing, Prev: SH-Regs, Up: SH Syntax
-
-Addressing Modes
-................
-
- `as' understands the following addressing modes for the SH. `RN' in
-the following refers to any of the numbered registers, but *not* the
-control registers.
-
-`RN'
- Register direct
-
-`@RN'
- Register indirect
-
-`@-RN'
- Register indirect with pre-decrement
-
-`@RN+'
- Register indirect with post-increment
-
-`@(DISP, RN)'
- Register indirect with displacement
-
-`@(R0, RN)'
- Register indexed
-
-`@(DISP, GBR)'
- `GBR' offset
-
-`@(R0, GBR)'
- GBR indexed
-
-`ADDR'
-`@(DISP, PC)'
- PC relative address (for branch or for addressing memory). The
- `as' implementation allows you to use the simpler form ADDR
- anywhere a PC relative address is called for; the alternate form
- is supported for compatibility with other assemblers.
-
-`#IMM'
- Immediate data
-
-
-File: as.info, Node: SH Floating Point, Next: SH Directives, Prev: SH Syntax, Up: SH-Dependent
-
-Floating Point
---------------
-
- The SH family has no hardware floating point, but the `.float'
-directive generates IEEE floating-point numbers for compatibility with
-other development tools.
-
-
-File: as.info, Node: SH Directives, Next: SH Opcodes, Prev: SH Floating Point, Up: SH-Dependent
-
-SH Machine Directives
----------------------
-
- `as' has no machine-dependent directives for the SH.
-
-
-File: as.info, Node: SH Opcodes, Prev: SH Directives, Up: SH-Dependent
-
-Opcodes
--------
-
- For detailed information on the SH machine instruction set, see
-`SH-Microcomputer User's Manual' (Hitachi Micro Systems, Inc.).
-
- `as' implements all the standard SH opcodes. No additional
-pseudo-instructions are needed on this family. Note, however, that
-because `as' supports a simpler form of PC-relative addressing, you may
-simply write (for example)
-
- mov.l bar,r0
-
-where other assemblers might require an explicit displacement to `bar'
-from the program counter:
-
- mov.l @(DISP, PC)
-
- Here is a summary of SH opcodes:
-
- Legend:
- Rn a numbered register
- Rm another numbered register
- #imm immediate data
- disp displacement
- disp8 8-bit displacement
- disp12 12-bit displacement
-
- add #imm,Rn lds.l @Rn+,PR
- add Rm,Rn mac.w @Rm+,@Rn+
- addc Rm,Rn mov #imm,Rn
- addv Rm,Rn mov Rm,Rn
- and #imm,R0 mov.b Rm,@(R0,Rn)
- and Rm,Rn mov.b Rm,@-Rn
- and.b #imm,@(R0,GBR) mov.b Rm,@Rn
- bf disp8 mov.b @(disp,Rm),R0
- bra disp12 mov.b @(disp,GBR),R0
- bsr disp12 mov.b @(R0,Rm),Rn
- bt disp8 mov.b @Rm+,Rn
- clrmac mov.b @Rm,Rn
- clrt mov.b R0,@(disp,Rm)
- cmp/eq #imm,R0 mov.b R0,@(disp,GBR)
- cmp/eq Rm,Rn mov.l Rm,@(disp,Rn)
- cmp/ge Rm,Rn mov.l Rm,@(R0,Rn)
- cmp/gt Rm,Rn mov.l Rm,@-Rn
- cmp/hi Rm,Rn mov.l Rm,@Rn
- cmp/hs Rm,Rn mov.l @(disp,Rn),Rm
- cmp/pl Rn mov.l @(disp,GBR),R0
- cmp/pz Rn mov.l @(disp,PC),Rn
- cmp/str Rm,Rn mov.l @(R0,Rm),Rn
- div0s Rm,Rn mov.l @Rm+,Rn
- div0u mov.l @Rm,Rn
- div1 Rm,Rn mov.l R0,@(disp,GBR)
- exts.b Rm,Rn mov.w Rm,@(R0,Rn)
- exts.w Rm,Rn mov.w Rm,@-Rn
- extu.b Rm,Rn mov.w Rm,@Rn
- extu.w Rm,Rn mov.w @(disp,Rm),R0
- jmp @Rn mov.w @(disp,GBR),R0
- jsr @Rn mov.w @(disp,PC),Rn
- ldc Rn,GBR mov.w @(R0,Rm),Rn
- ldc Rn,SR mov.w @Rm+,Rn
- ldc Rn,VBR mov.w @Rm,Rn
- ldc.l @Rn+,GBR mov.w R0,@(disp,Rm)
- ldc.l @Rn+,SR mov.w R0,@(disp,GBR)
- ldc.l @Rn+,VBR mova @(disp,PC),R0
- lds Rn,MACH movt Rn
- lds Rn,MACL muls Rm,Rn
- lds Rn,PR mulu Rm,Rn
- lds.l @Rn+,MACH neg Rm,Rn
- lds.l @Rn+,MACL negc Rm,Rn
-
- nop stc VBR,Rn
- not Rm,Rn stc.l GBR,@-Rn
- or #imm,R0 stc.l SR,@-Rn
- or Rm,Rn stc.l VBR,@-Rn
- or.b #imm,@(R0,GBR) sts MACH,Rn
- rotcl Rn sts MACL,Rn
- rotcr Rn sts PR,Rn
- rotl Rn sts.l MACH,@-Rn
- rotr Rn sts.l MACL,@-Rn
- rte sts.l PR,@-Rn
- rts sub Rm,Rn
- sett subc Rm,Rn
- shal Rn subv Rm,Rn
- shar Rn swap.b Rm,Rn
- shll Rn swap.w Rm,Rn
- shll16 Rn tas.b @Rn
- shll2 Rn trapa #imm
- shll8 Rn tst #imm,R0
- shlr Rn tst Rm,Rn
- shlr16 Rn tst.b #imm,@(R0,GBR)
- shlr2 Rn xor #imm,R0
- shlr8 Rn xor Rm,Rn
- sleep xor.b #imm,@(R0,GBR)
- stc GBR,Rn xtrct Rm,Rn
- stc SR,Rn
-
-
-File: as.info, Node: i960-Dependent, Next: M68K-Dependent, Prev: SH-Dependent, Up: Machine Dependencies
-
-Intel 80960 Dependent Features
-==============================
-
-* Menu:
-
-* Options-i960:: i960 Command-line Options
-* Floating Point-i960:: Floating Point
-* Directives-i960:: i960 Machine Directives
-* Opcodes for i960:: i960 Opcodes
-
-
-File: as.info, Node: Options-i960, Next: Floating Point-i960, Up: i960-Dependent
-
-i960 Command-line Options
--------------------------
-
-`-ACA | -ACA_A | -ACB | -ACC | -AKA | -AKB | -AKC | -AMC'
- Select the 80960 architecture. Instructions or features not
- supported by the selected architecture cause fatal errors.
-
- `-ACA' is equivalent to `-ACA_A'; `-AKC' is equivalent to `-AMC'.
- Synonyms are provided for compatibility with other tools.
-
- If you do not specify any of these options, `as' generates code
- for any instruction or feature that is supported by *some* version
- of the 960 (even if this means mixing architectures!). In
- principle, `as' attempts to deduce the minimal sufficient
- processor type if none is specified; depending on the object code
- format, the processor type may be recorded in the object file. If
- it is critical that the `as' output match a specific architecture,
- specify that architecture explicitly.
-
-`-b'
- Add code to collect information about conditional branches taken,
- for later optimization using branch prediction bits. (The
- conditional branch instructions have branch prediction bits in the
- CA, CB, and CC architectures.) If BR represents a conditional
- branch instruction, the following represents the code generated by
- the assembler when `-b' is specified:
-
- call INCREMENT ROUTINE
- .word 0 # pre-counter
- Label: BR
- call INCREMENT ROUTINE
- .word 0 # post-counter
-
- The counter following a branch records the number of times that
- branch was *not* taken; the differenc between the two counters is
- the number of times the branch *was* taken.
-
- A table of every such `Label' is also generated, so that the
- external postprocessor `gbr960' (supplied by Intel) can locate all
- the counters. This table is always labelled `__BRANCH_TABLE__';
- this is a local symbol to permit collecting statistics for many
- separate object files. The table is word aligned, and begins with
- a two-word header. The first word, initialized to 0, is used in
- maintaining linked lists of branch tables. The second word is a
- count of the number of entries in the table, which follow
- immediately: each is a word, pointing to one of the labels
- illustrated above.
-
- +------------+------------+------------+ ... +------------+
- | | | | | |
- | *NEXT | COUNT: N | *BRLAB 1 | | *BRLAB N |
- | | | | | |
- +------------+------------+------------+ ... +------------+
-
- __BRANCH_TABLE__ layout
-
- The first word of the header is used to locate multiple branch
- tables, since each object file may contain one. Normally the links
- are maintained with a call to an initialization routine, placed at
- the beginning of each function in the file. The GNU C compiler
- generates these calls automatically when you give it a `-b' option.
- For further details, see the documentation of `gbr960'.
-
-`-no-relax'
- Normally, Compare-and-Branch instructions with targets that require
- displacements greater than 13 bits (or that have external targets)
- are replaced with the corresponding compare (or `chkbit') and
- branch instructions. You can use the `-no-relax' option to
- specify that `as' should generate errors instead, if the target
- displacement is larger than 13 bits.
-
- This option does not affect the Compare-and-Jump instructions; the
- code emitted for them is *always* adjusted when necessary
- (depending on displacement size), regardless of whether you use
- `-no-relax'.
-
-
-File: as.info, Node: Floating Point-i960, Next: Directives-i960, Prev: Options-i960, Up: i960-Dependent
-
-Floating Point
---------------
-
- `as' generates IEEE floating-point numbers for the directives
-`.float', `.double', `.extended', and `.single'.
-
-
-File: as.info, Node: Directives-i960, Next: Opcodes for i960, Prev: Floating Point-i960, Up: i960-Dependent
-
-i960 Machine Directives
------------------------
-
-`.bss SYMBOL, LENGTH, ALIGN'
- Reserve LENGTH bytes in the bss section for a local SYMBOL,
- aligned to the power of two specified by ALIGN. LENGTH and ALIGN
- must be positive absolute expressions. This directive differs
- from `.lcomm' only in that it permits you to specify an alignment.
- *Note `.lcomm': Lcomm.
-
-`.extended FLONUMS'
- `.extended' expects zero or more flonums, separated by commas; for
- each flonum, `.extended' emits an IEEE extended-format (80-bit)
- floating-point number.
-
-`.leafproc CALL-LAB, BAL-LAB'
- You can use the `.leafproc' directive in conjunction with the
- optimized `callj' instruction to enable faster calls of leaf
- procedures. If a procedure is known to call no other procedures,
- you may define an entry point that skips procedure prolog code
- (and that does not depend on system-supplied saved context), and
- declare it as the BAL-LAB using `.leafproc'. If the procedure
- also has an entry point that goes through the normal prolog, you
- can specify that entry point as CALL-LAB.
-
- A `.leafproc' declaration is meant for use in conjunction with the
- optimized call instruction `callj'; the directive records the data
- needed later to choose between converting the `callj' into a `bal'
- or a `call'.
-
- CALL-LAB is optional; if only one argument is present, or if the
- two arguments are identical, the single argument is assumed to be
- the `bal' entry point.
-
-`.sysproc NAME, INDEX'
- The `.sysproc' directive defines a name for a system procedure.
- After you define it using `.sysproc', you can use NAME to refer to
- the system procedure identified by INDEX when calling procedures
- with the optimized call instruction `callj'.
-
- Both arguments are required; INDEX must be between 0 and 31
- (inclusive).
-
-
-File: as.info, Node: Opcodes for i960, Prev: Directives-i960, Up: i960-Dependent
-
-i960 Opcodes
-------------
-
- All Intel 960 machine instructions are supported; *note i960
-Command-line Options: Options-i960. for a discussion of selecting the
-instruction subset for a particular 960 architecture.
-
- Some opcodes are processed beyond simply emitting a single
-corresponding instruction: `callj', and Compare-and-Branch or
-Compare-and-Jump instructions with target displacements larger than 13
-bits.
-
-* Menu:
-
-* callj-i960:: `callj'
-* Compare-and-branch-i960:: Compare-and-Branch
-
-
-File: as.info, Node: callj-i960, Next: Compare-and-branch-i960, Up: Opcodes for i960
-
-`callj'
-.......
-
- You can write `callj' to have the assembler or the linker determine
-the most appropriate form of subroutine call: `call', `bal', or
-`calls'. If the assembly source contains enough information--a
-`.leafproc' or `.sysproc' directive defining the operand--then `as'
-translates the `callj'; if not, it simply emits the `callj', leaving it
-for the linker to resolve.
-
-
-File: as.info, Node: Compare-and-branch-i960, Prev: callj-i960, Up: Opcodes for i960
-
-Compare-and-Branch
-..................
-
- The 960 architectures provide combined Compare-and-Branch
-instructions that permit you to store the branch target in the lower 13
-bits of the instruction word itself. However, if you specify a branch
-target far enough away that its address won't fit in 13 bits, the
-assembler can either issue an error, or convert your Compare-and-Branch
-instruction into separate instructions to do the compare and the branch.
-
- Whether `as' gives an error or expands the instruction depends on
-two choices you can make: whether you use the `-no-relax' option, and
-whether you use a "Compare and Branch" instruction or a "Compare and
-Jump" instruction. The "Jump" instructions are *always* expanded if
-necessary; the "Branch" instructions are expanded when necessary
-*unless* you specify `-no-relax'--in which case `as' gives an error
-instead.
-
- These are the Compare-and-Branch instructions, their "Jump" variants,
-and the instruction pairs they may expand into:
-
- Compare and
- Branch Jump Expanded to
- ------ ------ ------------
- bbc chkbit; bno
- bbs chkbit; bo
- cmpibe cmpije cmpi; be
- cmpibg cmpijg cmpi; bg
- cmpibge cmpijge cmpi; bge
- cmpibl cmpijl cmpi; bl
- cmpible cmpijle cmpi; ble
- cmpibno cmpijno cmpi; bno
- cmpibne cmpijne cmpi; bne
- cmpibo cmpijo cmpi; bo
- cmpobe cmpoje cmpo; be
- cmpobg cmpojg cmpo; bg
- cmpobge cmpojge cmpo; bge
- cmpobl cmpojl cmpo; bl
- cmpoble cmpojle cmpo; ble
- cmpobne cmpojne cmpo; bne
-
-
-File: as.info, Node: M68K-Dependent, Next: Sparc-Dependent, Prev: i960-Dependent, Up: Machine Dependencies
-
-M680x0 Dependent Features
-=========================
-
-* Menu:
-
-* M68K-Opts:: M680x0 Options
-* M68K-Syntax:: Syntax
-* M68K-Moto-Syntax:: Motorola Syntax
-* M68K-Float:: Floating Point
-* M68K-Directives:: 680x0 Machine Directives
-* M68K-opcodes:: Opcodes
-
-
-File: as.info, Node: M68K-Opts, Next: M68K-Syntax, Up: M68K-Dependent
-
-M680x0 Options
---------------
-
- The Motorola 680x0 version of `as' has a few machine dependent
-options.
-
- You can use the `-l' option to shorten the size of references to
-undefined symbols. If you do not use the `-l' option, references to
-undefined symbols are wide enough for a full `long' (32 bits). (Since
-`as' cannot know where these symbols end up, `as' can only allocate
-space for the linker to fill in later. Since `as' does not know how
-far away these symbols are, it allocates as much space as it can.) If
-you use this option, the references are only one word wide (16 bits).
-This may be useful if you want the object file to be as small as
-possible, and you know that the relevant symbols are always less than
-17 bits away.
-
- For some configurations, especially those where the compiler normally
-does not prepend an underscore to the names of user variables, the
-assembler requires a `%' before any use of a register name. This is
-intended to let the assembler distinguish between C variables and
-functions named `a0' through `a7', and so on. The `%' is always
-accepted, but is not required for certain configurations, notably
-`sun3'. The `--register-prefix-optional' option may be used to permit
-omitting the `%' even for configurations for which it is normally
-required. If this is done, it will generally be impossible to refer to
-C variables and functions with the same names as register names.
-
- `as' can assemble code for several different members of the Motorola
-680x0 family. The default depends upon how `as' was configured when it
-was built; normally, the default is to assemble code for the 68020
-microprocessor. The following options may be used to change the
-default. These options control which instructions and addressing modes
-are permitted. The members of the 680x0 family are very similar. For
-detailed information about the differences, see the Motorola manuals.
-
-`-m68000'
-`-m68008'
-`-m68302'
- Assemble for the 68000. `-m68008' and `-m68302' are synonyms for
- `-m68000', since the chips are the same from the point of view of
- the assembler.
-
-`-m68010'
- Assemble for the 68010.
-
-`-m68020'
- Assemble for the 68020. This is normally the default.
-
-`-m68030'
- Assemble for the 68030.
-
-`-m68040'
- Assemble for the 68040.
-
-`-m68060'
- Assemble for the 68060.
-
-`-mcpu32'
-`-m68331'
-`-m68332'
-`-m68333'
-`-m68340'
-`-m68360'
- Assemble for the CPU32 family of chips.
-
-`-m68881'
-`-m68882'
- Assemble 68881 floating point instructions. This is the default
- for the 68020, 68030, and the CPU32. The 68040 and 68060 always
- support floating point instructions.
-
-`-mno-68881'
- Do not assemble 68881 floating point instructions. This is the
- default for 68000 and the 68010. The 68040 and 68060 always
- support floating point instructions, even if this option is used.
-
-`-m68851'
- Assemble 68851 MMU instructions. This is the default for the
- 68020, 68030, and 68060. The 68040 accepts a somewhat different
- set of MMU instructions; `-m68851' and `-m68040' should not be used
- together.
-
-`-mno-68851'
- Do not assemble 68851 MMU instructions. This is the default for
- the 68000, 68010, and the CPU32. The 68040 accepts a somewhat
- different set of MMU instructions.
-
-
-File: as.info, Node: M68K-Syntax, Next: M68K-Moto-Syntax, Prev: M68K-Opts, Up: M68K-Dependent
-
-Syntax
-------
-
- This syntax for the Motorola 680x0 was developed at MIT.
-
- The 680x0 version of `as' uses instructions names and syntax
-compatible with the Sun assembler. Intervening periods are ignored;
-for example, `movl' is equivalent to `mov.l'.
-
- In the following table APC stands for any of the address registers
-(`%a0' through `%a7'), the program counter (`%pc'), the zero-address
-relative to the program counter (`%zpc'), a suppressed address register
-(`%za0' through `%za7'), or it may be omitted entirely. The use of
-SIZE means one of `w' or `l', and it may be omitted, along with the
-leading colon, unless a scale is also specified. The use of SCALE
-means one of `1', `2', `4', or `8', and it may always be omitted along
-with the leading colon.
-
- The following addressing modes are understood:
-"Immediate"
- `#NUMBER'
-
-"Data Register"
- `%d0' through `%d7'
-
-"Address Register"
- `%a0' through `%a7'
- `%a7' is also known as `%sp', i.e. the Stack Pointer. `%a6' is
- also known as `%fp', the Frame Pointer.
-
-"Address Register Indirect"
- `%a0@' through `%a7@'
-
-"Address Register Postincrement"
- `%a0@+' through `%a7@+'
-
-"Address Register Predecrement"
- `%a0@-' through `%a7@-'
-
-"Indirect Plus Offset"
- `APC@(NUMBER)'
-
-"Index"
- `APC@(NUMBER,REGISTER:SIZE:SCALE)'
-
- The NUMBER may be omitted.
-
-"Postindex"
- `APC@(NUMBER)@(ONUMBER,REGISTER:SIZE:SCALE)'
-
- The ONUMBER or the REGISTER, but not both, may be omitted.
-
-"Preindex"
- `APC@(NUMBER,REGISTER:SIZE:SCALE)@(ONUMBER)'
-
- The NUMBER may be omitted. Omitting the REGISTER produces the
- Postindex addressing mode.
-
-"Absolute"
- `SYMBOL', or `DIGITS', optionally followed by `:b', `:w', or `:l'.
-
-
-File: as.info, Node: M68K-Moto-Syntax, Next: M68K-Float, Prev: M68K-Syntax, Up: M68K-Dependent
-
-Motorola Syntax
----------------
-
- The standard Motorola syntax for this chip differs from the syntax
-already discussed (*note Syntax: M68K-Syntax.). `as' can accept
-Motorola syntax for operands, even if MIT syntax is used for other
-operands in the same instruction. The two kinds of syntax are fully
-compatible.
-
- In the following table APC stands for any of the address registers
-(`%a0' through `%a7'), the program counter (`%pc'), the zero-address
-relative to the program counter (`%zpc'), or a suppressed address
-register (`%za0' through `%za7'). The use of SIZE means one of `w' or
-`l', and it may always be omitted along with the leading dot. The use
-of SCALE means one of `1', `2', `4', or `8', and it may always be
-omitted along with the leading asterisk.
-
- The following additional addressing modes are understood:
-
-"Address Register Indirect"
- `(%a0)' through `(%a7)'
- `%a7' is also known as `%sp', i.e. the Stack Pointer. `%a6' is
- also known as `%fp', the Frame Pointer.
-
-"Address Register Postincrement"
- `(%a0)+' through `(%a7)+'
-
-"Address Register Predecrement"
- `-(%a0)' through `-(%a7)'
-
-"Indirect Plus Offset"
- `NUMBER(%A0)' through `NUMBER(%A7)', or `NUMBER(%PC)'.
-
- The NUMBER may also appear within the parentheses, as in
- `(NUMBER,%A0)'. When used with the PC, the NUMBER may be omitted
- (with an address register, omitting the NUMBER produces Address
- Register Indirect mode).
-
-"Index"
- `NUMBER(APC,REGISTER.SIZE*SCALE)'
-
- The NUMBER may be omitted, or it may appear within the
- parentheses. The APC may be omitted. The REGISTER and the APC
- may appear in either order. If both APC and REGISTER are address
- registers, and the SIZE and SCALE are omitted, then the first
- register is taken as the base register, and the second as the
- index register.
-
-"Postindex"
- `([NUMBER,APC],REGISTER.SIZE*SCALE,ONUMBER)'
-
- The ONUMBER, or the REGISTER, or both, may be omitted. Either the
- NUMBER or the APC may be omitted, but not both.
-
-"Preindex"
- `([NUMBER,APC,REGISTER.SIZE*SCALE],ONUMBER)'
-
- The NUMBER, or the APC, or the REGISTER, or any two of them, may
- be omitted. The ONUMBER may be omitted. The REGISTER and the APC
- may appear in either order. If both APC and REGISTER are address
- registers, and the SIZE and SCALE are omitted, then the first
- register is taken as the base register, and the second as the
- index register.
-
-
-File: as.info, Node: M68K-Float, Next: M68K-Directives, Prev: M68K-Moto-Syntax, Up: M68K-Dependent
-
-Floating Point
---------------
-
- Packed decimal (P) format floating literals are not supported. Feel
-free to add the code!
-
- The floating point formats generated by directives are these.
-
-`.float'
- `Single' precision floating point constants.
-
-`.double'
- `Double' precision floating point constants.
-
- There is no directive to produce regions of memory holding extended
-precision numbers, however they can be used as immediate operands to
-floating-point instructions. Adding a directive to create extended
-precision numbers would not be hard, but it has not yet seemed
-necessary.
-
-
-File: as.info, Node: M68K-Directives, Next: M68K-opcodes, Prev: M68K-Float, Up: M68K-Dependent
-
-680x0 Machine Directives
-------------------------
-
- In order to be compatible with the Sun assembler the 680x0 assembler
-understands the following directives.
-
-`.data1'
- This directive is identical to a `.data 1' directive.
-
-`.data2'
- This directive is identical to a `.data 2' directive.
-
-`.even'
- This directive is a special case of the `.align' directive; it
- aligns the output to an even byte boundary.
-
-`.skip'
- This directive is identical to a `.space' directive.
-
-
-File: as.info, Node: M68K-opcodes, Prev: M68K-Directives, Up: M68K-Dependent
-
-Opcodes
--------
-
-* Menu:
-
-* M68K-Branch:: Branch Improvement
-* M68K-Chars:: Special Characters
-
-
-File: as.info, Node: M68K-Branch, Next: M68K-Chars, Up: M68K-opcodes
-
-Branch Improvement
-..................
-
- Certain pseudo opcodes are permitted for branch instructions. They
-expand to the shortest branch instruction that reach the target.
-Generally these mnemonics are made by substituting `j' for `b' at the
-start of a Motorola mnemonic.
-
- The following table summarizes the pseudo-operations. A `*' flags
-cases that are more fully described after the table:
-
- Displacement
- +-------------------------------------------------
- | 68020 68000/10
- Pseudo-Op |BYTE WORD LONG LONG non-PC relative
- +-------------------------------------------------
- jbsr |bsrs bsr bsrl jsr jsr
- jra |bras bra bral jmp jmp
- * jXX |bXXs bXX bXXl bNXs;jmpl bNXs;jmp
- * dbXX |dbXX dbXX dbXX; bra; jmpl
- * fjXX |fbXXw fbXXw fbXXl fbNXw;jmp
-
- XX: condition
- NX: negative of condition XX
-
- `*'--see full description below
-
-`jbsr'
-`jra'
- These are the simplest jump pseudo-operations; they always map to
- one particular machine instruction, depending on the displacement
- to the branch target.
-
-`jXX'
- Here, `jXX' stands for an entire family of pseudo-operations,
- where XX is a conditional branch or condition-code test. The full
- list of pseudo-ops in this family is:
- jhi jls jcc jcs jne jeq jvc
- jvs jpl jmi jge jlt jgt jle
-
- For the cases of non-PC relative displacements and long
- displacements on the 68000 or 68010, `as' issues a longer code
- fragment in terms of NX, the opposite condition to XX. For
- example, for the non-PC relative case:
- jXX foo
- gives
- bNXs oof
- jmp foo
- oof:
-
-`dbXX'
- The full family of pseudo-operations covered here is
- dbhi dbls dbcc dbcs dbne dbeq dbvc
- dbvs dbpl dbmi dbge dblt dbgt dble
- dbf dbra dbt
-
- Other than for word and byte displacements, when the source reads
- `dbXX foo', `as' emits
- dbXX oo1
- bra oo2
- oo1:jmpl foo
- oo2:
-
-`fjXX'
- This family includes
- fjne fjeq fjge fjlt fjgt fjle fjf
- fjt fjgl fjgle fjnge fjngl fjngle fjngt
- fjnle fjnlt fjoge fjogl fjogt fjole fjolt
- fjor fjseq fjsf fjsne fjst fjueq fjuge
- fjugt fjule fjult fjun
-
- For branch targets that are not PC relative, `as' emits
- fbNX oof
- jmp foo
- oof:
- when it encounters `fjXX foo'.
-
-
-File: as.info, Node: M68K-Chars, Prev: M68K-Branch, Up: M68K-opcodes
-
-Special Characters
-..................
-
- The immediate character is `#' for Sun compatibility. The
-line-comment character is `|'. If a `#' appears at the beginning of a
-line, it is treated as a comment unless it looks like `# line file', in
-which case it is treated normally.
-
-
-File: as.info, Node: Sparc-Dependent, Next: Z8000-Dependent, Prev: M68K-Dependent, Up: Machine Dependencies
-
-SPARC Dependent Features
-========================
-
-* Menu:
-
-* Sparc-Opts:: Options
-* Sparc-Float:: Floating Point
-* Sparc-Directives:: Sparc Machine Directives
-
-
-File: as.info, Node: Sparc-Opts, Next: Sparc-Float, Up: Sparc-Dependent
-
-Options
--------
-
- The SPARC chip family includes several successive levels (or other
-variants) of chip, using the same core instruction set, but including a
-few additional instructions at each level.
-
- By default, `as' assumes the core instruction set (SPARC v6), but
-"bumps" the architecture level as needed: it switches to successively
-higher architectures as it encounters instructions that only exist in
-the higher levels.
-
-`-Av6 | -Av7 | -Av8 | -Av9 | -Asparclite'
- Use one of the `-A' options to select one of the SPARC
- architectures explicitly. If you select an architecture
- explicitly, `as' reports a fatal error if it encounters an
- instruction or feature requiring a higher level.
-
-`-bump'
- Permit the assembler to "bump" the architecture level as required,
- but warn whenever it is necessary to switch to another level.
-
-
-File: as.info, Node: Sparc-Float, Next: Sparc-Directives, Prev: Sparc-Opts, Up: Sparc-Dependent
-
-Floating Point
---------------
-
- The Sparc uses IEEE floating-point numbers.
-
-
-File: as.info, Node: Sparc-Directives, Prev: Sparc-Float, Up: Sparc-Dependent
-
-Sparc Machine Directives
-------------------------
-
- The Sparc version of `as' supports the following additional machine
-directives:
-
-`.align'
- This must be followed by the desired alignment in bytes.
-
-`.common'
- This must be followed by a symbol name, a positive number, and
- `"bss"'. This behaves somewhat like `.comm', but the syntax is
- different.
-
-`.half'
- This is functionally identical to `.short'.
-
-`.proc'
- This directive is ignored. Any text following it on the same line
- is also ignored.
-
-`.reserve'
- This must be followed by a symbol name, a positive number, and
- `"bss"'. This behaves somewhat like `.lcomm', but the syntax is
- different.
-
-`.seg'
- This must be followed by `"text"', `"data"', or `"data1"'. It
- behaves like `.text', `.data', or `.data 1'.
-
-`.skip'
- This is functionally identical to the `.space' directive.
-
-`.word'
- On the Sparc, the `.word' directive produces 32 bit values,
- instead of the 16 bit values it produces on many other machines.
-
-`.xword'
- On the Sparc V9 processor, the `.xword' directive produces 64 bit
- values.
-
-
-File: as.info, Node: i386-Dependent, Prev: MIPS-Dependent, Up: Machine Dependencies
-
-80386 Dependent Features
-========================
-
-* Menu:
-
-* i386-Options:: Options
-* i386-Syntax:: AT&T Syntax versus Intel Syntax
-* i386-Opcodes:: Opcode Naming
-* i386-Regs:: Register Naming
-* i386-prefixes:: Opcode Prefixes
-* i386-Memory:: Memory References
-* i386-jumps:: Handling of Jump Instructions
-* i386-Float:: Floating Point
-* i386-16bit:: Writing 16-bit Code
-* i386-Notes:: Notes
-
-
-File: as.info, Node: i386-Options, Next: i386-Syntax, Up: i386-Dependent
-
-Options
--------
-
- The 80386 has no machine dependent options.
-
-
-File: as.info, Node: i386-Syntax, Next: i386-Opcodes, Prev: i386-Options, Up: i386-Dependent
-
-AT&T Syntax versus Intel Syntax
--------------------------------
-
- In order to maintain compatibility with the output of `gcc', `as'
-supports AT&T System V/386 assembler syntax. This is quite different
-from Intel syntax. We mention these differences because almost all
-80386 documents used only Intel syntax. Notable differences between
-the two syntaxes are:
-
- * AT&T immediate operands are preceded by `$'; Intel immediate
- operands are undelimited (Intel `push 4' is AT&T `pushl $4').
- AT&T register operands are preceded by `%'; Intel register operands
- are undelimited. AT&T absolute (as opposed to PC relative)
- jump/call operands are prefixed by `*'; they are undelimited in
- Intel syntax.
-
- * AT&T and Intel syntax use the opposite order for source and
- destination operands. Intel `add eax, 4' is `addl $4, %eax'. The
- `source, dest' convention is maintained for compatibility with
- previous Unix assemblers.
-
- * In AT&T syntax the size of memory operands is determined from the
- last character of the opcode name. Opcode suffixes of `b', `w',
- and `l' specify byte (8-bit), word (16-bit), and long (32-bit)
- memory references. Intel syntax accomplishes this by prefixes
- memory operands (*not* the opcodes themselves) with `byte ptr',
- `word ptr', and `dword ptr'. Thus, Intel `mov al, byte ptr FOO'
- is `movb FOO, %al' in AT&T syntax.
-
- * Immediate form long jumps and calls are `lcall/ljmp $SECTION,
- $OFFSET' in AT&T syntax; the Intel syntax is `call/jmp far
- SECTION:OFFSET'. Also, the far return instruction is `lret
- $STACK-ADJUST' in AT&T syntax; Intel syntax is `ret far
- STACK-ADJUST'.
-
- * The AT&T assembler does not provide support for multiple section
- programs. Unix style systems expect all programs to be single
- sections.
-
-
-File: as.info, Node: i386-Opcodes, Next: i386-Regs, Prev: i386-Syntax, Up: i386-Dependent
-
-Opcode Naming
--------------
-
- Opcode names are suffixed with one character modifiers which specify
-the size of operands. The letters `b', `w', and `l' specify byte,
-word, and long operands. If no suffix is specified by an instruction
-and it contains no memory operands then `as' tries to fill in the
-missing suffix based on the destination register operand (the last one
-by convention). Thus, `mov %ax, %bx' is equivalent to `movw %ax, %bx';
-also, `mov $1, %bx' is equivalent to `movw $1, %bx'. Note that this is
-incompatible with the AT&T Unix assembler which assumes that a missing
-opcode suffix implies long operand size. (This incompatibility does
-not affect compiler output since compilers always explicitly specify
-the opcode suffix.)
-
- Almost all opcodes have the same names in AT&T and Intel format.
-There are a few exceptions. The sign extend and zero extend
-instructions need two sizes to specify them. They need a size to
-sign/zero extend *from* and a size to zero extend *to*. This is
-accomplished by using two opcode suffixes in AT&T syntax. Base names
-for sign extend and zero extend are `movs...' and `movz...' in AT&T
-syntax (`movsx' and `movzx' in Intel syntax). The opcode suffixes are
-tacked on to this base name, the *from* suffix before the *to* suffix.
-Thus, `movsbl %al, %edx' is AT&T syntax for "move sign extend *from*
-%al *to* %edx." Possible suffixes, thus, are `bl' (from byte to long),
-`bw' (from byte to word), and `wl' (from word to long).
-
- The Intel-syntax conversion instructions
-
- * `cbw' -- sign-extend byte in `%al' to word in `%ax',
-
- * `cwde' -- sign-extend word in `%ax' to long in `%eax',
-
- * `cwd' -- sign-extend word in `%ax' to long in `%dx:%ax',
-
- * `cdq' -- sign-extend dword in `%eax' to quad in `%edx:%eax',
-
-are called `cbtw', `cwtl', `cwtd', and `cltd' in AT&T naming. `as'
-accepts either naming for these instructions.
-
- Far call/jump instructions are `lcall' and `ljmp' in AT&T syntax,
-but are `call far' and `jump far' in Intel convention.
-
-
-File: as.info, Node: i386-Regs, Next: i386-prefixes, Prev: i386-Opcodes, Up: i386-Dependent
-
-Register Naming
----------------
-
- Register operands are always prefixes with `%'. The 80386 registers
-consist of
-
- * the 8 32-bit registers `%eax' (the accumulator), `%ebx', `%ecx',
- `%edx', `%edi', `%esi', `%ebp' (the frame pointer), and `%esp'
- (the stack pointer).
-
- * the 8 16-bit low-ends of these: `%ax', `%bx', `%cx', `%dx', `%di',
- `%si', `%bp', and `%sp'.
-
- * the 8 8-bit registers: `%ah', `%al', `%bh', `%bl', `%ch', `%cl',
- `%dh', and `%dl' (These are the high-bytes and low-bytes of `%ax',
- `%bx', `%cx', and `%dx')
-
- * the 6 section registers `%cs' (code section), `%ds' (data
- section), `%ss' (stack section), `%es', `%fs', and `%gs'.
-
- * the 3 processor control registers `%cr0', `%cr2', and `%cr3'.
-
- * the 6 debug registers `%db0', `%db1', `%db2', `%db3', `%db6', and
- `%db7'.
-
- * the 2 test registers `%tr6' and `%tr7'.
-
- * the 8 floating point register stack `%st' or equivalently
- `%st(0)', `%st(1)', `%st(2)', `%st(3)', `%st(4)', `%st(5)',
- `%st(6)', and `%st(7)'.
-
-
-File: as.info, Node: i386-prefixes, Next: i386-Memory, Prev: i386-Regs, Up: i386-Dependent
-
-Opcode Prefixes
----------------
-
- Opcode prefixes are used to modify the following opcode. They are
-used to repeat string instructions, to provide section overrides, to
-perform bus lock operations, and to give operand and address size
-(16-bit operands are specified in an instruction by prefixing what would
-normally be 32-bit operands with a "operand size" opcode prefix).
-Opcode prefixes are usually given as single-line instructions with no
-operands, and must directly precede the instruction they act upon. For
-example, the `scas' (scan string) instruction is repeated with:
- repne
- scas
-
- Here is a list of opcode prefixes:
-
- * Section override prefixes `cs', `ds', `ss', `es', `fs', `gs'.
- These are automatically added by specifying using the
- SECTION:MEMORY-OPERAND form for memory references.
-
- * Operand/Address size prefixes `data16' and `addr16' change 32-bit
- operands/addresses into 16-bit operands/addresses. Note that
- 16-bit addressing modes (i.e. 8086 and 80286 addressing modes) are
- not supported (yet).
-
- * The bus lock prefix `lock' inhibits interrupts during execution of
- the instruction it precedes. (This is only valid with certain
- instructions; see a 80386 manual for details).
-
- * The wait for coprocessor prefix `wait' waits for the coprocessor
- to complete the current instruction. This should never be needed
- for the 80386/80387 combination.
-
- * The `rep', `repe', and `repne' prefixes are added to string
- instructions to make them repeat `%ecx' times.
-
-
-File: as.info, Node: i386-Memory, Next: i386-jumps, Prev: i386-prefixes, Up: i386-Dependent
-
-Memory References
------------------
-
- An Intel syntax indirect memory reference of the form
-
- SECTION:[BASE + INDEX*SCALE + DISP]
-
-is translated into the AT&T syntax
-
- SECTION:DISP(BASE, INDEX, SCALE)
-
-where BASE and INDEX are the optional 32-bit base and index registers,
-DISP is the optional displacement, and SCALE, taking the values 1, 2,
-4, and 8, multiplies INDEX to calculate the address of the operand. If
-no SCALE is specified, SCALE is taken to be 1. SECTION specifies the
-optional section register for the memory operand, and may override the
-default section register (see a 80386 manual for section register
-defaults). Note that section overrides in AT&T syntax *must* have be
-preceded by a `%'. If you specify a section override which coincides
-with the default section register, `as' does *not* output any section
-register override prefixes to assemble the given instruction. Thus,
-section overrides can be specified to emphasize which section register
-is used for a given memory operand.
-
- Here are some examples of Intel and AT&T style memory references:
-
-AT&T: `-4(%ebp)', Intel: `[ebp - 4]'
- BASE is `%ebp'; DISP is `-4'. SECTION is missing, and the default
- section is used (`%ss' for addressing with `%ebp' as the base
- register). INDEX, SCALE are both missing.
-
-AT&T: `foo(,%eax,4)', Intel: `[foo + eax*4]'
- INDEX is `%eax' (scaled by a SCALE 4); DISP is `foo'. All other
- fields are missing. The section register here defaults to `%ds'.
-
-AT&T: `foo(,1)'; Intel `[foo]'
- This uses the value pointed to by `foo' as a memory operand. Note
- that BASE and INDEX are both missing, but there is only *one* `,'.
- This is a syntactic exception.
-
-AT&T: `%gs:foo'; Intel `gs:foo'
- This selects the contents of the variable `foo' with section
- register SECTION being `%gs'.
-
- Absolute (as opposed to PC relative) call and jump operands must be
-prefixed with `*'. If no `*' is specified, `as' always chooses PC
-relative addressing for jump/call labels.
-
- Any instruction that has a memory operand *must* specify its size
-(byte, word, or long) with an opcode suffix (`b', `w', or `l',
-respectively).
-
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info-5 b/gnu/usr.bin/binutils/gas/doc/as.info-5
deleted file mode 100644
index 9e992ff2a64..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info-5
+++ /dev/null
@@ -1,741 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: as.info, Node: i386-jumps, Next: i386-Float, Prev: i386-Memory, Up: i386-Dependent
-
-Handling of Jump Instructions
------------------------------
-
- Jump instructions are always optimized to use the smallest possible
-displacements. This is accomplished by using byte (8-bit) displacement
-jumps whenever the target is sufficiently close. If a byte displacement
-is insufficient a long (32-bit) displacement is used. We do not support
-word (16-bit) displacement jumps (i.e. prefixing the jump instruction
-with the `addr16' opcode prefix), since the 80386 insists upon masking
-`%eip' to 16 bits after the word displacement is added.
-
- Note that the `jcxz', `jecxz', `loop', `loopz', `loope', `loopnz'
-and `loopne' instructions only come in byte displacements, so that if
-you use these instructions (`gcc' does not use them) you may get an
-error message (and incorrect code). The AT&T 80386 assembler tries to
-get around this problem by expanding `jcxz foo' to
-
- jcxz cx_zero
- jmp cx_nonzero
- cx_zero: jmp foo
- cx_nonzero:
-
-
-File: as.info, Node: i386-Float, Next: i386-16bit, Prev: i386-jumps, Up: i386-Dependent
-
-Floating Point
---------------
-
- All 80387 floating point types except packed BCD are supported.
-(BCD support may be added without much difficulty). These data types
-are 16-, 32-, and 64- bit integers, and single (32-bit), double
-(64-bit), and extended (80-bit) precision floating point. Each
-supported type has an opcode suffix and a constructor associated with
-it. Opcode suffixes specify operand's data types. Constructors build
-these data types into memory.
-
- * Floating point constructors are `.float' or `.single', `.double',
- and `.tfloat' for 32-, 64-, and 80-bit formats. These correspond
- to opcode suffixes `s', `l', and `t'. `t' stands for temporary
- real, and that the 80387 only supports this format via the `fldt'
- (load temporary real to stack top) and `fstpt' (store temporary
- real and pop stack) instructions.
-
- * Integer constructors are `.word', `.long' or `.int', and `.quad'
- for the 16-, 32-, and 64-bit integer formats. The corresponding
- opcode suffixes are `s' (single), `l' (long), and `q' (quad). As
- with the temporary real format the 64-bit `q' format is only
- present in the `fildq' (load quad integer to stack top) and
- `fistpq' (store quad integer and pop stack) instructions.
-
- Register to register operations do not require opcode suffixes, so
-that `fst %st, %st(1)' is equivalent to `fstl %st, %st(1)'.
-
- Since the 80387 automatically synchronizes with the 80386 `fwait'
-instructions are almost never needed (this is not the case for the
-80286/80287 and 8086/8087 combinations). Therefore, `as' suppresses
-the `fwait' instruction whenever it is implicitly selected by one of
-the `fn...' instructions. For example, `fsave' and `fnsave' are
-treated identically. In general, all the `fn...' instructions are made
-equivalent to `f...' instructions. If `fwait' is desired it must be
-explicitly coded.
-
-
-File: as.info, Node: i386-16bit, Next: i386-Notes, Prev: i386-Float, Up: i386-Dependent
-
-Writing 16-bit Code
--------------------
-
- While GAS normally writes only "pure" 32-bit i386 code, it has
-limited support for writing code to run in real mode or in 16-bit
-protected mode code segments. To do this, insert a `.code16' directive
-before the assembly language instructions to be run in 16-bit mode.
-You can switch GAS back to writing normal 32-bit code with the
-`.code32' directive.
-
- GAS understands exactly the same assembly language syntax in 16-bit
-mode as in 32-bit mode. The function of any given instruction is
-exactly the same regardless of mode, as long as the resulting object
-code is executed in the mode for which GAS wrote it. So, for example,
-the `ret' mnemonic produces a 32-bit return instruction regardless of
-whether it is to be run in 16-bit or 32-bit mode. (If GAS is in 16-bit
-mode, it will add an operand size prefix to the instruction to force it
-to be a 32-bit return.)
-
- This means, for one thing, that you can use GNU CC to write code to
-be run in real mode or 16-bit protected mode. Just insert the statement
-`asm(".code16");' at the beginning of your C source file, and while GNU
-CC will still be generating 32-bit code, GAS will automatically add all
-the necessary size prefixes to make that code run in 16-bit mode. Of
-course, since GNU CC only writes small-model code (it doesn't know how
-to attach segment selectors to pointers like native x86 compilers do),
-any 16-bit code you write with GNU CC will essentially be limited to a
-64K address space. Also, there will be a code size and performance
-penalty due to all the extra address and operand size prefixes GAS has
-to add to the instructions.
-
- Note that placing GAS in 16-bit mode does not mean that the resulting
-code will necessarily run on a 16-bit pre-80386 processor. To write
-code that runs on such a processor, you would have to refrain from using
-*any* 32-bit constructs which require GAS to output address or operand
-size prefixes. At the moment this would be rather difficult, because
-GAS currently supports *only* 32-bit addressing modes: when writing
-16-bit code, it *always* outputs address size prefixes for any
-instruction that uses a non-register addressing mode. So you can write
-code that runs on 16-bit processors, but only if that code never
-references memory.
-
-
-File: as.info, Node: i386-Notes, Prev: i386-16bit, Up: i386-Dependent
-
-Notes
------
-
- There is some trickery concerning the `mul' and `imul' instructions
-that deserves mention. The 16-, 32-, and 64-bit expanding multiplies
-(base opcode `0xf6'; extension 4 for `mul' and 5 for `imul') can be
-output only in the one operand form. Thus, `imul %ebx, %eax' does
-*not* select the expanding multiply; the expanding multiply would
-clobber the `%edx' register, and this would confuse `gcc' output. Use
-`imul %ebx' to get the 64-bit product in `%edx:%eax'.
-
- We have added a two operand form of `imul' when the first operand is
-an immediate mode expression and the second operand is a register.
-This is just a shorthand, so that, multiplying `%eax' by 69, for
-example, can be done with `imul $69, %eax' rather than `imul $69, %eax,
-%eax'.
-
-
-File: as.info, Node: Z8000-Dependent, Next: MIPS-Dependent, Prev: Sparc-Dependent, Up: Machine Dependencies
-
-Z8000 Dependent Features
-========================
-
- The Z8000 as supports both members of the Z8000 family: the
-unsegmented Z8002, with 16 bit addresses, and the segmented Z8001 with
-24 bit addresses.
-
- When the assembler is in unsegmented mode (specified with the
-`unsegm' directive), an address takes up one word (16 bit) sized
-register. When the assembler is in segmented mode (specified with the
-`segm' directive), a 24-bit address takes up a long (32 bit) register.
-*Note Assembler Directives for the Z8000: Z8000 Directives, for a list
-of other Z8000 specific assembler directives.
-
-* Menu:
-
-* Z8000 Options:: No special command-line options for Z8000
-* Z8000 Syntax:: Assembler syntax for the Z8000
-* Z8000 Directives:: Special directives for the Z8000
-* Z8000 Opcodes:: Opcodes
-
-
-File: as.info, Node: Z8000 Options, Next: Z8000 Syntax, Up: Z8000-Dependent
-
-Options
--------
-
- `as' has no additional command-line options for the Zilog Z8000
-family.
-
-
-File: as.info, Node: Z8000 Syntax, Next: Z8000 Directives, Prev: Z8000 Options, Up: Z8000-Dependent
-
-Syntax
-------
-
-* Menu:
-
-* Z8000-Chars:: Special Characters
-* Z8000-Regs:: Register Names
-* Z8000-Addressing:: Addressing Modes
-
-
-File: as.info, Node: Z8000-Chars, Next: Z8000-Regs, Up: Z8000 Syntax
-
-Special Characters
-..................
-
- `!' is the line comment character.
-
- You can use `;' instead of a newline to separate statements.
-
-
-File: as.info, Node: Z8000-Regs, Next: Z8000-Addressing, Prev: Z8000-Chars, Up: Z8000 Syntax
-
-Register Names
-..............
-
- The Z8000 has sixteen 16 bit registers, numbered 0 to 15. You can
-refer to different sized groups of registers by register number, with
-the prefix `r' for 16 bit registers, `rr' for 32 bit registers and `rq'
-for 64 bit registers. You can also refer to the contents of the first
-eight (of the sixteen 16 bit registers) by bytes. They are named `rNh'
-and `rNl'.
-
-*byte registers*
- r0l r0h r1h r1l r2h r2l r3h r3l
- r4h r4l r5h r5l r6h r6l r7h r7l
-*word registers*
- r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15
-*long word registers*
- rr0 rr2 rr4 rr6 rr8 rr10 rr12 rr14
-*quad word registers*
- rq0 rq4 rq8 rq12
-
-
-File: as.info, Node: Z8000-Addressing, Prev: Z8000-Regs, Up: Z8000 Syntax
-
-Addressing Modes
-................
-
- as understands the following addressing modes for the Z8000:
-
-`rN'
- Register direct
-
-`@rN'
- Indirect register
-
-`ADDR'
- Direct: the 16 bit or 24 bit address (depending on whether the
- assembler is in segmented or unsegmented mode) of the operand is
- in the instruction.
-
-`address(rN)'
- Indexed: the 16 or 24 bit address is added to the 16 bit register
- to produce the final address in memory of the operand.
-
-`rN(#IMM)'
- Base Address: the 16 or 24 bit register is added to the 16 bit sign
- extended immediate displacement to produce the final address in
- memory of the operand.
-
-`rN(rM)'
- Base Index: the 16 or 24 bit register rN is added to the sign
- extended 16 bit index register rM to produce the final address in
- memory of the operand.
-
-`#XX'
- Immediate data XX.
-
-
-File: as.info, Node: Z8000 Directives, Next: Z8000 Opcodes, Prev: Z8000 Syntax, Up: Z8000-Dependent
-
-Assembler Directives for the Z8000
-----------------------------------
-
- The Z8000 port of as includes these additional assembler directives,
-for compatibility with other Z8000 assemblers. As shown, these do not
-begin with `.' (unlike the ordinary as directives).
-
-`segm'
- Generates code for the segmented Z8001.
-
-`unsegm'
- Generates code for the unsegmented Z8002.
-
-`name'
- Synonym for `.file'
-
-`global'
- Synonym for `.global'
-
-`wval'
- Synonym for `.word'
-
-`lval'
- Synonym for `.long'
-
-`bval'
- Synonym for `.byte'
-
-`sval'
- Assemble a string. `sval' expects one string literal, delimited by
- single quotes. It assembles each byte of the string into
- consecutive addresses. You can use the escape sequence `%XX'
- (where XX represents a two-digit hexadecimal number) to represent
- the character whose ASCII value is XX. Use this feature to
- describe single quote and other characters that may not appear in
- string literals as themselves. For example, the C statement
- `char *a = "he said \"it's 50% off\"";' is represented in Z8000
- assembly language (shown with the assembler output in hex at the
- left) as
-
- 68652073 sval 'he said %22it%27s 50%25 off%22%00'
- 61696420
- 22697427
- 73203530
- 25206F66
- 662200
-
-`rsect'
- synonym for `.section'
-
-`block'
- synonym for `.space'
-
-`even'
- special case of `.align'; aligns output to even byte boundary.
-
-
-File: as.info, Node: Z8000 Opcodes, Prev: Z8000 Directives, Up: Z8000-Dependent
-
-Opcodes
--------
-
- For detailed information on the Z8000 machine instruction set, see
-`Z8000 Technical Manual'.
-
- The following table summarizes the opcodes and their arguments:
-
- rs 16 bit source register
- rd 16 bit destination register
- rbs 8 bit source register
- rbd 8 bit destination register
- rrs 32 bit source register
- rrd 32 bit destination register
- rqs 64 bit source register
- rqd 64 bit destination register
- addr 16/24 bit address
- imm immediate data
-
- adc rd,rs clrb addr cpsir @rd,@rs,rr,cc
- adcb rbd,rbs clrb addr(rd) cpsirb @rd,@rs,rr,cc
- add rd,@rs clrb rbd dab rbd
- add rd,addr com @rd dbjnz rbd,disp7
- add rd,addr(rs) com addr dec @rd,imm4m1
- add rd,imm16 com addr(rd) dec addr(rd),imm4m1
- add rd,rs com rd dec addr,imm4m1
- addb rbd,@rs comb @rd dec rd,imm4m1
- addb rbd,addr comb addr decb @rd,imm4m1
- addb rbd,addr(rs) comb addr(rd) decb addr(rd),imm4m1
- addb rbd,imm8 comb rbd decb addr,imm4m1
- addb rbd,rbs comflg flags decb rbd,imm4m1
- addl rrd,@rs cp @rd,imm16 di i2
- addl rrd,addr cp addr(rd),imm16 div rrd,@rs
- addl rrd,addr(rs) cp addr,imm16 div rrd,addr
- addl rrd,imm32 cp rd,@rs div rrd,addr(rs)
- addl rrd,rrs cp rd,addr div rrd,imm16
- and rd,@rs cp rd,addr(rs) div rrd,rs
- and rd,addr cp rd,imm16 divl rqd,@rs
- and rd,addr(rs) cp rd,rs divl rqd,addr
- and rd,imm16 cpb @rd,imm8 divl rqd,addr(rs)
- and rd,rs cpb addr(rd),imm8 divl rqd,imm32
- andb rbd,@rs cpb addr,imm8 divl rqd,rrs
- andb rbd,addr cpb rbd,@rs djnz rd,disp7
- andb rbd,addr(rs) cpb rbd,addr ei i2
- andb rbd,imm8 cpb rbd,addr(rs) ex rd,@rs
- andb rbd,rbs cpb rbd,imm8 ex rd,addr
- bit @rd,imm4 cpb rbd,rbs ex rd,addr(rs)
- bit addr(rd),imm4 cpd rd,@rs,rr,cc ex rd,rs
- bit addr,imm4 cpdb rbd,@rs,rr,cc exb rbd,@rs
- bit rd,imm4 cpdr rd,@rs,rr,cc exb rbd,addr
- bit rd,rs cpdrb rbd,@rs,rr,cc exb rbd,addr(rs)
- bitb @rd,imm4 cpi rd,@rs,rr,cc exb rbd,rbs
- bitb addr(rd),imm4 cpib rbd,@rs,rr,cc ext0e imm8
- bitb addr,imm4 cpir rd,@rs,rr,cc ext0f imm8
- bitb rbd,imm4 cpirb rbd,@rs,rr,cc ext8e imm8
- bitb rbd,rs cpl rrd,@rs ext8f imm8
- bpt cpl rrd,addr exts rrd
- call @rd cpl rrd,addr(rs) extsb rd
- call addr cpl rrd,imm32 extsl rqd
- call addr(rd) cpl rrd,rrs halt
- calr disp12 cpsd @rd,@rs,rr,cc in rd,@rs
- clr @rd cpsdb @rd,@rs,rr,cc in rd,imm16
- clr addr cpsdr @rd,@rs,rr,cc inb rbd,@rs
- clr addr(rd) cpsdrb @rd,@rs,rr,cc inb rbd,imm16
- clr rd cpsi @rd,@rs,rr,cc inc @rd,imm4m1
- clrb @rd cpsib @rd,@rs,rr,cc inc addr(rd),imm4m1
- inc addr,imm4m1 ldb rbd,rs(rx) mult rrd,addr(rs)
- inc rd,imm4m1 ldb rd(imm16),rbs mult rrd,imm16
- incb @rd,imm4m1 ldb rd(rx),rbs mult rrd,rs
- incb addr(rd),imm4m1 ldctl ctrl,rs multl rqd,@rs
- incb addr,imm4m1 ldctl rd,ctrl multl rqd,addr
- incb rbd,imm4m1 ldd @rs,@rd,rr multl rqd,addr(rs)
- ind @rd,@rs,ra lddb @rs,@rd,rr multl rqd,imm32
- indb @rd,@rs,rba lddr @rs,@rd,rr multl rqd,rrs
- inib @rd,@rs,ra lddrb @rs,@rd,rr neg @rd
- inibr @rd,@rs,ra ldi @rd,@rs,rr neg addr
- iret ldib @rd,@rs,rr neg addr(rd)
- jp cc,@rd ldir @rd,@rs,rr neg rd
- jp cc,addr ldirb @rd,@rs,rr negb @rd
- jp cc,addr(rd) ldk rd,imm4 negb addr
- jr cc,disp8 ldl @rd,rrs negb addr(rd)
- ld @rd,imm16 ldl addr(rd),rrs negb rbd
- ld @rd,rs ldl addr,rrs nop
- ld addr(rd),imm16 ldl rd(imm16),rrs or rd,@rs
- ld addr(rd),rs ldl rd(rx),rrs or rd,addr
- ld addr,imm16 ldl rrd,@rs or rd,addr(rs)
- ld addr,rs ldl rrd,addr or rd,imm16
- ld rd(imm16),rs ldl rrd,addr(rs) or rd,rs
- ld rd(rx),rs ldl rrd,imm32 orb rbd,@rs
- ld rd,@rs ldl rrd,rrs orb rbd,addr
- ld rd,addr ldl rrd,rs(imm16) orb rbd,addr(rs)
- ld rd,addr(rs) ldl rrd,rs(rx) orb rbd,imm8
- ld rd,imm16 ldm @rd,rs,n orb rbd,rbs
- ld rd,rs ldm addr(rd),rs,n out @rd,rs
- ld rd,rs(imm16) ldm addr,rs,n out imm16,rs
- ld rd,rs(rx) ldm rd,@rs,n outb @rd,rbs
- lda rd,addr ldm rd,addr(rs),n outb imm16,rbs
- lda rd,addr(rs) ldm rd,addr,n outd @rd,@rs,ra
- lda rd,rs(imm16) ldps @rs outdb @rd,@rs,rba
- lda rd,rs(rx) ldps addr outib @rd,@rs,ra
- ldar rd,disp16 ldps addr(rs) outibr @rd,@rs,ra
- ldb @rd,imm8 ldr disp16,rs pop @rd,@rs
- ldb @rd,rbs ldr rd,disp16 pop addr(rd),@rs
- ldb addr(rd),imm8 ldrb disp16,rbs pop addr,@rs
- ldb addr(rd),rbs ldrb rbd,disp16 pop rd,@rs
- ldb addr,imm8 ldrl disp16,rrs popl @rd,@rs
- ldb addr,rbs ldrl rrd,disp16 popl addr(rd),@rs
- ldb rbd,@rs mbit popl addr,@rs
- ldb rbd,addr mreq rd popl rrd,@rs
- ldb rbd,addr(rs) mres push @rd,@rs
- ldb rbd,imm8 mset push @rd,addr
- ldb rbd,rbs mult rrd,@rs push @rd,addr(rs)
- ldb rbd,rs(imm16) mult rrd,addr push @rd,imm16
- push @rd,rs set addr,imm4 subl rrd,imm32
- pushl @rd,@rs set rd,imm4 subl rrd,rrs
- pushl @rd,addr set rd,rs tcc cc,rd
- pushl @rd,addr(rs) setb @rd,imm4 tccb cc,rbd
- pushl @rd,rrs setb addr(rd),imm4 test @rd
- res @rd,imm4 setb addr,imm4 test addr
- res addr(rd),imm4 setb rbd,imm4 test addr(rd)
- res addr,imm4 setb rbd,rs test rd
- res rd,imm4 setflg imm4 testb @rd
- res rd,rs sinb rbd,imm16 testb addr
- resb @rd,imm4 sinb rd,imm16 testb addr(rd)
- resb addr(rd),imm4 sind @rd,@rs,ra testb rbd
- resb addr,imm4 sindb @rd,@rs,rba testl @rd
- resb rbd,imm4 sinib @rd,@rs,ra testl addr
- resb rbd,rs sinibr @rd,@rs,ra testl addr(rd)
- resflg imm4 sla rd,imm8 testl rrd
- ret cc slab rbd,imm8 trdb @rd,@rs,rba
- rl rd,imm1or2 slal rrd,imm8 trdrb @rd,@rs,rba
- rlb rbd,imm1or2 sll rd,imm8 trib @rd,@rs,rbr
- rlc rd,imm1or2 sllb rbd,imm8 trirb @rd,@rs,rbr
- rlcb rbd,imm1or2 slll rrd,imm8 trtdrb @ra,@rb,rbr
- rldb rbb,rba sout imm16,rs trtib @ra,@rb,rr
- rr rd,imm1or2 soutb imm16,rbs trtirb @ra,@rb,rbr
- rrb rbd,imm1or2 soutd @rd,@rs,ra trtrb @ra,@rb,rbr
- rrc rd,imm1or2 soutdb @rd,@rs,rba tset @rd
- rrcb rbd,imm1or2 soutib @rd,@rs,ra tset addr
- rrdb rbb,rba soutibr @rd,@rs,ra tset addr(rd)
- rsvd36 sra rd,imm8 tset rd
- rsvd38 srab rbd,imm8 tsetb @rd
- rsvd78 sral rrd,imm8 tsetb addr
- rsvd7e srl rd,imm8 tsetb addr(rd)
- rsvd9d srlb rbd,imm8 tsetb rbd
- rsvd9f srll rrd,imm8 xor rd,@rs
- rsvdb9 sub rd,@rs xor rd,addr
- rsvdbf sub rd,addr xor rd,addr(rs)
- sbc rd,rs sub rd,addr(rs) xor rd,imm16
- sbcb rbd,rbs sub rd,imm16 xor rd,rs
- sc imm8 sub rd,rs xorb rbd,@rs
- sda rd,rs subb rbd,@rs xorb rbd,addr
- sdab rbd,rs subb rbd,addr xorb rbd,addr(rs)
- sdal rrd,rs subb rbd,addr(rs) xorb rbd,imm8
- sdl rd,rs subb rbd,imm8 xorb rbd,rbs
- sdlb rbd,rs subb rbd,rbs xorb rbd,rbs
- sdll rrd,rs subl rrd,@rs
- set @rd,imm4 subl rrd,addr
- set addr(rd),imm4 subl rrd,addr(rs)
-
-
-File: as.info, Node: MIPS-Dependent, Next: i386-Dependent, Prev: Z8000-Dependent, Up: Machine Dependencies
-
-MIPS Dependent Features
-=======================
-
- GNU `as' for MIPS architectures supports the MIPS R2000, R3000,
-R4000 and R6000 processors. For information about the MIPS instruction
-set, see `MIPS RISC Architecture', by Kane and Heindrich
-(Prentice-Hall). For an overview of MIPS assembly conventions, see
-"Appendix D: Assembly Language Programming" in the same work.
-
-* Menu:
-
-* MIPS Opts:: Assembler options
-* MIPS Object:: ECOFF object code
-* MIPS Stabs:: Directives for debugging information
-* MIPS ISA:: Directives to override the ISA level
-
-
-File: as.info, Node: MIPS Opts, Next: MIPS Object, Up: MIPS-Dependent
-
-Assembler options
------------------
-
- The MIPS configurations of GNU `as' support these special options:
-
-`-G NUM'
- This option sets the largest size of an object that can be
- referenced implicitly with the `gp' register. It is only accepted
- for targets that use ECOFF format. The default value is 8.
-
-`-EB'
-`-EL'
- Any MIPS configuration of `as' can select big-endian or
- little-endian output at run time (unlike the other GNU development
- tools, which must be configured for one or the other). Use `-EB'
- to select big-endian output, and `-EL' for little-endian.
-
-`-mips1'
-`-mips2'
-`-mips3'
- Generate code for a particular MIPS Instruction Set Architecture
- level. `-mips1' corresponds to the R2000 and R3000 processors,
- `-mips2' to the R6000 processor, and `-mips3' to the R4000
- processor. You can also switch instruction sets during the
- assembly; see *Note Directives to override the ISA level: MIPS ISA.
-
-`-m4650'
-`-no-m4650'
- Generate code for the MIPS R4650 chip. This tells the assembler
- to accept the `mad' and `madu' instruction, and to not schedule
- `nop' instructions around accesses to the `HI' and `LO' registers.
- `-no-m4650' turns off this option.
-
-`-m4010'
-`-no-m4010'
- Generate code for the LSI R4010 chip. This tells the assembler to
- accept the R4010 specific instructions (`addciu', `ffc', etc.),
- and to not schedule `nop' instructions around accesses to the `HI'
- and `LO' registers. `-no-m4010' turns off this option.
-
-`-mcpu=CPU'
- Generate code for a particular MIPS cpu. This has little effect
- on the assembler, but it is passed by `gcc'.
-
-`-nocpp'
- This option is ignored. It is accepted for command-line
- compatibility with other assemblers, which use it to turn off C
- style preprocessing. With GNU `as', there is no need for
- `-nocpp', because the GNU assembler itself never runs the C
- preprocessor.
-
-`--trap'
-`--no-break'
- `as' automatically macro expands certain division and
- multiplication instructions to check for overflow and division by
- zero. This option causes `as' to generate code to take a trap
- exception rather than a break exception when an error is detected.
- The trap instructions are only supported at Instruction Set
- Architecture level 2 and higher.
-
-`--break'
-`--no-trap'
- Generate code to take a break exception rather than a trap
- exception when an error is detected. This is the default.
-
-
-File: as.info, Node: MIPS Object, Next: MIPS Stabs, Prev: MIPS Opts, Up: MIPS-Dependent
-
-MIPS ECOFF object code
-----------------------
-
- Assembling for a MIPS ECOFF target supports some additional sections
-besides the usual `.text', `.data' and `.bss'. The additional sections
-are `.rdata', used for read-only data, `.sdata', used for small data,
-and `.sbss', used for small common objects.
-
- When assembling for ECOFF, the assembler uses the `$gp' (`$28')
-register to form the address of a "small object". Any object in the
-`.sdata' or `.sbss' sections is considered "small" in this sense. For
-external objects, or for objects in the `.bss' section, you can use the
-`gcc' `-G' option to control the size of objects addressed via `$gp';
-the default value is 8, meaning that a reference to any object eight
-bytes or smaller uses `$gp'. Passing `-G 0' to `as' prevents it from
-using the `$gp' register on the basis of object size (but the assembler
-uses `$gp' for objects in `.sdata' or `sbss' in any case). The size of
-an object in the `.bss' section is set by the `.comm' or `.lcomm'
-directive that defines it. The size of an external object may be set
-with the `.extern' directive. For example, `.extern sym,4' declares
-that the object at `sym' is 4 bytes in length, whie leaving `sym'
-otherwise undefined.
-
- Using small ECOFF objects requires linker support, and assumes that
-the `$gp' register is correctly initialized (normally done
-automatically by the startup code). MIPS ECOFF assembly code must not
-modify the `$gp' register.
-
-
-File: as.info, Node: MIPS Stabs, Next: MIPS ISA, Prev: MIPS Object, Up: MIPS-Dependent
-
-Directives for debugging information
-------------------------------------
-
- MIPS ECOFF `as' supports several directives used for generating
-debugging information which are not support by traditional MIPS
-assemblers. These are `.def', `.endef', `.dim', `.file', `.scl',
-`.size', `.tag', `.type', `.val', `.stabd', `.stabn', and `.stabs'.
-The debugging information generated by the three `.stab' directives can
-only be read by GDB, not by traditional MIPS debuggers (this
-enhancement is required to fully support C++ debugging). These
-directives are primarily used by compilers, not assembly language
-programmers!
-
-
-File: as.info, Node: MIPS ISA, Prev: MIPS Stabs, Up: MIPS-Dependent
-
-Directives to override the ISA level
-------------------------------------
-
- GNU `as' supports an additional directive to change the MIPS
-Instruction Set Architecture level on the fly: `.set mipsN'. N should
-be a number from 0 to 3. A value from 1 to 3 makes the assembler
-accept instructions for the corresponding ISA level, from that point on
-in the assembly. `.set mipsN' affects not only which instructions are
-permitted, but also how certain macros are expanded. `.set mips0'
-restores the ISA level to its original level: either the level you
-selected with command line options, or the default for your
-configuration. You can use this feature to permit specific R4000
-instructions while assembling in 32 bit mode. Use this directive with
-care!
-
- Traditional MIPS assemblers do not support this directive.
-
-
-File: as.info, Node: Acknowledgements, Next: Index, Prev: Machine Dependencies, Up: Top
-
-Acknowledgements
-****************
-
- If you have contributed to `as' and your name isn't listed here, it
-is not meant as a slight. We just don't know about it. Send mail to
-the maintainer, and we'll correct the situation. Currently the
-maintainer is Ken Raeburn (email address `raeburn@cygnus.com').
-
- Dean Elsner wrote the original GNU assembler for the VAX.(1)
-
- Jay Fenlason maintained GAS for a while, adding support for
-GDB-specific debug information and the 68k series machines, most of the
-preprocessing pass, and extensive changes in `messages.c',
-`input-file.c', `write.c'.
-
- K. Richard Pixley maintained GAS for a while, adding various
-enhancements and many bug fixes, including merging support for several
-processors, breaking GAS up to handle multiple object file format back
-ends (including heavy rewrite, testing, an integration of the coff and
-b.out back ends), adding configuration including heavy testing and
-verification of cross assemblers and file splits and renaming,
-converted GAS to strictly ANSI C including full prototypes, added
-support for m680[34]0 and cpu32, did considerable work on i960
-including a COFF port (including considerable amounts of reverse
-engineering), a SPARC opcode file rewrite, DECstation, rs6000, and
-hp300hpux host ports, updated "know" assertions and made them work,
-much other reorganization, cleanup, and lint.
-
- Ken Raeburn wrote the high-level BFD interface code to replace most
-of the code in format-specific I/O modules.
-
- The original VMS support was contributed by David L. Kashtan. Eric
-Youngdale has done much work with it since.
-
- The Intel 80386 machine description was written by Eliot Dresselhaus.
-
- Minh Tran-Le at IntelliCorp contributed some AIX 386 support.
-
- The Motorola 88k machine description was contributed by Devon Bowen
-of Buffalo University and Torbjorn Granlund of the Swedish Institute of
-Computer Science.
-
- Keith Knowles at the Open Software Foundation wrote the original
-MIPS back end (`tc-mips.c', `tc-mips.h'), and contributed Rose format
-support (which hasn't been merged in yet). Ralph Campbell worked with
-the MIPS code to support a.out format.
-
- Support for the Zilog Z8k and Hitachi H8/300 and H8/500 processors
-(tc-z8k, tc-h8300, tc-h8500), and IEEE 695 object file format
-(obj-ieee), was written by Steve Chamberlain of Cygnus Support. Steve
-also modified the COFF back end to use BFD for some low-level
-operations, for use with the H8/300 and AMD 29k targets.
-
- John Gilmore built the AMD 29000 support, added `.include' support,
-and simplified the configuration of which versions accept which
-directives. He updated the 68k machine description so that Motorola's
-opcodes always produced fixed-size instructions (e.g. `jsr'), while
-synthetic instructions remained shrinkable (`jbsr'). John fixed many
-bugs, including true tested cross-compilation support, and one bug in
-relaxation that took a week and required the proverbial one-bit fix.
-
- Ian Lance Taylor of Cygnus Support merged the Motorola and MIT
-syntax for the 68k, completed support for some COFF targets (68k, i386
-SVR3, and SCO Unix), added support for MIPS ECOFF and ELF targets, and
-made a few other minor patches.
-
- Steve Chamberlain made `as' able to generate listings.
-
- Hewlett-Packard contributed support for the HP9000/300.
-
- Jeff Law wrote GAS and BFD support for the native HPPA object format
-(SOM) along with a fairly extensive HPPA testsuite (for both SOM and
-ELF object formats). This work was supported by both the Center for
-Software Science at the University of Utah and Cygnus Support.
-
- Support for ELF format files has been worked on by Mark Eichin of
-Cygnus Support (original, incomplete implementation for SPARC), Pete
-Hoogenboom and Jeff Law at the University of Utah (HPPA mainly),
-Michael Meissner of the Open Software Foundation (i386 mainly), and Ken
-Raeburn of Cygnus Support (sparc, and some initial 64-bit support).
-
- Several engineers at Cygnus Support have also provided many small
-bug fixes and configuration enhancements.
-
- Many others have contributed large or small bugfixes and
-enhancements. If you have contributed significant work and are not
-mentioned on this list, and want to be, let us know. Some of the
-history has been lost; we are not intentionally leaving anyone out.
-
- ---------- Footnotes ----------
-
- (1) Any more details?
-
diff --git a/gnu/usr.bin/binutils/gas/doc/as.info-6 b/gnu/usr.bin/binutils/gas/doc/as.info-6
deleted file mode 100644
index 8ae6716e4bb..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/as.info-6
+++ /dev/null
@@ -1,776 +0,0 @@
-This is Info file as.info, produced by Makeinfo-1.55 from the input
-file ./as.texinfo.
-
-START-INFO-DIR-ENTRY
-* As: (as). The GNU assembler.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU Assembler "as".
-
- Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation,
-Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: as.info, Node: Index, Prev: Acknowledgements, Up: Top
-
-Index
-*****
-
-* Menu:
-
-* #: Comments.
-* #APP: Preprocessing.
-* #NO_APP: Preprocessing.
-* -: Command Line.
-* -statistics: statistics.
-* -a: a.
-* -ad: a.
-* -ah: a.
-* -al: a.
-* -an: a.
-* -as: a.
-* -Asparclite: Sparc-Opts.
-* -Av6: Sparc-Opts.
-* -Av8: Sparc-Opts.
-* -Av9: Sparc-Opts.
-* -D: D.
-* -f: f.
-* -I PATH: I.
-* -K: K.
-* -L: L.
-* -M: M.
-* -o: o.
-* -R: R.
-* -v: v.
-* -version: v.
-* -W: W.
-* .o: Object.
-* 16-bit code, i386: i386-16bit.
-* 29K support: AMD29K-Dependent.
-* $ in symbol names: H8/500-Chars.
-* $ in symbol names: SH-Chars.
-* -+ option, VAX/VMS: Vax-Opts.
-* -A options, i960: Options-i960.
-* -b option, i960: Options-i960.
-* -D, ignored on VAX: Vax-Opts.
-* -d, VAX option: Vax-Opts.
-* -EB option (MIPS): MIPS Opts.
-* -EL option (MIPS): MIPS Opts.
-* -G option (MIPS): MIPS Opts.
-* -h option, VAX/VMS: Vax-Opts.
-* -J, ignored on VAX: Vax-Opts.
-* -no-relax option, i960: Options-i960.
-* -nocpp ignored (MIPS): MIPS Opts.
-* -S, ignored on VAX: Vax-Opts.
-* -t, ignored on VAX: Vax-Opts.
-* -T, ignored on VAX: Vax-Opts.
-* -V, redundant on VAX: Vax-Opts.
-* .param on HPPA: HPPA Directives.
-* .set mipsN: MIPS ISA.
-* . (symbol): Dot.
-* : (label): Statements.
-* as version: v.
-* a.out symbol attributes: a.out Symbols.
-* ABORT directive: ABORT.
-* abort directive: Abort.
-* align directive: Align.
-* align directive, SPARC: Sparc-Directives.
-* app-file directive: App-File.
-* ascii directive: Ascii.
-* asciz directive: Asciz.
-* balign directive: Balign.
-* block directive, AMD 29K: AMD29K Directives.
-* bss directive, i960: Directives-i960.
-* byte directive: Byte.
-* callj, i960 pseudo-opcode: callj-i960.
-* code16 directive, i386: i386-16bit.
-* code32 directive, i386: i386-16bit.
-* common directive, SPARC: Sparc-Directives.
-* comm directive: Comm.
-* cputype directive, AMD 29K: AMD29K Directives.
-* data1 directive, M680x0: M68K-Directives.
-* data2 directive, M680x0: M68K-Directives.
-* data directive: Data.
-* def directive: Def.
-* desc directive: Desc.
-* dfloat directive, VAX: VAX-directives.
-* dim directive: Dim.
-* double directive: Double.
-* double directive, i386: i386-Float.
-* double directive, M680x0: M68K-Float.
-* double directive, VAX: VAX-float.
-* eject directive: Eject.
-* else directive: Else.
-* endef directive: Endef.
-* endif directive: Endif.
-* endm directive: Macro.
-* equ directive: Equ.
-* even directive, M680x0: M68K-Directives.
-* exitm directive: Macro.
-* extended directive, i96: Directives-i960.
-* extern directive: Extern.
-* ffloat directive, VAX: VAX-directives.
-* file directive: File.
-* file directive, AMD 29K: AMD29K Directives.
-* fill directive: Fill.
-* float directive: Float.
-* float directive, i386: i386-Float.
-* float directive, M680x0: M68K-Float.
-* float directive, VAX: VAX-float.
-* fwait instruction, i386: i386-Float.
-* gbr960, i960 postprocessor: Options-i960.
-* gfloat directive, VAX: VAX-directives.
-* global directive: Global.
-* gp register, MIPS: MIPS Object.
-* half directive, SPARC: Sparc-Directives.
-* hfloat directive, VAX: VAX-directives.
-* hword directive: hword.
-* ident directive: Ident.
-* ifdef directive: If.
-* ifndef directive: If.
-* ifnotdef directive: If.
-* if directive: If.
-* imul instruction, i386: i386-Notes.
-* include directive: Include.
-* include directive search path: I.
-* int directive: Int.
-* int directive, H8/300: H8/300 Directives.
-* int directive, H8/500: H8/500 Directives.
-* int directive, i386: i386-Float.
-* int directive, SH: SH Directives.
-* irpc directive: Irpc.
-* irp directive: Irp.
-* lcomm directive: Lcomm.
-* leafproc directive, i960: Directives-i960.
-* lflags directive (ignored): Lflags.
-* line directive: Line.
-* line directive, AMD 29K: AMD29K Directives.
-* list directive: List.
-* ln directive: Ln.
-* long directive: Long.
-* long directive, i386: i386-Float.
-* macro directive: Macro.
-* mul instruction, i386: i386-Notes.
-* nolist directive: Nolist.
-* octa directive: Octa.
-* org directive: Org.
-* p2align directive: P2align.
-* proc directive, SPARC: Sparc-Directives.
-* psize directive: Psize.
-* quad directive: Quad.
-* quad directive, i386: i386-Float.
-* rept directive: Rept.
-* reserve directive, SPARC: Sparc-Directives.
-* sbttl directive: Sbttl.
-* scl directive: Scl.
-* section directive: Section.
-* sect directive, AMD 29K: AMD29K Directives.
-* seg directive, SPARC: Sparc-Directives.
-* set directive: Set.
-* short directive: Short.
-* single directive: Single.
-* single directive, i386: i386-Float.
-* size directive: Size.
-* skip directive, M680x0: M68K-Directives.
-* skip directive, SPARC: Sparc-Directives.
-* space directive: Space.
-* stabX directives: Stab.
-* stabd directive: Stab.
-* stabn directive: Stab.
-* stabs directive: Stab.
-* string directive: String.
-* string directive on HPPA: HPPA Directives.
-* sysproc directive, i960: Directives-i960.
-* tag directive: Tag.
-* text directive: Text.
-* tfloat directive, i386: i386-Float.
-* title directive: Title.
-* type directive: Type.
-* use directive, AMD 29K: AMD29K Directives.
-* val directive: Val.
-* word directive: Word.
-* word directive, H8/300: H8/300 Directives.
-* word directive, H8/500: H8/500 Directives.
-* word directive, i386: i386-Float.
-* word directive, SH: SH Directives.
-* word directive, SPARC: Sparc-Directives.
-* xword directive, SPARC: Sparc-Directives.
-* \" (doublequote character): Strings.
-* \DDD (octal character code): Strings.
-* \XDD (hex character code): Strings.
-* \b (backspace character): Strings.
-* \f (formfeed character): Strings.
-* \n (newline character): Strings.
-* \r (carriage return character): Strings.
-* \t (tab): Strings.
-* \\ (\ character): Strings.
-* -register-prefix-optional option, M680x0: M68K-Opts.
-* -l option, M680x0: M68K-Opts.
-* -m68000 and related options: M68K-Opts.
-* MIT: M68K-Syntax.
-* a.out: Object.
-* absolute section: Ld Sections.
-* addition, permitted arguments: Infix Ops.
-* addresses: Expressions.
-* addresses, format of: Secs Background.
-* addressing modes, H8/300: H8/300-Addressing.
-* addressing modes, H8/500: H8/500-Addressing.
-* addressing modes, M680x0: M68K-Syntax.
-* addressing modes, SH: SH-Addressing.
-* addressing modes, Z8000: Z8000-Addressing.
-* advancing location counter: Org.
-* altered difference tables: Word.
-* alternate syntax for the 680x0: M68K-Moto-Syntax.
-* AMD 29K floating point (IEEE): AMD29K Floating Point.
-* AMD 29K identifiers: AMD29K-Chars.
-* AMD 29K line comment character: AMD29K-Chars.
-* AMD 29K machine directives: AMD29K Directives.
-* AMD 29K macros: AMD29K-Macros.
-* AMD 29K opcodes: AMD29K Opcodes.
-* AMD 29K options (none): AMD29K Options.
-* AMD 29K protected registers: AMD29K-Regs.
-* AMD 29K register names: AMD29K-Regs.
-* AMD 29K special purpose registers: AMD29K-Regs.
-* AMD 29K support: AMD29K-Dependent.
-* architecture options, i960: Options-i960.
-* architecture options, M680x0: M68K-Opts.
-* architectures, SPARC: Sparc-Opts.
-* arguments for addition: Infix Ops.
-* arguments for subtraction: Infix Ops.
-* arguments in expressions: Arguments.
-* arithmetic functions: Operators.
-* arithmetic operands: Arguments.
-* assembler internal logic error: As Sections.
-* assembler, and linker: Secs Background.
-* assembly listings, enabling: a.
-* assigning values to symbols: Setting Symbols.
-* assigning values to symbols: Equ.
-* attributes, symbol: Symbol Attributes.
-* auxiliary attributes, COFF symbols: COFF Symbols.
-* auxiliary symbol information, COFF: Dim.
-* Av7: Sparc-Opts.
-* backslash (\\): Strings.
-* backspace (\b): Strings.
-* big endian output, MIPS: Overview.
-* big-endian output, MIPS: MIPS Opts.
-* bignums: Bignums.
-* binary integers: Integers.
-* bitfields, not supported on VAX: VAX-no.
-* block: Z8000 Directives.
-* branch improvement, M680x0: M68K-Branch.
-* branch improvement, VAX: VAX-branch.
-* branch recording, i960: Options-i960.
-* branch statistics table, i960: Options-i960.
-* bss section: bss.
-* bss section: Ld Sections.
-* bus lock prefixes, i386: i386-prefixes.
-* bval: Z8000 Directives.
-* call instructions, i386: i386-Opcodes.
-* carriage return (\r): Strings.
-* character constants: Characters.
-* character escape codes: Strings.
-* character, single: Chars.
-* characters used in symbols: Symbol Intro.
-* COFF auxiliary symbol information: Dim.
-* COFF named section: Section.
-* COFF structure debugging: Tag.
-* COFF symbol attributes: COFF Symbols.
-* COFF symbol descriptor: Desc.
-* COFF symbol storage class: Scl.
-* COFF symbol type: Type.
-* COFF symbols, debugging: Def.
-* COFF value attribute: Val.
-* command line conventions: Command Line.
-* command-line options ignored, VAX: Vax-Opts.
-* comments: Comments.
-* comments, M680x0: M68K-Chars.
-* comments, removed by preprocessor: Preprocessing.
-* common variable storage: bss.
-* compare and jump expansions, i960: Compare-and-branch-i960.
-* compare/branch instructions, i960: Compare-and-branch-i960.
-* conditional assembly: If.
-* constant, single character: Chars.
-* constants: Constants.
-* constants, bignum: Bignums.
-* constants, character: Characters.
-* constants, converted by preprocessor: Preprocessing.
-* constants, floating point: Flonums.
-* constants, integer: Integers.
-* constants, number: Numbers.
-* constants, string: Strings.
-* continuing statements: Statements.
-* conversion instructions, i386: i386-Opcodes.
-* coprocessor wait, i386: i386-prefixes.
-* current address: Dot.
-* current address, advancing: Org.
-* data and text sections, joining: R.
-* data section: Ld Sections.
-* debuggers, and symbol order: Symbols.
-* debugging COFF symbols: Def.
-* decimal integers: Integers.
-* deprecated directives: Deprecated.
-* descriptor, of a.out symbol: Symbol Desc.
-* difference tables altered: Word.
-* difference tables, warning: K.
-* directives and instructions: Statements.
-* directives, M680x0: M68K-Directives.
-* directives, machine independent: Pseudo Ops.
-* directives, Z8000: Z8000 Directives.
-* displacement sizing character, VAX: VAX-operands.
-* dot (symbol): Dot.
-* doublequote (\"): Strings.
-* ECOFF sections: MIPS Object.
-* eight-byte integer: Quad.
-* empty expressions: Empty Exprs.
-* emulation: Overview.
-* endianness, MIPS: Overview.
-* EOF, newline must precede: Statements.
-* error messsages: Errors.
-* errors, continuing after: Z.
-* escape codes, character: Strings.
-* even: Z8000 Directives.
-* expr (internal section): As Sections.
-* expression arguments: Arguments.
-* expressions: Expressions.
-* expressions, empty: Empty Exprs.
-* expressions, integer: Integer Exprs.
-* faster processing (-f): f.
-* file name, logical: File.
-* file name, logical: App-File.
-* files, including: Include.
-* files, input: Input Files.
-* filling memory: Space.
-* floating point numbers: Flonums.
-* floating point numbers (double): Double.
-* floating point numbers (single): Float.
-* floating point numbers (single): Single.
-* floating point, AMD 29K (IEEE): AMD29K Floating Point.
-* floating point, H8/300 (IEEE): H8/300 Floating Point.
-* floating point, H8/500 (IEEE): H8/500 Floating Point.
-* floating point, HPPA (IEEE): HPPA Floating Point.
-* floating point, i386: i386-Float.
-* floating point, i960 (IEEE): Floating Point-i960.
-* floating point, M680x0: M68K-Float.
-* floating point, SH (IEEE): SH Floating Point.
-* floating point, SPARC (IEEE): Sparc-Float.
-* floating point, VAX: VAX-float.
-* flonums: Flonums.
-* format of error messages: Errors.
-* format of warning messages: Errors.
-* formfeed (\f): Strings.
-* functions, in expressions: Operators.
-* global: Z8000 Directives.
-* grouping data: Sub-Sections.
-* H8/300 addressing modes: H8/300-Addressing.
-* H8/300 floating point (IEEE): H8/300 Floating Point.
-* H8/300 line comment character: H8/300-Chars.
-* H8/300 line separator: H8/300-Chars.
-* H8/300 machine directives (none): H8/300 Directives.
-* H8/300 opcode summary: H8/300 Opcodes.
-* H8/300 options (none): H8/300 Options.
-* H8/300 registers: H8/300-Regs.
-* H8/300 size suffixes: H8/300 Opcodes.
-* H8/300 support: H8/300-Dependent.
-* H8/300H, assembling for: H8/300 Directives.
-* H8/500 addressing modes: H8/500-Addressing.
-* H8/500 floating point (IEEE): H8/500 Floating Point.
-* H8/500 line comment character: H8/500-Chars.
-* H8/500 line separator: H8/500-Chars.
-* H8/500 machine directives (none): H8/500 Directives.
-* H8/500 opcode summary: H8/500 Opcodes.
-* H8/500 options (none): H8/500 Options.
-* H8/500 registers: H8/500-Regs.
-* H8/500 support: H8/500-Dependent.
-* hex character code (\XDD): Strings.
-* hexadecimal integers: Integers.
-* HPPA directives not supported: HPPA Directives.
-* HPPA floating point (IEEE): HPPA Floating Point.
-* HPPA Syntax: HPPA Options.
-* HPPA-only directives: HPPA Directives.
-* i386 16-bit code: i386-16bit.
-* i386 fwait instruction: i386-Float.
-* i386 mul, imul instructions: i386-Notes.
-* i386 conversion instructions: i386-Opcodes.
-* i386 floating point: i386-Float.
-* i386 immediate operands: i386-Syntax.
-* i386 jump optimization: i386-jumps.
-* i386 jump, call, return: i386-Syntax.
-* i386 jump/call operands: i386-Syntax.
-* i386 memory references: i386-Memory.
-* i386 opcode naming: i386-Opcodes.
-* i386 opcode prefixes: i386-prefixes.
-* i386 options (none): i386-Options.
-* i386 register operands: i386-Syntax.
-* i386 registers: i386-Regs.
-* i386 sections: i386-Syntax.
-* i386 size suffixes: i386-Syntax.
-* i386 source, destination operands: i386-Syntax.
-* i386 support: i386-Dependent.
-* i386 syntax compatibility: i386-Syntax.
-* i80306 support: i386-Dependent.
-* i960 callj pseudo-opcode: callj-i960.
-* i960 architecture options: Options-i960.
-* i960 branch recording: Options-i960.
-* i960 compare and jump expansions: Compare-and-branch-i960.
-* i960 compare/branch instructions: Compare-and-branch-i960.
-* i960 floating point (IEEE): Floating Point-i960.
-* i960 machine directives: Directives-i960.
-* i960 opcodes: Opcodes for i960.
-* i960 options: Options-i960.
-* i960 support: i960-Dependent.
-* identifiers, AMD 29K: AMD29K-Chars.
-* immediate character, M680x0: M68K-Chars.
-* immediate character, VAX: VAX-operands.
-* immediate operands, i386: i386-Syntax.
-* indirect character, VAX: VAX-operands.
-* infix operators: Infix Ops.
-* inhibiting interrupts, i386: i386-prefixes.
-* input: Input Files.
-* input file linenumbers: Input Files.
-* instruction set, M680x0: M68K-opcodes.
-* instruction summary, H8/300: H8/300 Opcodes.
-* instruction summary, H8/500: H8/500 Opcodes.
-* instruction summary, SH: SH Opcodes.
-* instruction summary, Z8000: Z8000 Opcodes.
-* instructions and directives: Statements.
-* integer expressions: Integer Exprs.
-* integer, 16-byte: Octa.
-* integer, 8-byte: Quad.
-* integers: Integers.
-* integers, 16-bit: hword.
-* integers, 32-bit: Int.
-* integers, binary: Integers.
-* integers, decimal: Integers.
-* integers, hexadecimal: Integers.
-* integers, octal: Integers.
-* integers, one byte: Byte.
-* internal as sections: As Sections.
-* invocation summary: Overview.
-* joining text and data sections: R.
-* jump instructions, i386: i386-Opcodes.
-* jump optimization, i386: i386-jumps.
-* jump/call operands, i386: i386-Syntax.
-* label (:): Statements.
-* labels: Labels.
-* ld: Object.
-* length of symbols: Symbol Intro.
-* line comment character: Comments.
-* line comment character, AMD 29K: AMD29K-Chars.
-* line comment character, H8/300: H8/300-Chars.
-* line comment character, H8/500: H8/500-Chars.
-* line comment character, M680x0: M68K-Chars.
-* line comment character, SH: SH-Chars.
-* line comment character, Z8000: Z8000-Chars.
-* line numbers, in input files: Input Files.
-* line numbers, in warnings/errors: Errors.
-* line separator character: Statements.
-* line separator, H8/300: H8/300-Chars.
-* line separator, H8/500: H8/500-Chars.
-* line separator, SH: SH-Chars.
-* line separator, Z8000: Z8000-Chars.
-* lines starting with #: Comments.
-* linker: Object.
-* linker, and assembler: Secs Background.
-* listing control, turning off: Nolist.
-* listing control, turning on: List.
-* listing control: new page: Eject.
-* listing control: paper size: Psize.
-* listing control: subtitle: Sbttl.
-* listing control: title line: Title.
-* listings, enabling: a.
-* little endian output, MIPS: Overview.
-* little-endian output, MIPS: MIPS Opts.
-* local common symbols: Lcomm.
-* local labels, retaining in output: L.
-* local symbol names: Symbol Names.
-* location counter: Dot.
-* location counter, advancing: Org.
-* logical file name: App-File.
-* logical file name: File.
-* logical line number: Line.
-* logical line numbers: Comments.
-* lval: Z8000 Directives.
-* M680x0 addressing modes: M68K-Syntax.
-* M680x0 architecture options: M68K-Opts.
-* M680x0 branch improvement: M68K-Branch.
-* M680x0 directives: M68K-Directives.
-* M680x0 floating point: M68K-Float.
-* M680x0 immediate character: M68K-Chars.
-* M680x0 line comment character: M68K-Chars.
-* M680x0 opcodes: M68K-opcodes.
-* M680x0 options: M68K-Opts.
-* M680x0 pseudo-opcodes: M68K-Branch.
-* M680x0 size modifiers: M68K-Syntax.
-* M680x0 support: M68K-Dependent.
-* M680x0 syntax: M68K-Syntax.
-* machine dependencies: Machine Dependencies.
-* machine directives, AMD 29K: AMD29K Directives.
-* machine directives, H8/300 (none): H8/300 Directives.
-* machine directives, H8/500 (none): H8/500 Directives.
-* machine directives, i960: Directives-i960.
-* machine directives, SH (none): SH Directives.
-* machine directives, SPARC: Sparc-Directives.
-* machine directives, VAX: VAX-directives.
-* machine independent directives: Pseudo Ops.
-* machine instructions (not covered): Manual.
-* machine-independent syntax: Syntax.
-* macros: Macro.
-* Macros, AMD 29K: AMD29K-Macros.
-* macros, count executed: Macro.
-* manual, structure and purpose: Manual.
-* memory references, i386: i386-Memory.
-* merging text and data sections: R.
-* messages from as: Errors.
-* minus, permitted arguments: Infix Ops.
-* MIPS architecture options: MIPS Opts.
-* MIPS big-endian output: MIPS Opts.
-* MIPS debugging directives: MIPS Stabs.
-* MIPS ECOFF sections: MIPS Object.
-* MIPS endianness: Overview.
-* MIPS ISA: Overview.
-* MIPS ISA override: MIPS ISA.
-* MIPS little-endian output: MIPS Opts.
-* MIPS R2000: MIPS-Dependent.
-* MIPS R3000: MIPS-Dependent.
-* MIPS R4000: MIPS-Dependent.
-* MIPS R6000: MIPS-Dependent.
-* mnemonics for opcodes, VAX: VAX-opcodes.
-* mnemonics, H8/300: H8/300 Opcodes.
-* mnemonics, H8/500: H8/500 Opcodes.
-* mnemonics, SH: SH Opcodes.
-* mnemonics, Z8000: Z8000 Opcodes.
-* Motorola syntax for the 680x0: M68K-Moto-Syntax.
-* MRI compatibility mode: M.
-* multi-line statements: Statements.
-* name: Z8000 Directives.
-* named section (COFF): Section.
-* named sections: Ld Sections.
-* names, symbol: Symbol Names.
-* naming object file: o.
-* new page, in listings: Eject.
-* newline (\n): Strings.
-* newline, required at file end: Statements.
-* null-terminated strings: Asciz.
-* number constants: Numbers.
-* number of macros executed: Macro.
-* numbered subsections: Sub-Sections.
-* numbers, 16-bit: hword.
-* numeric values: Expressions.
-* object file: Object.
-* object file format: Object Formats.
-* object file name: o.
-* object file, after errors: Z.
-* obsolescent directives: Deprecated.
-* octal character code (\DDD): Strings.
-* octal integers: Integers.
-* opcode mnemonics, VAX: VAX-opcodes.
-* opcode naming, i386: i386-Opcodes.
-* opcode prefixes, i386: i386-prefixes.
-* opcode suffixes, i386: i386-Syntax.
-* opcode summary, H8/300: H8/300 Opcodes.
-* opcode summary, H8/500: H8/500 Opcodes.
-* opcode summary, SH: SH Opcodes.
-* opcode summary, Z8000: Z8000 Opcodes.
-* opcodes for AMD 29K: AMD29K Opcodes.
-* opcodes, i960: Opcodes for i960.
-* opcodes, M680x0: M68K-opcodes.
-* operand delimiters, i386: i386-Syntax.
-* operand notation, VAX: VAX-operands.
-* operands in expressions: Arguments.
-* operator precedence: Infix Ops.
-* operators, in expressions: Operators.
-* operators, permitted arguments: Infix Ops.
-* option summary: Overview.
-* options for AMD29K (none): AMD29K Options.
-* options for i386 (none): i386-Options.
-* options for SPARC: Sparc-Opts.
-* options for VAX/VMS: Vax-Opts.
-* options, all versions of as: Invoking.
-* options, command line: Command Line.
-* options, H8/300 (none): H8/300 Options.
-* options, H8/500 (none): H8/500 Options.
-* options, i960: Options-i960.
-* options, M680x0: M68K-Opts.
-* options, SH (none): SH Options.
-* options, Z8000: Z8000 Options.
-* other attribute, of a.out symbol: Symbol Other.
-* output file: Object.
-* padding the location counter: Align.
-* padding the location counter given a power of two: P2align.
-* padding the location counter given number of bytes: Balign.
-* page, in listings: Eject.
-* paper size, for listings: Psize.
-* paths for .include: I.
-* patterns, writing in memory: Fill.
-* plus, permitted arguments: Infix Ops.
-* precedence of operators: Infix Ops.
-* precision, floating point: Flonums.
-* prefix operators: Prefix Ops.
-* prefixes, i386: i386-prefixes.
-* preprocessing: Preprocessing.
-* preprocessing, turning on and off: Preprocessing.
-* primary attributes, COFF symbols: COFF Symbols.
-* protected registers, AMD 29K: AMD29K-Regs.
-* pseudo-opcodes, M680x0: M68K-Branch.
-* pseudo-ops for branch, VAX: VAX-branch.
-* pseudo-ops, machine independent: Pseudo Ops.
-* purpose of GNU as: GNU Assembler.
-* real-mode code, i386: i386-16bit.
-* register names, AMD 29K: AMD29K-Regs.
-* register names, H8/300: H8/300-Regs.
-* register names, VAX: VAX-operands.
-* register operands, i386: i386-Syntax.
-* registers, H8/500: H8/500-Regs.
-* registers, i386: i386-Regs.
-* registers, SH: SH-Regs.
-* registers, Z8000: Z8000-Regs.
-* relocation: Sections.
-* relocation example: Ld Sections.
-* repeat prefixes, i386: i386-prefixes.
-* return instructions, i386: i386-Syntax.
-* rsect: Z8000 Directives.
-* search path for .include: I.
-* section override prefixes, i386: i386-prefixes.
-* section-relative addressing: Secs Background.
-* sections: Sections.
-* sections in messages, internal: As Sections.
-* sections, i386: i386-Syntax.
-* sections, named: Ld Sections.
-* segm: Z8000 Directives.
-* SH addressing modes: SH-Addressing.
-* SH floating point (IEEE): SH Floating Point.
-* SH line comment character: SH-Chars.
-* SH line separator: SH-Chars.
-* SH machine directives (none): SH Directives.
-* SH opcode summary: SH Opcodes.
-* SH options (none): SH Options.
-* SH registers: SH-Regs.
-* SH support: SH-Dependent.
-* single character constant: Chars.
-* sixteen bit integers: hword.
-* sixteen byte integer: Octa.
-* size modifiers, M680x0: M68K-Syntax.
-* size prefixes, i386: i386-prefixes.
-* size suffixes, H8/300: H8/300 Opcodes.
-* sizes operands, i386: i386-Syntax.
-* small objects, MIPS ECOFF: MIPS Object.
-* SOM symbol attributes: SOM Symbols.
-* source program: Input Files.
-* source, destination operands; i386: i386-Syntax.
-* space used, maximum for assembly: statistics.
-* SPARC architectures: Sparc-Opts.
-* SPARC floating point (IEEE): Sparc-Float.
-* SPARC machine directives: Sparc-Directives.
-* SPARC options: Sparc-Opts.
-* SPARC support: Sparc-Dependent.
-* special characters, M680x0: M68K-Chars.
-* special purpose registers, AMD 29K: AMD29K-Regs.
-* standard as sections: Secs Background.
-* standard input, as input file: Command Line.
-* statement on multiple lines: Statements.
-* statement separator character: Statements.
-* statement separator, H8/300: H8/300-Chars.
-* statement separator, H8/500: H8/500-Chars.
-* statement separator, SH: SH-Chars.
-* statement separator, Z8000: Z8000-Chars.
-* statements, structure of: Statements.
-* statistics, about assembly: statistics.
-* stopping the assembly: Abort.
-* string constants: Strings.
-* string literals: Ascii.
-* string, copying to object file: String.
-* structure debugging, COFF: Tag.
-* subexpressions: Arguments.
-* subtitles for listings: Sbttl.
-* subtraction, permitted arguments: Infix Ops.
-* summary of options: Overview.
-* support: HPPA-Dependent.
-* supporting files, including: Include.
-* suppressing warnings: W.
-* sval: Z8000 Directives.
-* symbol attributes: Symbol Attributes.
-* symbol attributes, a.out: a.out Symbols.
-* symbol attributes, COFF: COFF Symbols.
-* symbol attributes, SOM: SOM Symbols.
-* symbol descriptor, COFF: Desc.
-* symbol names: Symbol Names.
-* symbol names, $ in: H8/500-Chars.
-* symbol names, $ in: SH-Chars.
-* symbol names, local: Symbol Names.
-* symbol names, temporary: Symbol Names.
-* symbol storage class (COFF): Scl.
-* symbol type: Symbol Type.
-* symbol type, COFF: Type.
-* symbol value: Symbol Value.
-* symbol value, setting: Set.
-* symbol values, assigning: Setting Symbols.
-* symbol, common: Comm.
-* symbol, making visible to linker: Global.
-* symbolic debuggers, information for: Stab.
-* symbols: Symbols.
-* symbols with lowercase, VAX/VMS: Vax-Opts.
-* symbols, assigning values to: Equ.
-* symbols, local common: Lcomm.
-* syntax compatibility, i386: i386-Syntax.
-* syntax, M680x0: M68K-Syntax.
-* syntax, machine-independent: Syntax.
-* tab (\t): Strings.
-* temporary symbol names: Symbol Names.
-* text and data sections, joining: R.
-* text section: Ld Sections.
-* time, total for assembly: statistics.
-* trusted compiler: f.
-* turning preprocessing on and off: Preprocessing.
-* type of a symbol: Symbol Type.
-* undefined section: Ld Sections.
-* unsegm: Z8000 Directives.
-* value attribute, COFF: Val.
-* value of a symbol: Symbol Value.
-* VAX bitfields not supported: VAX-no.
-* VAX branch improvement: VAX-branch.
-* VAX command-line options ignored: Vax-Opts.
-* VAX displacement sizing character: VAX-operands.
-* VAX floating point: VAX-float.
-* VAX immediate character: VAX-operands.
-* VAX indirect character: VAX-operands.
-* VAX machine directives: VAX-directives.
-* VAX opcode mnemonics: VAX-opcodes.
-* VAX operand notation: VAX-operands.
-* VAX register names: VAX-operands.
-* VAX support: Vax-Dependent.
-* Vax-11 C compatibility: Vax-Opts.
-* VAX/VMS options: Vax-Opts.
-* version of as: v.
-* VMS (VAX) options: Vax-Opts.
-* warning for altered difference tables: K.
-* warning messages: Errors.
-* warnings, suppressing: W.
-* whitespace: Whitespace.
-* whitespace, removed by preprocessor: Preprocessing.
-* wide floating point directives, VAX: VAX-directives.
-* writing patterns in memory: Fill.
-* wval: Z8000 Directives.
-* Z800 addressing modes: Z8000-Addressing.
-* Z8000 directives: Z8000 Directives.
-* Z8000 line comment character: Z8000-Chars.
-* Z8000 line separator: Z8000-Chars.
-* Z8000 opcode summary: Z8000 Opcodes.
-* Z8000 options: Z8000 Options.
-* Z8000 registers: Z8000-Regs.
-* Z8000 support: Z8000-Dependent.
-* zero-terminated strings: Asciz.
-
-
diff --git a/gnu/usr.bin/binutils/gas/doc/gasp.info b/gnu/usr.bin/binutils/gas/doc/gasp.info
deleted file mode 100644
index a47aa98a4e8..00000000000
--- a/gnu/usr.bin/binutils/gas/doc/gasp.info
+++ /dev/null
@@ -1,1087 +0,0 @@
-This is Info file gasp.info, produced by Makeinfo-1.55 from the input
-file ./gasp.texi.
-
-START-INFO-DIR-ENTRY
-* gasp: (gasp). The GNU Assembler Preprocessor
-END-INFO-DIR-ENTRY
-
- Copyright (C) 1994, 1995 Free Software Foundation, Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided also
-that the entire resulting derived work is distributed under the terms
-of a permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: gasp.info, Node: Top, Next: Overview, Prev: (DIR), Up: (DIR)
-
-GASP
-****
-
- GASP is a preprocessor for assembly programs.
-
- This file describes version 1 of GASP.
-
- Steve Chamberlain wrote GASP; Roland Pesch wrote this manual.
-
-* Menu:
-
-* Overview:: What is GASP?
-* Invoking GASP:: Command line options.
-* Commands:: Preprocessor commands.
-* Index:: Index.
-
-
-File: gasp.info, Node: Overview, Next: Invoking GASP, Prev: Top, Up: Top
-
-What is GASP?
-*************
-
- The primary purpose of the GNU assembler is to assemble the output of
-other programs--notably compilers. When you have to hand-code
-specialized routines in assembly, that means the GNU assembler is an
-unfriendly processor: it has no directives for macros, conditionals, or
-many other conveniences that you might expect.
-
- In some cases you can simply use the C preprocessor, or a generalized
-preprocessor like M4; but this can be awkward, since none of these
-things are designed with assembly in mind.
-
- GASP fills this need. It is expressly designed to provide the
-facilities you need with hand-coded assembly code. Implementing it as a
-preprocessor, rather than part of the assembler, allows the maximum
-flexibility: you can use it with hand-coded assembly, without paying a
-penalty of added complexity in the assembler you use for compiler
-output.
-
- Here is a small example to give the flavor of GASP. This input to
-GASP
-
- .MACRO saveregs from=8 to=14
- count .ASSIGNA \from
- ! save r\from..r\to
- .AWHILE \&count LE \to
- mov r\&count,@-sp
- count .ASSIGNA \&count + 1
- .AENDW
- .ENDM
-
- saveregs from=12
-
- bar: mov #H'dead+10,r0
- foo .SDATAC "hello"<10>
- .END
-
-generates this assembly program:
-
- ! save r12..r14
- mov r12,@-sp
- mov r13,@-sp
- mov r14,@-sp
-
- bar: mov #57005+10,r0
- foo: .byte 6,104,101,108,108,111,10
-
-
-File: gasp.info, Node: Invoking GASP, Next: Commands, Prev: Overview, Up: Top
-
-Command Line Options
-********************
-
- The simplest way to use GASP is to run it as a filter and assemble
-its output. In Unix and its ilk, you can do this, for example:
-
- $ gasp prog.asm | as -o prog.o
-
- Naturally, there are also a few command-line options to allow you to
-request variations on this basic theme. Here is the full set of
-possibilities for the GASP command line.
-
- gasp [ -a | --alternate ]
- [ -c CHAR | --commentchar CHAR ]
- [ -d | --debug ] [ -h | --help ] [ -M | --mri ]
- [ -o OUTFILE | --output OUTFILE ]
- [ -p | --print ] [ -s | --copysource ]
- [ -u | --unreasonable ] [ -v | --version ]
- INFILE ...
-
-`INFILE ...'
- The input file names. You must specify at least one input file;
- if you specify more, GASP preprocesses them all, concatenating the
- output in the order you list the INFILE arguments.
-
- Mark the end of each input file with the preprocessor command
- `.END'. *Note Miscellaneous commands: Other Commands.
-
-`-a'
-`--alternate'
- Use alternative macro syntax. *Note Alternate macro syntax:
- Alternate, for a discussion of how this syntax differs from the
- default GASP syntax.
-
-`-c 'CHAR''
-`--commentchar 'CHAR''
- Use CHAR as the comment character. The default comment character
- is `!'. For example, to use a semicolon as the comment character,
- specify `-c ';'' on the GASP command line. Since assembler
- command characters often have special significance to command
- shells, it is a good idea to quote or escape CHAR when you specify
- a comment character.
-
- For the sake of simplicity, all examples in this manual use the
- default comment character `!'.
-
-`-d'
-`--debug'
- Show debugging statistics. In this version of GASP, this option
- produces statistics about the string buffers that GASP allocates
- internally. For each defined buffersize S, GASP shows the number
- of strings N that it allocated, with a line like this:
-
- strings size S : N
-
- GASP displays these statistics on the standard error stream, when
- done preprocessing.
-
-`-h'
-`--help'
- Display a summary of the GASP command line options.
-
-`-M'
-`--mri'
- Use MRI compatibility mode. Using this option causes GASP to
- accept the syntax and pseudo-ops used by the Microtec Research
- `ASM68K' assembler.
-
-`-o OUTFILE'
-`--output OUTFILE'
- Write the output in a file called OUTFILE. If you do not use the
- `-o' option, GASP writes its output on the standard output stream.
-
-`-p'
-`--print'
- Print line numbers. GASP obeys this option *only* if you also
- specify `-s' to copy source lines to its output. With `-s -p',
- GASP displays the line number of each source line copied
- (immediately after the comment character at the beginning of the
- line).
-
-`-s'
-`--copysource'
- Copy the source lines to the output file. Use this option to see
- the effect of each preprocessor line on the GASP output. GASP
- places a comment character (`!' by default) at the beginning of
- each source line it copies, so that you can use this option and
- still assemble the result.
-
-`-u'
-`--unreasonable'
- Bypass "unreasonable expansion" limit. Since you can define GASP
- macros inside other macro definitions, the preprocessor normally
- includes a sanity check. If your program requires more than 1,000
- nested expansions, GASP normally exits with an error message. Use
- this option to turn off this check, allowing unlimited nested
- expansions.
-
-`-v'
-`--version'
- Display the GASP version number.
-
-
-File: gasp.info, Node: Commands, Next: Index, Prev: Invoking GASP, Up: Top
-
-Preprocessor Commands
-*********************
-
- GASP commands have a straightforward syntax that fits in well with
-assembly conventions. In general, a command extends for a line, and may
-have up to three fields: an optional label, the command itself, and
-optional arguments to the command. You can write commands in upper or
-lower case, though this manual shows them in upper case. *Note Details
-of the GASP syntax: Syntax Details, for more information.
-
-* Menu:
-
-* Conditionals::
-* Loops::
-* Variables::
-* Macros::
-* Data::
-* Listings::
-* Other Commands::
-* Syntax Details::
-* Alternate::
-
-
-File: gasp.info, Node: Conditionals, Next: Loops, Up: Commands
-
-Conditional assembly
-====================
-
- The conditional-assembly directives allow you to include or exclude
-portions of an assembly depending on how a pair of expressions, or a
-pair of strings, compare.
-
- The overall structure of conditionals is familiar from many other
-contexts. `.AIF' marks the start of a conditional, and precedes
-assembly for the case when the condition is true. An optional
-`.AELSE' precedes assembly for the converse case, and an `.AENDI' marks
-the end of the condition.
-
- You may nest conditionals up to a depth of 100; GASP rejects nesting
-beyond that, because it may indicate a bug in your macro structure.
-
- Conditionals are primarily useful inside macro definitions, where you
-often need different effects depending on argument values. *Note
-Defining your own directives: Macros, for details about defining macros.
-
-`.AIF EXPRA CMP EXPRB'
-`.AIF "STRA" CMP "STRB"'
- The governing condition goes on the same line as the `.AIF'
- preprocessor command. You may compare either two strings, or two
- expressions.
-
- When you compare strings, only two conditional CMP comparison
- operators are available: `EQ' (true if STRA and STRB are
- identical), and `NE' (the opposite).
-
- When you compare two expressions, *both expressions must be
- absolute* (*note Arithmetic expressions in GASP: Expressions.).
- You can use these CMP comparison operators with expressions:
-
- `EQ'
- Are EXPRA and EXPRB equal? (For strings, are STRA and STRB
- identical?)
-
- `NE'
- Are EXPRA and EXPRB different? (For strings, are STRA and
- STRB different?
-
- `LT'
- Is EXPRA less than EXPRB? (Not allowed for strings.)
-
- `LE'
- Is EXPRA less than or equal to EXPRB? (Not allowed for
- strings.)
-
- `GT'
- Is EXPRA greater than EXPRB? (Not allowed for strings.)
-
- `GE'
- Is EXPRA greater than or equal to EXPRB? (Not allowed for
- strings.)
-
-`.AELSE'
- Marks the start of assembly code to be included if the condition
- fails. Optional, and only allowed within a conditional (between
- `.AIF' and `.AENDI').
-
-`.AENDI'
- Marks the end of a conditional assembly.
-
-
-File: gasp.info, Node: Loops, Next: Variables, Prev: Conditionals, Up: Commands
-
-Repetitive sections of assembly
-===============================
-
- Two preprocessor directives allow you to repeatedly issue copies of
-the same block of assembly code.
-
-`.AREPEAT AEXP'
-`.AENDR'
- If you simply need to repeat the same block of assembly over and
- over a fixed number of times, sandwich one instance of the
- repeated block between `.AREPEAT' and `.AENDR'. Specify the
- number of copies as AEXP (which must be an absolute expression).
- For example, this repeats two assembly statements three times in
- succession:
-
- .AREPEAT 3
- rotcl r2
- div1 r0,r1
- .AENDR
-
-`.AWHILE EXPRA CMP EXPRB'
-`.AENDW'
-`.AWHILE STRA CMP STRB'
-`.AENDW'
- To repeat a block of assembly depending on a conditional test,
- rather than repeating it for a specific number of times, use
- `.AWHILE'. `.AENDW' marks the end of the repeated block. The
- conditional comparison works exactly the same way as for `.AIF',
- with the same comparison operators (*note Conditional assembly:
- Conditionals.).
-
- Since the terms of the comparison must be absolute expression,
- `.AWHILE' is primarily useful within macros. *Note Defining your
- own directives: Macros.
-
- You can use the `.EXITM' preprocessor directive to break out of
-loops early (as well as to break out of macros). *Note Defining your
-own directives: Macros.
-
-
-File: gasp.info, Node: Variables, Next: Macros, Prev: Loops, Up: Commands
-
-Preprocessor variables
-======================
-
- You can use variables in GASP to represent strings, registers, or
-the results of expressions.
-
- You must distinguish two kinds of variables:
- 1. Variables defined with `.EQU' or `.ASSIGN'. To evaluate this kind
- of variable in your assembly output, simply mention its name. For
- example, these two lines define and use a variable `eg':
-
- eg .EQU FLIP-64
- ...
- mov.l eg,r0
-
- *Do not use* this kind of variable in conditional expressions or
- while loops; GASP only evaluates these variables when writing
- assembly output.
-
- 2. Variables for use during preprocessing. You can define these with
- `.ASSIGNC' or `.ASSIGNA'. To evaluate this kind of variable,
- write `\&' before the variable name; for example,
-
- opcit .ASSIGNA 47
- ...
- .AWHILE \&opcit GT 0
- ...
- .AENDW
-
- GASP treats macro arguments almost the same way, but to evaluate
- them you use the prefix `\' rather than `\&'. *Note Defining your
- own directives: Macros.
-
-`PVAR .EQU EXPR'
- Assign preprocessor variable PVAR the value of the expression
- EXPR. There are no restrictions on redefinition; use `.EQU' with
- the same PVAR as often as you find it convenient.
-
-`PVAR .ASSIGN EXPR'
- Almost the same as `.EQU', save that you may not redefine PVAR
- using `.ASSIGN' once it has a value.
-
-`PVAR .ASSIGNA AEXPR'
- Define a variable with a numeric value, for use during
- preprocessing. AEXPR must be an absolute expression. You can
- redefine variables with `.ASSIGNA' at any time.
-
-`PVAR .ASSIGNC "STR"'
- Define a variable with a string value, for use during
- preprocessing. You can redefine variables with `.ASSIGNC' at any
- time.
-
-`PVAR .REG (REGISTER)'
- Use `.REG' to define a variable that represents a register. In
- particular, REGISTER is *not evaluated* as an expression. You may
- use `.REG' at will to redefine register variables.
-
- All these directives accept the variable name in the "label"
-position, that is at the left margin. You may specify a colon after
-the variable name if you wish; the first example above could have
-started `eg:' with the same effect.
-
-
-File: gasp.info, Node: Macros, Next: Data, Prev: Variables, Up: Commands
-
-Defining your own directives
-============================
-
- The commands `.MACRO' and `.ENDM' allow you to define macros that
-generate assembly output. You can use these macros with a syntax
-similar to built-in GASP or assembler directives. For example, this
-definition specifies a macro `SUM' that adds together a range of
-consecutive registers:
-
- .MACRO SUM FROM=0, TO=9
- ! \FROM \TO
- mov r\FROM,r10
- COUNT .ASSIGNA \FROM+1
- .AWHILE \&COUNT LE \TO
- add r\&COUNT,r10
- COUNT .ASSIGNA \&COUNT+1
- .AENDW
- .ENDM
-
-With that definition, `SUM 0,5' generates this assembly output:
-
- ! 0 5
- mov r0,r10
- add r1,r10
- add r2,r10
- add r3,r10
- add r4,r10
- add r5,r10
-
-`.MACRO MACNAME'
-`.MACRO MACNAME MACARGS ...'
- Begin the definition of a macro called MACNAME. If your macro
- definition requires arguments, specify their names after the macro
- name, separated by commas or spaces. You can supply a default
- value for any macro argument by following the name with `=DEFLT'.
- For example, these are all valid `.MACRO' statements:
-
- `.MACRO COMM'
- Begin the definition of a macro called `COMM', which takes no
- arguments.
-
- `.MACRO PLUS1 P, P1'
- `.MACRO PLUS1 P P1'
- Either statement begins the definition of a macro called
- `PLUS1', which takes two arguments; within the macro
- definition, write `\P' or `\P1' to evaluate the arguments.
-
- `.MACRO RESERVE_STR P1=0 P2'
- Begin the definition of a macro called `RESERVE_STR', with two
- arguments. The first argument has a default value, but not
- the second. After the definition is complete, you can call
- the macro either as `RESERVE_STR A,B' (with `\P1' evaluating
- to A and `\P2' evaluating to B), or as `RESERVE_STR ,B' (with
- `\P1' evaluating as the default, in this case `0', and `\P2'
- evaluating to B).
-
- When you call a macro, you can specify the argument values either
- by position, or by keyword. For example, `SUM 9,17' is equivalent
- to `SUM TO=17, FROM=9'. Macro arguments are preprocessor variables
- similar to the variables you define with `.ASSIGNA' or `.ASSIGNC';
- in particular, you can use them in conditionals or for loop
- control. (The only difference is the prefix you write to evaluate
- the variable: for a macro argument, write `\ARGNAME', but for a
- preprocessor variable, write `\&VARNAME'.)
-
-`NAME .MACRO'
-`NAME .MACRO ( MACARGS ... )'
- An alternative form of introducing a macro definition: specify the
- macro name in the label position, and the arguments (if any)
- between parentheses after the name. Defaulting rules and usage
- work the same way as for the other macro definition syntax.
-
-`.ENDM'
- Mark the end of a macro definition.
-
-`.EXITM'
- Exit early from the current macro definition, `.AREPEAT' loop, or
- `.AWHILE' loop.
-
-`\@'
- GASP maintains a counter of how many macros it has executed in
- this pseudo-variable; you can copy that number to your output with
- `\@', but *only within a macro definition*.
-
-`LOCAL NAME [ , ... ]'
- *Warning: `LOCAL' is only available if you select "alternate macro
- syntax" with `-a' or `--alternate'.* *Note Alternate macro
- syntax: Alternate.
-
- Generate a string replacement for each of the NAME arguments, and
- replace any instances of NAME in each macro expansion. The
- replacement string is unique in the assembly, and different for
- each separate macro expansion. `LOCAL' allows you to write macros
- that define symbols, without fear of conflict between separate
- macro expansions.
-
-
-File: gasp.info, Node: Data, Next: Listings, Prev: Macros, Up: Commands
-
-Data output
-===========
-
- In assembly code, you often need to specify working areas of memory;
-depending on the application, you may want to initialize such memory or
-not. GASP provides preprocessor directives to help you avoid
-repetitive coding for both purposes.
-
- You can use labels as usual to mark the data areas.
-
-* Menu:
-
-* Initialized::
-* Uninitialized::
-
-
-File: gasp.info, Node: Initialized, Next: Uninitialized, Up: Data
-
-Initialized data
-----------------
-
- These are the GASP directives for initialized data, and the standard
-GNU assembler directives they expand to:
-
-`.DATA EXPR, EXPR, ...'
-`.DATA.B EXPR, EXPR, ...'
-`.DATA.W EXPR, EXPR, ...'
-`.DATA.L EXPR, EXPR, ...'
- Evaluate arithmetic expressions EXPR, and emit the corresponding
- `as' directive (labelled with LAB). The unqualified `.DATA' emits
- `.long'; `.DATA.B' emits `.byte'; `.DATA.W' emits `.short'; and
- `.DATA.L' emits `.long'.
-
- For example, `foo .DATA 1,2,3' emits `foo: .long 1,2,3'.
-
-`.DATAB REPEAT, EXPR'
-`.DATAB.B REPEAT, EXPR'
-`.DATAB.W REPEAT, EXPR'
-`.DATAB.L REPEAT, EXPR'
- Make `as' emit REPEAT copies of the value of the expression EXPR
- (using the `as' directive `.fill'). `.DATAB.B' repeats one-byte
- values; `.DATAB.W' repeats two-byte values; and `.DATAB.L' repeats
- four-byte values. `.DATAB' without a suffix repeats four-byte
- values, just like `.DATAB.L'.
-
- REPEAT must be an absolute expression with a positive value.
-
-`.SDATA "STR" ...'
- String data. Emits a concatenation of bytes, precisely as you
- specify them (in particular, *nothing is added to mark the end* of
- the string). *Note String and numeric constants: Constants, for
- details about how to write strings. `.SDATA' concatenates multiple
- arguments, making it easy to switch between string
- representations. You can use commas to separate the individual
- arguments for clarity, if you choose.
-
-`.SDATAB REPEAT, "STR" ...'
- Repeated string data. The first argument specifies how many
- copies of the string to emit; the remaining arguments specify the
- string, in the same way as the arguments to `.SDATA'.
-
-`.SDATAZ "STR" ...'
- Zero-terminated string data. Just like `.SDATA', except that
- `.SDATAZ' writes a zero byte at the end of the string.
-
-`.SDATAC "STR" ...'
- Count-prefixed string data. Just like `.SDATA', except that GASP
- precedes the string with a leading one-byte count. For example,
- `.SDATAC "HI"' generates `.byte 2,72,73'. Since the count field
- is only one byte, you can only use `.SDATAC' for strings less than
- 256 bytes in length.
-
-
-File: gasp.info, Node: Uninitialized, Prev: Initialized, Up: Data
-
-Uninitialized data
-------------------
-
- Use the `.RES', `.SRES', `.SRESC', and `.SRESZ' directives to
-reserve memory and leave it uninitialized. GASP resolves these
-directives to appropriate calls of the GNU `as' `.space' directive.
-
-`.RES COUNT'
-`.RES.B COUNT'
-`.RES.W COUNT'
-`.RES.L COUNT'
- Reserve room for COUNT uninitialized elements of data. The suffix
- specifies the size of each element: `.RES.B' reserves COUNT bytes,
- `.RES.W' reserves COUNT pairs of bytes, and `.RES.L' reserves
- COUNT quartets. `.RES' without a suffix is equivalent to `.RES.L'.
-
-`.SRES COUNT'
-`.SRES.B COUNT'
-`.SRES.W COUNT'
-`.SRES.L COUNT'
- `.SRES' is a synonym for `.RES'.
-
-`.SRESC COUNT'
-`.SRESC.B COUNT'
-`.SRESC.W COUNT'
-`.SRESC.L COUNT'
- Like `.SRES', but reserves space for `COUNT+1' elements.
-
-`.SRESZ COUNT'
-`.SRESZ.B COUNT'
-`.SRESZ.W COUNT'
-`.SRESZ.L COUNT'
- Like `.SRES', but reserves space for `COUNT+1' elements.
-
-
-File: gasp.info, Node: Listings, Next: Other Commands, Prev: Data, Up: Commands
-
-Assembly listing control
-========================
-
- The GASP listing-control directives correspond to related GNU `as'
-directives.
-
-`.PRINT LIST'
-`.PRINT NOLIST'
- Print control. This directive emits the GNU `as' directive
- `.list' or `.nolist', according to its argument. *Note `.list':
- (as.info)List, for details on how these directives interact.
-
-`.FORM LIN=LN'
-`.FORM COL=COLS'
-`.FORM LIN=LN COL=COLS'
- Specify the page size for assembly listings: LN represents the
- number of lines, and COLS the number of columns. You may specify
- either page dimension independently, or both together. If you do
- not specify the number of lines, GASP assumes 60 lines; if you do
- not specify the number of columns, GASP assumes 132 columns. (Any
- values you may have specified in previous instances of `.FORM' do
- *not* carry over as defaults.) Emits the `.psize' assembler
- directive.
-
-`.HEADING STRING'
- Specify STRING as the title of your assembly listings. Emits
- `.title "STRING"'.
-
-`.PAGE'
- Force a new page in assembly listings. Emits `.eject'.
-
-
-File: gasp.info, Node: Other Commands, Next: Syntax Details, Prev: Listings, Up: Commands
-
-Miscellaneous commands
-======================
-
-`.ALTERNATE'
- Use the alternate macro syntax henceforth in the assembly. *Note
- Alternate macro syntax: Alternate.
-
-`.ORG'
- This command is recognized, but not yet implemented. GASP
- generates an error message for programs that use `.ORG'.
-
-`.RADIX S'
- GASP understands numbers in any of base two, eight, ten, or
- sixteen. You can encode the base explicitly in any numeric
- constant (*note String and numeric constants: Constants.). If you
- write numbers without an explicit indication of the base, the most
- recent `.RADIX S' command determines how they are interpreted. S
- is a single letter, one of the following:
-
- `.RADIX B'
- Base 2.
-
- `.RADIX Q'
- Base 8.
-
- `.RADIX D'
- Base 10. This is the original default radix.
-
- `.RADIX H'
- Base 16.
-
- You may specify the argument S in lower case (any of `bqdh') with
- the same effects.
-
-`.EXPORT NAME'
-`.GLOBAL NAME'
- Declare NAME global (emits `.global NAME'). The two directives
- are synonymous.
-
-`.PROGRAM'
- No effect: GASP accepts this directive, and silently ignores it.
-
-`.END'
- Mark end of each preprocessor file. GASP issues a warning if it
- reaches end of file without seeing this command.
-
-`.INCLUDE "STR"'
- Preprocess the file named by STR, as if its contents appeared
- where the `.INCLUDE' directive does. GASP imposes a maximum limit
- of 30 stacked include files, as a sanity check.
-
-`.ALIGN SIZE'
- Evaluate the absolute expression SIZE, and emit the assembly
- instruction `.align SIZE' using the result.
-
-
-File: gasp.info, Node: Syntax Details, Next: Alternate, Prev: Other Commands, Up: Commands
-
-Details of the GASP syntax
-==========================
-
- Since GASP is meant to work with assembly code, its statement syntax
-has no surprises for the assembly programmer.
-
- *Whitespace* (blanks or tabs; *not* newline) is partially
-significant, in that it delimits up to three fields in a line. The
-amount of whitespace does not matter; you may line up fields in separate
-lines if you wish, but GASP does not require that.
-
- The *first field*, an optional "label", must be flush left in a line
-(with no leading whitespace) if it appears at all. You may use a colon
-after the label if you wish; GASP neither requires the colon nor
-objects to it (but will not include it as part of the label name).
-
- The *second field*, which must appear after some whitespace,
-contains a GASP or assembly "directive".
-
- Any *further fields* on a line are "arguments" to the directive; you
-can separate them from one another using either commas or whitespace.
-
-* Menu:
-
-* Markers::
-* Constants::
-* Symbols::
-* Expressions::
-* String Builtins::
-
-
-File: gasp.info, Node: Markers, Next: Constants, Up: Syntax Details
-
-Special syntactic markers
--------------------------
-
- GASP recognizes a few special markers: to delimit comments, to
-continue a statement on the next line, to separate symbols from other
-characters, and to copy text to the output literally. (One other
-special marker, `\@', works only within macro definitions; *note
-Defining your own directives: Macros..)
-
- The trailing part of any GASP source line may be a "comment". A
-comment begins with the first unquoted comment character (`!' by
-default), or an escaped or doubled comment character (`\!' or `!!' by
-default), and extends to the end of a line. You can specify what
-comment character to use with the `-c' option (*note Command Line
-Options: Invoking GASP.). The two kinds of comment markers lead to
-slightly different treatment:
-
-`!'
- A single, un-escaped comment character generates an assembly
- comment in the GASP output. GASP evaluates any preprocessor
- variables (macro arguments, or variables defined with `.ASSIGNA' or
- `.ASSIGNC') present. For example, a macro that begins like this
-
- .MACRO SUM FROM=0, TO=9
- ! \FROM \TO
-
- issues as the first line of output a comment that records the
- values you used to call the macro.
-
-`\!'
-`!!'
- Either an escaped comment character, or a double comment character,
- marks a GASP source comment. GASP does not copy such comments to
- the assembly output.
-
- To *continue a statement* on the next line of the file, begin the
-second line with the character `+'.
-
- Occasionally you may want to prevent GASP from preprocessing some
-particular bit of text. To *copy literally* from the GASP source to
-its output, place `\(' before the string to copy, and `)' at the end.
-For example, write `\(\!)' if you need the characters `\!' in your
-assembly output.
-
- To *separate a preprocessor variable* from text to appear
-immediately after its value, write a single quote (`''). For example,
-`.SDATA "\P'1"' writes a string built by concatenating the value of `P'
-and the digit `1'. (You cannot achieve this by writing just `\P1',
-since `P1' is itself a valid name for a preprocessor variable.)
-
-
-File: gasp.info, Node: Constants, Next: Symbols, Prev: Markers, Up: Syntax Details
-
-String and numeric constants
-----------------------------
-
- There are two ways of writing "string constants" in GASP: as literal
-text, and by numeric byte value. Specify a string literal between
-double quotes (`"STR"'). Specify an individual numeric byte value as
-an absolute expression between angle brackets (`<EXPR>'. Directives
-that output strings allow you to specify any number of either kind of
-value, in whatever order is convenient, and concatenate the result.
-(Alternate syntax mode introduces a number of alternative string
-notations; *note Alternate macro syntax: Alternate..)
-
- You can write "numeric constants" either in a specific base, or in
-whatever base is currently selected (either 10, or selected by the most
-recent `.RADIX').
-
- To write a number in a *specific base*, use the pattern `S'DDD': a
-base specifier character S, followed by a single quote followed by
-digits DDD. The base specifier character matches those you can specify
-with `.RADIX': `B' for base 2, `Q' for base 8, `D' for base 10, and `H'
-for base 16. (You can write this character in lower case if you
-prefer.)
-
-
-File: gasp.info, Node: Symbols, Next: Expressions, Prev: Constants, Up: Syntax Details
-
-Symbols
--------
-
- GASP recognizes symbol names that start with any alphabetic
-character, `_', or `$', and continue with any of the same characters or
-with digits. Label names follow the same rules.
-
-
-File: gasp.info, Node: Expressions, Next: String Builtins, Prev: Symbols, Up: Syntax Details
-
-Arithmetic expressions in GASP
-------------------------------
-
- There are two kinds of expressions, depending on their result:
-"absolute" expressions, which resolve to a constant (that is, they do
-not involve any values unknown to GASP), and "relocatable" expressions,
-which must reduce to the form
-
- ADDSYM+CONST-SUBSYM
-
-where ADDSYM and SUBSYM are assembly symbols of unknown value, and
-CONST is a constant.
-
- Arithmetic for GASP expressions follows very similar rules to C.
-You can use parentheses to change precedence; otherwise, arithmetic
-primitives have decreasing precedence in the order of the following
-list.
-
- 1. Single-argument `+' (identity), `-' (arithmetic opposite), or `~'
- (bitwise negation). *The argument must be an absolute expression.*
-
- 2. `*' (multiplication) and `/' (division). *Both arguments must be
- absolute expressions.*
-
- 3. `+' (addition) and `-' (subtraction). *At least one argument must
- be absolute.*
-
- 4. `&' (bitwise and). *Both arguments must be absolute.*
-
- 5. `|' (bitwise or) and `~' (bitwise exclusive or; `^' in C). *Both
- arguments must be absolute.*
-
-
-File: gasp.info, Node: String Builtins, Prev: Expressions, Up: Syntax Details
-
-String primitives
------------------
-
- You can use these primitives to manipulate strings (in the argument
-field of GASP statements):
-
-`.LEN("STR")'
- Calculate the length of string `"STR"', as an absolute expression.
- For example, `.RES.B .LEN("sample")' reserves six bytes of memory.
-
-`.INSTR("STRING", "SEG", IX)'
- Search for the first occurrence of SEG after position IX of
- STRING. For example, `.INSTR("ABCDEFG", "CDE", 0)' evaluates to
- the absolute result `2'.
-
- The result is `-1' if SEG does not occur in STRING after position
- IX.
-
-`.SUBSTR("STRING",START,LEN)'
- The substring of STRING beginning at byte number START and
- extending for LEN bytes.
-
-
-File: gasp.info, Node: Alternate, Prev: Syntax Details, Up: Commands
-
-Alternate macro syntax
-======================
-
- If you specify `-a' or `--alternate' on the GASP command line, the
-preprocessor uses somewhat different syntax. This syntax is
-reminiscent of the syntax of Phar Lap macro assembler, but it is *not*
-meant to be a full emulation of Phar Lap or similar assemblers. In
-particular, GASP does not support directives such as `DB' and `IRP',
-even in alternate syntax mode.
-
- In particular, `-a' (or `--alternate') elicits these differences:
-
-*Preprocessor directives*
- You can use GASP preprocessor directives without a leading `.'
- dot. For example, you can write `SDATA' with the same effect as
- `.SDATA'.
-
-*LOCAL*
- One additional directive, `LOCAL', is available. *Note Defining
- your own directives: Macros, for an explanation of how to use
- `LOCAL'.
-
-*String delimiters*
- You can write strings delimited in these other ways besides
- `"STRING"':
-
- `'STRING''
- You can delimit strings with single-quote charaters.
-
- `<STRING>'
- You can delimit strings with matching angle brackets.
-
-*single-character string escape*
- To include any single character literally in a string (even if the
- character would otherwise have some special meaning), you can
- prefix the character with `!' (an exclamation mark). For example,
- you can write `<4.3 !> 5.4!!>' to get the literal text `4.3 >
- 5.4!'.
-
-*Expression results as strings*
- You can write `%EXPR' to evaluate the expression EXPR and use the
- result as a string.
-
-
-File: gasp.info, Node: Index, Prev: Commands, Up: Top
-
-Index
-*****
-
-* Menu:
-
-* +: Markers.
-* -alternate: Invoking GASP.
-* -commentchar 'CHAR': Invoking GASP.
-* -copysource: Invoking GASP.
-* -debug: Invoking GASP.
-* -help: Invoking GASP.
-* -mri: Invoking GASP.
-* -output OUTFILE: Invoking GASP.
-* -print: Invoking GASP.
-* -unreasonable: Invoking GASP.
-* -version: Invoking GASP.
-* -a: Invoking GASP.
-* -c 'CHAR': Invoking GASP.
-* -d: Invoking GASP.
-* -h: Invoking GASP.
-* -M: Invoking GASP.
-* -o OUTFILE: Invoking GASP.
-* -p: Invoking GASP.
-* -s: Invoking GASP.
-* -u: Invoking GASP.
-* -v: Invoking GASP.
-* .AELSE: Conditionals.
-* .AENDI: Conditionals.
-* .AENDR: Loops.
-* .AENDW: Loops.
-* .AENDW: Loops.
-* .AIF "STRA" CMP "STRB": Conditionals.
-* .AIF EXPRA CMP EXPRB: Conditionals.
-* .ALIGN SIZE: Other Commands.
-* .ALTERNATE: Other Commands.
-* .AREPEAT AEXP: Loops.
-* .AWHILE EXPRA CMP EXPRB: Loops.
-* .AWHILE STRA CMP STRB: Loops.
-* .DATA EXPR, EXPR, ...: Initialized.
-* .DATA.B EXPR, EXPR, ...: Initialized.
-* .DATA.L EXPR, EXPR, ...: Initialized.
-* .DATA.W EXPR, EXPR, ...: Initialized.
-* .DATAB REPEAT, EXPR: Initialized.
-* .DATAB.B REPEAT, EXPR: Initialized.
-* .DATAB.L REPEAT, EXPR: Initialized.
-* .DATAB.W REPEAT, EXPR: Initialized.
-* .END: Other Commands.
-* .ENDM: Macros.
-* .EXITM: Macros.
-* .EXPORT NAME: Other Commands.
-* .FORM COL=COLS: Listings.
-* .FORM LIN=LN: Listings.
-* .FORM LIN=LN COL=COLS: Listings.
-* .GLOBAL NAME: Other Commands.
-* .HEADING STRING: Listings.
-* .INCLUDE "STR": Other Commands.
-* .INSTR("STRING", "SEG", IX): String Builtins.
-* .LEN("STR"): String Builtins.
-* .MACRO MACNAME: Macros.
-* .MACRO MACNAME MACARGS ...: Macros.
-* .ORG: Other Commands.
-* .PAGE: Listings.
-* .PRINT LIST: Listings.
-* .PRINT NOLIST: Listings.
-* .PROGRAM: Other Commands.
-* .RADIX S: Other Commands.
-* .RES COUNT: Uninitialized.
-* .RES.B COUNT: Uninitialized.
-* .RES.L COUNT: Uninitialized.
-* .RES.W COUNT: Uninitialized.
-* .SDATA "STR" ...: Initialized.
-* .SDATAB REPEAT, "STR" ...: Initialized.
-* .SDATAC "STR" ...: Initialized.
-* .SDATAZ "STR" ...: Initialized.
-* .SRES COUNT: Uninitialized.
-* .SRES.B COUNT: Uninitialized.
-* .SRES.L COUNT: Uninitialized.
-* .SRES.W COUNT: Uninitialized.
-* .SRESC COUNT: Uninitialized.
-* .SRESC.B COUNT: Uninitialized.
-* .SRESC.L COUNT: Uninitialized.
-* .SRESC.W COUNT: Uninitialized.
-* .SRESZ COUNT: Uninitialized.
-* .SRESZ.B COUNT: Uninitialized.
-* .SRESZ.L COUNT: Uninitialized.
-* .SRESZ.W COUNT: Uninitialized.
-* .SUBSTR("STRING",START,LEN): String Builtins.
-* ! default comment char: Invoking GASP.
-* ; as comment char: Invoking GASP.
-* INFILE ...: Invoking GASP.
-* NAME .MACRO: Macros.
-* NAME .MACRO ( MACARGS ... ): Macros.
-* PVAR .ASSIGN EXPR: Variables.
-* PVAR .ASSIGNA AEXPR: Variables.
-* PVAR .ASSIGNC "STR": Variables.
-* PVAR .EQU EXPR: Variables.
-* PVAR .REG (REGISTER): Variables.
-* absolute expressions: Expressions.
-* argument fields: Syntax Details.
-* avoiding preprocessing: Markers.
-* bang, as comment: Invoking GASP.
-* breaking out of loops: Loops.
-* comment character, changing: Invoking GASP.
-* comments: Markers.
-* continuation character: Markers.
-* copying literally to output: Markers.
-* directive field: Syntax Details.
-* EQ: Conditionals.
-* exclamation mark, as comment: Invoking GASP.
-* fields of GASP source line: Syntax Details.
-* GE: Conditionals.
-* GT: Conditionals.
-* label field: Syntax Details.
-* LE: Conditionals.
-* literal copy to output: Markers.
-* LOCAL NAME [ , ... ]: Macros.
-* loops, breaking out of: Loops.
-* LT: Conditionals.
-* macros, count executed: Macros.
-* NE: Conditionals.
-* number of macros executed: Macros.
-* preprocessing, avoiding: Markers.
-* relocatable expressions: Expressions.
-* semicolon, as comment: Invoking GASP.
-* shriek, as comment: Invoking GASP.
-* symbol separator: Markers.
-* symbols, separating from text: Markers.
-* text, separating from symbols: Markers.
-* whitespace: Syntax Details.
-* \@: Macros.
-
-
-
-Tag Table:
-Node: Top828
-Node: Overview1276
-Node: Invoking GASP2942
-Node: Commands6678
-Node: Conditionals7354
-Node: Loops9646
-Node: Variables11171
-Node: Macros13566
-Node: Data17528
-Node: Initialized17976
-Node: Uninitialized20255
-Node: Listings21266
-Node: Other Commands22462
-Node: Syntax Details24214
-Node: Markers25350
-Node: Constants27598
-Node: Symbols28800
-Node: Expressions29096
-Node: String Builtins30328
-Node: Alternate31109
-Node: Index32727
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/gas/m68k-parse.c b/gnu/usr.bin/binutils/gas/m68k-parse.c
deleted file mode 100644
index 60decaab7d4..00000000000
--- a/gnu/usr.bin/binutils/gas/m68k-parse.c
+++ /dev/null
@@ -1,1916 +0,0 @@
-
-/* A Bison parser, made from ./config/m68k-parse.y with Bison version GNU Bison version 1.24
- */
-
-#define YYBISON 1 /* Identify Bison output. */
-
-#define DR 258
-#define AR 259
-#define FPR 260
-#define FPCR 261
-#define LPC 262
-#define ZAR 263
-#define ZDR 264
-#define LZPC 265
-#define CREG 266
-#define INDEXREG 267
-#define EXPR 268
-
-#line 27 "./config/m68k-parse.y"
-
-
-#include "as.h"
-#include "tc-m68k.h"
-#include "m68k-parse.h"
-
-/* Remap normal yacc parser interface names (yyparse, yylex, yyerror,
- etc), as well as gratuitiously global symbol names If other parser
- generators (bison, byacc, etc) produce additional global names that
- conflict at link time, then those parser generators need to be
- fixed instead of adding those names to this list. */
-
-#define yymaxdepth m68k_maxdepth
-#define yyparse m68k_parse
-#define yylex m68k_lex
-#define yyerror m68k_error
-#define yylval m68k_lval
-#define yychar m68k_char
-#define yydebug m68k_debug
-#define yypact m68k_pact
-#define yyr1 m68k_r1
-#define yyr2 m68k_r2
-#define yydef m68k_def
-#define yychk m68k_chk
-#define yypgo m68k_pgo
-#define yyact m68k_act
-#define yyexca m68k_exca
-#define yyerrflag m68k_errflag
-#define yynerrs m68k_nerrs
-#define yyps m68k_ps
-#define yypv m68k_pv
-#define yys m68k_s
-#define yy_yys m68k_yys
-#define yystate m68k_state
-#define yytmp m68k_tmp
-#define yyv m68k_v
-#define yy_yyv m68k_yyv
-#define yyval m68k_val
-#define yylloc m68k_lloc
-#define yyreds m68k_reds /* With YYDEBUG defined */
-#define yytoks m68k_toks /* With YYDEBUG defined */
-#define yylhs m68k_yylhs
-#define yylen m68k_yylen
-#define yydefred m68k_yydefred
-#define yydgoto m68k_yydgoto
-#define yysindex m68k_yysindex
-#define yyrindex m68k_yyrindex
-#define yygindex m68k_yygindex
-#define yytable m68k_yytable
-#define yycheck m68k_yycheck
-
-#ifndef YYDEBUG
-#define YYDEBUG 1
-#endif
-
-/* Internal functions. */
-
-static enum m68k_register m68k_reg_parse PARAMS ((char **));
-static int yylex PARAMS (());
-static void yyerror PARAMS ((const char *));
-
-/* The parser sets fields pointed to by this global variable. */
-static struct m68k_op *op;
-
-
-#line 93 "./config/m68k-parse.y"
-typedef union
-{
- struct m68k_indexreg indexreg;
- enum m68k_register reg;
- struct m68k_exp exp;
- unsigned long mask;
- int onereg;
-} YYSTYPE;
-
-#ifndef YYLTYPE
-typedef
- struct yyltype
- {
- int timestamp;
- int first_line;
- int first_column;
- int last_line;
- int last_column;
- char *text;
- }
- yyltype;
-
-#define YYLTYPE yyltype
-#endif
-
-#include <stdio.h>
-
-#ifndef __cplusplus
-#ifndef __STDC__
-#define const
-#endif
-#endif
-
-
-
-#define YYFINAL 168
-#define YYFLAG -32768
-#define YYNTBASE 25
-
-#define YYTRANSLATE(x) ((unsigned)(x) <= 268 ? yytranslate[x] : 44)
-
-static const char yytranslate[] = { 0,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 14, 2, 2, 15, 2, 16,
- 17, 2, 18, 20, 19, 2, 24, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 23, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 21, 2, 22, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 1, 2, 3, 4, 5,
- 6, 7, 8, 9, 10, 11, 12, 13
-};
-
-#if YYDEBUG != 0
-static const short yyprhs[] = { 0,
- 0, 2, 4, 6, 8, 10, 12, 14, 16, 18,
- 21, 24, 26, 30, 35, 40, 46, 51, 55, 59,
- 63, 71, 79, 86, 93, 99, 106, 112, 118, 123,
- 133, 141, 150, 157, 168, 177, 188, 197, 206, 209,
- 213, 217, 223, 230, 241, 251, 262, 264, 266, 268,
- 270, 272, 274, 276, 278, 280, 282, 284, 286, 288,
- 290, 291, 293, 295, 297, 298, 301, 302, 305, 306,
- 309, 311, 315, 319, 321, 323, 327, 331, 335, 337,
- 339, 341
-};
-
-static const short yyrhs[] = { 26,
- 0, 27, 0, 28, 0, 3, 0, 4, 0, 5,
- 0, 6, 0, 11, 0, 13, 0, 14, 13, 0,
- 15, 13, 0, 40, 0, 16, 4, 17, 0, 16,
- 4, 17, 18, 0, 19, 16, 4, 17, 0, 16,
- 13, 20, 34, 17, 0, 13, 16, 34, 17, 0,
- 16, 7, 17, 0, 16, 8, 17, 0, 16, 10,
- 17, 0, 16, 13, 20, 34, 20, 29, 17, 0,
- 16, 13, 20, 34, 20, 36, 17, 0, 16, 13,
- 20, 30, 37, 17, 0, 13, 16, 34, 20, 29,
- 17, 0, 16, 34, 20, 29, 17, 0, 13, 16,
- 34, 20, 36, 17, 0, 16, 34, 20, 36, 17,
- 0, 13, 16, 30, 37, 17, 0, 16, 30, 37,
- 17, 0, 16, 21, 13, 37, 22, 20, 29, 38,
- 17, 0, 16, 21, 13, 37, 22, 38, 17, 0,
- 16, 21, 34, 22, 20, 29, 38, 17, 0, 16,
- 21, 34, 22, 38, 17, 0, 16, 21, 13, 20,
- 34, 20, 29, 22, 38, 17, 0, 16, 21, 34,
- 20, 29, 22, 38, 17, 0, 16, 21, 13, 20,
- 34, 20, 36, 22, 38, 17, 0, 16, 21, 34,
- 20, 36, 22, 38, 17, 0, 16, 21, 39, 30,
- 37, 22, 38, 17, 0, 35, 23, 0, 35, 23,
- 18, 0, 35, 23, 19, 0, 35, 23, 16, 13,
- 17, 0, 35, 23, 16, 39, 29, 17, 0, 35,
- 23, 16, 13, 17, 23, 16, 39, 29, 17, 0,
- 35, 23, 16, 13, 17, 23, 16, 13, 17, 0,
- 35, 23, 16, 39, 29, 17, 23, 16, 13, 17,
- 0, 12, 0, 31, 0, 12, 0, 32, 0, 32,
- 0, 4, 0, 8, 0, 3, 0, 9, 0, 4,
- 0, 7, 0, 33, 0, 10, 0, 8, 0, 0,
- 34, 0, 7, 0, 10, 0, 0, 20, 34, 0,
- 0, 20, 13, 0, 0, 13, 20, 0, 42, 0,
- 42, 24, 41, 0, 43, 24, 41, 0, 43, 0,
- 42, 0, 42, 24, 41, 0, 43, 24, 41, 0,
- 43, 19, 43, 0, 3, 0, 4, 0, 5, 0,
- 6, 0
-};
-
-#endif
-
-#if YYDEBUG != 0
-static const short yyrline[] = { 0,
- 116, 118, 119, 124, 130, 135, 140, 145, 150, 155,
- 160, 165, 177, 183, 188, 193, 203, 213, 218, 223,
- 228, 235, 246, 253, 260, 266, 277, 287, 294, 300,
- 308, 315, 322, 328, 336, 343, 355, 366, 378, 387,
- 395, 403, 413, 420, 428, 435, 448, 450, 462, 464,
- 475, 477, 478, 483, 485, 490, 492, 498, 500, 501,
- 506, 511, 516, 518, 523, 528, 536, 542, 550, 556,
- 564, 566, 570, 581, 586, 587, 591, 597, 604, 609,
- 613, 617
-};
-
-static const char * const yytname[] = { "$","error","$undefined.","DR","AR",
-"FPR","FPCR","LPC","ZAR","ZDR","LZPC","CREG","INDEXREG","EXPR","'#'","'&'","'('",
-"')'","'+'","'-'","','","'['","']'","'@'","'/'","operand","generic_operand",
-"motorola_operand","mit_operand","zireg","zdireg","zadr","zdr","apc","zapc",
-"optzapc","zpc","optczapc","optcexpr","optexprc","reglist","ireglist","reglistpair",
-"reglistreg",""
-};
-#endif
-
-static const short yyr1[] = { 0,
- 25, 25, 25, 26, 26, 26, 26, 26, 26, 26,
- 26, 26, 27, 27, 27, 27, 27, 27, 27, 27,
- 27, 27, 27, 27, 27, 27, 27, 27, 27, 27,
- 27, 27, 27, 27, 27, 27, 27, 27, 28, 28,
- 28, 28, 28, 28, 28, 28, 29, 29, 30, 30,
- 31, 31, 31, 32, 32, 33, 33, 34, 34, 34,
- 35, 35, 36, 36, 37, 37, 38, 38, 39, 39,
- 40, 40, 40, 41, 41, 41, 41, 42, 43, 43,
- 43, 43
-};
-
-static const short yyr2[] = { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 2,
- 2, 1, 3, 4, 4, 5, 4, 3, 3, 3,
- 7, 7, 6, 6, 5, 6, 5, 5, 4, 9,
- 7, 8, 6, 10, 8, 10, 8, 8, 2, 3,
- 3, 5, 6, 10, 9, 10, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 0, 1, 1, 1, 0, 2, 0, 2, 0, 2,
- 1, 3, 3, 1, 1, 3, 3, 3, 1, 1,
- 1, 1
-};
-
-static const short yydefact[] = { 61,
- 79, 80, 81, 82, 57, 60, 59, 8, 9, 0,
- 0, 0, 0, 1, 2, 3, 58, 62, 0, 12,
- 71, 0, 0, 10, 11, 54, 56, 57, 60, 55,
- 59, 49, 0, 69, 65, 50, 0, 0, 39, 0,
- 0, 0, 56, 65, 0, 13, 18, 19, 20, 0,
- 65, 0, 0, 0, 0, 0, 0, 69, 40, 41,
- 79, 80, 81, 82, 72, 75, 74, 78, 73, 0,
- 17, 0, 14, 65, 0, 70, 0, 0, 67, 65,
- 66, 29, 52, 63, 53, 64, 47, 0, 48, 51,
- 0, 15, 0, 0, 0, 0, 28, 0, 0, 0,
- 16, 0, 66, 67, 0, 0, 0, 0, 0, 25,
- 27, 42, 70, 0, 76, 77, 24, 26, 23, 0,
- 0, 0, 0, 0, 67, 67, 68, 67, 33, 67,
- 0, 43, 21, 22, 0, 0, 67, 31, 0, 0,
- 0, 0, 0, 69, 0, 67, 67, 0, 35, 37,
- 32, 38, 0, 0, 0, 0, 0, 30, 45, 0,
- 0, 34, 36, 44, 46, 0, 0, 0
-};
-
-static const short yydefgoto[] = { 166,
- 14, 15, 16, 88, 35, 89, 90, 17, 18, 19,
- 91, 55, 108, 53, 20, 65, 66, 67
-};
-
-static const short yypact[] = { 74,
- 19, 14, 33, 53,-32768,-32768,-32768,-32768, 45, 57,
- 81, 55, 79,-32768,-32768,-32768,-32768,-32768, 83,-32768,
- 86, -2, 95,-32768,-32768,-32768, 94, 104, 119,-32768,
- 121,-32768, 113, 112, 120,-32768, 122, 137, 116, 125,
- 125, 125,-32768, 120, -5, 126,-32768,-32768,-32768, 95,
- 123, 117, 115, 65, 128, 105, 129, 134,-32768,-32768,
--32768,-32768,-32768,-32768,-32768, 124, 36,-32768,-32768, 132,
--32768, 105,-32768, 120, 25, 65, 130, 105, 131, 120,
--32768,-32768,-32768,-32768,-32768,-32768,-32768, 133,-32768,-32768,
- 136,-32768, 54, 17, 125, 125,-32768, 138, 139, 140,
--32768, 105, 141, 142, 143, 144, 88, 146, 145,-32768,
--32768, 135,-32768, 147,-32768,-32768,-32768,-32768,-32768, 151,
- 152, 105, 88, 153, 154, 154,-32768, 154,-32768, 154,
- 155, 149,-32768,-32768, 156, 157, 154,-32768, 160, 158,
- 159, 163, 164, 169, 161, 154, 154, 166,-32768,-32768,
--32768,-32768, 106, 17, 171, 168, 170,-32768,-32768, 172,
- 173,-32768,-32768,-32768,-32768, 186, 188,-32768
-};
-
-static const short yypgoto[] = {-32768,
--32768,-32768,-32768, -71, -15,-32768, -7,-32768, -10,-32768,
- -68, -33, -98, -58,-32768, -39, 191, 9
-};
-
-
-#define YYLAST 191
-
-
-static const short yytable[] = { 94,
- 98, 37, 69, 99, 36, 124, 105, 44, 22, 106,
- 70, 71, 45, -5, 72, 36, 41, 77, -4, 26,
- 83, 42, 114, 52, 85, 30, 140, 141, 87, 142,
- 120, 143, -6, 121, 74, 128, -56, 80, 148, 75,
- 100, 101, 36, 81, 102, 36, 109, 156, 157, 68,
- 135, 137, -7, 136, 41, 115, 116, 26, 27, 96,
- 23, 28, 29, 30, 31, 103, 32, 33, 43, 24,
- 112, 5, 6, 113, 7, 34, 1, 2, 3, 4,
- 5, 6, 160, 7, 8, 154, 9, 10, 11, 12,
- 26, 83, 13, 25, 38, 85, 30, 26, 43, 87,
- 127, 5, 6, 30, 7, 39, 32, 26, 83, 40,
- 46, 84, 85, 30, 86, 43, 87, 26, 5, 6,
- 47, 7, 159, 30, 51, 113, 32, 61, 62, 63,
- 64, 58, 50, 59, 60, 48, 78, 49, 79, 54,
- 57, 56, 76, 73, 82, 92, 93, 95, 97, 110,
- 107, 104, 111, 0, 117, 118, 119, 131, 0, 0,
- 122, 123, 129, 132, 125, 126, 130, 133, 134, 138,
- 144, 145, 127, 139, 149, 150, 155, 146, 147, 151,
- 152, 153, 158, 161, 162, 167, 163, 168, 164, 165,
- 21
-};
-
-static const short yycheck[] = { 58,
- 72, 12, 42, 72, 12, 104, 78, 23, 0, 78,
- 44, 17, 23, 0, 20, 23, 19, 51, 0, 3,
- 4, 24, 94, 34, 8, 9, 125, 126, 12, 128,
- 102, 130, 0, 102, 50, 107, 23, 53, 137, 50,
- 74, 17, 50, 54, 20, 53, 80, 146, 147, 41,
- 122, 123, 0, 122, 19, 95, 96, 3, 4, 24,
- 16, 7, 8, 9, 10, 76, 12, 13, 4, 13,
- 17, 7, 8, 20, 10, 21, 3, 4, 5, 6,
- 7, 8, 154, 10, 11, 144, 13, 14, 15, 16,
- 3, 4, 19, 13, 16, 8, 9, 3, 4, 12,
- 13, 7, 8, 9, 10, 23, 12, 3, 4, 24,
- 17, 7, 8, 9, 10, 4, 12, 3, 7, 8,
- 17, 10, 17, 9, 13, 20, 12, 3, 4, 5,
- 6, 16, 20, 18, 19, 17, 20, 17, 22, 20,
- 4, 20, 20, 18, 17, 17, 13, 24, 17, 17,
- 20, 22, 17, -1, 17, 17, 17, 23, -1, -1,
- 20, 20, 17, 17, 22, 22, 22, 17, 17, 17,
- 16, 23, 13, 20, 17, 17, 16, 22, 22, 17,
- 17, 13, 17, 13, 17, 0, 17, 0, 17, 17,
- 0
-};
-/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
-#line 3 "/usr/unsupported/share/bison.simple"
-
-/* Skeleton output parser for bison,
- Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-#ifndef alloca
-#ifdef __GNUC__
-#define alloca __builtin_alloca
-#else /* not GNU C. */
-#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi)
-#include <alloca.h>
-#else /* not sparc */
-#if defined (MSDOS) && !defined (__TURBOC__)
-#include <malloc.h>
-#else /* not MSDOS, or __TURBOC__ */
-#if defined(_AIX)
-#include <malloc.h>
- #pragma alloca
-#else /* not MSDOS, __TURBOC__, or _AIX */
-#ifdef __hpux
-#ifdef __cplusplus
-extern "C" {
-void *alloca (unsigned int);
-};
-#else /* not __cplusplus */
-void *alloca ();
-#endif /* not __cplusplus */
-#endif /* __hpux */
-#endif /* not _AIX */
-#endif /* not MSDOS, or __TURBOC__ */
-#endif /* not sparc. */
-#endif /* not GNU C. */
-#endif /* alloca not defined. */
-
-/* This is the parser code that is written into each bison parser
- when the %semantic_parser declaration is not specified in the grammar.
- It was written by Richard Stallman by simplifying the hairy parser
- used when %semantic_parser is specified. */
-
-/* Note: there must be only one dollar sign in this file.
- It is replaced by the list of actions, each action
- as one case of the switch. */
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY -2
-#define YYEOF 0
-#define YYACCEPT return(0)
-#define YYABORT return(1)
-#define YYERROR goto yyerrlab1
-/* Like YYERROR except do call yyerror.
- This remains here temporarily to ease the
- transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. */
-#define YYFAIL goto yyerrlab
-#define YYRECOVERING() (!!yyerrstatus)
-#define YYBACKUP(token, value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { yychar = (token), yylval = (value); \
- yychar1 = YYTRANSLATE (yychar); \
- YYPOPSTACK; \
- goto yybackup; \
- } \
- else \
- { yyerror ("syntax error: cannot back up"); YYERROR; } \
-while (0)
-
-#define YYTERROR 1
-#define YYERRCODE 256
-
-#ifndef YYPURE
-#define YYLEX yylex()
-#endif
-
-#ifdef YYPURE
-#ifdef YYLSP_NEEDED
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval, &yylloc)
-#endif
-#else /* not YYLSP_NEEDED */
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval)
-#endif
-#endif /* not YYLSP_NEEDED */
-#endif
-
-/* If nonreentrant, generate the variables here */
-
-#ifndef YYPURE
-
-int yychar; /* the lookahead symbol */
-YYSTYPE yylval; /* the semantic value of the */
- /* lookahead symbol */
-
-#ifdef YYLSP_NEEDED
-YYLTYPE yylloc; /* location data for the lookahead */
- /* symbol */
-#endif
-
-int yynerrs; /* number of parse errors so far */
-#endif /* not YYPURE */
-
-#if YYDEBUG != 0
-int yydebug; /* nonzero means print parse trace */
-/* Since this is uninitialized, it does not stop multiple parsers
- from coexisting. */
-#endif
-
-/* YYINITDEPTH indicates the initial size of the parser's stacks */
-
-#ifndef YYINITDEPTH
-#define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH is the maximum size the stacks can grow to
- (effective only if the built-in stack extension method is used). */
-
-#if YYMAXDEPTH == 0
-#undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-#define YYMAXDEPTH 10000
-#endif
-
-/* Prevent warning if -Wstrict-prototypes. */
-#ifdef __GNUC__
-int yyparse (void);
-#endif
-
-#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
-#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT)
-#else /* not GNU C or C++ */
-#ifndef __cplusplus
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (from, to, count)
- char *from;
- char *to;
- int count;
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#else /* __cplusplus */
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (char *from, char *to, int count)
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#endif
-#endif
-
-#line 192 "/usr/unsupported/share/bison.simple"
-
-/* The user can define YYPARSE_PARAM as the name of an argument to be passed
- into yyparse. The argument should have type void *.
- It should actually point to an object.
- Grammar actions can access the variable by casting it
- to the proper pointer type. */
-
-#ifdef YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
-#else
-#define YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL
-#endif
-
-int
-yyparse(YYPARSE_PARAM)
- YYPARSE_PARAM_DECL
-{
- register int yystate;
- register int yyn;
- register short *yyssp;
- register YYSTYPE *yyvsp;
- int yyerrstatus; /* number of tokens to shift before error messages enabled */
- int yychar1 = 0; /* lookahead token as an internal (translated) token number */
-
- short yyssa[YYINITDEPTH]; /* the state stack */
- YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
-
- short *yyss = yyssa; /* refer to the stacks thru separate pointers */
- YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
-
-#ifdef YYLSP_NEEDED
- YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */
- YYLTYPE *yyls = yylsa;
- YYLTYPE *yylsp;
-
-#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
-#else
-#define YYPOPSTACK (yyvsp--, yyssp--)
-#endif
-
- int yystacksize = YYINITDEPTH;
-
-#ifdef YYPURE
- int yychar;
- YYSTYPE yylval;
- int yynerrs;
-#ifdef YYLSP_NEEDED
- YYLTYPE yylloc;
-#endif
-#endif
-
- YYSTYPE yyval; /* the variable used to return */
- /* semantic values from the action */
- /* routines */
-
- int yylen;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Starting parse\n");
-#endif
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
-
- yyssp = yyss - 1;
- yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
- yylsp = yyls;
-#endif
-
-/* Push a new state, which is found in yystate . */
-/* In all cases, when you get here, the value and location stacks
- have just been pushed. so pushing a state here evens the stacks. */
-yynewstate:
-
- *++yyssp = yystate;
-
- if (yyssp >= yyss + yystacksize - 1)
- {
- /* Give user a chance to reallocate the stack */
- /* Use copies of these so that the &'s don't force the real ones into memory. */
- YYSTYPE *yyvs1 = yyvs;
- short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
- YYLTYPE *yyls1 = yyls;
-#endif
-
- /* Get the current used size of the three stacks, in elements. */
- int size = yyssp - yyss + 1;
-
-#ifdef yyoverflow
- /* Each stack pointer address is followed by the size of
- the data in use in that stack, in bytes. */
-#ifdef YYLSP_NEEDED
- /* This used to be a conditional around just the two extra args,
- but that might be undefined if yyoverflow is a macro. */
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yyls1, size * sizeof (*yylsp),
- &yystacksize);
-#else
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yystacksize);
-#endif
-
- yyss = yyss1; yyvs = yyvs1;
-#ifdef YYLSP_NEEDED
- yyls = yyls1;
-#endif
-#else /* no yyoverflow */
- /* Extend the stack our own way. */
- if (yystacksize >= YYMAXDEPTH)
- {
- yyerror("parser stack overflow");
- return 2;
- }
- yystacksize *= 2;
- if (yystacksize > YYMAXDEPTH)
- yystacksize = YYMAXDEPTH;
- yyss = (short *) alloca (yystacksize * sizeof (*yyssp));
- __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp));
- yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp));
- __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp));
-#ifdef YYLSP_NEEDED
- yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp));
- __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp));
-#endif
-#endif /* no yyoverflow */
-
- yyssp = yyss + size - 1;
- yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
- yylsp = yyls + size - 1;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Stack size increased to %d\n", yystacksize);
-#endif
-
- if (yyssp >= yyss + yystacksize - 1)
- YYABORT;
- }
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Entering state %d\n", yystate);
-#endif
-
- goto yybackup;
- yybackup:
-
-/* Do appropriate processing given the current state. */
-/* Read a lookahead token if we need one and don't already have one. */
-/* yyresume: */
-
- /* First try to decide what to do without reference to lookahead token. */
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* yychar is either YYEMPTY or YYEOF
- or a valid token in external form. */
-
- if (yychar == YYEMPTY)
- {
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Reading a token: ");
-#endif
- yychar = YYLEX;
- }
-
- /* Convert token to internal form (in yychar1) for indexing tables with */
-
- if (yychar <= 0) /* This means end of input. */
- {
- yychar1 = 0;
- yychar = YYEOF; /* Don't call YYLEX any more */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Now at end of input.\n");
-#endif
- }
- else
- {
- yychar1 = YYTRANSLATE(yychar);
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
- /* Give the individual parser a way to print the precise meaning
- of a token, for further debugging info. */
-#ifdef YYPRINT
- YYPRINT (stderr, yychar, yylval);
-#endif
- fprintf (stderr, ")\n");
- }
-#endif
- }
-
- yyn += yychar1;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
- goto yydefault;
-
- yyn = yytable[yyn];
-
- /* yyn is what to do for this token type in this state.
- Negative => reduce, -yyn is rule number.
- Positive => shift, yyn is new state.
- New state is final state => don't bother to shift,
- just return success.
- 0, or most negative number => error. */
-
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrlab;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- /* Shift the lookahead token. */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
-#endif
-
- /* Discard the token being shifted unless it is eof. */
- if (yychar != YYEOF)
- yychar = YYEMPTY;
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- /* count tokens shifted since error; after three, turn off error status. */
- if (yyerrstatus) yyerrstatus--;
-
- yystate = yyn;
- goto yynewstate;
-
-/* Do the default action for the current state. */
-yydefault:
-
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
-
-/* Do a reduction. yyn is the number of a rule to reduce with. */
-yyreduce:
- yylen = yyr2[yyn];
- if (yylen > 0)
- yyval = yyvsp[1-yylen]; /* implement default value of the action */
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- int i;
-
- fprintf (stderr, "Reducing via rule %d (line %d), ",
- yyn, yyrline[yyn]);
-
- /* Print the symbols being reduced, and their result. */
- for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
- fprintf (stderr, "%s ", yytname[yyrhs[i]]);
- fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
- }
-#endif
-
-
- switch (yyn) {
-
-case 4:
-#line 126 "./config/m68k-parse.y"
-{
- op->mode = DREG;
- op->reg = yyvsp[0].reg;
- ;
- break;}
-case 5:
-#line 131 "./config/m68k-parse.y"
-{
- op->mode = AREG;
- op->reg = yyvsp[0].reg;
- ;
- break;}
-case 6:
-#line 136 "./config/m68k-parse.y"
-{
- op->mode = FPREG;
- op->reg = yyvsp[0].reg;
- ;
- break;}
-case 7:
-#line 141 "./config/m68k-parse.y"
-{
- op->mode = CONTROL;
- op->reg = yyvsp[0].reg;
- ;
- break;}
-case 8:
-#line 146 "./config/m68k-parse.y"
-{
- op->mode = CONTROL;
- op->reg = yyvsp[0].reg;
- ;
- break;}
-case 9:
-#line 151 "./config/m68k-parse.y"
-{
- op->mode = ABSL;
- op->disp = yyvsp[0].exp;
- ;
- break;}
-case 10:
-#line 156 "./config/m68k-parse.y"
-{
- op->mode = IMMED;
- op->disp = yyvsp[0].exp;
- ;
- break;}
-case 11:
-#line 161 "./config/m68k-parse.y"
-{
- op->mode = IMMED;
- op->disp = yyvsp[0].exp;
- ;
- break;}
-case 12:
-#line 166 "./config/m68k-parse.y"
-{
- op->mode = REGLST;
- op->mask = yyvsp[0].mask;
- ;
- break;}
-case 13:
-#line 179 "./config/m68k-parse.y"
-{
- op->mode = AINDR;
- op->reg = yyvsp[-1].reg;
- ;
- break;}
-case 14:
-#line 184 "./config/m68k-parse.y"
-{
- op->mode = AINC;
- op->reg = yyvsp[-2].reg;
- ;
- break;}
-case 15:
-#line 189 "./config/m68k-parse.y"
-{
- op->mode = ADEC;
- op->reg = yyvsp[-1].reg;
- ;
- break;}
-case 16:
-#line 194 "./config/m68k-parse.y"
-{
- op->reg = yyvsp[-1].reg;
- op->disp = yyvsp[-3].exp;
- if ((yyvsp[-1].reg >= ZADDR0 && yyvsp[-1].reg <= ZADDR7)
- || yyvsp[-1].reg == ZPC)
- op->mode = BASE;
- else
- op->mode = DISP;
- ;
- break;}
-case 17:
-#line 204 "./config/m68k-parse.y"
-{
- op->reg = yyvsp[-1].reg;
- op->disp = yyvsp[-3].exp;
- if ((yyvsp[-1].reg >= ZADDR0 && yyvsp[-1].reg <= ZADDR7)
- || yyvsp[-1].reg == ZPC)
- op->mode = BASE;
- else
- op->mode = DISP;
- ;
- break;}
-case 18:
-#line 214 "./config/m68k-parse.y"
-{
- op->mode = DISP;
- op->reg = yyvsp[-1].reg;
- ;
- break;}
-case 19:
-#line 219 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- ;
- break;}
-case 20:
-#line 224 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- ;
- break;}
-case 21:
-#line 229 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-3].reg;
- op->disp = yyvsp[-5].exp;
- op->index = yyvsp[-1].indexreg;
- ;
- break;}
-case 22:
-#line 236 "./config/m68k-parse.y"
-{
- if (yyvsp[-3].reg == PC || yyvsp[-3].reg == ZPC)
- yyerror ("syntax error");
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- op->disp = yyvsp[-5].exp;
- op->index.reg = yyvsp[-3].reg;
- op->index.size = SIZE_UNSPEC;
- op->index.scale = 1;
- ;
- break;}
-case 23:
-#line 247 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- op->disp = yyvsp[-4].exp;
- op->index = yyvsp[-2].indexreg;
- ;
- break;}
-case 24:
-#line 254 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-3].reg;
- op->disp = yyvsp[-5].exp;
- op->index = yyvsp[-1].indexreg;
- ;
- break;}
-case 25:
-#line 261 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-3].reg;
- op->index = yyvsp[-1].indexreg;
- ;
- break;}
-case 26:
-#line 267 "./config/m68k-parse.y"
-{
- if (yyvsp[-3].reg == PC || yyvsp[-3].reg == ZPC)
- yyerror ("syntax error");
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- op->disp = yyvsp[-5].exp;
- op->index.reg = yyvsp[-3].reg;
- op->index.size = SIZE_UNSPEC;
- op->index.scale = 1;
- ;
- break;}
-case 27:
-#line 278 "./config/m68k-parse.y"
-{
- if (yyvsp[-3].reg == PC || yyvsp[-3].reg == ZPC)
- yyerror ("syntax error");
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- op->index.reg = yyvsp[-3].reg;
- op->index.size = SIZE_UNSPEC;
- op->index.scale = 1;
- ;
- break;}
-case 28:
-#line 288 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- op->disp = yyvsp[-4].exp;
- op->index = yyvsp[-2].indexreg;
- ;
- break;}
-case 29:
-#line 295 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-1].reg;
- op->index = yyvsp[-2].indexreg;
- ;
- break;}
-case 30:
-#line 301 "./config/m68k-parse.y"
-{
- op->mode = POST;
- op->reg = yyvsp[-5].reg;
- op->disp = yyvsp[-6].exp;
- op->index = yyvsp[-2].indexreg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 31:
-#line 309 "./config/m68k-parse.y"
-{
- op->mode = POST;
- op->reg = yyvsp[-3].reg;
- op->disp = yyvsp[-4].exp;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 32:
-#line 316 "./config/m68k-parse.y"
-{
- op->mode = POST;
- op->reg = yyvsp[-5].reg;
- op->index = yyvsp[-2].indexreg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 33:
-#line 323 "./config/m68k-parse.y"
-{
- op->mode = POST;
- op->reg = yyvsp[-3].reg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 34:
-#line 329 "./config/m68k-parse.y"
-{
- op->mode = PRE;
- op->reg = yyvsp[-5].reg;
- op->disp = yyvsp[-7].exp;
- op->index = yyvsp[-3].indexreg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 35:
-#line 337 "./config/m68k-parse.y"
-{
- op->mode = PRE;
- op->reg = yyvsp[-5].reg;
- op->index = yyvsp[-3].indexreg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 36:
-#line 344 "./config/m68k-parse.y"
-{
- if (yyvsp[-5].reg == PC || yyvsp[-5].reg == ZPC)
- yyerror ("syntax error");
- op->mode = PRE;
- op->reg = yyvsp[-3].reg;
- op->disp = yyvsp[-7].exp;
- op->index.reg = yyvsp[-5].reg;
- op->index.size = SIZE_UNSPEC;
- op->index.scale = 1;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 37:
-#line 356 "./config/m68k-parse.y"
-{
- if (yyvsp[-5].reg == PC || yyvsp[-5].reg == ZPC)
- yyerror ("syntax error");
- op->mode = PRE;
- op->reg = yyvsp[-3].reg;
- op->index.reg = yyvsp[-5].reg;
- op->index.size = SIZE_UNSPEC;
- op->index.scale = 1;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 38:
-#line 367 "./config/m68k-parse.y"
-{
- op->mode = PRE;
- op->reg = yyvsp[-3].reg;
- op->disp = yyvsp[-5].exp;
- op->index = yyvsp[-4].indexreg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 39:
-#line 380 "./config/m68k-parse.y"
-{
- /* We use optzapc to avoid a shift/reduce conflict. */
- if (yyvsp[-1].reg < ADDR0 || yyvsp[-1].reg > ADDR7)
- yyerror ("syntax error");
- op->mode = AINDR;
- op->reg = yyvsp[-1].reg;
- ;
- break;}
-case 40:
-#line 388 "./config/m68k-parse.y"
-{
- /* We use optzapc to avoid a shift/reduce conflict. */
- if (yyvsp[-2].reg < ADDR0 || yyvsp[-2].reg > ADDR7)
- yyerror ("syntax error");
- op->mode = AINC;
- op->reg = yyvsp[-2].reg;
- ;
- break;}
-case 41:
-#line 396 "./config/m68k-parse.y"
-{
- /* We use optzapc to avoid a shift/reduce conflict. */
- if (yyvsp[-2].reg < ADDR0 || yyvsp[-2].reg > ADDR7)
- yyerror ("syntax error");
- op->mode = ADEC;
- op->reg = yyvsp[-2].reg;
- ;
- break;}
-case 42:
-#line 404 "./config/m68k-parse.y"
-{
- op->reg = yyvsp[-4].reg;
- op->disp = yyvsp[-1].exp;
- if ((yyvsp[-4].reg >= ZADDR0 && yyvsp[-4].reg <= ZADDR7)
- || yyvsp[-4].reg == ZPC)
- op->mode = BASE;
- else
- op->mode = DISP;
- ;
- break;}
-case 43:
-#line 414 "./config/m68k-parse.y"
-{
- op->mode = BASE;
- op->reg = yyvsp[-5].reg;
- op->disp = yyvsp[-2].exp;
- op->index = yyvsp[-1].indexreg;
- ;
- break;}
-case 44:
-#line 421 "./config/m68k-parse.y"
-{
- op->mode = POST;
- op->reg = yyvsp[-9].reg;
- op->disp = yyvsp[-6].exp;
- op->index = yyvsp[-1].indexreg;
- op->odisp = yyvsp[-2].exp;
- ;
- break;}
-case 45:
-#line 429 "./config/m68k-parse.y"
-{
- op->mode = POST;
- op->reg = yyvsp[-8].reg;
- op->disp = yyvsp[-5].exp;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 46:
-#line 436 "./config/m68k-parse.y"
-{
- op->mode = PRE;
- op->reg = yyvsp[-9].reg;
- op->disp = yyvsp[-6].exp;
- op->index = yyvsp[-5].indexreg;
- op->odisp = yyvsp[-1].exp;
- ;
- break;}
-case 48:
-#line 451 "./config/m68k-parse.y"
-{
- yyval.indexreg.reg = yyvsp[0].reg;
- yyval.indexreg.size = SIZE_UNSPEC;
- yyval.indexreg.scale = 1;
- ;
- break;}
-case 50:
-#line 465 "./config/m68k-parse.y"
-{
- yyval.indexreg.reg = yyvsp[0].reg;
- yyval.indexreg.size = SIZE_UNSPEC;
- yyval.indexreg.scale = 1;
- ;
- break;}
-case 61:
-#line 508 "./config/m68k-parse.y"
-{
- yyval.reg = ZADDR0;
- ;
- break;}
-case 65:
-#line 525 "./config/m68k-parse.y"
-{
- yyval.reg = ZADDR0;
- ;
- break;}
-case 66:
-#line 529 "./config/m68k-parse.y"
-{
- yyval.reg = yyvsp[0].reg;
- ;
- break;}
-case 67:
-#line 538 "./config/m68k-parse.y"
-{
- yyval.exp.exp.X_op = O_absent;
- yyval.exp.size = SIZE_UNSPEC;
- ;
- break;}
-case 68:
-#line 543 "./config/m68k-parse.y"
-{
- yyval.exp = yyvsp[0].exp;
- ;
- break;}
-case 69:
-#line 552 "./config/m68k-parse.y"
-{
- yyval.exp.exp.X_op = O_absent;
- yyval.exp.size = SIZE_UNSPEC;
- ;
- break;}
-case 70:
-#line 557 "./config/m68k-parse.y"
-{
- yyval.exp = yyvsp[-1].exp;
- ;
- break;}
-case 72:
-#line 567 "./config/m68k-parse.y"
-{
- yyval.mask = yyvsp[-2].mask | yyvsp[0].mask;
- ;
- break;}
-case 73:
-#line 571 "./config/m68k-parse.y"
-{
- yyval.mask = (1 << yyvsp[-2].onereg) | yyvsp[0].mask;
- ;
- break;}
-case 74:
-#line 583 "./config/m68k-parse.y"
-{
- yyval.mask = 1 << yyvsp[0].onereg;
- ;
- break;}
-case 76:
-#line 588 "./config/m68k-parse.y"
-{
- yyval.mask = yyvsp[-2].mask | yyvsp[0].mask;
- ;
- break;}
-case 77:
-#line 592 "./config/m68k-parse.y"
-{
- yyval.mask = (1 << yyvsp[-2].onereg) | yyvsp[0].mask;
- ;
- break;}
-case 78:
-#line 599 "./config/m68k-parse.y"
-{
- yyval.mask = (1 << (yyvsp[0].onereg + 1)) - 1 - ((1 << yyvsp[-2].onereg) - 1);
- ;
- break;}
-case 79:
-#line 606 "./config/m68k-parse.y"
-{
- yyval.onereg = yyvsp[0].reg - DATA0;
- ;
- break;}
-case 80:
-#line 610 "./config/m68k-parse.y"
-{
- yyval.onereg = yyvsp[0].reg - ADDR0 + 8;
- ;
- break;}
-case 81:
-#line 614 "./config/m68k-parse.y"
-{
- yyval.onereg = yyvsp[0].reg - FP0 + 16;
- ;
- break;}
-case 82:
-#line 618 "./config/m68k-parse.y"
-{
- if (yyvsp[0].reg == FPI)
- yyval.onereg = 24;
- else if (yyvsp[0].reg == FPS)
- yyval.onereg = 25;
- else
- yyval.onereg = 26;
- ;
- break;}
-}
- /* the action file gets copied in in place of this dollarsign */
-#line 487 "/usr/unsupported/share/bison.simple"
-
- yyvsp -= yylen;
- yyssp -= yylen;
-#ifdef YYLSP_NEEDED
- yylsp -= yylen;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
- *++yyvsp = yyval;
-
-#ifdef YYLSP_NEEDED
- yylsp++;
- if (yylen == 0)
- {
- yylsp->first_line = yylloc.first_line;
- yylsp->first_column = yylloc.first_column;
- yylsp->last_line = (yylsp-1)->last_line;
- yylsp->last_column = (yylsp-1)->last_column;
- yylsp->text = 0;
- }
- else
- {
- yylsp->last_line = (yylsp+yylen-1)->last_line;
- yylsp->last_column = (yylsp+yylen-1)->last_column;
- }
-#endif
-
- /* Now "shift" the result of the reduction.
- Determine what state that goes to,
- based on the state we popped back to
- and the rule number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
- if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTBASE];
-
- goto yynewstate;
-
-yyerrlab: /* here on detecting error */
-
- if (! yyerrstatus)
- /* If not already recovering from an error, report this error. */
- {
- ++yynerrs;
-
-#ifdef YYERROR_VERBOSE
- yyn = yypact[yystate];
-
- if (yyn > YYFLAG && yyn < YYLAST)
- {
- int size = 0;
- char *msg;
- int x, count;
-
- count = 0;
- /* Start X at -yyn if nec to avoid negative indexes in yycheck. */
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- size += strlen(yytname[x]) + 15, count++;
- msg = (char *) malloc(size + 15);
- if (msg != 0)
- {
- strcpy(msg, "parse error");
-
- if (count < 5)
- {
- count = 0;
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- {
- strcat(msg, count == 0 ? ", expecting `" : " or `");
- strcat(msg, yytname[x]);
- strcat(msg, "'");
- count++;
- }
- }
- yyerror(msg);
- free(msg);
- }
- else
- yyerror ("parse error; also virtual memory exceeded");
- }
- else
-#endif /* YYERROR_VERBOSE */
- yyerror("parse error");
- }
-
- goto yyerrlab1;
-yyerrlab1: /* here on error raised explicitly by an action */
-
- if (yyerrstatus == 3)
- {
- /* if just tried and failed to reuse lookahead token after an error, discard it. */
-
- /* return failure if at end of input */
- if (yychar == YYEOF)
- YYABORT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
-#endif
-
- yychar = YYEMPTY;
- }
-
- /* Else will try to reuse lookahead token
- after shifting the error token. */
-
- yyerrstatus = 3; /* Each real token shifted decrements this */
-
- goto yyerrhandle;
-
-yyerrdefault: /* current state does not do anything special for the error token. */
-
-#if 0
- /* This is wrong; only states that explicitly want error tokens
- should shift them. */
- yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
- if (yyn) goto yydefault;
-#endif
-
-yyerrpop: /* pop the current state because it cannot handle the error token */
-
- if (yyssp == yyss) YYABORT;
- yyvsp--;
- yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
- yylsp--;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "Error: state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
-yyerrhandle:
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yyerrdefault;
-
- yyn += YYTERROR;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
- goto yyerrdefault;
-
- yyn = yytable[yyn];
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrpop;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrpop;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting error token, ");
-#endif
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- yystate = yyn;
- goto yynewstate;
-}
-#line 628 "./config/m68k-parse.y"
-
-
-/* The string to parse is stored here, and modified by yylex. */
-
-static char *str;
-
-/* The original string pointer. */
-
-static char *strorig;
-
-/* If *CCP could be a register, return the register number and advance
- *CCP. Otherwise don't change *CCP, and return 0. */
-
-static enum m68k_register
-m68k_reg_parse (ccp)
- register char **ccp;
-{
- char *start = *ccp;
- char c;
- char *p;
- symbolS *symbolp;
-
- if (flag_reg_prefix_optional)
- {
- if (*start == REGISTER_PREFIX)
- start++;
- p = start;
- }
- else
- {
- if (*start != REGISTER_PREFIX)
- return 0;
- p = start + 1;
- }
-
- if (! is_name_beginner (*p))
- return 0;
-
- p++;
- while (is_part_of_name (*p) && *p != '.' && *p != ':' && *p != '*')
- p++;
-
- c = *p;
- *p = 0;
- symbolp = symbol_find (start);
- *p = c;
-
- if (symbolp != NULL && S_GET_SEGMENT (symbolp) == reg_section)
- {
- *ccp = p;
- return S_GET_VALUE (symbolp);
- }
-
- /* In MRI mode, something like foo.bar can be equated to a register
- name. */
- while (flag_mri && c == '.')
- {
- ++p;
- while (is_part_of_name (*p) && *p != '.' && *p != ':' && *p != '*')
- p++;
- c = *p;
- *p = '\0';
- symbolp = symbol_find (start);
- *p = c;
- if (symbolp != NULL && S_GET_SEGMENT (symbolp) == reg_section)
- {
- *ccp = p;
- return S_GET_VALUE (symbolp);
- }
- }
-
- return 0;
-}
-
-/* The lexer. */
-
-static int
-yylex ()
-{
- enum m68k_register reg;
- char *s;
- int parens;
- int c = 0;
- char *hold;
-
- if (*str == ' ')
- ++str;
-
- if (*str == '\0')
- return 0;
-
- /* Various special characters are just returned directly. */
- switch (*str)
- {
- case '#':
- case '&':
- case ',':
- case ')':
- case '/':
- case '@':
- case '[':
- case ']':
- return *str++;
- case '+':
- /* It so happens that a '+' can only appear at the end of an
- operand. If it appears anywhere else, it must be a unary
- plus on an expression. */
- if (str[1] == '\0')
- return *str++;
- break;
- case '-':
- /* A '-' can only appear in -(ar), rn-rn, or ar@-. If it
- appears anywhere else, it must be a unary minus on an
- expression. */
- if (str[1] == '\0')
- return *str++;
- s = str + 1;
- if (*s == '(')
- ++s;
- if (m68k_reg_parse (&s) != 0)
- return *str++;
- break;
- case '(':
- /* A '(' can only appear in `(reg)', `(expr,...', `([', `@(', or
- `)('. If it appears anywhere else, it must be starting an
- expression. */
- if (str[1] == '['
- || (str > strorig
- && (str[-1] == '@'
- || str[-1] == ')')))
- return *str++;
- s = str + 1;
- if (m68k_reg_parse (&s) != 0)
- return *str++;
- /* Check for the case of '(expr,...' by scanning ahead. If we
- find a comma outside of balanced parentheses, we return '('.
- If we find an unbalanced right parenthesis, then presumably
- the '(' really starts an expression. */
- parens = 0;
- for (s = str + 1; *s != '\0'; s++)
- {
- if (*s == '(')
- ++parens;
- else if (*s == ')')
- {
- if (parens == 0)
- break;
- --parens;
- }
- else if (*s == ',' && parens == 0)
- {
- /* A comma can not normally appear in an expression, so
- this is a case of '(expr,...'. */
- return *str++;
- }
- }
- }
-
- /* See if it's a register. */
-
- reg = m68k_reg_parse (&str);
- if (reg != 0)
- {
- int ret;
-
- yylval.reg = reg;
-
- if (reg >= DATA0 && reg <= DATA7)
- ret = DR;
- else if (reg >= ADDR0 && reg <= ADDR7)
- ret = AR;
- else if (reg >= FP0 && reg <= FP7)
- return FPR;
- else if (reg == FPI
- || reg == FPS
- || reg == FPC)
- return FPCR;
- else if (reg == PC)
- return LPC;
- else if (reg >= ZDATA0 && reg <= ZDATA7)
- ret = ZDR;
- else if (reg >= ZADDR0 && reg <= ZADDR7)
- ret = ZAR;
- else if (reg == ZPC)
- return LZPC;
- else
- return CREG;
-
- /* If we get here, we have a data or address register. We
- must check for a size or scale; if we find one, we must
- return INDEXREG. */
-
- s = str;
-
- if (*s != '.' && *s != ':' && *s != '*')
- return ret;
-
- yylval.indexreg.reg = reg;
-
- if (*s != '.' && *s != ':')
- yylval.indexreg.size = SIZE_UNSPEC;
- else
- {
- ++s;
- switch (*s)
- {
- case 'w':
- case 'W':
- yylval.indexreg.size = SIZE_WORD;
- ++s;
- break;
- case 'l':
- case 'L':
- yylval.indexreg.size = SIZE_LONG;
- ++s;
- break;
- default:
- yyerror ("illegal size specification");
- yylval.indexreg.size = SIZE_UNSPEC;
- break;
- }
- }
-
- if (*s != '*' && *s != ':')
- yylval.indexreg.scale = 1;
- else
- {
- ++s;
- switch (*s)
- {
- case '1':
- case '2':
- case '4':
- case '8':
- yylval.indexreg.scale = *s - '0';
- ++s;
- break;
- default:
- yyerror ("illegal scale specification");
- yylval.indexreg.scale = 1;
- break;
- }
- }
-
- str = s;
-
- return INDEXREG;
- }
-
- /* It must be an expression. Before we call expression, we need to
- look ahead to see if there is a size specification. We must do
- that first, because otherwise foo.l will be treated as the symbol
- foo.l, rather than as the symbol foo with a long size
- specification. The grammar requires that all expressions end at
- the end of the operand, or with ',', '(', ']', ')'. */
-
- parens = 0;
- for (s = str; *s != '\0'; s++)
- {
- if (*s == '(')
- {
- if (parens == 0
- && s > str
- && (s[-1] == ')' || isalnum ((unsigned char) s[-1])))
- break;
- ++parens;
- }
- else if (*s == ')')
- {
- if (parens == 0)
- break;
- --parens;
- }
- else if (parens == 0
- && (*s == ',' || *s == ']'))
- break;
- }
-
- yylval.exp.size = SIZE_UNSPEC;
- if (s <= str + 2
- || (s[-2] != '.' && s[-2] != ':'))
- s = NULL;
- else
- {
- switch (s[-1])
- {
- case 's':
- case 'S':
- case 'b':
- case 'B':
- yylval.exp.size = SIZE_BYTE;
- break;
- case 'w':
- case 'W':
- yylval.exp.size = SIZE_WORD;
- break;
- case 'l':
- case 'L':
- yylval.exp.size = SIZE_LONG;
- break;
- default:
- s = NULL;
- break;
- }
- if (yylval.exp.size != SIZE_UNSPEC)
- {
- c = s[-2];
- s[-2] = '\0';
- }
- }
-
- hold = input_line_pointer;
- input_line_pointer = str;
- expression (&yylval.exp.exp);
- str = input_line_pointer;
- input_line_pointer = hold;
-
- if (s != NULL)
- {
- s[-2] = c;
- str = s;
- }
-
- return EXPR;
-}
-
-/* Parse an m68k operand. This is the only function which is called
- from outside this file. */
-
-int
-m68k_ip_op (s, oparg)
- char *s;
- struct m68k_op *oparg;
-{
- memset (oparg, 0, sizeof *oparg);
- oparg->error = NULL;
- oparg->index.reg = ZDATA0;
- oparg->index.scale = 1;
- oparg->disp.exp.X_op = O_absent;
- oparg->odisp.exp.X_op = O_absent;
-
- str = strorig = s;
- op = oparg;
-
- return yyparse ();
-}
-
-/* The error handler. */
-
-static void
-yyerror (s)
- const char *s;
-{
- op->error = s;
-}
diff --git a/gnu/usr.bin/binutils/gas/make-gas.com b/gnu/usr.bin/binutils/gas/make-gas.com
deleted file mode 100644
index 5b14b58ca40..00000000000
--- a/gnu/usr.bin/binutils/gas/make-gas.com
+++ /dev/null
@@ -1,126 +0,0 @@
-$! Set the def dir to proper place for use in batch. Works for interactive to.
-$flnm = f$enviroment("PROCEDURE") ! get current procedure name
-$set default 'f$parse(flnm,,,"DEVICE")''f$parse(flnm,,,"DIRECTORY")'
-$v = 'f$verify(0)'
-$!
-$! Command file to build a GNU assembler on VMS
-$!
-$! If you are using a version of GCC that supports global constants
-$! you should remove the define="const=" from the gcc lines.
-$!
-$! Caution: Versions 1.38.1 and earlier had a bug in the handling of
-$! some static constants. If you are using such a version of the
-$! assembler, and you wish to compile without the "const=" hack,
-$! you should first build this version *with* the "const="
-$! definition, and then use that assembler to rebuild it without the
-$! "const=" definition. Failure to do this will result in an assembler
-$! that will mung floating point constants.
-$!
-$! Note: The version of gas shipped on the GCC VMS tapes has been patched
-$! to fix the above mentioned bug.
-$!
-$ !The gcc-vms driver was modified to use `-1' quite some time ago,
-$ !so don't echo this text any more...
-$ !write sys$output "If this assembler is going to be used with GCC 1.n, you"
-$ !write sys$output "need to modify the driver to supply the -1 switch to gas."
-$ !write sys$output "This is required because of a small change in how global"
-$ !write sys$output "constant variables are handled. Failure to include this"
-$ !write sys$output "will result in linker warning messages about mismatched
-$ !write sys$output "psect attributes."
-$!
-$ C_DEFS :="""VMS"""
-$! C_DEFS :="""VMS""","""const="""
-$ C_INCLUDES = "/Include=([],[.config],[-.include],[-.include.aout])"
-$ C_FLAGS = "/noVerbose/Debug" + c_includes
-$!
-$!
-$ on error then goto bail
-$ if f$search("[-.libiberty]liberty.olb").eqs.""
-$ then @[-.libiberty]vmsbuild.com
-$ write sys$output "Now building gas."
-$ endif
-$ if "''p1'" .eqs. "LINK" then goto Link
-$!
-$! This helps gcc 1.nn find the aout/* files.
-$!
-$ aout_dev = f$parse(flnm,,,"DEVICE")
-$ tmp = aout_dev - ":"
-$if f$trnlnm(tmp).nes."" then aout_dev = f$trnlnm(tmp)
-$ aout_dir = aout_dev+f$parse(flnm,,,"DIRECTORY")' -
- - "GAS]" + "INCLUDE.AOUT.]" - "]["
-$assign 'aout_dir' aout/tran=conc
-$ opcode_dir = aout_dev+f$parse(flnm,,,"DIRECTORY")' -
- - "GAS]" + "INCLUDE.OPCODE.]" - "]["
-$assign 'opcode_dir' opcode/tran=conc
-$!
-$ set verify
-$!
-$ gcc 'c_flags'/Define=('C_DEFS') targ-cpu.c
-$ gcc 'c_flags'/Define=('C_DEFS') obj-format.c
-$ gcc 'c_flags'/Define=('C_DEFS') atof-targ.c
-$ gcc 'c_flags'/Define=('C_DEFS') app.c
-$ gcc 'c_flags'/Define=('C_DEFS') as.c
-$ gcc 'c_flags'/Define=('C_DEFS') atof-generic.c
-$ gcc 'c_flags'/Define=('C_DEFS') bignum-copy.c
-$ gcc 'c_flags'/Define=('C_DEFS') cond.c
-$ gcc 'c_flags'/Define=('C_DEFS') expr.c
-$ gcc 'c_flags'/Define=('C_DEFS') flonum-konst.c
-$ gcc 'c_flags'/Define=('C_DEFS') flonum-copy.c
-$ gcc 'c_flags'/Define=('C_DEFS') flonum-mult.c
-$ gcc 'c_flags'/Define=('C_DEFS') frags.c
-$ gcc 'c_flags'/Define=('C_DEFS') hash.c
-$ gcc 'c_flags'/Define=('C_DEFS') input-file.c
-$ gcc 'c_flags'/Define=('C_DEFS') input-scrub.c
-$ gcc 'c_flags'/Define=('C_DEFS') literal.c
-$ gcc 'c_flags'/Define=('C_DEFS') messages.c
-$ gcc 'c_flags'/Define=('C_DEFS') output-file.c
-$ gcc 'c_flags'/Define=('C_DEFS') read.c
-$ gcc 'c_flags'/Define=('C_DEFS') subsegs.c
-$ gcc 'c_flags'/Define=('C_DEFS') symbols.c
-$ gcc 'c_flags'/Define=('C_DEFS') write.c
-$ gcc 'c_flags'/Define=('C_DEFS') listing.c
-$ gcc 'c_flags'/Define=('C_DEFS') ecoff.c
-$ gcc 'c_flags'/Define=('C_DEFS') stabs.c
-$ gcc 'c_flags'/Define=('C_DEFS') sb.c
-$ gcc 'c_flags'/Define=('C_DEFS') macro.c
-$link:
-$!'f$verify(0)'
-$ set verify=(Proc,noImag)
-$ link/noMap/Exec=gcc-as version.opt/Opt+sys$input:/Opt
-!
-! Linker options file for GNU assembler
-!
-targ-cpu.obj,-
-obj-format.obj,-
-atof-targ.obj,-
-app.obj,-
-as.obj,-
-atof-generic.obj,-
-bignum-copy.obj,-
-cond.obj,-
-expr.obj,-
-flonum-konst.obj,-
-flonum-copy.obj,-
-flonum-mult.obj,-
-frags.obj,-
-hash.obj,-
-input-file.obj,-
-input-scrub.obj,-
-literal.obj,-
-messages.obj,-
-output-file.obj,-
-read.obj,-
-subsegs.obj,-
-symbols.obj,-
-write.obj,-
-listing.obj,-
-ecoff.obj,-
-stabs.obj,-
-sb.obj,-
-macro.obj,-
-[-.libiberty]liberty.olb/Lib
-gnu_cc:[000000]gcclib.olb/Lib,sys$library:vaxcrtl.olb/Lib
-! Tell linker exactly what psect attributes we want -- match VAXCRTL.
-psect_attr=ENVIRON,long,pic,ovr,rel,gbl,noshr,noexe,rd,wrt
-$!
-$bail: exit $status + 0*f$verify(v) !'f$verify(0)'
diff --git a/gnu/usr.bin/binutils/gprof/bsd_callg_bl.c b/gnu/usr.bin/binutils/gprof/bsd_callg_bl.c
deleted file mode 100644
index 5be63b9a24c..00000000000
--- a/gnu/usr.bin/binutils/gprof/bsd_callg_bl.c
+++ /dev/null
@@ -1,118 +0,0 @@
-/* ==> Do not modify this file!! It is created automatically
- from bsd_callg_bl.m using the gen-c-prog.awk script. <== */
-
-#include <stdio.h>
-
-void
-bsd_callg_blurb (file)
- FILE *file;
-{
- fputs ("\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs ("call graph profile:\n", file);
- fputs (" The sum of self and descendents is the major sort\n", file);
- fputs (" for this listing.\n", file);
- fputs ("\n", file);
- fputs (" function entries:\n", file);
- fputs ("\n", file);
- fputs ("index the index of the function in the call graph\n", file);
- fputs (" listing, as an aid to locating it (see below).\n", file);
- fputs ("\n", file);
- fputs ("%time the percentage of the total time of the program\n", file);
- fputs (" accounted for by this function and its\n", file);
- fputs (" descendents.\n", file);
- fputs ("\n", file);
- fputs ("self the number of seconds spent in this function\n", file);
- fputs (" itself.\n", file);
- fputs ("\n", file);
- fputs ("descendents\n", file);
- fputs (" the number of seconds spent in the descendents of\n", file);
- fputs (" this function on behalf of this function.\n", file);
- fputs ("\n", file);
- fputs ("called the number of times this function is called (other\n", file);
- fputs (" than recursive calls).\n", file);
- fputs ("\n", file);
- fputs ("self the number of times this function calls itself\n", file);
- fputs (" recursively.\n", file);
- fputs ("\n", file);
- fputs ("name the name of the function, with an indication of\n", file);
- fputs (" its membership in a cycle, if any.\n", file);
- fputs ("\n", file);
- fputs ("index the index of the function in the call graph\n", file);
- fputs (" listing, as an aid to locating it.\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs (" parent listings:\n", file);
- fputs ("\n", file);
- fputs ("self* the number of seconds of this function's self time\n", file);
- fputs (" which is due to calls from this parent.\n", file);
- fputs ("\n", file);
- fputs ("descendents*\n", file);
- fputs (" the number of seconds of this function's\n", file);
- fputs (" descendent time which is due to calls from this\n", file);
- fputs (" parent.\n", file);
- fputs ("\n", file);
- fputs ("called** the number of times this function is called by\n", file);
- fputs (" this parent. This is the numerator of the\n", file);
- fputs (" fraction which divides up the function's time to\n", file);
- fputs (" its parents.\n", file);
- fputs ("\n", file);
- fputs ("total* the number of times this function was called by\n", file);
- fputs (" all of its parents. This is the denominator of\n", file);
- fputs (" the propagation fraction.\n", file);
- fputs ("\n", file);
- fputs ("parents the name of this parent, with an indication of the\n", file);
- fputs (" parent's membership in a cycle, if any.\n", file);
- fputs ("\n", file);
- fputs ("index the index of this parent in the call graph\n", file);
- fputs (" listing, as an aid in locating it.\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs (" children listings:\n", file);
- fputs ("\n", file);
- fputs ("self* the number of seconds of this child's self time\n", file);
- fputs (" which is due to being called by this function.\n", file);
- fputs ("\n", file);
- fputs ("descendent*\n", file);
- fputs (" the number of seconds of this child's descendent's\n", file);
- fputs (" time which is due to being called by this\n", file);
- fputs (" function.\n", file);
- fputs ("\n", file);
- fputs ("called** the number of times this child is called by this\n", file);
- fputs (" function. This is the numerator of the\n", file);
- fputs (" propagation fraction for this child.\n", file);
- fputs ("\n", file);
- fputs ("total* the number of times this child is called by all\n", file);
- fputs (" functions. This is the denominator of the\n", file);
- fputs (" propagation fraction.\n", file);
- fputs ("\n", file);
- fputs ("children the name of this child, and an indication of its\n", file);
- fputs (" membership in a cycle, if any.\n", file);
- fputs ("\n", file);
- fputs ("index the index of this child in the call graph listing,\n", file);
- fputs (" as an aid to locating it.\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs (" * these fields are omitted for parents (or\n", file);
- fputs (" children) in the same cycle as the function. If\n", file);
- fputs (" the function (or child) is a member of a cycle,\n", file);
- fputs (" the propagated times and propagation denominator\n", file);
- fputs (" represent the self time and descendent time of the\n", file);
- fputs (" cycle as a whole.\n", file);
- fputs ("\n", file);
- fputs (" ** static-only parents and children are indicated\n", file);
- fputs (" by a call count of 0.\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs (" cycle listings:\n", file);
- fputs (" the cycle as a whole is listed with the same\n", file);
- fputs (" fields as a function entry. Below it are listed\n", file);
- fputs (" the members of the cycle, and their contributions\n", file);
- fputs (" to the time and call counts of the cycle.\n", file);
- fputs (" \n", file);
-}
diff --git a/gnu/usr.bin/binutils/gprof/flat_bl.c b/gnu/usr.bin/binutils/gprof/flat_bl.c
deleted file mode 100644
index e02c209798c..00000000000
--- a/gnu/usr.bin/binutils/gprof/flat_bl.c
+++ /dev/null
@@ -1,37 +0,0 @@
-/* ==> Do not modify this file!! It is created automatically
- from flat_bl.m using the gen-c-prog.awk script. <== */
-
-#include <stdio.h>
-
-void
-flat_blurb (file)
- FILE *file;
-{
- fputs ("\n", file);
- fputs (" % the percentage of the total running time of the\n", file);
- fputs ("time program used by this function.\n", file);
- fputs ("\n", file);
- fputs ("cumulative a running sum of the number of seconds accounted\n", file);
- fputs (" seconds for by this function and those listed above it.\n", file);
- fputs ("\n", file);
- fputs (" self the number of seconds accounted for by this\n", file);
- fputs ("seconds function alone. This is the major sort for this\n", file);
- fputs (" listing.\n", file);
- fputs ("\n", file);
- fputs ("calls the number of times this function was invoked, if\n", file);
- fputs (" this function is profiled, else blank.\n", file);
- fputs (" \n", file);
- fputs (" self the average number of milliseconds spent in this\n", file);
- fputs ("ms/call function per call, if this function is profiled,\n", file);
- fputs (" else blank.\n", file);
- fputs ("\n", file);
- fputs (" total the average number of milliseconds spent in this\n", file);
- fputs ("ms/call function and its descendents per call, if this \n", file);
- fputs (" function is profiled, else blank.\n", file);
- fputs ("\n", file);
- fputs ("name the name of the function. This is the minor sort\n", file);
- fputs (" for this listing. The index shows the location of\n", file);
- fputs (" the function in the gprof listing. If the index is\n", file);
- fputs (" in parenthesis it shows where it would appear in\n", file);
- fputs (" the gprof listing if it were to be printed.\n", file);
-}
diff --git a/gnu/usr.bin/binutils/gprof/fsf_callg_bl.c b/gnu/usr.bin/binutils/gprof/fsf_callg_bl.c
deleted file mode 100644
index d8182b551b0..00000000000
--- a/gnu/usr.bin/binutils/gprof/fsf_callg_bl.c
+++ /dev/null
@@ -1,93 +0,0 @@
-/* ==> Do not modify this file!! It is created automatically
- from fsf_callg_bl.m using the gen-c-prog.awk script. <== */
-
-#include <stdio.h>
-
-void
-fsf_callg_blurb (file)
- FILE *file;
-{
- fputs ("\n", file);
- fputs (" This table describes the call tree of the program, and was sorted by\n", file);
- fputs (" the total amount of time spent in each function and its children.\n", file);
- fputs ("\n", file);
- fputs (" Each entry in this table consists of several lines. The line with the\n", file);
- fputs (" index number at the left hand margin lists the current function.\n", file);
- fputs (" The lines above it list the functions that called this function,\n", file);
- fputs (" and the lines below it list the functions this one called.\n", file);
- fputs (" This line lists:\n", file);
- fputs (" index A unique number given to each element of the table.\n", file);
- fputs (" Index numbers are sorted numerically.\n", file);
- fputs (" The index number is printed next to every function name so\n", file);
- fputs (" it is easier to look up where the function in the table.\n", file);
- fputs ("\n", file);
- fputs (" % time This is the percentage of the `total' time that was spent\n", file);
- fputs (" in this function and its children. Note that due to\n", file);
- fputs (" different viewpoints, functions excluded by options, etc,\n", file);
- fputs (" these numbers will NOT add up to 100%.\n", file);
- fputs ("\n", file);
- fputs (" self This is the total amount of time spent in this function.\n", file);
- fputs ("\n", file);
- fputs (" children This is the total amount of time propagated into this\n", file);
- fputs (" function by its children.\n", file);
- fputs ("\n", file);
- fputs (" called This is the number of times the function was called.\n", file);
- fputs (" If the function called itself recursively, the number\n", file);
- fputs (" only includes non-recursive calls, and is followed by\n", file);
- fputs (" a `+' and the number of recursive calls.\n", file);
- fputs ("\n", file);
- fputs (" name The name of the current function. The index number is\n", file);
- fputs (" printed after it. If the function is a member of a\n", file);
- fputs (" cycle, the cycle number is printed between the\n", file);
- fputs (" function's name and the index number.\n", file);
- fputs ("\n", file);
- fputs ("\n", file);
- fputs (" For the function's parents, the fields have the following meanings:\n", file);
- fputs ("\n", file);
- fputs (" self This is the amount of time that was propagated directly\n", file);
- fputs (" from the function into this parent.\n", file);
- fputs ("\n", file);
- fputs (" children This is the amount of time that was propagated from\n", file);
- fputs (" the function's children into this parent.\n", file);
- fputs ("\n", file);
- fputs (" called This is the number of times this parent called the\n", file);
- fputs (" function `/' the total number of times the function\n", file);
- fputs (" was called. Recursive calls to the function are not\n", file);
- fputs (" included in the number after the `/'.\n", file);
- fputs ("\n", file);
- fputs (" name This is the name of the parent. The parent's index\n", file);
- fputs (" number is printed after it. If the parent is a\n", file);
- fputs (" member of a cycle, the cycle number is printed between\n", file);
- fputs (" the name and the index number.\n", file);
- fputs ("\n", file);
- fputs (" If the parents of the function cannot be determined, the word\n", file);
- fputs (" `<spontaneous>' is printed in the `name' field, and all the other\n", file);
- fputs (" fields are blank.\n", file);
- fputs ("\n", file);
- fputs (" For the function's children, the fields have the following meanings:\n", file);
- fputs ("\n", file);
- fputs (" self This is the amount of time that was propagated directly\n", file);
- fputs (" from the child into the function.\n", file);
- fputs ("\n", file);
- fputs (" children This is the amount of time that was propagated from the\n", file);
- fputs (" child's children to the function.\n", file);
- fputs ("\n", file);
- fputs (" called This is the number of times the function called\n", file);
- fputs (" this child `/' the total number of times the child\n", file);
- fputs (" was called. Recursive calls by the child are not\n", file);
- fputs (" listed in the number after the `/'.\n", file);
- fputs ("\n", file);
- fputs (" name This is the name of the child. The child's index\n", file);
- fputs (" number is printed after it. If the child is a\n", file);
- fputs (" member of a cycle, the cycle number is printed\n", file);
- fputs (" between the name and the index number.\n", file);
- fputs ("\n", file);
- fputs (" If there are any cycles (circles) in the call graph, there is an\n", file);
- fputs (" entry for the cycle-as-a-whole. This entry shows who called the\n", file);
- fputs (" cycle (as parents) and the members of the cycle (as children.)\n", file);
- fputs (" The `+' recursive calls entry shows the number of function calls that\n", file);
- fputs (" were internal to the cycle, and the calls entry for each member shows,\n", file);
- fputs (" for that member, how many times it was called from other members of\n", file);
- fputs (" the cycle.\n", file);
- fputs ("\n", file);
-}
diff --git a/gnu/usr.bin/binutils/gprof/gprof.info b/gnu/usr.bin/binutils/gprof/gprof.info
deleted file mode 100644
index 60a2d9a9f43..00000000000
--- a/gnu/usr.bin/binutils/gprof/gprof.info
+++ /dev/null
@@ -1,951 +0,0 @@
-This is Info file gprof.info, produced by Makeinfo-1.55 from the input
-file ./gprof.texi.
-
-START-INFO-DIR-ENTRY
-* gprof: (gprof). Profiling your program's execution
-END-INFO-DIR-ENTRY
-
- This file documents the gprof profiler of the GNU system.
-
- Copyright (C) 1988, 1992 Free Software Foundation, Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided that
-the entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: gprof.info, Node: Top, Next: Why, Prev: (DIR), Up: (DIR)
-
-Profiling a Program: Where Does It Spend Its Time?
-**************************************************
-
- This manual describes the GNU profiler, `gprof', and how you can use
-it to determine which parts of a program are taking most of the
-execution time. We assume that you know how to write, compile, and
-execute programs. GNU `gprof' was written by Jay Fenlason.
-
- This manual was updated January 1993.
-
-* Menu:
-
-* Why:: What profiling means, and why it is useful.
-* Compiling:: How to compile your program for profiling.
-* Executing:: How to execute your program to generate the
- profile data file `gmon.out'.
-* Invoking:: How to run `gprof', and how to specify
- options for it.
-
-* Flat Profile:: The flat profile shows how much time was spent
- executing directly in each function.
-* Call Graph:: The call graph shows which functions called which
- others, and how much time each function used
- when its subroutine calls are included.
-
-* Implementation:: How the profile data is recorded and written.
-* Sampling Error:: Statistical margins of error.
- How to accumulate data from several runs
- to make it more accurate.
-
-* Assumptions:: Some of `gprof''s measurements are based
- on assumptions about your program
- that could be very wrong.
-
-* Incompatibilities:: (between GNU `gprof' and Unix `gprof'.)
-
-
-File: gprof.info, Node: Why, Next: Compiling, Prev: Top, Up: Top
-
-Why Profile
-***********
-
- Profiling allows you to learn where your program spent its time and
-which functions called which other functions while it was executing.
-This information can show you which pieces of your program are slower
-than you expected, and might be candidates for rewriting to make your
-program execute faster. It can also tell you which functions are being
-called more or less often than you expected. This may help you spot
-bugs that had otherwise been unnoticed.
-
- Since the profiler uses information collected during the actual
-execution of your program, it can be used on programs that are too
-large or too complex to analyze by reading the source. However, how
-your program is run will affect the information that shows up in the
-profile data. If you don't use some feature of your program while it
-is being profiled, no profile information will be generated for that
-feature.
-
- Profiling has several steps:
-
- * You must compile and link your program with profiling enabled.
- *Note Compiling::.
-
- * You must execute your program to generate a profile data file.
- *Note Executing::.
-
- * You must run `gprof' to analyze the profile data. *Note
- Invoking::.
-
- The next three chapters explain these steps in greater detail.
-
- The result of the analysis is a file containing two tables, the
-"flat profile" and the "call graph" (plus blurbs which briefly explain
-the contents of these tables).
-
- The flat profile shows how much time your program spent in each
-function, and how many times that function was called. If you simply
-want to know which functions burn most of the cycles, it is stated
-concisely here. *Note Flat Profile::.
-
- The call graph shows, for each function, which functions called it,
-which other functions it called, and how many times. There is also an
-estimate of how much time was spent in the subroutines of each
-function. This can suggest places where you might try to eliminate
-function calls that use a lot of time. *Note Call Graph::.
-
-
-File: gprof.info, Node: Compiling, Next: Executing, Prev: Why, Up: Top
-
-Compiling a Program for Profiling
-*********************************
-
- The first step in generating profile information for your program is
-to compile and link it with profiling enabled.
-
- To compile a source file for profiling, specify the `-pg' option when
-you run the compiler. (This is in addition to the options you normally
-use.)
-
- To link the program for profiling, if you use a compiler such as `cc'
-to do the linking, simply specify `-pg' in addition to your usual
-options. The same option, `-pg', alters either compilation or linking
-to do what is necessary for profiling. Here are examples:
-
- cc -g -c myprog.c utils.c -pg
- cc -o myprog myprog.o utils.o -pg
-
- The `-pg' option also works with a command that both compiles and
-links:
-
- cc -o myprog myprog.c utils.c -g -pg
-
- If you run the linker `ld' directly instead of through a compiler
-such as `cc', you must specify the profiling startup file
-`/lib/gcrt0.o' as the first input file instead of the usual startup
-file `/lib/crt0.o'. In addition, you would probably want to specify
-the profiling C library, `/usr/lib/libc_p.a', by writing `-lc_p'
-instead of the usual `-lc'. This is not absolutely necessary, but
-doing this gives you number-of-calls information for standard library
-functions such as `read' and `open'. For example:
-
- ld -o myprog /lib/gcrt0.o myprog.o utils.o -lc_p
-
- If you compile only some of the modules of the program with `-pg',
-you can still profile the program, but you won't get complete
-information about the modules that were compiled without `-pg'. The
-only information you get for the functions in those modules is the
-total time spent in them; there is no record of how many times they
-were called, or from where. This will not affect the flat profile
-(except that the `calls' field for the functions will be blank), but
-will greatly reduce the usefulness of the call graph.
-
-
-File: gprof.info, Node: Executing, Next: Invoking, Prev: Compiling, Up: Top
-
-Executing the Program to Generate Profile Data
-**********************************************
-
- Once the program is compiled for profiling, you must run it in order
-to generate the information that `gprof' needs. Simply run the program
-as usual, using the normal arguments, file names, etc. The program
-should run normally, producing the same output as usual. It will,
-however, run somewhat slower than normal because of the time spent
-collecting and the writing the profile data.
-
- The way you run the program--the arguments and input that you give
-it--may have a dramatic effect on what the profile information shows.
-The profile data will describe the parts of the program that were
-activated for the particular input you use. For example, if the first
-command you give to your program is to quit, the profile data will show
-the time used in initialization and in cleanup, but not much else.
-
- You program will write the profile data into a file called `gmon.out'
-just before exiting. If there is already a file called `gmon.out', its
-contents are overwritten. There is currently no way to tell the
-program to write the profile data under a different name, but you can
-rename the file afterward if you are concerned that it may be
-overwritten.
-
- In order to write the `gmon.out' file properly, your program must
-exit normally: by returning from `main' or by calling `exit'. Calling
-the low-level function `_exit' does not write the profile data, and
-neither does abnormal termination due to an unhandled signal.
-
- The `gmon.out' file is written in the program's *current working
-directory* at the time it exits. This means that if your program calls
-`chdir', the `gmon.out' file will be left in the last directory your
-program `chdir''d to. If you don't have permission to write in this
-directory, the file is not written. You may get a confusing error
-message if this happens. (We have not yet replaced the part of Unix
-responsible for this; when we do, we will make the error message
-comprehensible.)
-
-
-File: gprof.info, Node: Invoking, Next: Flat Profile, Prev: Executing, Up: Top
-
-`gprof' Command Summary
-***********************
-
- After you have a profile data file `gmon.out', you can run `gprof'
-to interpret the information in it. The `gprof' program prints a flat
-profile and a call graph on standard output. Typically you would
-redirect the output of `gprof' into a file with `>'.
-
- You run `gprof' like this:
-
- gprof OPTIONS [EXECUTABLE-FILE [PROFILE-DATA-FILES...]] [> OUTFILE]
-
-Here square-brackets indicate optional arguments.
-
- If you omit the executable file name, the file `a.out' is used. If
-you give no profile data file name, the file `gmon.out' is used. If
-any file is not in the proper format, or if the profile data file does
-not appear to belong to the executable file, an error message is
-printed.
-
- You can give more than one profile data file by entering all their
-names after the executable file name; then the statistics in all the
-data files are summed together.
-
- The following options may be used to selectively include or exclude
-functions in the output:
-
-`-a'
- The `-a' option causes `gprof' to suppress the printing of
- statically declared (private) functions. (These are functions
- whose names are not listed as global, and which are not visible
- outside the file/function/block where they were defined.) Time
- spent in these functions, calls to/from them, etc, will all be
- attributed to the function that was loaded directly before it in
- the executable file. This option affects both the flat profile
- and the call graph.
-
-`-e FUNCTION_NAME'
- The `-e FUNCTION' option tells `gprof' to not print information
- about the function FUNCTION_NAME (and its children...) in the call
- graph. The function will still be listed as a child of any
- functions that call it, but its index number will be shown as
- `[not printed]'. More than one `-e' option may be given; only one
- FUNCTION_NAME may be indicated with each `-e' option.
-
-`-E FUNCTION_NAME'
- The `-E FUNCTION' option works like the `-e' option, but time
- spent in the function (and children who were not called from
- anywhere else), will not be used to compute the
- percentages-of-time for the call graph. More than one `-E' option
- may be given; only one FUNCTION_NAME may be indicated with each
- `-E' option.
-
-`-f FUNCTION_NAME'
- The `-f FUNCTION' option causes `gprof' to limit the call graph to
- the function FUNCTION_NAME and its children (and their
- children...). More than one `-f' option may be given; only one
- FUNCTION_NAME may be indicated with each `-f' option.
-
-`-F FUNCTION_NAME'
- The `-F FUNCTION' option works like the `-f' option, but only time
- spent in the function and its children (and their children...)
- will be used to determine total-time and percentages-of-time for
- the call graph. More than one `-F' option may be given; only one
- FUNCTION_NAME may be indicated with each `-F' option. The `-F'
- option overrides the `-E' option.
-
-`-k FROM... TO...'
- The `-k' option allows you to delete from the profile any arcs from
- routine FROM to routine TO.
-
-`-v'
- The `-v' flag causes `gprof' to print the current version number,
- and then exit.
-
-`-z'
- If you give the `-z' option, `gprof' will mention all functions in
- the flat profile, even those that were never called, and that had
- no time spent in them. This is useful in conjunction with the
- `-c' option for discovering which routines were never called.
-
- The order of these options does not matter.
-
- Note that only one function can be specified with each `-e', `-E',
-`-f' or `-F' option. To specify more than one function, use multiple
-options. For example, this command:
-
- gprof -e boring -f foo -f bar myprogram > gprof.output
-
-lists in the call graph all functions that were reached from either
-`foo' or `bar' and were not reachable from `boring'.
-
- There are a few other useful `gprof' options:
-
-`-b'
- If the `-b' option is given, `gprof' doesn't print the verbose
- blurbs that try to explain the meaning of all of the fields in the
- tables. This is useful if you intend to print out the output, or
- are tired of seeing the blurbs.
-
-`-c'
- The `-c' option causes the static call-graph of the program to be
- discovered by a heuristic which examines the text space of the
- object file. Static-only parents or children are indicated with
- call counts of `0'.
-
-`-d NUM'
- The `-d NUM' option specifies debugging options.
-
-`-s'
- The `-s' option causes `gprof' to summarize the information in the
- profile data files it read in, and write out a profile data file
- called `gmon.sum', which contains all the information from the
- profile data files that `gprof' read in. The file `gmon.sum' may
- be one of the specified input files; the effect of this is to
- merge the data in the other input files into `gmon.sum'. *Note
- Sampling Error::.
-
- Eventually you can run `gprof' again without `-s' to analyze the
- cumulative data in the file `gmon.sum'.
-
-`-T'
- The `-T' option causes `gprof' to print its output in
- "traditional" BSD style.
-
-
-File: gprof.info, Node: Flat Profile, Next: Call Graph, Prev: Invoking, Up: Top
-
-How to Understand the Flat Profile
-**********************************
-
- The "flat profile" shows the total amount of time your program spent
-executing each function. Unless the `-z' option is given, functions
-with no apparent time spent in them, and no apparent calls to them, are
-not mentioned. Note that if a function was not compiled for profiling,
-and didn't run long enough to show up on the program counter histogram,
-it will be indistinguishable from a function that was never called.
-
- This is part of a flat profile for a small program:
-
- Flat profile:
-
- Each sample counts as 0.01 seconds.
- % cumulative self self total
- time seconds seconds calls ms/call ms/call name
- 33.34 0.02 0.02 7208 0.00 0.00 open
- 16.67 0.03 0.01 244 0.04 0.12 offtime
- 16.67 0.04 0.01 8 1.25 1.25 memccpy
- 16.67 0.05 0.01 7 1.43 1.43 write
- 16.67 0.06 0.01 mcount
- 0.00 0.06 0.00 236 0.00 0.00 tzset
- 0.00 0.06 0.00 192 0.00 0.00 tolower
- 0.00 0.06 0.00 47 0.00 0.00 strlen
- 0.00 0.06 0.00 45 0.00 0.00 strchr
- 0.00 0.06 0.00 1 0.00 50.00 main
- 0.00 0.06 0.00 1 0.00 0.00 memcpy
- 0.00 0.06 0.00 1 0.00 10.11 print
- 0.00 0.06 0.00 1 0.00 0.00 profil
- 0.00 0.06 0.00 1 0.00 50.00 report
- ...
-
-The functions are sorted by decreasing run-time spent in them. The
-functions `mcount' and `profil' are part of the profiling aparatus and
-appear in every flat profile; their time gives a measure of the amount
-of overhead due to profiling.
-
- The sampling period estimates the margin of error in each of the time
-figures. A time figure that is not much larger than this is not
-reliable. In this example, the `self seconds' field for `mcount' might
-well be `0' or `0.04' in another run. *Note Sampling Error::, for a
-complete discussion.
-
- Here is what the fields in each line mean:
-
-`% time'
- This is the percentage of the total execution time your program
- spent in this function. These should all add up to 100%.
-
-`cumulative seconds'
- This is the cumulative total number of seconds the computer spent
- executing this functions, plus the time spent in all the functions
- above this one in this table.
-
-`self seconds'
- This is the number of seconds accounted for by this function alone.
- The flat profile listing is sorted first by this number.
-
-`calls'
- This is the total number of times the function was called. If the
- function was never called, or the number of times it was called
- cannot be determined (probably because the function was not
- compiled with profiling enabled), the "calls" field is blank.
-
-`self ms/call'
- This represents the average number of milliseconds spent in this
- function per call, if this function is profiled. Otherwise, this
- field is blank for this function.
-
-`total ms/call'
- This represents the average number of milliseconds spent in this
- function and its descendants per call, if this function is
- profiled. Otherwise, this field is blank for this function.
-
-`name'
- This is the name of the function. The flat profile is sorted by
- this field alphabetically after the "self seconds" field is sorted.
-
-
-File: gprof.info, Node: Call Graph, Next: Implementation, Prev: Flat Profile, Up: Top
-
-How to Read the Call Graph
-**************************
-
- The "call graph" shows how much time was spent in each function and
-its children. From this information, you can find functions that,
-while they themselves may not have used much time, called other
-functions that did use unusual amounts of time.
-
- Here is a sample call from a small program. This call came from the
-same `gprof' run as the flat profile example in the previous chapter.
-
- granularity: each sample hit covers 2 byte(s) for 20.00% of 0.05 seconds
-
- index % time self children called name
- <spontaneous>
- [1] 100.0 0.00 0.05 start [1]
- 0.00 0.05 1/1 main [2]
- 0.00 0.00 1/2 on_exit [28]
- 0.00 0.00 1/1 exit [59]
- -----------------------------------------------
- 0.00 0.05 1/1 start [1]
- [2] 100.0 0.00 0.05 1 main [2]
- 0.00 0.05 1/1 report [3]
- -----------------------------------------------
- 0.00 0.05 1/1 main [2]
- [3] 100.0 0.00 0.05 1 report [3]
- 0.00 0.03 8/8 timelocal [6]
- 0.00 0.01 1/1 print [9]
- 0.00 0.01 9/9 fgets [12]
- 0.00 0.00 12/34 strncmp <cycle 1> [40]
- 0.00 0.00 8/8 lookup [20]
- 0.00 0.00 1/1 fopen [21]
- 0.00 0.00 8/8 chewtime [24]
- 0.00 0.00 8/16 skipspace [44]
- -----------------------------------------------
- [4] 59.8 0.01 0.02 8+472 <cycle 2 as a whole> [4]
- 0.01 0.02 244+260 offtime <cycle 2> [7]
- 0.00 0.00 236+1 tzset <cycle 2> [26]
- -----------------------------------------------
-
- The lines full of dashes divide this table into "entries", one for
-each function. Each entry has one or more lines.
-
- In each entry, the primary line is the one that starts with an index
-number in square brackets. The end of this line says which function
-the entry is for. The preceding lines in the entry describe the
-callers of this function and the following lines describe its
-subroutines (also called "children" when we speak of the call graph).
-
- The entries are sorted by time spent in the function and its
-subroutines.
-
- The internal profiling function `mcount' (*note Flat Profile::.) is
-never mentioned in the call graph.
-
-* Menu:
-
-* Primary:: Details of the primary line's contents.
-* Callers:: Details of caller-lines' contents.
-* Subroutines:: Details of subroutine-lines' contents.
-* Cycles:: When there are cycles of recursion,
- such as `a' calls `b' calls `a'...
-
-
-File: gprof.info, Node: Primary, Next: Callers, Up: Call Graph
-
-The Primary Line
-================
-
- The "primary line" in a call graph entry is the line that describes
-the function which the entry is about and gives the overall statistics
-for this function.
-
- For reference, we repeat the primary line from the entry for function
-`report' in our main example, together with the heading line that shows
-the names of the fields:
-
- index % time self children called name
- ...
- [3] 100.0 0.00 0.05 1 report [3]
-
- Here is what the fields in the primary line mean:
-
-`index'
- Entries are numbered with consecutive integers. Each function
- therefore has an index number, which appears at the beginning of
- its primary line.
-
- Each cross-reference to a function, as a caller or subroutine of
- another, gives its index number as well as its name. The index
- number guides you if you wish to look for the entry for that
- function.
-
-`% time'
- This is the percentage of the total time that was spent in this
- function, including time spent in subroutines called from this
- function.
-
- The time spent in this function is counted again for the callers of
- this function. Therefore, adding up these percentages is
- meaningless.
-
-`self'
- This is the total amount of time spent in this function. This
- should be identical to the number printed in the `seconds' field
- for this function in the flat profile.
-
-`children'
- This is the total amount of time spent in the subroutine calls
- made by this function. This should be equal to the sum of all the
- `self' and `children' entries of the children listed directly
- below this function.
-
-`called'
- This is the number of times the function was called.
-
- If the function called itself recursively, there are two numbers,
- separated by a `+'. The first number counts non-recursive calls,
- and the second counts recursive calls.
-
- In the example above, the function `report' was called once from
- `main'.
-
-`name'
- This is the name of the current function. The index number is
- repeated after it.
-
- If the function is part of a cycle of recursion, the cycle number
- is printed between the function's name and the index number (*note
- Cycles::.). For example, if function `gnurr' is part of cycle
- number one, and has index number twelve, its primary line would be
- end like this:
-
- gnurr <cycle 1> [12]
-
-
-File: gprof.info, Node: Callers, Next: Subroutines, Prev: Primary, Up: Call Graph
-
-Lines for a Function's Callers
-==============================
-
- A function's entry has a line for each function it was called by.
-These lines' fields correspond to the fields of the primary line, but
-their meanings are different because of the difference in context.
-
- For reference, we repeat two lines from the entry for the function
-`report', the primary line and one caller-line preceding it, together
-with the heading line that shows the names of the fields:
-
- index % time self children called name
- ...
- 0.00 0.05 1/1 main [2]
- [3] 100.0 0.00 0.05 1 report [3]
-
- Here are the meanings of the fields in the caller-line for `report'
-called from `main':
-
-`self'
- An estimate of the amount of time spent in `report' itself when it
- was called from `main'.
-
-`children'
- An estimate of the amount of time spent in subroutines of `report'
- when `report' was called from `main'.
-
- The sum of the `self' and `children' fields is an estimate of the
- amount of time spent within calls to `report' from `main'.
-
-`called'
- Two numbers: the number of times `report' was called from `main',
- followed by the total number of nonrecursive calls to `report' from
- all its callers.
-
-`name and index number'
- The name of the caller of `report' to which this line applies,
- followed by the caller's index number.
-
- Not all functions have entries in the call graph; some options to
- `gprof' request the omission of certain functions. When a caller
- has no entry of its own, it still has caller-lines in the entries
- of the functions it calls.
-
- If the caller is part of a recursion cycle, the cycle number is
- printed between the name and the index number.
-
- If the identity of the callers of a function cannot be determined, a
-dummy caller-line is printed which has `<spontaneous>' as the "caller's
-name" and all other fields blank. This can happen for signal handlers.
-
-
-File: gprof.info, Node: Subroutines, Next: Cycles, Prev: Callers, Up: Call Graph
-
-Lines for a Function's Subroutines
-==================================
-
- A function's entry has a line for each of its subroutines--in other
-words, a line for each other function that it called. These lines'
-fields correspond to the fields of the primary line, but their meanings
-are different because of the difference in context.
-
- For reference, we repeat two lines from the entry for the function
-`main', the primary line and a line for a subroutine, together with the
-heading line that shows the names of the fields:
-
- index % time self children called name
- ...
- [2] 100.0 0.00 0.05 1 main [2]
- 0.00 0.05 1/1 report [3]
-
- Here are the meanings of the fields in the subroutine-line for `main'
-calling `report':
-
-`self'
- An estimate of the amount of time spent directly within `report'
- when `report' was called from `main'.
-
-`children'
- An estimate of the amount of time spent in subroutines of `report'
- when `report' was called from `main'.
-
- The sum of the `self' and `children' fields is an estimate of the
- total time spent in calls to `report' from `main'.
-
-`called'
- Two numbers, the number of calls to `report' from `main' followed
- by the total number of nonrecursive calls to `report'.
-
-`name'
- The name of the subroutine of `main' to which this line applies,
- followed by the subroutine's index number.
-
- If the caller is part of a recursion cycle, the cycle number is
- printed between the name and the index number.
-
-
-File: gprof.info, Node: Cycles, Prev: Subroutines, Up: Call Graph
-
-How Mutually Recursive Functions Are Described
-==============================================
-
- The graph may be complicated by the presence of "cycles of
-recursion" in the call graph. A cycle exists if a function calls
-another function that (directly or indirectly) calls (or appears to
-call) the original function. For example: if `a' calls `b', and `b'
-calls `a', then `a' and `b' form a cycle.
-
- Whenever there are call-paths both ways between a pair of functions,
-they belong to the same cycle. If `a' and `b' call each other and `b'
-and `c' call each other, all three make one cycle. Note that even if
-`b' only calls `a' if it was not called from `a', `gprof' cannot
-determine this, so `a' and `b' are still considered a cycle.
-
- The cycles are numbered with consecutive integers. When a function
-belongs to a cycle, each time the function name appears in the call
-graph it is followed by `<cycle NUMBER>'.
-
- The reason cycles matter is that they make the time values in the
-call graph paradoxical. The "time spent in children" of `a' should
-include the time spent in its subroutine `b' and in `b''s
-subroutines--but one of `b''s subroutines is `a'! How much of `a''s
-time should be included in the children of `a', when `a' is indirectly
-recursive?
-
- The way `gprof' resolves this paradox is by creating a single entry
-for the cycle as a whole. The primary line of this entry describes the
-total time spent directly in the functions of the cycle. The
-"subroutines" of the cycle are the individual functions of the cycle,
-and all other functions that were called directly by them. The
-"callers" of the cycle are the functions, outside the cycle, that
-called functions in the cycle.
-
- Here is an example portion of a call graph which shows a cycle
-containing functions `a' and `b'. The cycle was entered by a call to
-`a' from `main'; both `a' and `b' called `c'.
-
- index % time self children called name
- ----------------------------------------
- 1.77 0 1/1 main [2]
- [3] 91.71 1.77 0 1+5 <cycle 1 as a whole> [3]
- 1.02 0 3 b <cycle 1> [4]
- 0.75 0 2 a <cycle 1> [5]
- ----------------------------------------
- 3 a <cycle 1> [5]
- [4] 52.85 1.02 0 0 b <cycle 1> [4]
- 2 a <cycle 1> [5]
- 0 0 3/6 c [6]
- ----------------------------------------
- 1.77 0 1/1 main [2]
- 2 b <cycle 1> [4]
- [5] 38.86 0.75 0 1 a <cycle 1> [5]
- 3 b <cycle 1> [4]
- 0 0 3/6 c [6]
- ----------------------------------------
-
-(The entire call graph for this program contains in addition an entry
-for `main', which calls `a', and an entry for `c', with callers `a' and
-`b'.)
-
- index % time self children called name
- <spontaneous>
- [1] 100.00 0 1.93 0 start [1]
- 0.16 1.77 1/1 main [2]
- ----------------------------------------
- 0.16 1.77 1/1 start [1]
- [2] 100.00 0.16 1.77 1 main [2]
- 1.77 0 1/1 a <cycle 1> [5]
- ----------------------------------------
- 1.77 0 1/1 main [2]
- [3] 91.71 1.77 0 1+5 <cycle 1 as a whole> [3]
- 1.02 0 3 b <cycle 1> [4]
- 0.75 0 2 a <cycle 1> [5]
- 0 0 6/6 c [6]
- ----------------------------------------
- 3 a <cycle 1> [5]
- [4] 52.85 1.02 0 0 b <cycle 1> [4]
- 2 a <cycle 1> [5]
- 0 0 3/6 c [6]
- ----------------------------------------
- 1.77 0 1/1 main [2]
- 2 b <cycle 1> [4]
- [5] 38.86 0.75 0 1 a <cycle 1> [5]
- 3 b <cycle 1> [4]
- 0 0 3/6 c [6]
- ----------------------------------------
- 0 0 3/6 b <cycle 1> [4]
- 0 0 3/6 a <cycle 1> [5]
- [6] 0.00 0 0 6 c [6]
- ----------------------------------------
-
- The `self' field of the cycle's primary line is the total time spent
-in all the functions of the cycle. It equals the sum of the `self'
-fields for the individual functions in the cycle, found in the entry in
-the subroutine lines for these functions.
-
- The `children' fields of the cycle's primary line and subroutine
-lines count only subroutines outside the cycle. Even though `a' calls
-`b', the time spent in those calls to `b' is not counted in `a''s
-`children' time. Thus, we do not encounter the problem of what to do
-when the time in those calls to `b' includes indirect recursive calls
-back to `a'.
-
- The `children' field of a caller-line in the cycle's entry estimates
-the amount of time spent *in the whole cycle*, and its other
-subroutines, on the times when that caller called a function in the
-cycle.
-
- The `calls' field in the primary line for the cycle has two numbers:
-first, the number of times functions in the cycle were called by
-functions outside the cycle; second, the number of times they were
-called by functions in the cycle (including times when a function in
-the cycle calls itself). This is a generalization of the usual split
-into nonrecursive and recursive calls.
-
- The `calls' field of a subroutine-line for a cycle member in the
-cycle's entry says how many time that function was called from
-functions in the cycle. The total of all these is the second number in
-the primary line's `calls' field.
-
- In the individual entry for a function in a cycle, the other
-functions in the same cycle can appear as subroutines and as callers.
-These lines show how many times each function in the cycle called or
-was called from each other function in the cycle. The `self' and
-`children' fields in these lines are blank because of the difficulty of
-defining meanings for them when recursion is going on.
-
-
-File: gprof.info, Node: Implementation, Next: Sampling Error, Prev: Call Graph, Up: Top
-
-Implementation of Profiling
-***************************
-
- Profiling works by changing how every function in your program is
-compiled so that when it is called, it will stash away some information
-about where it was called from. From this, the profiler can figure out
-what function called it, and can count how many times it was called.
-This change is made by the compiler when your program is compiled with
-the `-pg' option.
-
- Profiling also involves watching your program as it runs, and
-keeping a histogram of where the program counter happens to be every
-now and then. Typically the program counter is looked at around 100
-times per second of run time, but the exact frequency may vary from
-system to system.
-
- A special startup routine allocates memory for the histogram and
-sets up a clock signal handler to make entries in it. Use of this
-special startup routine is one of the effects of using `gcc ... -pg' to
-link. The startup file also includes an `exit' function which is
-responsible for writing the file `gmon.out'.
-
- Number-of-calls information for library routines is collected by
-using a special version of the C library. The programs in it are the
-same as in the usual C library, but they were compiled with `-pg'. If
-you link your program with `gcc ... -pg', it automatically uses the
-profiling version of the library.
-
- The output from `gprof' gives no indication of parts of your program
-that are limited by I/O or swapping bandwidth. This is because samples
-of the program counter are taken at fixed intervals of run time.
-Therefore, the time measurements in `gprof' output say nothing about
-time that your program was not running. For example, a part of the
-program that creates so much data that it cannot all fit in physical
-memory at once may run very slowly due to thrashing, but `gprof' will
-say it uses little time. On the other hand, sampling by run time has
-the advantage that the amount of load due to other users won't directly
-affect the output you get.
-
-
-File: gprof.info, Node: Sampling Error, Next: Assumptions, Prev: Implementation, Up: Top
-
-Statistical Inaccuracy of `gprof' Output
-****************************************
-
- The run-time figures that `gprof' gives you are based on a sampling
-process, so they are subject to statistical inaccuracy. If a function
-runs only a small amount of time, so that on the average the sampling
-process ought to catch that function in the act only once, there is a
-pretty good chance it will actually find that function zero times, or
-twice.
-
- By contrast, the number-of-calls figures are derived by counting, not
-sampling. They are completely accurate and will not vary from run to
-run if your program is deterministic.
-
- The "sampling period" that is printed at the beginning of the flat
-profile says how often samples are taken. The rule of thumb is that a
-run-time figure is accurate if it is considerably bigger than the
-sampling period.
-
- The actual amount of error is usually more than one sampling period.
-In fact, if a value is N times the sampling period, the *expected*
-error in it is the square-root of N sampling periods. If the sampling
-period is 0.01 seconds and `foo''s run-time is 1 second, the expected
-error in `foo''s run-time is 0.1 seconds. It is likely to vary this
-much *on the average* from one profiling run to the next. (*Sometimes*
-it will vary more.)
-
- This does not mean that a small run-time figure is devoid of
-information. If the program's *total* run-time is large, a small
-run-time for one function does tell you that that function used an
-insignificant fraction of the whole program's time. Usually this means
-it is not worth optimizing.
-
- One way to get more accuracy is to give your program more (but
-similar) input data so it will take longer. Another way is to combine
-the data from several runs, using the `-s' option of `gprof'. Here is
-how:
-
- 1. Run your program once.
-
- 2. Issue the command `mv gmon.out gmon.sum'.
-
- 3. Run your program again, the same as before.
-
- 4. Merge the new data in `gmon.out' into `gmon.sum' with this command:
-
- gprof -s EXECUTABLE-FILE gmon.out gmon.sum
-
- 5. Repeat the last two steps as often as you wish.
-
- 6. Analyze the cumulative data using this command:
-
- gprof EXECUTABLE-FILE gmon.sum > OUTPUT-FILE
-
-
-File: gprof.info, Node: Assumptions, Next: Incompatibilities, Prev: Sampling Error, Up: Top
-
-Estimating `children' Times Uses an Assumption
-**********************************************
-
- Some of the figures in the call graph are estimates--for example, the
-`children' time values and all the the time figures in caller and
-subroutine lines.
-
- There is no direct information about these measurements in the
-profile data itself. Instead, `gprof' estimates them by making an
-assumption about your program that might or might not be true.
-
- The assumption made is that the average time spent in each call to
-any function `foo' is not correlated with who called `foo'. If `foo'
-used 5 seconds in all, and 2/5 of the calls to `foo' came from `a',
-then `foo' contributes 2 seconds to `a''s `children' time, by
-assumption.
-
- This assumption is usually true enough, but for some programs it is
-far from true. Suppose that `foo' returns very quickly when its
-argument is zero; suppose that `a' always passes zero as an argument,
-while other callers of `foo' pass other arguments. In this program,
-all the time spent in `foo' is in the calls from callers other than `a'.
-But `gprof' has no way of knowing this; it will blindly and incorrectly
-charge 2 seconds of time in `foo' to the children of `a'.
-
- We hope some day to put more complete data into `gmon.out', so that
-this assumption is no longer needed, if we can figure out how. For the
-nonce, the estimated figures are usually more useful than misleading.
-
-
-File: gprof.info, Node: Incompatibilities, Prev: Assumptions, Up: Top
-
-Incompatibilities with Unix `gprof'
-***********************************
-
- GNU `gprof' and Berkeley Unix `gprof' use the same data file
-`gmon.out', and provide essentially the same information. But there
-are a few differences.
-
- * For a recursive function, Unix `gprof' lists the function as a
- parent and as a child, with a `calls' field that lists the number
- of recursive calls. GNU `gprof' omits these lines and puts the
- number of recursive calls in the primary line.
-
- * When a function is suppressed from the call graph with `-e', GNU
- `gprof' still lists it as a subroutine of functions that call it.
-
- * The blurbs, field widths, and output formats are different. GNU
- `gprof' prints blurbs after the tables, so that you can see the
- tables without skipping the blurbs.
-
-
-
-Tag Table:
-Node: Top888
-Node: Why2593
-Node: Compiling4687
-Node: Executing6671
-Node: Invoking8782
-Node: Flat Profile14056
-Node: Call Graph17742
-Node: Primary20981
-Node: Callers23514
-Node: Subroutines25621
-Node: Cycles27280
-Node: Implementation34044
-Node: Sampling Error36144
-Node: Assumptions38463
-Node: Incompatibilities39988
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/ld/ld.info b/gnu/usr.bin/binutils/ld/ld.info
deleted file mode 100644
index 657cb438d34..00000000000
--- a/gnu/usr.bin/binutils/ld/ld.info
+++ /dev/null
@@ -1,66 +0,0 @@
-This is Info file ld.info, produced by Makeinfo-1.55 from the input
-file ./ld.texinfo.
-
-START-INFO-DIR-ENTRY
-* Ld: (ld). The GNU linker.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU linker LD.
-
- Copyright (C) 1991, 92, 93, 94, 1995 Free Software Foundation, Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided also
-that the entire resulting derived work is distributed under the terms
-of a permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-Indirect:
-ld.info-1: 865
-ld.info-2: 50745
-ld.info-3: 87906
-
-Tag Table:
-(Indirect)
-Node: Top865
-Node: Overview1338
-Node: Invocation2451
-Node: Options2859
-Node: Environment31228
-Node: Commands32173
-Node: Scripts33167
-Node: Expressions34265
-Node: Integers35192
-Node: Symbols36031
-Node: Location Counter36777
-Node: Operators37925
-Node: Evaluation38835
-Node: Assignment39530
-Node: Arithmetic Functions43059
-Node: MEMORY46594
-Node: SECTIONS49143
-Node: Section Definition50745
-Node: Section Placement52480
-Node: Section Data Expressions56964
-Node: Section Options60825
-Node: Entry Point64497
-Node: Option Commands66042
-Node: Machine Dependent70838
-Node: H8/30071258
-Node: i96072053
-Node: BFD73719
-Node: BFD outline75162
-Node: BFD information loss76447
-Node: Canonical format78955
-Node: MRI83301
-Node: Index87906
-
-End Tag Table
diff --git a/gnu/usr.bin/binutils/ld/ld.info-1 b/gnu/usr.bin/binutils/ld/ld.info-1
deleted file mode 100644
index 8062e684daf..00000000000
--- a/gnu/usr.bin/binutils/ld/ld.info-1
+++ /dev/null
@@ -1,1239 +0,0 @@
-This is Info file ld.info, produced by Makeinfo-1.55 from the input
-file ./ld.texinfo.
-
-START-INFO-DIR-ENTRY
-* Ld: (ld). The GNU linker.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU linker LD.
-
- Copyright (C) 1991, 92, 93, 94, 1995 Free Software Foundation, Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided also
-that the entire resulting derived work is distributed under the terms
-of a permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: ld.info, Node: Top, Next: Overview, Prev: (DIR), Up: (DIR)
-
-Using ld
-********
-
- This file documents the GNU linker ld.
-
-* Menu:
-
-* Overview:: Overview
-* Invocation:: Invocation
-* Commands:: Command Language
-
-* Machine Dependent:: Machine Dependent Features
-
-* BFD:: BFD
-
-* MRI:: MRI Compatible Script Files
-* Index:: Index
-
-
-File: ld.info, Node: Overview, Next: Invocation, Prev: Top, Up: Top
-
-Overview
-********
-
- `ld' combines a number of object and archive files, relocates their
-data and ties up symbol references. Usually the last step in compiling
-a program is to run `ld'.
-
- `ld' accepts Linker Command Language files written in a superset of
-AT&T's Link Editor Command Language syntax, to provide explicit and
-total control over the linking process.
-
- This version of `ld' uses the general purpose BFD libraries to
-operate on object files. This allows `ld' to read, combine, and write
-object files in many different formats--for example, COFF or `a.out'.
-Different formats may be linked together to produce any available kind
-of object file. *Note BFD::, for more information.
-
- Aside from its flexibility, the GNU linker is more helpful than other
-linkers in providing diagnostic information. Many linkers abandon
-execution immediately upon encountering an error; whenever possible,
-`ld' continues executing, allowing you to identify other errors (or, in
-some cases, to get an output file in spite of the error).
-
-
-File: ld.info, Node: Invocation, Next: Commands, Prev: Overview, Up: Top
-
-Invocation
-**********
-
- The GNU linker `ld' is meant to cover a broad range of situations,
-and to be as compatible as possible with other linkers. As a result,
-you have many choices to control its behavior.
-
-* Menu:
-
-* Options:: Command Line Options
-* Environment:: Environment Variables
-
-
-File: ld.info, Node: Options, Next: Environment, Up: Invocation
-
-Command Line Options
-====================
-
- Here is a summary of the options you can use on the `ld' command
-line:
-
- ld [ -o OUTPUT ] OBJFILE...
- [ -AARCHITECTURE ] [ -b INPUT-FORMAT ]
- [ -Bstatic ] [ -Bdynamic ] [ -Bsymbolic ]
- [ -c MRI-COMMANDFILE ] [ -d | -dc | -dp ]
- [ -defsym SYMBOL=EXPRESSION ]
- [ -dynamic-linker FILE ] [ -embedded-relocs ]
- [ -e ENTRY ] [ -F ] [ -F FORMAT ]
- [ -format INPUT-FORMAT ] [ -g ] [ -G SIZE ]
- [ -help ] [ -i ] [ -lARCHIVE ] [ -LSEARCHDIR ]
- [ -M ] [ -Map MAPFILE ] [ -m EMULATION ]
- [ -N | -n ] [ -noinhibit-exec ] [ -no-keep-memory ]
- [ -oformat OUTPUT-FORMAT ] [ -R FILENAME ]
- [ -relax ] [ -retain-symbols-file FILENAME ]
- [ -r | -Ur ] [ -rpath DIR ] [-rpath-link DIR ]
- [ -S ] [ -s ] [ -soname NAME ] [ -shared ]
- [ -sort-common ] [ -stats ] [ -T COMMANDFILE ]
- [ -Ttext ORG ] [ -Tdata ORG ]
- [ -Tbss ORG ] [ -t ] [ -traditional-format ]
- [ -u SYMBOL] [-V] [-v] [ -verbose] [ -version ]
- [ -warn-common ] [ -warn-constructors] [ -warn-once ]
- [ -y SYMBOL ] [ -X ] [-x ]
- [ -( [ archives ] -) ]
- [ --start-group [ archives ] --end-group ]
- [ -split-by-reloc COUNT ] [ -split-by-file ]
- [ --whole-archive ]
-
- This plethora of command-line options may seem intimidating, but in
-actual practice few of them are used in any particular context. For
-instance, a frequent use of `ld' is to link standard Unix object files
-on a standard, supported Unix system. On such a system, to link a file
-`hello.o':
-
- ld -o OUTPUT /lib/crt0.o hello.o -lc
-
- This tells `ld' to produce a file called OUTPUT as the result of
-linking the file `/lib/crt0.o' with `hello.o' and the library `libc.a',
-which will come from the standard search directories. (See the
-discussion of the `-l' option below.)
-
- The command-line options to `ld' may be specified in any order, and
-may be repeated at will. Repeating most options with a different
-argument will either have no further effect, or override prior
-occurrences (those further to the left on the command line) of that
-option.
-
- The exceptions--which may meaningfully be used more than once--are
-`-A', `-b' (or its synonym `-format'), `-defsym', `-L', `-l', `-R',
-`-u', and `-(' (or its synonym `--start-group')..
-
- The list of object files to be linked together, shown as OBJFILE...,
-may follow, precede, or be mixed in with command-line options, except
-that an OBJFILE argument may not be placed between an option and its
-argument.
-
- Usually the linker is invoked with at least one object file, but you
-can specify other forms of binary input files using `-l', `-R', and the
-script command language. If *no* binary input files at all are
-specified, the linker does not produce any output, and issues the
-message `No input files'.
-
- If the linker can not recognize the format of an object file, it will
-assume that it is a linker script. A script specified in this way
-augments the main linker script used for the link (either the default
-linker script or the one specified by using `-T'). This feature
-permits the linker to link against a file which appears to be an object
-or an archive, but actually merely defines some symbol values, or uses
-`INPUT' or `GROUP' to load other objects. *Note Commands::.
-
- For options whose names are a single letter, option arguments must
-either follow the option letter without intervening whitespace, or be
-given as separate arguments immediately following the option that
-requires them.
-
- For options whose names are multiple letters, either one dash or two
-can precede the option name; for example, `--oformat' and `-oformat'
-are equivalent. Arguments to multiple-letter options must either be
-separated from the option name by an equals sign, or be given as
-separate arguments immediately following the option that requires them.
-For example, `--oformat srec' and `--oformat=srec' are equivalent.
-Unique abbreviations of the names of multiple-letter options are
-accepted.
-
-`-AARCHITECTURE'
- In the current release of `ld', this option is useful only for the
- Intel 960 family of architectures. In that `ld' configuration, the
- ARCHITECTURE argument identifies the particular architecture in
- the 960 family, enabling some safeguards and modifying the
- archive-library search path. *Note `ld' and the Intel 960 family:
- i960, for details.
-
- Future releases of `ld' may support similar functionality for
- other architecture families.
-
-`-b INPUT-FORMAT'
- `ld' may be configured to support more than one kind of object
- file. If your `ld' is configured this way, you can use the `-b'
- option to specify the binary format for input object files that
- follow this option on the command line. Even when `ld' is
- configured to support alternative object formats, you don't
- usually need to specify this, as `ld' should be configured to
- expect as a default input format the most usual format on each
- machine. INPUT-FORMAT is a text string, the name of a particular
- format supported by the BFD libraries. (You can list the
- available binary formats with `objdump -i'.)
- `-format INPUT-FORMAT' has the same effect, as does the script
- command `TARGET'. *Note BFD::.
-
- You may want to use this option if you are linking files with an
- unusual binary format. You can also use `-b' to switch formats
- explicitly (when linking object files of different formats), by
- including `-b INPUT-FORMAT' before each group of object files in a
- particular format.
-
- The default format is taken from the environment variable
- `GNUTARGET'. *Note Environment::. You can also define the input
- format from a script, using the command `TARGET'; see *Note Option
- Commands::.
-
-`-Bstatic'
- Do not link against shared libraries. This is only meaningful on
- platforms for which shared libraries are supported.
-
-`-Bdynamic'
- Link against dynamic libraries. This is only meaningful on
- platforms for which shared libraries are supported. This option
- is normally the default on such platforms.
-
-`-Bsymbolic'
- When creating a shared library, bind references to global symbols
- to the definition within the shared library, if any. Normally, it
- is possible for a program linked against a shared library to
- override the definition within the shared library. This option is
- only meaningful on ELF platforms which support shared libraries.
-
-`-c MRI-COMMANDFILE'
- For compatibility with linkers produced by MRI, `ld' accepts script
- files written in an alternate, restricted command language,
- described in *Note MRI Compatible Script Files: MRI. Introduce
- MRI script files with the option `-c'; use the `-T' option to run
- linker scripts written in the general-purpose `ld' scripting
- language. If MRI-CMDFILE does not exist, `ld' looks for it in the
- directories specified by any `-L' options.
-
-`-d'
-`-dc'
-`-dp'
- These three options are equivalent; multiple forms are supported
- for compatibility with other linkers. They assign space to common
- symbols even if a relocatable output file is specified (with
- `-r'). The script command `FORCE_COMMON_ALLOCATION' has the same
- effect. *Note Option Commands::.
-
-`-defsym SYMBOL=EXPRESSION'
- Create a global symbol in the output file, containing the absolute
- address given by EXPRESSION. You may use this option as many
- times as necessary to define multiple symbols in the command line.
- A limited form of arithmetic is supported for the EXPRESSION in
- this context: you may give a hexadecimal constant or the name of
- an existing symbol, or use `+' and `-' to add or subtract
- hexadecimal constants or symbols. If you need more elaborate
- expressions, consider using the linker command language from a
- script (*note Assignment: Symbol Definitions: Assignment.).
- *Note:* there should be no white space between SYMBOL, the equals
- sign ("="), and EXPRESSION.
-
-`-dynamic-linker FILE'
- Set the name of the dynamic linker. This is only meaningful when
- generating dynamically linked ELF executables. The default dynamic
- linker is normally correct; don't use this unless you know what
- you are doing.
-
-`-embedded-relocs'
- This option is only meaningful when linking MIPS embedded PIC code,
- generated by the -membedded-pic option to the GNU compiler and
- assembler. It causes the linker to create a table which may be
- used at runtime to relocate any data which was statically
- initialized to pointer values. See the code in testsuite/ld-empic
- for details.
-
-`-e ENTRY'
- Use ENTRY as the explicit symbol for beginning execution of your
- program, rather than the default entry point. *Note Entry Point::,
- for a discussion of defaults and other ways of specifying the
- entry point.
-
-`-F'
-`-FFORMAT'
- Ignored. Some older linkers used this option throughout a
- compilation toolchain for specifying object-file format for both
- input and output object files. The mechanisms `ld' uses for this
- purpose (the `-b' or `-format' options for input files, `-oformat'
- option or the `TARGET' command in linker scripts for output files,
- the `GNUTARGET' environment variable) are more flexible, but `ld'
- accepts the `-F' option for compatibility with scripts written to
- call the old linker.
-
-`-format INPUT-FORMAT'
- Synonym for `-b INPUT-FORMAT'.
-
-`-g'
- Ignored. Provided for compatibility with other tools.
-
-`-GVALUE'
-`-G VALUE'
- Set the maximum size of objects to be optimized using the GP
- register to SIZE under MIPS ECOFF. Ignored for other object file
- formats.
-
-`-help'
- Print a summary of the command-line options on the standard output
- and exit.
-
-`-i'
- Perform an incremental link (same as option `-r').
-
-`-lAR'
- Add archive file ARCHIVE to the list of files to link. This
- option may be used any number of times. `ld' will search its
- path-list for occurrences of `libAR.a' for every ARCHIVE specified.
-
-`-LSEARCHDIR'
-`-L SEARCHDIR'
- Add path SEARCHDIR to the list of paths that `ld' will search for
- archive libraries and `ld' control scripts. You may use this
- option any number of times. The directories are searched in the
- order in which they are specified on the command line.
- Directories specified on the command line are searched before the
- default directories. All `-L' options apply to all `-l' options,
- regardless of the order in which the options appear.
-
- The default set of paths searched (without being specified with
- `-L') depends on which emulation mode `ld' is using, and in some
- cases also on how it was configured. *Note Environment::.
-
- The paths can also be specified in a link script with the
- `SEARCH_DIR' command. Directories specified this way are searched
- at the point in which the linker script appears in the command
- line.
-
-`-M'
- Print (to the standard output) a link map--diagnostic information
- about where symbols are mapped by `ld', and information on global
- common storage allocation.
-
-`-Map MAPFILE'
- Print to the file MAPFILE a link map--diagnostic information about
- where symbols are mapped by `ld', and information on global common
- storage allocation.
-
-`-mEMULATION'
-`-m EMULATION'
- Emulate the EMULATION linker. You can list the available
- emulations with the `--verbose' or `-V' options. The default
- depends on how your `ld' was configured.
-
-`-N'
- Set the text and data sections to be readable and writable. Also,
- do not page-align the data segment. If the output format supports
- Unix style magic numbers, mark the output as `OMAGIC'.
-
-`-n'
- Set the text segment to be read only, and mark the output as
- `NMAGIC' if possible.
-
-`-noinhibit-exec'
- Retain the executable output file whenever it is still usable.
- Normally, the linker will not produce an output file if it
- encounters errors during the link process; it exits without
- writing an output file when it issues any error whatsoever.
-
-`-no-keep-memory'
- `ld' normally optimizes for speed over memory usage by caching the
- symbol tables of input files in memory. This option tells `ld' to
- instead optimize for memory usage, by rereading the symbol tables
- as necessary. This may be required if `ld' runs out of memory
- space while linking a large executable.
-
-`-o OUTPUT'
- Use OUTPUT as the name for the program produced by `ld'; if this
- option is not specified, the name `a.out' is used by default. The
- script command `OUTPUT' can also specify the output file name.
-
-`-oformat OUTPUT-FORMAT'
- `ld' may be configured to support more than one kind of object
- file. If your `ld' is configured this way, you can use the
- `-oformat' option to specify the binary format for the output
- object file. Even when `ld' is configured to support alternative
- object formats, you don't usually need to specify this, as `ld'
- should be configured to produce as a default output format the most
- usual format on each machine. OUTPUT-FORMAT is a text string, the
- name of a particular format supported by the BFD libraries. (You
- can list the available binary formats with `objdump -i'.) The
- script command `OUTPUT_FORMAT' can also specify the output format,
- but this option overrides it. *Note BFD::.
-
-`-R FILENAME'
- Read symbol names and their addresses from FILENAME, but do not
- relocate it or include it in the output. This allows your output
- file to refer symbolically to absolute locations of memory defined
- in other programs.
-
-`-relax'
- An option with machine dependent effects. Currently this option
- is only supported on the H8/300 and the Intel 960. *Note `ld' and
- the H8/300: H8/300. *Note `ld' and the Intel 960 family: i960.
-
- On some platforms, the `-relax' option performs global
- optimizations that become possible when the linker resolves
- addressing in the program, such as relaxing address modes and
- synthesizing new instructions in the output object file.
-
- On platforms where this is not supported, `-relax' is accepted, but
- ignored.
-
-`-retain-symbols-file FILENAME'
- Retain *only* the symbols listed in the file FILENAME, discarding
- all others. FILENAME is simply a flat file, with one symbol name
- per line. This option is especially useful in environments (such
- as VxWorks) where a large global symbol table is accumulated
- gradually, to conserve run-time memory.
-
- `-retain-symbols-file' does *not* discard undefined symbols, or
- symbols needed for relocations.
-
- You may only specify `-retain-symbols-file' once in the command
- line. It overrides `-s' and `-S'.
-
-`-rpath DIR'
- Add a directory to the runtime library search path. This is used
- when linking an ELF executable with shared objects. All `-rpath'
- arguments are concatenated and passed to the runtime linker, which
- uses them to locate shared objects at runtime. The `-rpath'
- option is also used when locating shared objects which are needed
- by shared objects explicitly included in the link; see the
- description of the `-rpath-link' option. If `-rpath' is not used
- when linking an ELF executable, the contents of the environment
- variable `LD_RUN_PATH' will be used if it is defined.
-
- The `-rpath' option may also be used on SunOS. By default, on
- SunOS, the linker will form a runtime search patch out of all the
- `-L' options it is given. If a `-rpath' option is used, the
- runtime search path will be formed exclusively using the `-rpath'
- options, ignoring the `-L' options. This can be useful when using
- gcc, which adds many `-L' options which may be on NFS mounted
- filesystems.
-
-`-rpath-link DIR'
- When using ELF or SunOS, one shared library may require another.
- This happens when an `ld -shared' link includes a shared library
- as one of the input files.
-
- When the linker encounters such a dependency when doing a
- non-shared, non-relocateable link, it will automatically try to
- locate the required shared library and include it in the link, if
- it is not included explicitly. In such a case, the `-rpath-link'
- option specifies the first set of directories to search. The
- `-rpath-link' option may specify a sequence of directory names
- either by specifying a list of names separated by colons, or by
- appearing multiple times.
-
- The linker uses the following search paths to locate required
- shared libraries.
- 1. Any directories specified by `-rpath-link' options.
-
- 2. Any directories specified by `-rpath' options. The difference
- between `-rpath' and `-rpath-link' is that directories
- specified by `-rpath' options are included in the executable
- and used at runtime, whereas the `-rpath-link' option is only
- effective at link time.
-
- 3. On an ELF system, if the `-rpath' and `rpath-link' options
- were not used, search the contents of the environment variable
- `LD_RUN_PATH'.
-
- 4. On SunOS, if the `-rpath' option was not used, search any
- directories specified using `-L' options.
-
- 5. For a native linker, the contents of the environment variable
- `LD_LIBRARY_PATH'.
-
- 6. The default directories, normally `/lib' and `/usr/lib'.
-
- If the required shared library is not found, the linker will issue
- a warning and continue with the link.
-
-`-r'
- Generate relocatable output--i.e., generate an output file that
- can in turn serve as input to `ld'. This is often called "partial
- linking". As a side effect, in environments that support standard
- Unix magic numbers, this option also sets the output file's magic
- number to `OMAGIC'. If this option is not specified, an absolute
- file is produced. When linking C++ programs, this option *will
- not* resolve references to constructors; to do that, use `-Ur'.
-
- This option does the same thing as `-i'.
-
-`-S'
- Omit debugger symbol information (but not all symbols) from the
- output file.
-
-`-s'
- Omit all symbol information from the output file.
-
-`-soname NAME'
- When creating an ELF shared object, set the internal DT_SONAME
- field to the specified name. When an executable is linked with a
- shared object which has a DT_SONAME field, then when the
- executable is run the dynamic linker will attempt to load the
- shared object specified by the DT_SONAME field rather than the
- using the file name given to the linker.
-
-`-shared'
- Create a shared library. This is currently only supported on ELF
- and SunOS platforms. On SunOS, the linker will automatically
- create a shared library if the `-e' option is not used and there
- are undefined symbols in the link.
-
-`-sort-common'
- Normally, when `ld' places the global common symbols in the
- appropriate output sections, it sorts them by size. First come
- all the one byte symbols, then all the two bytes, then all the
- four bytes, and then everything else. This is to prevent gaps
- between symbols due to alignment constraints. This option
- disables that sorting.
-
-`-split-by-reloc COUNT'
- Trys to creates extra sections in the output file so that no
- single output section in the file contains more than COUNT
- relocations. This is useful when generating huge relocatable for
- downloading into certain real time kernels with the COFF object
- file format; since COFF cannot represent more than 65535
- relocations in a single section. Note that this will fail to work
- with object file formats which do not support arbitrary sections.
- The linker will not split up individual input sections for
- redistribution, so if a single input section contains more than
- COUNT relocations one output section will contain that many
- relocations.
-
-`-split-by-file'
- Similar to -split-by-reloc but creates a new output section for
- each input file.
-
-`-stats'
- Compute and display statistics about the operation of the linker,
- such as execution time and memory usage.
-
-`-Tbss ORG'
-`-Tdata ORG'
-`-Ttext ORG'
- Use ORG as the starting address for--respectively--the `bss',
- `data', or the `text' segment of the output file. ORG must be a
- single hexadecimal integer; for compatibility with other linkers,
- you may omit the leading `0x' usually associated with hexadecimal
- values.
-
-`-T COMMANDFILE'
-`-TCOMMANDFILE'
- Read link commands from the file COMMANDFILE. These commands
- replace `ld''s default link script (rather than adding to it), so
- COMMANDFILE must specify everything necessary to describe the
- target format. *Note Commands::. If COMMANDFILE does not exist,
- `ld' looks for it in the directories specified by any preceding
- `-L' options. Multiple `-T' options accumulate.
-
-`-t'
- Print the names of the input files as `ld' processes them.
-
-`-traditional-format'
- For some targets, the output of `ld' is different in some ways from
- the output of some existing linker. This switch requests `ld' to
- use the traditional format instead.
-
- For example, on SunOS, `ld' combines duplicate entries in the
- symbol string table. This can reduce the size of an output file
- with full debugging information by over 30 percent.
- Unfortunately, the SunOS `dbx' program can not read the resulting
- program (`gdb' has no trouble). The `-traditional-format' switch
- tells `ld' to not combine duplicate entries.
-
-`-u SYMBOL'
- Force SYMBOL to be entered in the output file as an undefined
- symbol. Doing this may, for example, trigger linking of
- additional modules from standard libraries. `-u' may be repeated
- with different option arguments to enter additional undefined
- symbols.
-
-`-Ur'
- For anything other than C++ programs, this option is equivalent to
- `-r': it generates relocatable output--i.e., an output file that
- can in turn serve as input to `ld'. When linking C++ programs,
- `-Ur' *does* resolve references to constructors, unlike `-r'. It
- does not work to use `-Ur' on files that were themselves linked
- with `-Ur'; once the constructor table has been built, it cannot
- be added to. Use `-Ur' only for the last partial link, and `-r'
- for the others.
-
-`--verbose'
- Display the version number for `ld' and list the linker emulations
- supported. Display which input files can and cannot be opened.
-
-`-v'
-`-V'
- Display the version number for `ld'. The `-V' option also lists
- the supported emulations.
-
-`-version'
- Display the version number for `ld' and exit.
-
-`-warn-common'
- Warn when a common symbol is combined with another common symbol
- or with a symbol definition. Unix linkers allow this somewhat
- sloppy practice, but linkers on some other operating systems do
- not. This option allows you to find potential problems from
- combining global symbols. Unfortunately, some C libraries use
- this practice, so you may get some warnings about symbols in the
- libraries as well as in your programs.
-
- There are three kinds of global symbols, illustrated here by C
- examples:
-
- `int i = 1;'
- A definition, which goes in the initialized data section of
- the output file.
-
- `extern int i;'
- An undefined reference, which does not allocate space. There
- must be either a definition or a common symbol for the
- variable somewhere.
-
- `int i;'
- A common symbol. If there are only (one or more) common
- symbols for a variable, it goes in the uninitialized data
- area of the output file. The linker merges multiple common
- symbols for the same variable into a single symbol. If they
- are of different sizes, it picks the largest size. The
- linker turns a common symbol into a declaration, if there is
- a definition of the same variable.
-
- The `-warn-common' option can produce five kinds of warnings. Each
- warning consists of a pair of lines: the first describes the
- symbol just encountered, and the second describes the previous
- symbol encountered with the same name. One or both of the two
- symbols will be a common symbol.
-
- 1. Turning a common symbol into a reference, because there is
- already a definition for the symbol.
- FILE(SECTION): warning: common of `SYMBOL'
- overridden by definition
- FILE(SECTION): warning: defined here
-
- 2. Turning a common symbol into a reference, because a later
- definition for the symbol is encountered. This is the same
- as the previous case, except that the symbols are encountered
- in a different order.
- FILE(SECTION): warning: definition of `SYMBOL'
- overriding common
- FILE(SECTION): warning: common is here
-
- 3. Merging a common symbol with a previous same-sized common
- symbol.
- FILE(SECTION): warning: multiple common
- of `SYMBOL'
- FILE(SECTION): warning: previous common is here
-
- 4. Merging a common symbol with a previous larger common symbol.
- FILE(SECTION): warning: common of `SYMBOL'
- overridden by larger common
- FILE(SECTION): warning: larger common is here
-
- 5. Merging a common symbol with a previous smaller common
- symbol. This is the same as the previous case, except that
- the symbols are encountered in a different order.
- FILE(SECTION): warning: common of `SYMBOL'
- overriding smaller common
- FILE(SECTION): warning: smaller common is here
-
-`-warn-constructors'
- Warn if any global constructors are used. This is only useful for
- a few object file formats. For formats like COFF or ELF, the
- linker can not detect the use of global constructors.
-
-`-warn-once'
- Only warn once for each undefined symbol, rather than once per
- module which refers to it.
-
- For each archive mentioned on the command line, include every
- object file in the archive in the link, rather than searching the
- archive for the required object files. This is normally used to
- turn an archive file into a shared library, forcing every object
- to be included in the resulting shared library.
-
-`-X'
- Delete all temporary local symbols. For most targets, this is all
- local symbols whose names begin with `L'.
-
-`-x'
- Delete all local symbols.
-
-`-y SYMBOL'
- Print the name of each linked file in which SYMBOL appears. This
- option may be given any number of times. On many systems it is
- necessary to prepend an underscore.
-
- This option is useful when you have an undefined symbol in your
- link but don't know where the reference is coming from.
-
-`-( ARCHIVES -)'
-`--start-group ARCHIVES --end-group'
- The ARCHIVES should be a list of archive files. They may be
- either explicit file names, or `-l' options.
-
- The specified archives are searched repeatedly until no new
- undefined references are created. Normally, an archive is
- searched only once in the order that it is specified on the
- command line. If a symbol in that archive is needed to resolve an
- undefined symbol referred to by an object in an archive that
- appears later on the command line, the linker would not be able to
- resolve that reference. By grouping the archives, they all be
- searched repeatedly until all possible references are resolved.
-
- Using this option has a significant performance cost. It is best
- to use it only when there are unavoidable circular references
- between two or more archives.
-
-
-File: ld.info, Node: Environment, Prev: Options, Up: Invocation
-
-Environment Variables
-=====================
-
- You can change the behavior of `ld' with the environment variable
-`GNUTARGET'.
-
- `GNUTARGET' determines the input-file object format if you don't use
-`-b' (or its synonym `-format'). Its value should be one of the BFD
-names for an input format (*note BFD::.). If there is no `GNUTARGET'
-in the environment, `ld' uses the natural format of the target. If
-`GNUTARGET' is set to `default' then BFD attempts to discover the input
-format by examining binary input files; this method often succeeds, but
-there are potential ambiguities, since there is no method of ensuring
-that the magic number used to specify object-file formats is unique.
-However, the configuration procedure for BFD on each system places the
-conventional format for that system first in the search-list, so
-ambiguities are resolved in favor of convention.
-
-
-File: ld.info, Node: Commands, Next: Machine Dependent, Prev: Invocation, Up: Top
-
-Command Language
-****************
-
- The command language provides explicit control over the link process,
-allowing complete specification of the mapping between the linker's
-input files and its output. It controls:
- * input files
-
- * file formats
-
- * output file layout
-
- * addresses of sections
-
- * placement of common blocks
-
- You may supply a command file (also known as a link script) to the
-linker either explicitly through the `-T' option, or implicitly as an
-ordinary file. If the linker opens a file which it cannot recognize as
-a supported object or archive format, it reports an error.
-
-* Menu:
-
-* Scripts:: Linker Scripts
-* Expressions:: Expressions
-* MEMORY:: MEMORY Command
-* SECTIONS:: SECTIONS Command
-* Entry Point:: The Entry Point
-* Option Commands:: Option Commands
-
-
-File: ld.info, Node: Scripts, Next: Expressions, Up: Commands
-
-Linker Scripts
-==============
-
- The `ld' command language is a collection of statements; some are
-simple keywords setting a particular option, some are used to select and
-group input files or name output files; and two statement types have a
-fundamental and pervasive impact on the linking process.
-
- The most fundamental command of the `ld' command language is the
-`SECTIONS' command (*note SECTIONS::.). Every meaningful command
-script must have a `SECTIONS' command: it specifies a "picture" of the
-output file's layout, in varying degrees of detail. No other command
-is required in all cases.
-
- The `MEMORY' command complements `SECTIONS' by describing the
-available memory in the target architecture. This command is optional;
-if you don't use a `MEMORY' command, `ld' assumes sufficient memory is
-available in a contiguous block for all output. *Note MEMORY::.
-
- You may include comments in linker scripts just as in C: delimited
-by `/*' and `*/'. As in C, comments are syntactically equivalent to
-whitespace.
-
-
-File: ld.info, Node: Expressions, Next: MEMORY, Prev: Scripts, Up: Commands
-
-Expressions
-===========
-
- Many useful commands involve arithmetic expressions. The syntax for
-expressions in the command language is identical to that of C
-expressions, with the following features:
- * All expressions evaluated as integers and are of "long" or
- "unsigned long" type.
-
- * All constants are integers.
-
- * All of the C arithmetic operators are provided.
-
- * You may reference, define, and create global variables.
-
- * You may call special purpose built-in functions.
-
-* Menu:
-
-* Integers:: Integers
-* Symbols:: Symbol Names
-* Location Counter:: The Location Counter
-* Operators:: Operators
-* Evaluation:: Evaluation
-* Assignment:: Assignment: Defining Symbols
-* Arithmetic Functions:: Built-In Functions
-
-
-File: ld.info, Node: Integers, Next: Symbols, Up: Expressions
-
-Integers
---------
-
- An octal integer is `0' followed by zero or more of the octal digits
-(`01234567').
- _as_octal = 0157255;
-
- A decimal integer starts with a non-zero digit followed by zero or
-more digits (`0123456789').
- _as_decimal = 57005;
-
- A hexadecimal integer is `0x' or `0X' followed by one or more
-hexadecimal digits chosen from `0123456789abcdefABCDEF'.
- _as_hex = 0xdead;
-
- To write a negative integer, use the prefix operator `-'; *note
-Operators::..
- _as_neg = -57005;
-
- Additionally the suffixes `K' and `M' may be used to scale a
-constant by `1024' or `1024*1024' respectively. For example, the
-following all refer to the same quantity:
-
- _fourk_1 = 4K;
- _fourk_2 = 4096;
- _fourk_3 = 0x1000;
-
-
-File: ld.info, Node: Symbols, Next: Location Counter, Prev: Integers, Up: Expressions
-
-Symbol Names
-------------
-
- Unless quoted, symbol names start with a letter, underscore, or point
-and may include any letters, underscores, digits, points, and hyphens.
-Unquoted symbol names must not conflict with any keywords. You can
-specify a symbol which contains odd characters or has the same name as
-a keyword, by surrounding the symbol name in double quotes:
- "SECTION" = 9;
- "with a space" = "also with a space" + 10;
-
- Since symbols can contain many non-alphabetic characters, it is
-safest to delimit symbols with spaces. For example, `A-B' is one
-symbol, whereas `A - B' is an expression involving subtraction.
-
-
-File: ld.info, Node: Location Counter, Next: Operators, Prev: Symbols, Up: Expressions
-
-The Location Counter
---------------------
-
- The special linker variable "dot" `.' always contains the current
-output location counter. Since the `.' always refers to a location in
-an output section, it must always appear in an expression within a
-`SECTIONS' command. The `.' symbol may appear anywhere that an ordinary
-symbol is allowed in an expression, but its assignments have a side
-effect. Assigning a value to the `.' symbol will cause the location
-counter to be moved. This may be used to create holes in the output
-section. The location counter may never be moved backwards.
- SECTIONS
- {
- output :
- {
- file1(.text)
- . = . + 1000;
- file2(.text)
- . += 1000;
- file3(.text)
- } = 0x1234;
- }
-
-In the previous example, `file1' is located at the beginning of the
-output section, then there is a 1000 byte gap. Then `file2' appears,
-also with a 1000 byte gap following before `file3' is loaded. The
-notation `= 0x1234' specifies what data to write in the gaps (*note
-Section Options::.).
-
-
-File: ld.info, Node: Operators, Next: Evaluation, Prev: Location Counter, Up: Expressions
-
-Operators
----------
-
- The linker recognizes the standard C set of arithmetic operators,
-with the standard bindings and precedence levels:
- precedence associativity Operators Notes
- (highest)
- 1 left ! - ~ (1)
- 2 left * / %
- 3 left + -
- 4 left >> <<
- 5 left == != > < <= >=
- 6 left &
- 7 left |
- 8 left &&
- 9 left ||
- 10 right ? :
- 11 right &= += -= *= /= (2)
- (lowest)
- Notes: (1) Prefix operators (2) *Note Assignment::
-
-
-File: ld.info, Node: Evaluation, Next: Assignment, Prev: Operators, Up: Expressions
-
-Evaluation
-----------
-
- The linker uses "lazy evaluation" for expressions; it only calculates
-an expression when absolutely necessary. The linker needs the value of
-the start address, and the lengths of memory regions, in order to do any
-linking at all; these values are computed as soon as possible when the
-linker reads in the command file. However, other values (such as symbol
-values) are not known or needed until after storage allocation. Such
-values are evaluated later, when other information (such as the sizes of
-output sections) is available for use in the symbol assignment
-expression.
-
-
-File: ld.info, Node: Assignment, Next: Arithmetic Functions, Prev: Evaluation, Up: Expressions
-
-Assignment: Defining Symbols
-----------------------------
-
- You may create global symbols, and assign values (addresses) to
-global symbols, using any of the C assignment operators:
-
-`SYMBOL = EXPRESSION ;'
-`SYMBOL &= EXPRESSION ;'
-`SYMBOL += EXPRESSION ;'
-`SYMBOL -= EXPRESSION ;'
-`SYMBOL *= EXPRESSION ;'
-`SYMBOL /= EXPRESSION ;'
- Two things distinguish assignment from other operators in `ld'
-expressions.
- * Assignment may only be used at the root of an expression; `a=b+3;'
- is allowed, but `a+b=3;' is an error.
-
- * You must place a trailing semicolon (";") at the end of an
- assignment statement.
-
- Assignment statements may appear:
- * as commands in their own right in an `ld' script; or
-
- * as independent statements within a `SECTIONS' command; or
-
- * as part of the contents of a section definition in a `SECTIONS'
- command.
-
- The first two cases are equivalent in effect--both define a symbol
-with an absolute address. The last case defines a symbol whose address
-is relative to a particular section (*note SECTIONS::.).
-
- When a linker expression is evaluated and assigned to a variable, it
-is given either an absolute or a relocatable type. An absolute
-expression type is one in which the symbol contains the value that it
-will have in the output file; a relocatable expression type is one in
-which the value is expressed as a fixed offset from the base of a
-section.
-
- The type of the expression is controlled by its position in the
-script file. A symbol assigned within a section definition is created
-relative to the base of the section; a symbol assigned in any other
-place is created as an absolute symbol. Since a symbol created within a
-section definition is relative to the base of the section, it will
-remain relocatable if relocatable output is requested. A symbol may be
-created with an absolute value even when assigned to within a section
-definition by using the absolute assignment function `ABSOLUTE'. For
-example, to create an absolute symbol whose address is the last byte of
-an output section named `.data':
- SECTIONS{ ...
- .data :
- {
- *(.data)
- _edata = ABSOLUTE(.) ;
- }
- ... }
-
- The linker tries to put off the evaluation of an assignment until all
-the terms in the source expression are known (*note Evaluation::.). For
-instance, the sizes of sections cannot be known until after allocation,
-so assignments dependent upon these are not performed until after
-allocation. Some expressions, such as those depending upon the location
-counter "dot", `.' must be evaluated during allocation. If the result
-of an expression is required, but the value is not available, then an
-error results. For example, a script like the following
- SECTIONS { ...
- text 9+this_isnt_constant :
- { ...
- }
- ... }
-
-will cause the error message "`Non constant expression for initial
-address'".
-
- In some cases, it is desirable for a linker script to define a symbol
-only if it is referenced, and only if it is not defined by any object
-included in the link. For example, traditional linkers defined the
-symbol `etext'. However, ANSI C requires that the user be able to use
-`etext' as a function name without encountering an error. The
-`PROVIDE' keyword may be used to define a symbol, such as `etext', only
-if it is referenced but not defined. The syntax is `PROVIDE(SYMBOL =
-EXPRESSION)'.
-
-
-File: ld.info, Node: Arithmetic Functions, Prev: Assignment, Up: Expressions
-
-Arithmetic Functions
---------------------
-
- The command language includes a number of built-in functions for use
-in link script expressions.
-`ABSOLUTE(EXP)'
- Return the absolute (non-relocatable, as opposed to non-negative)
- value of the expression EXP. Primarily useful to assign an
- absolute value to a symbol within a section definition, where
- symbol values are normally section-relative.
-
-`ADDR(SECTION)'
- Return the absolute address of the named SECTION. Your script must
- previously have defined the location of that section. In the
- following example, `symbol_1' and `symbol_2' are assigned identical
- values:
- SECTIONS{ ...
- .output1 :
- {
- start_of_output_1 = ABSOLUTE(.);
- ...
- }
- .output :
- {
- symbol_1 = ADDR(.output1);
- symbol_2 = start_of_output_1;
- }
- ... }
-
-`ALIGN(EXP)'
- Return the result of the current location counter (`.') aligned to
- the next EXP boundary. EXP must be an expression whose value is a
- power of two. This is equivalent to
- (. + EXP - 1) & ~(EXP - 1)
-
- `ALIGN' doesn't change the value of the location counter--it just
- does arithmetic on it. As an example, to align the output `.data'
- section to the next `0x2000' byte boundary after the preceding
- section and to set a variable within the section to the next
- `0x8000' boundary after the input sections:
- SECTIONS{ ...
- .data ALIGN(0x2000): {
- *(.data)
- variable = ALIGN(0x8000);
- }
- ... }
-
- The first use of `ALIGN' in this example specifies the location of
- a section because it is used as the optional START attribute of a
- section definition (*note Section Options::.). The second use
- simply defines the value of a variable.
-
- The built-in `NEXT' is closely related to `ALIGN'.
-
-`DEFINED(SYMBOL)'
- Return 1 if SYMBOL is in the linker global symbol table and is
- defined, otherwise return 0. You can use this function to provide
- default values for symbols. For example, the following
- command-file fragment shows how to set a global symbol `begin' to
- the first location in the `.text' section--but if a symbol called
- `begin' already existed, its value is preserved:
-
- SECTIONS{ ...
- .text : {
- begin = DEFINED(begin) ? begin : . ;
- ...
- }
- ... }
-
-`NEXT(EXP)'
- Return the next unallocated address that is a multiple of EXP.
- This function is closely related to `ALIGN(EXP)'; unless you use
- the `MEMORY' command to define discontinuous memory for the output
- file, the two functions are equivalent.
-
-`SIZEOF(SECTION)'
- Return the size in bytes of the named SECTION, if that section has
- been allocated. In the following example, `symbol_1' and
- `symbol_2' are assigned identical values:
- SECTIONS{ ...
- .output {
- .start = . ;
- ...
- .end = . ;
- }
- symbol_1 = .end - .start ;
- symbol_2 = SIZEOF(.output);
- ... }
-
-`SIZEOF_HEADERS'
-`sizeof_headers'
- Return the size in bytes of the output file's headers. You can
- use this number as the start address of the first section, if you
- choose, to facilitate paging.
-
-
-File: ld.info, Node: MEMORY, Next: SECTIONS, Prev: Expressions, Up: Commands
-
-Memory Layout
-=============
-
- The linker's default configuration permits allocation of all
-available memory. You can override this configuration by using the
-`MEMORY' command. The `MEMORY' command describes the location and size
-of blocks of memory in the target. By using it carefully, you can
-describe which memory regions may be used by the linker, and which
-memory regions it must avoid. The linker does not shuffle sections to
-fit into the available regions, but does move the requested sections
-into the correct regions and issue errors when the regions become too
-full.
-
- A command file may contain at most one use of the `MEMORY' command;
-however, you can define as many blocks of memory within it as you wish.
-The syntax is:
-
- MEMORY
- {
- NAME (ATTR) : ORIGIN = ORIGIN, LENGTH = LEN
- ...
- }
-
-`NAME'
- is a name used internally by the linker to refer to the region. Any
- symbol name may be used. The region names are stored in a separate
- name space, and will not conflict with symbols, file names or
- section names. Use distinct names to specify multiple regions.
-
-`(ATTR)'
- is an optional list of attributes, permitted for compatibility
- with the AT&T linker but not used by `ld' beyond checking that the
- attribute list is valid. Valid attribute lists must be made up of
- the characters "`LIRWX'". If you omit the attribute list, you may
- omit the parentheses around it as well.
-
-`ORIGIN'
- is the start address of the region in physical memory. It is an
- expression that must evaluate to a constant before memory
- allocation is performed. The keyword `ORIGIN' may be abbreviated
- to `org' or `o' (but not, for example, `ORG').
-
-`LEN'
- is the size in bytes of the region (an expression). The keyword
- `LENGTH' may be abbreviated to `len' or `l'.
-
- For example, to specify that memory has two regions available for
-allocation--one starting at 0 for 256 kilobytes, and the other starting
-at `0x40000000' for four megabytes:
-
- MEMORY
- {
- rom : ORIGIN = 0, LENGTH = 256K
- ram : org = 0x40000000, l = 4M
- }
-
- Once you have defined a region of memory named MEM, you can direct
-specific output sections there by using a command ending in `>MEM'
-within the `SECTIONS' command (*note Section Options::.). If the
-combined output sections directed to a region are too big for the
-region, the linker will issue an error message.
-
-
-File: ld.info, Node: SECTIONS, Next: Entry Point, Prev: MEMORY, Up: Commands
-
-Specifying Output Sections
-==========================
-
- The `SECTIONS' command controls exactly where input sections are
-placed into output sections, their order in the output file, and to
-which output sections they are allocated.
-
- You may use at most one `SECTIONS' command in a script file, but you
-can have as many statements within it as you wish. Statements within
-the `SECTIONS' command can do one of three things:
-
- * define the entry point;
-
- * assign a value to a symbol;
-
- * describe the placement of a named output section, and which input
- sections go into it.
-
- You can also use the first two operations--defining the entry point
-and defining symbols--outside the `SECTIONS' command: *note Entry
-Point::., and *note Assignment::.. They are permitted here as well for
-your convenience in reading the script, so that symbols and the entry
-point can be defined at meaningful points in your output-file layout.
-
- If you do not use a `SECTIONS' command, the linker places each input
-section into an identically named output section in the order that the
-sections are first encountered in the input files. If all input
-sections are present in the first file, for example, the order of
-sections in the output file will match the order in the first input
-file.
-
-* Menu:
-
-* Section Definition:: Section Definitions
-* Section Placement:: Section Placement
-* Section Data Expressions:: Section Data Expressions
-* Section Options:: Optional Section Attributes
-
diff --git a/gnu/usr.bin/binutils/ld/ld.info-2 b/gnu/usr.bin/binutils/ld/ld.info-2
deleted file mode 100644
index 2900aeff162..00000000000
--- a/gnu/usr.bin/binutils/ld/ld.info-2
+++ /dev/null
@@ -1,924 +0,0 @@
-This is Info file ld.info, produced by Makeinfo-1.55 from the input
-file ./ld.texinfo.
-
-START-INFO-DIR-ENTRY
-* Ld: (ld). The GNU linker.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU linker LD.
-
- Copyright (C) 1991, 92, 93, 94, 1995 Free Software Foundation, Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided also
-that the entire resulting derived work is distributed under the terms
-of a permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: ld.info, Node: Section Definition, Next: Section Placement, Up: SECTIONS
-
-Section Definitions
--------------------
-
- The most frequently used statement in the `SECTIONS' command is the
-"section definition", which specifies the properties of an output
-section: its location, alignment, contents, fill pattern, and target
-memory region. Most of these specifications are optional; the simplest
-form of a section definition is
- SECTIONS { ...
- SECNAME : {
- CONTENTS
- }
- ... }
-
-SECNAME is the name of the output section, and CONTENTS a specification
-of what goes there--for example, a list of input files or sections of
-input files (*note Section Placement::.). As you might assume, the
-whitespace shown is optional. You do need the colon `:' and the braces
-`{}', however.
-
- SECNAME must meet the constraints of your output format. In formats
-which only support a limited number of sections, such as `a.out', the
-name must be one of the names supported by the format (`a.out', for
-example, allows only `.text', `.data' or `.bss'). If the output format
-supports any number of sections, but with numbers and not names (as is
-the case for Oasys), the name should be supplied as a quoted numeric
-string. A section name may consist of any sequence of characters, but
-any name which does not conform to the standard `ld' symbol name syntax
-must be quoted. *Note Symbol Names: Symbols.
-
- The linker will not create output sections which do not have any
-contents. This is for convenience when referring to input sections that
-may or may not exist. For example,
- .foo { *(.foo }
- will only create a `.foo' section in the output file if there is a
-`.foo' section in at least one input file.
-
-
-File: ld.info, Node: Section Placement, Next: Section Data Expressions, Prev: Section Definition, Up: SECTIONS
-
-Section Placement
------------------
-
- In a section definition, you can specify the contents of an output
-section by listing particular input files, by listing particular
-input-file sections, or by a combination of the two. You can also place
-arbitrary data in the section, and define symbols relative to the
-beginning of the section.
-
- The CONTENTS of a section definition may include any of the
-following kinds of statement. You can include as many of these as you
-like in a single section definition, separated from one another by
-whitespace.
-
-`FILENAME'
- You may simply name a particular input file to be placed in the
- current output section; *all* sections from that file are placed
- in the current section definition. If the file name has already
- been mentioned in another section definition, with an explicit
- section name list, then only those sections which have not yet
- been allocated are used.
-
- To specify a list of particular files by name:
- .data : { afile.o bfile.o cfile.o }
-
- The example also illustrates that multiple statements can be
- included in the contents of a section definition, since each file
- name is a separate statement.
-
-`FILENAME( SECTION )'
-`FILENAME( SECTION, SECTION, ... )'
-`FILENAME( SECTION SECTION ... )'
- You can name one or more sections from your input files, for
- insertion in the current output section. If you wish to specify a
- list of input-file sections inside the parentheses, you may
- separate the section names by either commas or whitespace.
-
-`* (SECTION)'
-`* (SECTION, SECTION, ...)'
-`* (SECTION SECTION ...)'
- Instead of explicitly naming particular input files in a link
- control script, you can refer to *all* files from the `ld' command
- line: use `*' instead of a particular file name before the
- parenthesized input-file section list.
-
- If you have already explicitly included some files by name, `*'
- refers to all *remaining* files--those whose places in the output
- file have not yet been defined.
-
- For example, to copy sections `1' through `4' from an Oasys file
- into the `.text' section of an `a.out' file, and sections `13' and
- `14' into the `.data' section:
- SECTIONS {
- .text :{
- *("1" "2" "3" "4")
- }
-
- .data :{
- *("13" "14")
- }
- }
-
- `[ SECTION ... ]' used to be accepted as an alternate way to
- specify named sections from all unallocated input files. Because
- some operating systems (VMS) allow brackets in file names, that
- notation is no longer supported.
-
-`FILENAME`( COMMON )''
-`*( COMMON )'
- Specify where in your output file to place uninitialized data with
- this notation. `*(COMMON)' by itself refers to all uninitialized
- data from all input files (so far as it is not yet allocated);
- FILENAME`(COMMON)' refers to uninitialized data from a particular
- file. Both are special cases of the general mechanisms for
- specifying where to place input-file sections: `ld' permits you to
- refer to uninitialized data as if it were in an input-file section
- named `COMMON', regardless of the input file's format.
-
- For example, the following command script arranges the output file
-into three consecutive sections, named `.text', `.data', and `.bss',
-taking the input for each from the correspondingly named sections of
-all the input files:
-
- SECTIONS {
- .text : { *(.text) }
- .data : { *(.data) }
- .bss : { *(.bss) *(COMMON) }
- }
-
- The following example reads all of the sections from file `all.o'
-and places them at the start of output section `outputa' which starts
-at location `0x10000'. All of section `.input1' from file `foo.o'
-follows immediately, in the same output section. All of section
-`.input2' from `foo.o' goes into output section `outputb', followed by
-section `.input1' from `foo1.o'. All of the remaining `.input1' and
-`.input2' sections from any files are written to output section
-`outputc'.
-
- SECTIONS {
- outputa 0x10000 :
- {
- all.o
- foo.o (.input1)
- }
- outputb :
- {
- foo.o (.input2)
- foo1.o (.input1)
- }
- outputc :
- {
- *(.input1)
- *(.input2)
- }
- }
-
-
-File: ld.info, Node: Section Data Expressions, Next: Section Options, Prev: Section Placement, Up: SECTIONS
-
-Section Data Expressions
-------------------------
-
- The foregoing statements arrange, in your output file, data
-originating from your input files. You can also place data directly in
-an output section from the link command script. Most of these
-additional statements involve expressions; *note Expressions::..
-Although these statements are shown separately here for ease of
-presentation, no such segregation is needed within a section definition
-in the `SECTIONS' command; you can intermix them freely with any of the
-statements we've just described.
-
-`CREATE_OBJECT_SYMBOLS'
- Create a symbol for each input file in the current section, set to
- the address of the first byte of data written from that input
- file. For instance, with `a.out' files it is conventional to have
- a symbol for each input file. You can accomplish this by defining
- the output `.text' section as follows:
- SECTIONS {
- .text 0x2020 :
- {
- CREATE_OBJECT_SYMBOLS
- *(.text)
- _etext = ALIGN(0x2000);
- }
- ...
- }
-
- If `sample.ld' is a file containing this script, and `a.o', `b.o',
- `c.o', and `d.o' are four input files with contents like the
- following--
- /* a.c */
-
- afunction() { }
- int adata=1;
- int abss;
-
- `ld -M -T sample.ld a.o b.o c.o d.o' would create a map like this,
- containing symbols matching the object file names:
- 00000000 A __DYNAMIC
- 00004020 B _abss
- 00004000 D _adata
- 00002020 T _afunction
- 00004024 B _bbss
- 00004008 D _bdata
- 00002038 T _bfunction
- 00004028 B _cbss
- 00004010 D _cdata
- 00002050 T _cfunction
- 0000402c B _dbss
- 00004018 D _ddata
- 00002068 T _dfunction
- 00004020 D _edata
- 00004030 B _end
- 00004000 T _etext
- 00002020 t a.o
- 00002038 t b.o
- 00002050 t c.o
- 00002068 t d.o
-
-`SYMBOL = EXPRESSION ;'
-`SYMBOL F= EXPRESSION ;'
- SYMBOL is any symbol name (*note Symbols::.). "F=" refers to any
- of the operators `&= += -= *= /=' which combine arithmetic and
- assignment.
-
- When you assign a value to a symbol within a particular section
- definition, the value is relative to the beginning of the section
- (*note Assignment::.). If you write
-
- SECTIONS {
- abs = 14 ;
- ...
- .data : { ... rel = 14 ; ... }
- abs2 = 14 + ADDR(.data);
- ...
- }
-
- `abs' and `rel' do not have the same value; `rel' has the same
- value as `abs2'.
-
-`BYTE(EXPRESSION)'
-`SHORT(EXPRESSION)'
-`LONG(EXPRESSION)'
-`QUAD(EXPRESSION)'
- By including one of these four statements in a section definition,
- you can explicitly place one, two, four, or eight bytes
- (respectively) at the current address of that section. `QUAD' is
- only supported when using a 64 bit host or target.
-
- Multiple-byte quantities are represented in whatever byte order is
- appropriate for the output file format (*note BFD::.).
-
-`FILL(EXPRESSION)'
- Specify the "fill pattern" for the current section. Any otherwise
- unspecified regions of memory within the section (for example,
- regions you skip over by assigning a new value to the location
- counter `.') are filled with the two least significant bytes from
- the EXPRESSION argument. A `FILL' statement covers memory
- locations *after* the point it occurs in the section definition; by
- including more than one `FILL' statement, you can have different
- fill patterns in different parts of an output section.
-
-
-File: ld.info, Node: Section Options, Prev: Section Data Expressions, Up: SECTIONS
-
-Optional Section Attributes
----------------------------
-
- Here is the full syntax of a section definition, including all the
-optional portions:
-
- SECTIONS {
- ...
- SECNAME START BLOCK(ALIGN) (NOLOAD) : AT ( LDADR )
- { CONTENTS } >REGION =FILL
- ...
- }
-
- SECNAME and CONTENTS are required. *Note Section Definition::, and
-*note Section Placement::. for details on CONTENTS. The remaining
-elements--START, `BLOCK(ALIGN)', `(NOLOAD)', `AT ( LDADR )', `>REGION',
-and `=FILL'--are all optional.
-
-`START'
- You can force the output section to be loaded at a specified
- address by specifying START immediately following the section name.
- sTART can be represented as any expression. The following example
- generates section OUTPUT at location `0x40000000':
-
- SECTIONS {
- ...
- output 0x40000000: {
- ...
- }
- ...
- }
-
-`BLOCK(ALIGN)'
- You can include `BLOCK()' specification to advance the location
- counter `.' prior to the beginning of the section, so that the
- section will begin at the specified alignment. ALIGN is an
- expression.
-
-`(NOLOAD)'
- Use `(NOLOAD)' to prevent a section from being loaded into memory
- each time it is accessed. For example, in the script sample
- below, the `ROM' segment is addressed at memory location `0' and
- does not need to be loaded into each object file:
-
- SECTIONS {
- ROM 0 (NOLOAD) : { ... }
- ...
- }
-
-`AT ( LDADR )'
- The expression LDADR that follows the `AT' keyword specifies the
- load address of the section. The default (if you do not use the
- `AT' keyword) is to make the load address the same as the
- relocation address. This feature is designed to make it easy to
- build a ROM image. For example, this `SECTIONS' definition
- creates two output sections: one called `.text', which starts at
- `0x1000', and one called `.mdata', which is loaded at the end of
- the `.text' section even though its relocation address is
- `0x2000'. The symbol `_data' is defined with the value `0x2000':
-
- SECTIONS
- {
- .text 0x1000 : { *(.text) _etext = . ; }
- .mdata 0x2000 :
- AT ( ADDR(.text) + SIZEOF ( .text ) )
- { _data = . ; *(.data); _edata = . ; }
- .bss 0x3000 :
- { _bstart = . ; *(.bss) *(COMMON) ; _bend = . ;}
- }
-
- The run-time initialization code (for C programs, usually `crt0')
- for use with a ROM generated this way has to include something like
- the following, to copy the initialized data from the ROM image to
- its runtime address:
-
- char *src = _etext;
- char *dst = _data;
-
- /* ROM has data at end of text; copy it. */
- while (dst < _edata) {
- *dst++ = *src++;
- }
-
- /* Zero bss */
- for (dst = _bstart; dst< _bend; dst++)
- *dst = 0;
-
-`>REGION'
- Assign this section to a previously defined region of memory.
- *Note MEMORY::.
-
-`=FILL'
- Including `=FILL' in a section definition specifies the initial
- fill value for that section. You may use any expression to
- specify FILL. Any unallocated holes in the current output section
- when written to the output file will be filled with the two least
- significant bytes of the value, repeated as necessary. You can
- also change the fill value with a `FILL' statement in the CONTENTS
- of a section definition.
-
-
-File: ld.info, Node: Entry Point, Next: Option Commands, Prev: SECTIONS, Up: Commands
-
-The Entry Point
-===============
-
- The linker command language includes a command specifically for
-defining the first executable instruction in an output file (its "entry
-point"). Its argument is a symbol name:
- ENTRY(SYMBOL)
-
- Like symbol assignments, the `ENTRY' command may be placed either as
-an independent command in the command file, or among the section
-definitions within the `SECTIONS' command--whatever makes the most
-sense for your layout.
-
- `ENTRY' is only one of several ways of choosing the entry point.
-You may indicate it in any of the following ways (shown in descending
-order of priority: methods higher in the list override methods lower
-down).
- * the `-e' ENTRY command-line option;
-
- * the `ENTRY(SYMBOL)' command in a linker control script;
-
- * the value of the symbol `start', if present;
-
- * the address of the first byte of the `.text' section, if present;
-
- * The address `0'.
-
- For example, you can use these rules to generate an entry point with
-an assignment statement: if no symbol `start' is defined within your
-input files, you can simply define it, assigning it an appropriate
-value--
-
- start = 0x2020;
-
-The example shows an absolute address, but you can use any expression.
-For example, if your input object files use some other symbol-name
-convention for the entry point, you can just assign the value of
-whatever symbol contains the start address to `start':
-
- start = other_symbol ;
-
-
-File: ld.info, Node: Option Commands, Prev: Entry Point, Up: Commands
-
-Option Commands
-===============
-
- The command language includes a number of other commands that you can
-use for specialized purposes. They are similar in purpose to
-command-line options.
-
-`CONSTRUCTORS'
- This command ties up C++ style constructor and destructor records.
- The details of the constructor representation vary from one
- object format to another, but usually lists of constructors and
- destructors appear as special sections. The `CONSTRUCTORS'
- command specifies where the linker is to place the data from these
- sections, relative to the rest of the linked output. Constructor
- data is marked by the symbol `__CTOR_LIST__' at the start, and
- `__CTOR_LIST_END' at the end; destructor data is bracketed
- similarly, between `__DTOR_LIST__' and `__DTOR_LIST_END'. (The
- compiler must arrange to actually run this code; GNU C++ calls
- constructors from a subroutine `__main', which it inserts
- automatically into the startup code for `main', and destructors
- from `_exit'.)
-
-`FLOAT'
-`NOFLOAT'
- These keywords were used in some older linkers to request a
- particular math subroutine library. `ld' doesn't use the
- keywords, assuming instead that any necessary subroutines are in
- libraries specified using the general mechanisms for linking to
- archives; but to permit the use of scripts that were written for
- the older linkers, the keywords `FLOAT' and `NOFLOAT' are accepted
- and ignored.
-
-`FORCE_COMMON_ALLOCATION'
- This command has the same effect as the `-d' command-line option:
- to make `ld' assign space to common symbols even if a relocatable
- output file is specified (`-r').
-
-`INPUT ( FILE, FILE, ... )'
-`INPUT ( FILE FILE ... )'
- Use this command to include binary input files in the link, without
- including them in a particular section definition. Specify the
- full name for each FILE, including `.a' if required.
-
- `ld' searches for each FILE through the archive-library search
- path, just as for files you specify on the command line. See the
- description of `-L' in *Note Command Line Options: Options.
-
- If you use `-lFILE', `ld' will transform the name to `libFILE.a'
- as with the command line argument `-l'.
-
-`GROUP ( FILE, FILE, ... )'
-`GROUP ( FILE FILE ... )'
- This command is like `INPUT', except that the named files should
- all be archives, and they are searched repeatedly until no new
- undefined references are created. See the description of `-(' in
- *Note Command Line Options: Options.
-
-`OUTPUT ( FILENAME )'
- Use this command to name the link output file FILENAME. The
- effect of `OUTPUT(FILENAME)' is identical to the effect of
- `-o FILENAME', which overrides it. You can use this command to
- supply a default output-file name other than `a.out'.
-
-`OUTPUT_ARCH ( BFDNAME )'
- Specify a particular output machine architecture, with one of the
- names used by the BFD back-end routines (*note BFD::.). This
- command is often unnecessary; the architecture is most often set
- implicitly by either the system BFD configuration or as a side
- effect of the `OUTPUT_FORMAT' command.
-
-`OUTPUT_FORMAT ( BFDNAME )'
- When `ld' is configured to support multiple object code formats,
- you can use this command to specify a particular output format.
- bFDNAME is one of the names used by the BFD back-end routines
- (*note BFD::.). The effect is identical to the effect of the
- `-oformat' command-line option. This selection affects only the
- output file; the related command `TARGET' affects primarily input
- files.
-
-`SEARCH_DIR ( PATH )'
- Add PATH to the list of paths where `ld' looks for archive
- libraries. `SEARCH_DIR(PATH)' has the same effect as `-LPATH' on
- the command line.
-
-`STARTUP ( FILENAME )'
- Ensure that FILENAME is the first input file used in the link
- process.
-
-`TARGET ( FORMAT )'
- When `ld' is configured to support multiple object code formats,
- you can use this command to change the input-file object code
- format (like the command-line option `-b' or its synonym
- `-format'). The argument FORMAT is one of the strings used by BFD
- to name binary formats. If `TARGET' is specified but
- `OUTPUT_FORMAT' is not, the last `TARGET' argument is also used as
- the default format for the `ld' output file. *Note BFD::.
-
- If you don't use the `TARGET' command, `ld' uses the value of the
- environment variable `GNUTARGET', if available, to select the
- output file format. If that variable is also absent, `ld' uses
- the default format configured for your machine in the BFD
- libraries.
-
-
-File: ld.info, Node: Machine Dependent, Next: BFD, Prev: Commands, Up: Top
-
-Machine Dependent Features
-**************************
-
- `ld' has additional features on some platforms; the following
-sections describe them. Machines where `ld' has no additional
-functionality are not listed.
-
-* Menu:
-
-* H8/300:: `ld' and the H8/300
-* i960:: `ld' and the Intel 960 family
-
-
-File: ld.info, Node: H8/300, Next: i960, Up: Machine Dependent
-
-`ld' and the H8/300
-===================
-
- For the H8/300, `ld' can perform these global optimizations when you
-specify the `-relax' command-line option.
-
-*relaxing address modes*
- `ld' finds all `jsr' and `jmp' instructions whose targets are
- within eight bits, and turns them into eight-bit program-counter
- relative `bsr' and `bra' instructions, respectively.
-
-*synthesizing instructions*
- `ld' finds all `mov.b' instructions which use the sixteen-bit
- absolute address form, but refer to the top page of memory, and
- changes them to use the eight-bit address form. (That is: the
- linker turns `mov.b `@'AA:16' into `mov.b `@'AA:8' whenever the
- address AA is in the top page of memory).
-
-
-File: ld.info, Node: i960, Prev: H8/300, Up: Machine Dependent
-
-`ld' and the Intel 960 family
-=============================
-
- You can use the `-AARCHITECTURE' command line option to specify one
-of the two-letter names identifying members of the 960 family; the
-option specifies the desired output target, and warns of any
-incompatible instructions in the input files. It also modifies the
-linker's search strategy for archive libraries, to support the use of
-libraries specific to each particular architecture, by including in the
-search loop names suffixed with the string identifying the architecture.
-
- For example, if your `ld' command line included `-ACA' as well as
-`-ltry', the linker would look (in its built-in search paths, and in
-any paths you specify with `-L') for a library with the names
-
- try
- libtry.a
- tryca
- libtryca.a
-
-The first two possibilities would be considered in any event; the last
-two are due to the use of `-ACA'.
-
- You can meaningfully use `-A' more than once on a command line, since
-the 960 architecture family allows combination of target architectures;
-each use will add another pair of name variants to search for when `-l'
-specifies a library.
-
- `ld' supports the `-relax' option for the i960 family. If you
-specify `-relax', `ld' finds all `balx' and `calx' instructions whose
-targets are within 24 bits, and turns them into 24-bit program-counter
-relative `bal' and `cal' instructions, respectively. `ld' also turns
-`cal' instructions into `bal' instructions when it determines that the
-target subroutine is a leaf routine (that is, the target subroutine does
-not itself call any subroutines).
-
-
-File: ld.info, Node: BFD, Next: MRI, Prev: Machine Dependent, Up: Top
-
-BFD
-***
-
- The linker accesses object and archive files using the BFD libraries.
-These libraries allow the linker to use the same routines to operate on
-object files whatever the object file format. A different object file
-format can be supported simply by creating a new BFD back end and adding
-it to the library. To conserve runtime memory, however, the linker and
-associated tools are usually configured to support only a subset of the
-object file formats available. You can use `objdump -i' (*note
-objdump: (binutils.info)objdump.) to list all the formats available for
-your configuration.
-
- As with most implementations, BFD is a compromise between several
-conflicting requirements. The major factor influencing BFD design was
-efficiency: any time used converting between formats is time which
-would not have been spent had BFD not been involved. This is partly
-offset by abstraction payback; since BFD simplifies applications and
-back ends, more time and care may be spent optimizing algorithms for a
-greater speed.
-
- One minor artifact of the BFD solution which you should bear in mind
-is the potential for information loss. There are two places where
-useful information can be lost using the BFD mechanism: during
-conversion and during output. *Note BFD information loss::.
-
-* Menu:
-
-* BFD outline:: How it works: an outline of BFD
-
-
-File: ld.info, Node: BFD outline, Up: BFD
-
-How it works: an outline of BFD
-===============================
-
- When an object file is opened, BFD subroutines automatically
-determine the format of the input object file. They then build a
-descriptor in memory with pointers to routines that will be used to
-access elements of the object file's data structures.
-
- As different information from the the object files is required, BFD
-reads from different sections of the file and processes them. For
-example, a very common operation for the linker is processing symbol
-tables. Each BFD back end provides a routine for converting between
-the object file's representation of symbols and an internal canonical
-format. When the linker asks for the symbol table of an object file, it
-calls through a memory pointer to the routine from the relevant BFD
-back end which reads and converts the table into a canonical form. The
-linker then operates upon the canonical form. When the link is finished
-and the linker writes the output file's symbol table, another BFD back
-end routine is called to take the newly created symbol table and
-convert it into the chosen output format.
-
-* Menu:
-
-* BFD information loss:: Information Loss
-* Canonical format:: The BFD canonical object-file format
-
-
-File: ld.info, Node: BFD information loss, Next: Canonical format, Up: BFD outline
-
-Information Loss
-----------------
-
- *Information can be lost during output.* The output formats
-supported by BFD do not provide identical facilities, and information
-which can be described in one form has nowhere to go in another format.
-One example of this is alignment information in `b.out'. There is
-nowhere in an `a.out' format file to store alignment information on the
-contained data, so when a file is linked from `b.out' and an `a.out'
-image is produced, alignment information will not propagate to the
-output file. (The linker will still use the alignment information
-internally, so the link is performed correctly).
-
- Another example is COFF section names. COFF files may contain an
-unlimited number of sections, each one with a textual section name. If
-the target of the link is a format which does not have many sections
-(e.g., `a.out') or has sections without names (e.g., the Oasys format),
-the link cannot be done simply. You can circumvent this problem by
-describing the desired input-to-output section mapping with the linker
-command language.
-
- *Information can be lost during canonicalization.* The BFD internal
-canonical form of the external formats is not exhaustive; there are
-structures in input formats for which there is no direct representation
-internally. This means that the BFD back ends cannot maintain all
-possible data richness through the transformation between external to
-internal and back to external formats.
-
- This limitation is only a problem when an application reads one
-format and writes another. Each BFD back end is responsible for
-maintaining as much data as possible, and the internal BFD canonical
-form has structures which are opaque to the BFD core, and exported only
-to the back ends. When a file is read in one format, the canonical form
-is generated for BFD and the application. At the same time, the back
-end saves away any information which may otherwise be lost. If the data
-is then written back in the same format, the back end routine will be
-able to use the canonical form provided by the BFD core as well as the
-information it prepared earlier. Since there is a great deal of
-commonality between back ends, there is no information lost when
-linking or copying big endian COFF to little endian COFF, or `a.out' to
-`b.out'. When a mixture of formats is linked, the information is only
-lost from the files whose format differs from the destination.
-
-
-File: ld.info, Node: Canonical format, Prev: BFD information loss, Up: BFD outline
-
-The BFD canonical object-file format
-------------------------------------
-
- The greatest potential for loss of information occurs when there is
-the least overlap between the information provided by the source
-format, that stored by the canonical format, and that needed by the
-destination format. A brief description of the canonical form may help
-you understand which kinds of data you can count on preserving across
-conversions.
-
-*files*
- Information stored on a per-file basis includes target machine
- architecture, particular implementation format type, a demand
- pageable bit, and a write protected bit. Information like Unix
- magic numbers is not stored here--only the magic numbers' meaning,
- so a `ZMAGIC' file would have both the demand pageable bit and the
- write protected text bit set. The byte order of the target is
- stored on a per-file basis, so that big- and little-endian object
- files may be used with one another.
-
-*sections*
- Each section in the input file contains the name of the section,
- the section's original address in the object file, size and
- alignment information, various flags, and pointers into other BFD
- data structures.
-
-*symbols*
- Each symbol contains a pointer to the information for the object
- file which originally defined it, its name, its value, and various
- flag bits. When a BFD back end reads in a symbol table, it
- relocates all symbols to make them relative to the base of the
- section where they were defined. Doing this ensures that each
- symbol points to its containing section. Each symbol also has a
- varying amount of hidden private data for the BFD back end. Since
- the symbol points to the original file, the private data format
- for that symbol is accessible. `ld' can operate on a collection
- of symbols of wildly different formats without problems.
-
- Normal global and simple local symbols are maintained on output,
- so an output file (no matter its format) will retain symbols
- pointing to functions and to global, static, and common variables.
- Some symbol information is not worth retaining; in `a.out', type
- information is stored in the symbol table as long symbol names.
- This information would be useless to most COFF debuggers; the
- linker has command line switches to allow users to throw it away.
-
- There is one word of type information within the symbol, so if the
- format supports symbol type information within symbols (for
- example, COFF, IEEE, Oasys) and the type is simple enough to fit
- within one word (nearly everything but aggregates), the
- information will be preserved.
-
-*relocation level*
- Each canonical BFD relocation record contains a pointer to the
- symbol to relocate to, the offset of the data to relocate, the
- section the data is in, and a pointer to a relocation type
- descriptor. Relocation is performed by passing messages through
- the relocation type descriptor and the symbol pointer. Therefore,
- relocations can be performed on output data using a relocation
- method that is only available in one of the input formats. For
- instance, Oasys provides a byte relocation format. A relocation
- record requesting this relocation type would point indirectly to a
- routine to perform this, so the relocation may be performed on a
- byte being written to a 68k COFF file, even though 68k COFF has no
- such relocation type.
-
-*line numbers*
- Object formats can contain, for debugging purposes, some form of
- mapping between symbols, source line numbers, and addresses in the
- output file. These addresses have to be relocated along with the
- symbol information. Each symbol with an associated list of line
- number records points to the first record of the list. The head
- of a line number list consists of a pointer to the symbol, which
- allows finding out the address of the function whose line number
- is being described. The rest of the list is made up of pairs:
- offsets into the section and line numbers. Any format which can
- simply derive this information can pass it successfully between
- formats (COFF, IEEE and Oasys).
-
-
-File: ld.info, Node: MRI, Next: Index, Prev: BFD, Up: Top
-
-MRI Compatible Script Files
-***************************
-
- To aid users making the transition to GNU `ld' from the MRI linker,
-`ld' can use MRI compatible linker scripts as an alternative to the
-more general-purpose linker scripting language described in *Note
-Command Language: Commands. MRI compatible linker scripts have a much
-simpler command set than the scripting language otherwise used with
-`ld'. GNU `ld' supports the most commonly used MRI linker commands;
-these commands are described here.
-
- In general, MRI scripts aren't of much use with the `a.out' object
-file format, since it only has three sections and MRI scripts lack some
-features to make use of them.
-
- You can specify a file containing an MRI-compatible script using the
-`-c' command-line option.
-
- Each command in an MRI-compatible script occupies its own line; each
-command line starts with the keyword that identifies the command (though
-blank lines are also allowed for punctuation). If a line of an
-MRI-compatible script begins with an unrecognized keyword, `ld' issues
-a warning message, but continues processing the script.
-
- Lines beginning with `*' are comments.
-
- You can write these commands using all upper-case letters, or all
-lower case; for example, `chip' is the same as `CHIP'. The following
-list shows only the upper-case form of each command.
-
-`ABSOLUTE SECNAME'
-`ABSOLUTE SECNAME, SECNAME, ... SECNAME'
- Normally, `ld' includes in the output file all sections from all
- the input files. However, in an MRI-compatible script, you can
- use the `ABSOLUTE' command to restrict the sections that will be
- present in your output program. If the `ABSOLUTE' command is used
- at all in a script, then only the sections named explicitly in
- `ABSOLUTE' commands will appear in the linker output. You can
- still use other input sections (whatever you select on the command
- line, or using `LOAD') to resolve addresses in the output file.
-
-`ALIAS OUT-SECNAME, IN-SECNAME'
- Use this command to place the data from input section IN-SECNAME
- in a section called OUT-SECNAME in the linker output file.
-
- IN-SECNAME may be an integer.
-
-`ALIGN SECNAME = EXPRESSION'
- Align the section called SECNAME to EXPRESSION. The EXPRESSION
- should be a power of two.
-
-`BASE EXPRESSION'
- Use the value of EXPRESSION as the lowest address (other than
- absolute addresses) in the output file.
-
-`CHIP EXPRESSION'
-`CHIP EXPRESSION, EXPRESSION'
- This command does nothing; it is accepted only for compatibility.
-
-`END'
- This command does nothing whatever; it's only accepted for
- compatibility.
-
-`FORMAT OUTPUT-FORMAT'
- Similar to the `OUTPUT_FORMAT' command in the more general linker
- language, but restricted to one of these output formats:
-
- 1. S-records, if OUTPUT-FORMAT is `S'
-
- 2. IEEE, if OUTPUT-FORMAT is `IEEE'
-
- 3. COFF (the `coff-m68k' variant in BFD), if OUTPUT-FORMAT is
- `COFF'
-
-`LIST ANYTHING...'
- Print (to the standard output file) a link map, as produced by the
- `ld' command-line option `-M'.
-
- The keyword `LIST' may be followed by anything on the same line,
- with no change in its effect.
-
-`LOAD FILENAME'
-`LOAD FILENAME, FILENAME, ... FILENAME'
- Include one or more object file FILENAME in the link; this has the
- same effect as specifying FILENAME directly on the `ld' command
- line.
-
-`NAME OUTPUT-NAME'
- OUTPUT-NAME is the name for the program produced by `ld'; the
- MRI-compatible command `NAME' is equivalent to the command-line
- option `-o' or the general script language command `OUTPUT'.
-
-`ORDER SECNAME, SECNAME, ... SECNAME'
-`ORDER SECNAME SECNAME SECNAME'
- Normally, `ld' orders the sections in its output file in the order
- in which they first appear in the input files. In an
- MRI-compatible script, you can override this ordering with the
- `ORDER' command. The sections you list with `ORDER' will appear
- first in your output file, in the order specified.
-
-`PUBLIC NAME=EXPRESSION'
-`PUBLIC NAME,EXPRESSION'
-`PUBLIC NAME EXPRESSION'
- Supply a value (EXPRESSION) for external symbol NAME used in the
- linker input files.
-
-`SECT SECNAME, EXPRESSION'
-`SECT SECNAME=EXPRESSION'
-`SECT SECNAME EXPRESSION'
- You can use any of these three forms of the `SECT' command to
- specify the start address (EXPRESSION) for section SECNAME. If
- you have more than one `SECT' statement for the same SECNAME, only
- the *first* sets the start address.
-
diff --git a/gnu/usr.bin/binutils/ld/ld.info-3 b/gnu/usr.bin/binutils/ld/ld.info-3
deleted file mode 100644
index 2b364a6ec08..00000000000
--- a/gnu/usr.bin/binutils/ld/ld.info-3
+++ /dev/null
@@ -1,343 +0,0 @@
-This is Info file ld.info, produced by Makeinfo-1.55 from the input
-file ./ld.texinfo.
-
-START-INFO-DIR-ENTRY
-* Ld: (ld). The GNU linker.
-END-INFO-DIR-ENTRY
-
- This file documents the GNU linker LD.
-
- Copyright (C) 1991, 92, 93, 94, 1995 Free Software Foundation, Inc.
-
- Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
- Permission is granted to copy and distribute modified versions of
-this manual under the conditions for verbatim copying, provided also
-that the entire resulting derived work is distributed under the terms
-of a permission notice identical to this one.
-
- Permission is granted to copy and distribute translations of this
-manual into another language, under the above conditions for modified
-versions.
-
-
-File: ld.info, Node: Index, Prev: MRI, Up: Top
-
-Index
-*****
-
-* Menu:
-
-* ": Symbols.
-* *( COMMON ): Section Placement.
-* *(SECTION): Section Placement.
-* -(: Options.
-* -verbose: Options.
-* -whole-archive: Options.
-* -AARCH: Options.
-* -b FORMAT: Options.
-* -Bdynamic: Options.
-* -Bstatic: Options.
-* -Bsymbolic: Options.
-* -c MRI-CMDFILE: Options.
-* -d: Options.
-* -dc: Options.
-* -defsym SYMBOL=EXP: Options.
-* -dp: Options.
-* -dynamic-linker FILE: Options.
-* -e ENTRY: Options.
-* -embedded-relocs: Options.
-* -F: Options.
-* -format: Options.
-* -g: Options.
-* -G: Options.
-* -help: Options.
-* -i: Options.
-* -lARCHIVE: Options.
-* -LDIR: Options.
-* -M: Options.
-* -m EMULATION: Options.
-* -Map: Options.
-* -n: Options.
-* -N: Options.
-* -no-keep-memory: Options.
-* -noinhibit-exec: Options.
-* -o OUTPUT: Options.
-* -oformat: Options.
-* -r: Options.
-* -R FILE: Options.
-* -relax: Options.
-* -rpath: Options.
-* -rpath-link: Options.
-* -S: Options.
-* -s: Options.
-* -shared: Options.
-* -soname: Options.
-* -sort-common: Options.
-* -t: Options.
-* -T SCRIPT: Options.
-* -Tbss ORG: Options.
-* -Tdata ORG: Options.
-* -traditional-format: Options.
-* -Ttext ORG: Options.
-* -u SYMBOL: Options.
-* -Ur: Options.
-* -v: Options.
-* -V: Options.
-* -version: Options.
-* -warn-comon: Options.
-* -warn-constructors: Options.
-* -warn-once: Options.
-* -x: Options.
-* -X: Options.
-* -y SYMBOL: Options.
-* .: Location Counter.
-* 0x: Integers.
-* ;: Assignment.
-* =FILL: Section Options.
-* >REGION: Section Options.
-* -relax on i960: i960.
-* ABSOLUTE (MRI): MRI.
-* ALIAS (MRI): MRI.
-* ALIGN (MRI): MRI.
-* BASE (MRI): MRI.
-* CHIP (MRI): MRI.
-* END (MRI): MRI.
-* FORMAT (MRI): MRI.
-* LIST (MRI): MRI.
-* LOAD (MRI): MRI.
-* NAME (MRI): MRI.
-* ORDER (MRI): MRI.
-* PUBLIC (MRI): MRI.
-* SECT (MRI): MRI.
-* [SECTION...], not supported: Section Placement.
-* GNU linker: Overview.
-* FILENAME: Section Placement.
-* FILENAME(SECTION): Section Placement.
-* SYMBOL = EXPRESSION ;: Section Data Expressions.
-* SYMBOL F= EXPRESSION ;: Section Data Expressions.
-* absolute and relocatable symbols: Assignment.
-* ABSOLUTE(EXP): Arithmetic Functions.
-* ADDR(SECTION): Arithmetic Functions.
-* ALIGN(EXP): Arithmetic Functions.
-* aligning sections: Section Options.
-* allocating memory: MEMORY.
-* architectures: Options.
-* archive files, from cmd line: Options.
-* arithmetic: Expressions.
-* arithmetic operators: Operators.
-* assignment in scripts: Assignment.
-* assignment, in section defn: Section Data Expressions.
-* AT ( LDADR ): Section Options.
-* back end: BFD.
-* BFD canonical format: Canonical format.
-* BFD requirements: BFD.
-* binary input files: Option Commands.
-* binary input format: Options.
-* BLOCK(ALIGN): Section Options.
-* BYTE(EXPRESSION): Section Data Expressions.
-* C++ constructors, arranging in link: Option Commands.
-* combining symbols, warnings on: Options.
-* command files: Commands.
-* command line: Options.
-* commands, fundamental: Scripts.
-* comments: Scripts.
-* common allocation: Options.
-* common allocation: Option Commands.
-* commons in output: Section Placement.
-* compatibility, MRI: Options.
-* constructors: Options.
-* CONSTRUCTORS: Option Commands.
-* constructors, arranging in link: Option Commands.
-* contents of a section: Section Placement.
-* CREATE_OBJECT_SYMBOLS: Section Data Expressions.
-* current output location: Location Counter.
-* dbx: Options.
-* decimal integers: Integers.
-* default input format: Environment.
-* DEFINED(SYMBOL): Arithmetic Functions.
-* deleting local symbols: Options.
-* direct output: Section Data Expressions.
-* discontinuous memory: MEMORY.
-* dot: Location Counter.
-* dynamic linker, from command line: Options.
-* emulation: Options.
-* entry point, defaults: Entry Point.
-* entry point, from command line: Options.
-* ENTRY(SYMBOL): Entry Point.
-* expression evaluation order: Evaluation.
-* expression syntax: Expressions.
-* expression, absolute: Arithmetic Functions.
-* expressions in a section: Section Data Expressions.
-* filename symbols: Section Data Expressions.
-* files and sections, section defn: Section Placement.
-* files, including in output sections: Section Placement.
-* fill pattern, entire section: Section Options.
-* FILL(EXPRESSION): Section Data Expressions.
-* first input file: Option Commands.
-* first instruction: Entry Point.
-* FLOAT: Option Commands.
-* FORCE_COMMON_ALLOCATION: Option Commands.
-* format, output file: Option Commands.
-* functions in expression language: Arithmetic Functions.
-* fundamental script commands: Scripts.
-* GNUTARGET: Environment.
-* GNUTARGET: Option Commands.
-* GROUP ( FILES ): Option Commands.
-* grouping input files: Option Commands.
-* groups of archives: Options.
-* H8/300 support: H8/300.
-* header size: Arithmetic Functions.
-* help: Options.
-* hexadecimal integers: Integers.
-* holes: Location Counter.
-* holes, filling: Section Data Expressions.
-* i960 support: i960.
-* including an entire archive: Options.
-* incremental link: Options.
-* INPUT ( FILES ): Option Commands.
-* input file format: Option Commands.
-* input filename symbols: Section Data Expressions.
-* input files, displaying: Options.
-* input files, section defn: Section Placement.
-* input format: Options.
-* input format: Options.
-* input sections to output section: Section Placement.
-* integer notation: Integers.
-* integer suffixes: Integers.
-* internal object-file format: Canonical format.
-* K and M integer suffixes: Integers.
-* l =: MEMORY.
-* L, deleting symbols beginning: Options.
-* layout of output file: Scripts.
-* lazy evaluation: Evaluation.
-* len =: MEMORY.
-* LENGTH =: MEMORY.
-* link map: Options.
-* link map: Options.
-* link-time runtime library search path: Options.
-* load address, specifying: Section Options.
-* loading, preventing: Section Options.
-* local symbols, deleting: Options.
-* location counter: Location Counter.
-* LONG(EXPRESSION): Section Data Expressions.
-* M and K integer suffixes: Integers.
-* machine architecture, output: Option Commands.
-* machine dependencies: Machine Dependent.
-* MEMORY: MEMORY.
-* memory region attributes: MEMORY.
-* memory regions and sections: Section Options.
-* memory usage: Options.
-* MIPS embedded PIC code: Options.
-* MRI compatibility: MRI.
-* names: Symbols.
-* naming memory regions: MEMORY.
-* naming output sections: Section Definition.
-* naming the output file: Options.
-* naming the output file: Option Commands.
-* negative integers: Integers.
-* NEXT(EXP): Arithmetic Functions.
-* NMAGIC: Options.
-* NOFLOAT: Option Commands.
-* NOLOAD: Section Options.
-* Non constant expression: Assignment.
-* o =: MEMORY.
-* objdump -i: BFD.
-* object file management: BFD.
-* object files: Options.
-* object formats available: BFD.
-* object size: Options.
-* octal integers: Integers.
-* OMAGIC: Options.
-* opening object files: BFD outline.
-* Operators for arithmetic: Operators.
-* options: Options.
-* org =: MEMORY.
-* ORIGIN =: MEMORY.
-* OUTPUT ( FILENAME ): Option Commands.
-* output file after errors: Options.
-* output file layout: Scripts.
-* OUTPUT_ARCH ( BFDNAME ): Option Commands.
-* OUTPUT_FORMAT ( BFDNAME ): Option Commands.
-* partial link: Options.
-* path for libraries: Option Commands.
-* precedence in expressions: Operators.
-* prevent unnecessary loading: Section Options.
-* provide: Assignment.
-* QUAD(EXPRESSION): Section Data Expressions.
-* quoted symbol names: Symbols.
-* read-only text: Options.
-* read/write from cmd line: Options.
-* regions of memory: MEMORY.
-* relaxing addressing modes: Options.
-* relaxing on H8/300: H8/300.
-* relaxing on i960: i960.
-* relocatable and absolute symbols: Assignment.
-* relocatable output: Options.
-* requirements for BFD: BFD.
-* retaining specified symbols: Options.
-* rounding up location counter: Arithmetic Functions.
-* runtime library name: Options.
-* runtime library search path: Options.
-* scaled integers: Integers.
-* script files: Options.
-* search directory, from cmd line: Options.
-* search path, libraries: Option Commands.
-* SEARCH_DIR ( PATH ): Option Commands.
-* section address: Section Options.
-* section address: Arithmetic Functions.
-* section alignment: Section Options.
-* section definition: Section Definition.
-* section defn, full syntax: Section Options.
-* section fill pattern: Section Options.
-* section size: Arithmetic Functions.
-* section start: Section Options.
-* section, assigning to memory region: Section Options.
-* SECTIONS: SECTIONS.
-* segment origins, cmd line: Options.
-* semicolon: Assignment.
-* shared libraries: Options.
-* SHORT(EXPRESSION): Section Data Expressions.
-* SIZEOF(SECTION): Arithmetic Functions.
-* sizeof_headers: Arithmetic Functions.
-* SIZEOF_HEADERS: Arithmetic Functions.
-* specify load address: Section Options.
-* split: Options.
-* split: Options.
-* standard Unix system: Options.
-* start address, section: Section Options.
-* start of execution: Entry Point.
-* STARTUP ( FILENAME ): Option Commands.
-* strip all symbols: Options.
-* strip debugger symbols: Options.
-* stripping all but some symbols: Options.
-* suffixes for integers: Integers.
-* symbol defaults: Arithmetic Functions.
-* symbol definition, scripts: Assignment.
-* symbol names: Symbols.
-* symbol tracing: Options.
-* symbol-only input: Options.
-* symbols, from command line: Options.
-* symbols, relocatable and absolute: Assignment.
-* symbols, retaining selectively: Options.
-* synthesizing linker: Options.
-* synthesizing on H8/300: H8/300.
-* TARGET ( FORMAT ): Option Commands.
-* traditional format: Options.
-* unallocated address, next: Arithmetic Functions.
-* undefined symbol: Options.
-* undefined symbols, warnings on: Options.
-* uninitialized data: Section Placement.
-* unspecified memory: Section Data Expressions.
-* usage: Options.
-* variables, defining: Assignment.
-* verbose: Options.
-* version: Options.
-* version: Options.
-* warnings, on combining symbols: Options.
-* warnings, on undefined symbols: Options.
-* what is this?: Overview.
-
-
diff --git a/gnu/usr.bin/binutils/ld/ldgram.c b/gnu/usr.bin/binutils/ld/ldgram.c
deleted file mode 100644
index 612c02b27bd..00000000000
--- a/gnu/usr.bin/binutils/ld/ldgram.c
+++ /dev/null
@@ -1,2052 +0,0 @@
-
-/* A Bison parser, made from ./ldgram.y with Bison version GNU Bison version 1.24
- */
-
-#define YYBISON 1 /* Identify Bison output. */
-
-#define INT 258
-#define NAME 259
-#define LNAME 260
-#define PLUSEQ 261
-#define MINUSEQ 262
-#define MULTEQ 263
-#define DIVEQ 264
-#define LSHIFTEQ 265
-#define RSHIFTEQ 266
-#define ANDEQ 267
-#define OREQ 268
-#define OROR 269
-#define ANDAND 270
-#define EQ 271
-#define NE 272
-#define LE 273
-#define GE 274
-#define LSHIFT 275
-#define RSHIFT 276
-#define UNARY 277
-#define END 278
-#define ALIGN_K 279
-#define BLOCK 280
-#define QUAD 281
-#define LONG 282
-#define SHORT 283
-#define BYTE 284
-#define SECTIONS 285
-#define SIZEOF_HEADERS 286
-#define OUTPUT_FORMAT 287
-#define FORCE_COMMON_ALLOCATION 288
-#define OUTPUT_ARCH 289
-#define INCLUDE 290
-#define MEMORY 291
-#define DEFSYMEND 292
-#define NOLOAD 293
-#define DSECT 294
-#define COPY 295
-#define INFO 296
-#define OVERLAY 297
-#define DEFINED 298
-#define TARGET_K 299
-#define SEARCH_DIR 300
-#define MAP 301
-#define ENTRY 302
-#define SIZEOF 303
-#define NEXT 304
-#define ADDR 305
-#define STARTUP 306
-#define HLL 307
-#define SYSLIB 308
-#define FLOAT 309
-#define NOFLOAT 310
-#define ORIGIN 311
-#define FILL 312
-#define LENGTH 313
-#define CREATE_OBJECT_SYMBOLS 314
-#define INPUT 315
-#define GROUP 316
-#define OUTPUT 317
-#define CONSTRUCTORS 318
-#define ALIGNMOD 319
-#define AT 320
-#define PROVIDE 321
-#define CHIP 322
-#define LIST 323
-#define SECT 324
-#define ABSOLUTE 325
-#define LOAD 326
-#define NEWLINE 327
-#define ENDWORD 328
-#define ORDER 329
-#define NAMEWORD 330
-#define FORMAT 331
-#define PUBLIC 332
-#define BASE 333
-#define ALIAS 334
-#define TRUNCATE 335
-#define REL 336
-#define INPUT_SCRIPT 337
-#define INPUT_MRI_SCRIPT 338
-#define INPUT_DEFSYM 339
-#define CASE 340
-#define EXTERN 341
-#define START 342
-
-#line 21 "./ldgram.y"
-
-/*
-
- */
-
-#define DONTDECLARE_MALLOC
-
-#include "bfd.h"
-#include "sysdep.h"
-#include "bfdlink.h"
-#include "ld.h"
-#include "ldexp.h"
-#include "ldver.h"
-#include "ldlang.h"
-#include "ldemul.h"
-#include "ldfile.h"
-#include "ldmisc.h"
-#include "ldmain.h"
-#include "mri.h"
-#include "ldlex.h"
-
-#ifndef YYDEBUG
-#define YYDEBUG 1
-#endif
-
-static int typebits;
-
-lang_memory_region_type *region;
-
-
-char *current_file;
-boolean ldgram_want_filename = true;
-boolean had_script = false;
-boolean force_make_executable = false;
-
-boolean ldgram_in_script = false;
-boolean ldgram_had_equals = false;
-
-
-#define ERROR_NAME_MAX 20
-static char *error_names[ERROR_NAME_MAX];
-static int error_index;
-#define PUSH_ERROR(x) if (error_index < ERROR_NAME_MAX) error_names[error_index] = x; error_index++;
-#define POP_ERROR() error_index--;
-
-#line 66 "./ldgram.y"
-typedef union {
- bfd_vma integer;
- char *name;
- int token;
- union etree_union *etree;
-} YYSTYPE;
-
-#ifndef YYLTYPE
-typedef
- struct yyltype
- {
- int timestamp;
- int first_line;
- int first_column;
- int last_line;
- int last_column;
- char *text;
- }
- yyltype;
-
-#define YYLTYPE yyltype
-#endif
-
-#include <stdio.h>
-
-#ifndef __cplusplus
-#ifndef __STDC__
-#define const
-#endif
-#endif
-
-
-
-#define YYFINAL 394
-#define YYFLAG -32768
-#define YYNTBASE 111
-
-#define YYTRANSLATE(x) ((unsigned)(x) <= 342 ? yytranslate[x] : 176)
-
-static const char yytranslate[] = { 0,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 109, 2, 2, 2, 34, 21, 2, 37,
- 106, 32, 30, 104, 31, 2, 33, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 16, 105, 24,
- 10, 25, 15, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 107, 2, 108, 20, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 45, 19, 46, 110, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 1, 2, 3, 4, 5,
- 6, 7, 8, 9, 11, 12, 13, 14, 17, 18,
- 22, 23, 26, 27, 28, 29, 35, 36, 38, 39,
- 40, 41, 42, 43, 44, 47, 48, 49, 50, 51,
- 52, 53, 54, 55, 56, 57, 58, 59, 60, 61,
- 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
- 72, 73, 74, 75, 76, 77, 78, 79, 80, 81,
- 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
- 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
- 102, 103
-};
-
-#if YYDEBUG != 0
-static const short yyprhs[] = { 0,
- 0, 3, 6, 9, 11, 12, 17, 18, 21, 25,
- 26, 29, 34, 36, 38, 41, 43, 48, 53, 57,
- 60, 65, 69, 74, 79, 84, 89, 94, 97, 100,
- 103, 108, 113, 116, 119, 122, 125, 126, 132, 135,
- 136, 140, 143, 144, 146, 150, 152, 156, 157, 159,
- 163, 165, 169, 170, 173, 176, 177, 179, 181, 183,
- 185, 187, 189, 191, 193, 198, 203, 208, 213, 222,
- 227, 229, 234, 235, 241, 246, 247, 253, 255, 259,
- 262, 264, 268, 271, 276, 279, 282, 283, 288, 291,
- 293, 297, 299, 300, 305, 306, 312, 313, 319, 322,
- 324, 326, 328, 330, 335, 340, 343, 345, 346, 348,
- 350, 352, 354, 356, 359, 360, 362, 364, 366, 368,
- 370, 372, 374, 376, 378, 380, 384, 388, 395, 397,
- 398, 404, 407, 411, 412, 413, 421, 425, 429, 433,
- 434, 439, 444, 448, 452, 454, 459, 463, 464, 466,
- 468, 469, 472, 475, 479, 484, 487, 490, 493, 497,
- 501, 505, 509, 513, 517, 521, 525, 529, 533, 537,
- 541, 545, 549, 553, 557, 563, 567, 571, 576, 578,
- 580, 585, 590, 595, 600, 605, 607, 612, 613, 614,
- 615, 616, 617, 618, 633, 635, 637, 639, 641, 643,
- 647, 648, 652, 655, 658
-};
-
-static const short yyrhs[] = { 98,
- 125, 0, 99, 115, 0, 100, 113, 0, 4, 0,
- 0, 114, 4, 10, 164, 0, 0, 116, 117, 0,
- 117, 118, 88, 0, 0, 83, 164, 0, 83, 164,
- 104, 164, 0, 4, 0, 84, 0, 90, 120, 0,
- 89, 0, 93, 4, 10, 164, 0, 93, 4, 104,
- 164, 0, 93, 4, 164, 0, 92, 4, 0, 85,
- 4, 104, 164, 0, 85, 4, 164, 0, 85, 4,
- 10, 164, 0, 38, 4, 10, 164, 0, 38, 4,
- 104, 164, 0, 80, 4, 10, 164, 0, 80, 4,
- 104, 164, 0, 86, 122, 0, 87, 121, 0, 91,
- 4, 0, 95, 4, 104, 4, 0, 95, 4, 104,
- 3, 0, 94, 164, 0, 96, 3, 0, 101, 123,
- 0, 102, 124, 0, 0, 51, 112, 119, 117, 36,
- 0, 103, 4, 0, 0, 120, 104, 4, 0, 120,
- 4, 0, 0, 4, 0, 121, 104, 4, 0, 4,
- 0, 122, 104, 4, 0, 0, 4, 0, 123, 104,
- 4, 0, 4, 0, 124, 104, 4, 0, 0, 126,
- 127, 0, 127, 128, 0, 0, 149, 0, 132, 0,
- 156, 0, 157, 0, 159, 0, 161, 0, 134, 0,
- 105, 0, 60, 37, 4, 106, 0, 61, 37, 112,
- 106, 0, 78, 37, 112, 106, 0, 48, 37, 4,
- 106, 0, 48, 37, 4, 104, 4, 104, 4, 106,
- 0, 50, 37, 4, 106, 0, 49, 0, 76, 37,
- 131, 106, 0, 0, 77, 129, 37, 131, 106, 0,
- 62, 37, 112, 106, 0, 0, 51, 112, 130, 127,
- 36, 0, 4, 0, 131, 104, 4, 0, 131, 4,
- 0, 5, 0, 131, 104, 5, 0, 131, 5, 0,
- 44, 45, 133, 46, 0, 133, 166, 0, 133, 134,
- 0, 0, 63, 37, 4, 106, 0, 147, 146, 0,
- 4, 0, 135, 148, 4, 0, 4, 0, 0, 107,
- 137, 135, 108, 0, 0, 4, 138, 37, 135, 106,
- 0, 0, 32, 139, 37, 135, 106, 0, 147, 146,
- 0, 75, 0, 105, 0, 79, 0, 136, 0, 143,
- 37, 164, 106, 0, 73, 37, 164, 106, 0, 141,
- 140, 0, 140, 0, 0, 141, 0, 40, 0, 41,
- 0, 42, 0, 43, 0, 10, 162, 0, 0, 6,
- 0, 7, 0, 8, 0, 9, 0, 11, 0, 12,
- 0, 13, 0, 14, 0, 105, 0, 104, 0, 4,
- 10, 162, 0, 4, 145, 162, 0, 82, 37, 4,
- 10, 162, 106, 0, 104, 0, 0, 52, 45, 151,
- 150, 46, 0, 150, 151, 0, 150, 104, 151, 0,
- 0, 0, 4, 152, 155, 16, 153, 148, 154, 0,
- 72, 10, 162, 0, 74, 10, 162, 0, 37, 4,
- 106, 0, 0, 67, 37, 112, 106, 0, 68, 37,
- 158, 106, 0, 68, 37, 106, 0, 158, 148, 112,
- 0, 112, 0, 69, 37, 160, 106, 0, 160, 148,
- 112, 0, 0, 70, 0, 71, 0, 0, 163, 164,
- 0, 31, 164, 0, 37, 164, 106, 0, 65, 37,
- 164, 106, 0, 109, 164, 0, 30, 164, 0, 110,
- 164, 0, 164, 32, 164, 0, 164, 33, 164, 0,
- 164, 34, 164, 0, 164, 30, 164, 0, 164, 31,
- 164, 0, 164, 28, 164, 0, 164, 29, 164, 0,
- 164, 22, 164, 0, 164, 23, 164, 0, 164, 26,
- 164, 0, 164, 27, 164, 0, 164, 24, 164, 0,
- 164, 25, 164, 0, 164, 21, 164, 0, 164, 20,
- 164, 0, 164, 19, 164, 0, 164, 15, 164, 16,
- 164, 0, 164, 18, 164, 0, 164, 17, 164, 0,
- 59, 37, 4, 106, 0, 3, 0, 47, 0, 64,
- 37, 4, 106, 0, 66, 37, 4, 106, 0, 86,
- 37, 164, 106, 0, 38, 37, 164, 106, 0, 39,
- 37, 164, 106, 0, 4, 0, 81, 37, 164, 106,
- 0, 0, 0, 0, 0, 0, 0, 4, 167, 174,
- 165, 168, 45, 169, 142, 46, 170, 175, 144, 171,
- 148, 0, 54, 0, 55, 0, 56, 0, 57, 0,
- 58, 0, 37, 172, 106, 0, 0, 164, 173, 16,
- 0, 173, 16, 0, 25, 4, 0, 0
-};
-
-#endif
-
-#if YYDEBUG != 0
-static const short yyrline[] = { 0,
- 119, 121, 122, 126, 129, 131, 138, 143, 148, 150,
- 153, 155, 156, 159, 162, 163, 164, 166, 168, 170,
- 172, 174, 176, 178, 180, 182, 184, 186, 187, 188,
- 190, 192, 194, 196, 198, 199, 200, 201, 202, 204,
- 207, 209, 210, 213, 216, 219, 222, 226, 228, 229,
- 232, 235, 239, 244, 250, 252, 257, 259, 260, 261,
- 262, 263, 264, 265, 266, 268, 270, 272, 275, 277,
- 279, 281, 282, 284, 286, 288, 289, 292, 296, 299,
- 302, 305, 308, 313, 317, 319, 320, 323, 326, 329,
- 332, 336, 341, 346, 347, 351, 352, 356, 359, 361,
- 365, 366, 371, 372, 377, 387, 389, 392, 394, 397,
- 400, 402, 404, 408, 416, 421, 424, 426, 428, 430,
- 432, 434, 436, 441, 441, 445, 450, 458, 465, 466,
- 469, 473, 475, 476, 480, 482, 485, 491, 500, 505,
- 509, 514, 516, 520, 523, 528, 530, 533, 536, 539,
- 544, 546, 549, 552, 554, 556, 558, 560, 563, 565,
- 567, 569, 571, 573, 575, 577, 579, 581, 583, 585,
- 587, 589, 591, 593, 595, 597, 599, 601, 603, 605,
- 608, 610, 612, 614, 616, 618, 623, 625, 628, 630,
- 632, 636, 636, 643, 645, 647, 648, 649, 650, 653,
- 655, 659, 661, 664, 667
-};
-
-static const char * const yytname[] = { "$","error","$undefined.","INT","NAME",
-"LNAME","PLUSEQ","MINUSEQ","MULTEQ","DIVEQ","'='","LSHIFTEQ","RSHIFTEQ","ANDEQ",
-"OREQ","'?'","':'","OROR","ANDAND","'|'","'^'","'&'","EQ","NE","'<'","'>'","LE",
-"GE","LSHIFT","RSHIFT","'+'","'-'","'*'","'/'","'%'","UNARY","END","'('","ALIGN_K",
-"BLOCK","QUAD","LONG","SHORT","BYTE","SECTIONS","'{'","'}'","SIZEOF_HEADERS",
-"OUTPUT_FORMAT","FORCE_COMMON_ALLOCATION","OUTPUT_ARCH","INCLUDE","MEMORY","DEFSYMEND",
-"NOLOAD","DSECT","COPY","INFO","OVERLAY","DEFINED","TARGET_K","SEARCH_DIR","MAP",
-"ENTRY","SIZEOF","NEXT","ADDR","STARTUP","HLL","SYSLIB","FLOAT","NOFLOAT","ORIGIN",
-"FILL","LENGTH","CREATE_OBJECT_SYMBOLS","INPUT","GROUP","OUTPUT","CONSTRUCTORS",
-"ALIGNMOD","AT","PROVIDE","CHIP","LIST","SECT","ABSOLUTE","LOAD","NEWLINE","ENDWORD",
-"ORDER","NAMEWORD","FORMAT","PUBLIC","BASE","ALIAS","TRUNCATE","REL","INPUT_SCRIPT",
-"INPUT_MRI_SCRIPT","INPUT_DEFSYM","CASE","EXTERN","START","','","';'","')'",
-"'['","']'","'!'","'~'","file","filename","defsym_expr","@1","mri_script_file",
-"@2","mri_script_lines","mri_script_command","@3","ordernamelist","mri_load_name_list",
-"mri_abs_name_list","casesymlist","extern_name_list","script_file","@4","ifile_list",
-"ifile_p1","@5","@6","input_list","sections","sec_or_group_p1","statement_anywhere",
-"file_NAME_list","input_section_spec","@7","@8","@9","statement","statement_list",
-"statement_list_opt","length","fill_opt","assign_op","end","assignment","opt_comma",
-"memory","memory_spec_list","memory_spec","@10","origin_spec","length_spec",
-"attributes_opt","startup","high_level_library","high_level_library_NAME_list",
-"low_level_library","low_level_library_NAME_list","floating_point_support","mustbe_exp",
-"@11","exp","opt_at","section","@12","@13","@14","@15","@16","type","atype",
-"opt_exp_with_type","memspec_opt",""
-};
-#endif
-
-static const short yyr1[] = { 0,
- 111, 111, 111, 112, 114, 113, 116, 115, 117, 117,
- 118, 118, 118, 118, 118, 118, 118, 118, 118, 118,
- 118, 118, 118, 118, 118, 118, 118, 118, 118, 118,
- 118, 118, 118, 118, 118, 118, 119, 118, 118, 118,
- 120, 120, 120, 121, 121, 122, 122, 123, 123, 123,
- 124, 124, 126, 125, 127, 127, 128, 128, 128, 128,
- 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
- 128, 128, 129, 128, 128, 130, 128, 131, 131, 131,
- 131, 131, 131, 132, 133, 133, 133, 134, 134, 135,
- 135, 136, 137, 136, 138, 136, 139, 136, 140, 140,
- 140, 140, 140, 140, 140, 141, 141, 142, 142, 143,
- 143, 143, 143, 144, 144, 145, 145, 145, 145, 145,
- 145, 145, 145, 146, 146, 147, 147, 147, 148, 148,
- 149, 150, 150, 150, 152, 151, 153, 154, 155, 155,
- 156, 157, 157, 158, 158, 159, 160, 160, 161, 161,
- 163, 162, 164, 164, 164, 164, 164, 164, 164, 164,
- 164, 164, 164, 164, 164, 164, 164, 164, 164, 164,
- 164, 164, 164, 164, 164, 164, 164, 164, 164, 164,
- 164, 164, 164, 164, 164, 164, 165, 165, 167, 168,
- 169, 170, 171, 166, 172, 172, 172, 172, 172, 173,
- 173, 174, 174, 175, 175
-};
-
-static const short yyr2[] = { 0,
- 2, 2, 2, 1, 0, 4, 0, 2, 3, 0,
- 2, 4, 1, 1, 2, 1, 4, 4, 3, 2,
- 4, 3, 4, 4, 4, 4, 4, 2, 2, 2,
- 4, 4, 2, 2, 2, 2, 0, 5, 2, 0,
- 3, 2, 0, 1, 3, 1, 3, 0, 1, 3,
- 1, 3, 0, 2, 2, 0, 1, 1, 1, 1,
- 1, 1, 1, 1, 4, 4, 4, 4, 8, 4,
- 1, 4, 0, 5, 4, 0, 5, 1, 3, 2,
- 1, 3, 2, 4, 2, 2, 0, 4, 2, 1,
- 3, 1, 0, 4, 0, 5, 0, 5, 2, 1,
- 1, 1, 1, 4, 4, 2, 1, 0, 1, 1,
- 1, 1, 1, 2, 0, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 3, 3, 6, 1, 0,
- 5, 2, 3, 0, 0, 7, 3, 3, 3, 0,
- 4, 4, 3, 3, 1, 4, 3, 0, 1, 1,
- 0, 2, 2, 3, 4, 2, 2, 2, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 5, 3, 3, 4, 1, 1,
- 4, 4, 4, 4, 4, 1, 4, 0, 0, 0,
- 0, 0, 0, 14, 1, 1, 1, 1, 1, 3,
- 0, 3, 2, 2, 0
-};
-
-static const short yydefact[] = { 0,
- 53, 7, 5, 1, 56, 2, 10, 3, 0, 54,
- 8, 0, 0, 0, 0, 71, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 149, 150, 0, 73,
- 0, 0, 64, 55, 58, 63, 0, 57, 59, 60,
- 61, 62, 13, 0, 0, 0, 0, 14, 0, 0,
- 0, 16, 43, 0, 0, 0, 0, 0, 0, 48,
- 0, 0, 0, 0, 116, 117, 118, 119, 151, 120,
- 121, 122, 123, 151, 87, 0, 0, 4, 76, 0,
- 0, 0, 0, 0, 0, 0, 148, 0, 0, 0,
- 0, 125, 124, 89, 0, 37, 0, 179, 186, 0,
- 0, 0, 0, 0, 180, 0, 0, 0, 0, 0,
- 0, 0, 11, 0, 46, 28, 44, 29, 15, 30,
- 20, 0, 33, 0, 34, 49, 35, 51, 36, 39,
- 9, 6, 126, 0, 127, 0, 0, 0, 56, 135,
- 134, 0, 0, 0, 0, 0, 143, 145, 130, 130,
- 78, 81, 0, 0, 0, 0, 0, 0, 10, 0,
- 0, 157, 153, 0, 0, 0, 0, 0, 0, 0,
- 0, 156, 158, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 22, 0, 0, 42, 0,
- 0, 0, 19, 0, 0, 0, 152, 189, 84, 86,
- 85, 0, 68, 70, 0, 140, 0, 65, 66, 75,
- 88, 141, 129, 142, 0, 146, 0, 80, 83, 0,
- 72, 0, 67, 151, 24, 25, 40, 26, 27, 154,
- 0, 0, 0, 0, 0, 0, 0, 0, 177, 176,
- 174, 173, 172, 166, 167, 170, 171, 168, 169, 164,
- 165, 162, 163, 159, 160, 161, 12, 23, 21, 47,
- 45, 41, 17, 18, 32, 31, 50, 52, 201, 0,
- 77, 0, 0, 131, 0, 132, 144, 147, 79, 82,
- 74, 0, 38, 184, 185, 178, 181, 155, 182, 183,
- 0, 0, 201, 0, 188, 0, 0, 0, 133, 128,
- 175, 195, 196, 197, 198, 199, 0, 0, 0, 203,
- 0, 190, 0, 139, 0, 130, 200, 202, 0, 0,
- 69, 151, 0, 0, 191, 137, 0, 136, 187, 108,
- 151, 92, 97, 110, 111, 112, 113, 0, 100, 102,
- 101, 93, 103, 107, 109, 0, 0, 0, 138, 0,
- 0, 0, 0, 106, 192, 0, 99, 0, 0, 0,
- 90, 130, 205, 0, 130, 130, 105, 94, 0, 0,
- 115, 104, 96, 98, 91, 204, 151, 193, 114, 130,
- 194, 0, 0, 0
-};
-
-static const short yydefgoto[] = { 392,
- 79, 8, 9, 6, 7, 11, 63, 159, 119, 118,
- 116, 127, 129, 4, 5, 10, 34, 89, 139, 153,
- 35, 136, 36, 372, 353, 363, 360, 361, 354, 355,
- 356, 357, 388, 74, 94, 37, 379, 38, 217, 141,
- 216, 326, 338, 283, 39, 40, 149, 41, 150, 42,
- 133, 134, 164, 322, 211, 279, 330, 340, 373, 390,
- 317, 304, 305, 381
-};
-
-static const short yypact[] = { -37,
--32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768, 29, 341,
- 377, 30, 579, 21, 9,-32768, 48, 86, 56, 67,
- 69, 83, 116, 119, 120, 121,-32768,-32768, 123,-32768,
- 125, 128,-32768,-32768,-32768,-32768, -91,-32768,-32768,-32768,
--32768,-32768,-32768, 155, 86, 164, 174,-32768, 165, 166,
- 167,-32768,-32768, 168, 170, 171, 174, 172, 177, 178,
- 179, 181, 93, 174,-32768,-32768,-32768,-32768,-32768,-32768,
--32768,-32768,-32768,-32768,-32768, 183, 184,-32768,-32768, 185,
- 188, 86, 86, 191, 86, 3,-32768, 47, 159, 86,
- 199,-32768,-32768,-32768, -1,-32768, 12,-32768,-32768, 174,
- 174, 174, 169, 186,-32768, 197, 198, 204, 205, 207,
- 174, 174, 670, 163,-32768, 104,-32768, 105, 8,-32768,
--32768, 227, 758, 132,-32768,-32768, 141,-32768, 143,-32768,
--32768, 758,-32768, 174,-32768, 14, -83, 114,-32768,-32768,
--32768, 142, 144, 146, 147, 149,-32768,-32768, -28, -18,
--32768,-32768, 1, 47, 150, 241, 174, 174,-32768, 174,
- 174,-32768,-32768, 490, 174, 174, 259, 267, 174, 271,
- 174,-32768,-32768, 174, 174, 174, 174, 174, 174, 174,
- 174, 174, 174, 174, 174, 174, 174, 174, 174, 174,
- 174, 174, 174, 174, 174, 758, 272, 273,-32768, 274,
- 174, 174, 758, 122, 275, 276, 758, 579,-32768,-32768,
--32768, 277,-32768,-32768, 302, 248, 4,-32768,-32768,-32768,
--32768,-32768,-32768,-32768, 86,-32768, 86,-32768,-32768, 145,
--32768, 11,-32768,-32768, 758, 758, 401, 758, 758,-32768,
- 510, 530, 192, 193, 550, 194, 580, 732, 710, 774,
- 789, 803, 816, 827, 827, 40, 40, 40, 40, 5,
- 5, 60, 60,-32768,-32768,-32768, 758, 758, 758,-32768,
--32768,-32768, 758, 758,-32768,-32768,-32768,-32768, 258, 190,
--32768, 283, 285,-32768, 185,-32768,-32768,-32768,-32768,-32768,
--32768, 196,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
- 174, 160, 690, 287, 209, 300, 201, 236,-32768,-32768,
- 758,-32768,-32768,-32768,-32768,-32768, 203, 26, 294,-32768,
- 279,-32768, 206,-32768, 301, 214,-32768,-32768, 174, 280,
--32768,-32768, 246, 600,-32768,-32768, 311,-32768,-32768, 16,
--32768, 18,-32768,-32768,-32768,-32768,-32768, 289,-32768,-32768,
--32768,-32768,-32768,-32768, 16, 281, 291, -91,-32768, 292,
- 293, 174, 328,-32768,-32768, 174,-32768, 328, 328, 620,
--32768, -61, 308, 640, -7, -4,-32768,-32768, 330, 331,
- 329,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768, 214,
--32768, 340, 342,-32768
-};
-
-static const short yypgoto[] = {-32768,
- -41,-32768,-32768,-32768,-32768, 182,-32768,-32768,-32768,-32768,
--32768,-32768,-32768,-32768,-32768, 208,-32768,-32768,-32768, 189,
--32768,-32768, 212, -217,-32768,-32768,-32768,-32768, -6,-32768,
--32768,-32768,-32768,-32768, -3, -321, -147,-32768,-32768, -206,
--32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
- -73,-32768, -47,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
--32768, 53,-32768,-32768
-};
-
-
-#define YYLAST 861
-
-
-static const short yytable[] = { 113,
- 135, 225, 227, 96, 228, 229, 78, 140, 157, 123,
- 286, 199, 92, 93, 228, 229, 132, 208, 358, 342,
- 212, 160, 213, 65, 66, 67, 68, 69, 70, 71,
- 72, 73, 12, 358, 188, 189, 190, 191, 192, 64,
- 143, 144, 223, 146, 148, 76, 378, 343, 155, 284,
- 151, 152, 162, 163, -95, 344, 345, 346, 347, 209,
- 1, 2, 3, 172, 173, 75, 196, 186, 187, 188,
- 189, 190, 191, 192, 203, 223, 23, 224, 309, 312,
- 313, 314, 315, 316, 77, 223, 207, 226, 348, 78,
- 349, 190, 191, 192, 350, 32, 223, 32, 383, 223,
- 80, 384, 158, 81, 230, 82, 231, 285, 147, 235,
- 236, 200, 238, 239, 230, 161, 291, 241, 242, 83,
- 351, 245, 352, 247, 275, 276, 248, 249, 250, 251,
- 252, 253, 254, 255, 256, 257, 258, 259, 260, 261,
- 262, 263, 264, 265, 266, 267, 268, 269, 289, 290,
- 375, 376, 84, 273, 274, 85, 86, 87, 95, 88,
- 292, 90, 98, 99, 91, 98, 99, 97, 114, 115,
- 117, 120, 194, 121, 122, 124, 98, 99, 333, 125,
- 131, 126, 128, 287, 130, 288, 137, 138, 140, 100,
- 101, 142, 100, 101, 145, 154, 102, 103, 104, 102,
- 103, 104, 156, 100, 101, 165, 105, 197, 198, 105,
- 102, 103, 104, 312, 313, 314, 315, 316, 106, 214,
- 105, 106, 166, 107, 108, 109, 107, 108, 109, 98,
- 99, 303, 106, 167, 168, 204, 201, 107, 108, 109,
- 169, 170, 391, 171, 205, 110, 206, 218, 110, 219,
- 234, 220, 221, 311, 222, 233, 100, 101, 336, 110,
- 98, 99, 243, 102, 103, 104, 195, 359, 111, 112,
- 244, 111, 112, 105, 246, 270, 271, 272, 277, 278,
- 280, 334, 111, 112, 282, 106, 307, 100, 101, 321,
- 107, 108, 109, 306, 302, 103, 104, 296, 297, 299,
- 308, 310, 320, 323, 105, 13, 324, 325, 327, 328,
- 332, 331, 110, 389, 370, 329, 106, 223, 374, 337,
- 341, 107, 108, 109, 335, 362, 365, 366, 368, 369,
- 202, 371, 380, 385, 386, 111, 112, 281, 387, 393,
- 237, 394, 232, 110, 13, 14, 215, 210, 364, 15,
- 16, 17, 18, 19, 367, 319, 0, 0, 0, 0,
- 0, 20, 21, 22, 23, 0, 111, 112, 24, 25,
- 26, 27, 28, 0, 0, 0, 0, 29, 30, 31,
- 43, 0, 0, 32, 14, 0, 0, 0, 15, 16,
- 17, 18, 19, 0, 0, 0, 0, 0, 0, 0,
- 20, 21, 22, 23, 43, 0, 33, 24, 25, 26,
- 27, 28, 0, 0, 44, 0, 29, 30, 31, 0,
- 0, 0, 32, 0, 0, 0, 0, 45, 0, 0,
- 0, 0, 0, 0, 0, 0, 293, 0, 44, 0,
- 0, 0, 0, 0, 0, 33, 0, 0, 0, 0,
- 0, 45, 0, 0, 0, 0, 46, 0, 0, 47,
- 48, 49, 50, 51, -40, 52, 53, 54, 55, 56,
- 57, 58, 59, 0, 0, 0, 0, 60, 61, 62,
- 46, 0, 0, 47, 48, 49, 50, 51, 0, 52,
- 53, 54, 55, 56, 57, 58, 59, 0, 0, 0,
- 0, 60, 61, 62, 174, 0, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 0, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 0, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 0, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 65, 66, 67, 68, 69, 70,
- 71, 72, 73, 0, 174, 240, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 294, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 295, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 298, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 174, 300, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 174, 339, 175, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 0, 377, 318, 176, 177, 178,
- 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
- 189, 190, 191, 192, 0, 382, 174, 301, 175, 176,
- 177, 178, 179, 180, 181, 182, 183, 184, 185, 186,
- 187, 188, 189, 190, 191, 192, 0, 0, 0, 0,
- 0, 0, 174, 193, 175, 176, 177, 178, 179, 180,
- 181, 182, 183, 184, 185, 186, 187, 188, 189, 190,
- 191, 192, 177, 178, 179, 180, 181, 182, 183, 184,
- 185, 186, 187, 188, 189, 190, 191, 192, 178, 179,
- 180, 181, 182, 183, 184, 185, 186, 187, 188, 189,
- 190, 191, 192, 179, 180, 181, 182, 183, 184, 185,
- 186, 187, 188, 189, 190, 191, 192, 180, 181, 182,
- 183, 184, 185, 186, 187, 188, 189, 190, 191, 192,
- 182, 183, 184, 185, 186, 187, 188, 189, 190, 191,
- 192
-};
-
-static const short yycheck[] = { 47,
- 74, 149, 150, 45, 4, 5, 4, 4, 10, 57,
- 217, 4, 104, 105, 4, 5, 64, 4, 340, 4,
- 104, 10, 106, 6, 7, 8, 9, 10, 11, 12,
- 13, 14, 4, 355, 30, 31, 32, 33, 34, 10,
- 82, 83, 104, 85, 86, 37, 108, 32, 90, 46,
- 4, 5, 100, 101, 37, 40, 41, 42, 43, 46,
- 98, 99, 100, 111, 112, 45, 114, 28, 29, 30,
- 31, 32, 33, 34, 122, 104, 63, 106, 285, 54,
- 55, 56, 57, 58, 37, 104, 134, 106, 73, 4,
- 75, 32, 33, 34, 79, 82, 104, 82, 106, 104,
- 45, 106, 104, 37, 104, 37, 106, 104, 106, 157,
- 158, 104, 160, 161, 104, 104, 106, 165, 166, 37,
- 105, 169, 107, 171, 3, 4, 174, 175, 176, 177,
- 178, 179, 180, 181, 182, 183, 184, 185, 186, 187,
- 188, 189, 190, 191, 192, 193, 194, 195, 4, 5,
- 368, 369, 37, 201, 202, 37, 37, 37, 4, 37,
- 234, 37, 3, 4, 37, 3, 4, 4, 4, 4,
- 4, 4, 10, 4, 4, 4, 3, 4, 326, 3,
- 88, 4, 4, 225, 4, 227, 4, 4, 4, 30,
- 31, 4, 30, 31, 4, 37, 37, 38, 39, 37,
- 38, 39, 4, 30, 31, 37, 47, 104, 104, 47,
- 37, 38, 39, 54, 55, 56, 57, 58, 59, 106,
- 47, 59, 37, 64, 65, 66, 64, 65, 66, 3,
- 4, 279, 59, 37, 37, 104, 10, 64, 65, 66,
- 37, 37, 390, 37, 104, 86, 104, 106, 86, 106,
- 10, 106, 106, 301, 106, 106, 30, 31, 332, 86,
- 3, 4, 4, 37, 38, 39, 104, 341, 109, 110,
- 4, 109, 110, 47, 4, 4, 4, 4, 4, 4,
- 4, 329, 109, 110, 37, 59, 4, 30, 31, 81,
- 64, 65, 66, 104, 37, 38, 39, 106, 106, 106,
- 16, 106, 16, 4, 47, 4, 106, 72, 106, 16,
- 10, 106, 86, 387, 362, 37, 59, 104, 366, 74,
- 10, 64, 65, 66, 45, 37, 46, 37, 37, 37,
- 104, 4, 25, 4, 4, 109, 110, 36, 10, 0,
- 159, 0, 154, 86, 4, 44, 139, 136, 355, 48,
- 49, 50, 51, 52, 358, 303, -1, -1, -1, -1,
- -1, 60, 61, 62, 63, -1, 109, 110, 67, 68,
- 69, 70, 71, -1, -1, -1, -1, 76, 77, 78,
- 4, -1, -1, 82, 44, -1, -1, -1, 48, 49,
- 50, 51, 52, -1, -1, -1, -1, -1, -1, -1,
- 60, 61, 62, 63, 4, -1, 105, 67, 68, 69,
- 70, 71, -1, -1, 38, -1, 76, 77, 78, -1,
- -1, -1, 82, -1, -1, -1, -1, 51, -1, -1,
- -1, -1, -1, -1, -1, -1, 36, -1, 38, -1,
- -1, -1, -1, -1, -1, 105, -1, -1, -1, -1,
- -1, 51, -1, -1, -1, -1, 80, -1, -1, 83,
- 84, 85, 86, 87, 88, 89, 90, 91, 92, 93,
- 94, 95, 96, -1, -1, -1, -1, 101, 102, 103,
- 80, -1, -1, 83, 84, 85, 86, 87, -1, 89,
- 90, 91, 92, 93, 94, 95, 96, -1, -1, -1,
- -1, 101, 102, 103, 15, -1, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, -1, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, -1, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, -1, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 6, 7, 8, 9, 10, 11,
- 12, 13, 14, -1, 15, 106, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, 106, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, 106, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, 106, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 15, 106, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 15, 106, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, -1, 106, 37, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, -1, 106, 15, 16, 17, 18,
- 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
- 29, 30, 31, 32, 33, 34, -1, -1, -1, -1,
- -1, -1, 15, 104, 17, 18, 19, 20, 21, 22,
- 23, 24, 25, 26, 27, 28, 29, 30, 31, 32,
- 33, 34, 19, 20, 21, 22, 23, 24, 25, 26,
- 27, 28, 29, 30, 31, 32, 33, 34, 20, 21,
- 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 21, 22, 23, 24, 25, 26, 27,
- 28, 29, 30, 31, 32, 33, 34, 22, 23, 24,
- 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
- 24, 25, 26, 27, 28, 29, 30, 31, 32, 33,
- 34
-};
-/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
-#line 3 "/usr/unsupported/share/bison.simple"
-
-/* Skeleton output parser for bison,
- Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-#ifndef alloca
-#ifdef __GNUC__
-#define alloca __builtin_alloca
-#else /* not GNU C. */
-#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi)
-#include <alloca.h>
-#else /* not sparc */
-#if defined (MSDOS) && !defined (__TURBOC__)
-#include <malloc.h>
-#else /* not MSDOS, or __TURBOC__ */
-#if defined(_AIX)
-#include <malloc.h>
- #pragma alloca
-#else /* not MSDOS, __TURBOC__, or _AIX */
-#ifdef __hpux
-#ifdef __cplusplus
-extern "C" {
-void *alloca (unsigned int);
-};
-#else /* not __cplusplus */
-void *alloca ();
-#endif /* not __cplusplus */
-#endif /* __hpux */
-#endif /* not _AIX */
-#endif /* not MSDOS, or __TURBOC__ */
-#endif /* not sparc. */
-#endif /* not GNU C. */
-#endif /* alloca not defined. */
-
-/* This is the parser code that is written into each bison parser
- when the %semantic_parser declaration is not specified in the grammar.
- It was written by Richard Stallman by simplifying the hairy parser
- used when %semantic_parser is specified. */
-
-/* Note: there must be only one dollar sign in this file.
- It is replaced by the list of actions, each action
- as one case of the switch. */
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY -2
-#define YYEOF 0
-#define YYACCEPT return(0)
-#define YYABORT return(1)
-#define YYERROR goto yyerrlab1
-/* Like YYERROR except do call yyerror.
- This remains here temporarily to ease the
- transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. */
-#define YYFAIL goto yyerrlab
-#define YYRECOVERING() (!!yyerrstatus)
-#define YYBACKUP(token, value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { yychar = (token), yylval = (value); \
- yychar1 = YYTRANSLATE (yychar); \
- YYPOPSTACK; \
- goto yybackup; \
- } \
- else \
- { yyerror ("syntax error: cannot back up"); YYERROR; } \
-while (0)
-
-#define YYTERROR 1
-#define YYERRCODE 256
-
-#ifndef YYPURE
-#define YYLEX yylex()
-#endif
-
-#ifdef YYPURE
-#ifdef YYLSP_NEEDED
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval, &yylloc)
-#endif
-#else /* not YYLSP_NEEDED */
-#ifdef YYLEX_PARAM
-#define YYLEX yylex(&yylval, YYLEX_PARAM)
-#else
-#define YYLEX yylex(&yylval)
-#endif
-#endif /* not YYLSP_NEEDED */
-#endif
-
-/* If nonreentrant, generate the variables here */
-
-#ifndef YYPURE
-
-int yychar; /* the lookahead symbol */
-YYSTYPE yylval; /* the semantic value of the */
- /* lookahead symbol */
-
-#ifdef YYLSP_NEEDED
-YYLTYPE yylloc; /* location data for the lookahead */
- /* symbol */
-#endif
-
-int yynerrs; /* number of parse errors so far */
-#endif /* not YYPURE */
-
-#if YYDEBUG != 0
-int yydebug; /* nonzero means print parse trace */
-/* Since this is uninitialized, it does not stop multiple parsers
- from coexisting. */
-#endif
-
-/* YYINITDEPTH indicates the initial size of the parser's stacks */
-
-#ifndef YYINITDEPTH
-#define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH is the maximum size the stacks can grow to
- (effective only if the built-in stack extension method is used). */
-
-#if YYMAXDEPTH == 0
-#undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-#define YYMAXDEPTH 10000
-#endif
-
-/* Prevent warning if -Wstrict-prototypes. */
-#ifdef __GNUC__
-int yyparse (void);
-#endif
-
-#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
-#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT)
-#else /* not GNU C or C++ */
-#ifndef __cplusplus
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (from, to, count)
- char *from;
- char *to;
- int count;
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#else /* __cplusplus */
-
-/* This is the most reliable way to avoid incompatibilities
- in available built-in functions on various systems. */
-static void
-__yy_memcpy (char *from, char *to, int count)
-{
- register char *f = from;
- register char *t = to;
- register int i = count;
-
- while (i-- > 0)
- *t++ = *f++;
-}
-
-#endif
-#endif
-
-#line 192 "/usr/unsupported/share/bison.simple"
-
-/* The user can define YYPARSE_PARAM as the name of an argument to be passed
- into yyparse. The argument should have type void *.
- It should actually point to an object.
- Grammar actions can access the variable by casting it
- to the proper pointer type. */
-
-#ifdef YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
-#else
-#define YYPARSE_PARAM
-#define YYPARSE_PARAM_DECL
-#endif
-
-int
-yyparse(YYPARSE_PARAM)
- YYPARSE_PARAM_DECL
-{
- register int yystate;
- register int yyn;
- register short *yyssp;
- register YYSTYPE *yyvsp;
- int yyerrstatus; /* number of tokens to shift before error messages enabled */
- int yychar1 = 0; /* lookahead token as an internal (translated) token number */
-
- short yyssa[YYINITDEPTH]; /* the state stack */
- YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
-
- short *yyss = yyssa; /* refer to the stacks thru separate pointers */
- YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
-
-#ifdef YYLSP_NEEDED
- YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */
- YYLTYPE *yyls = yylsa;
- YYLTYPE *yylsp;
-
-#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
-#else
-#define YYPOPSTACK (yyvsp--, yyssp--)
-#endif
-
- int yystacksize = YYINITDEPTH;
-
-#ifdef YYPURE
- int yychar;
- YYSTYPE yylval;
- int yynerrs;
-#ifdef YYLSP_NEEDED
- YYLTYPE yylloc;
-#endif
-#endif
-
- YYSTYPE yyval; /* the variable used to return */
- /* semantic values from the action */
- /* routines */
-
- int yylen;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Starting parse\n");
-#endif
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
-
- yyssp = yyss - 1;
- yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
- yylsp = yyls;
-#endif
-
-/* Push a new state, which is found in yystate . */
-/* In all cases, when you get here, the value and location stacks
- have just been pushed. so pushing a state here evens the stacks. */
-yynewstate:
-
- *++yyssp = yystate;
-
- if (yyssp >= yyss + yystacksize - 1)
- {
- /* Give user a chance to reallocate the stack */
- /* Use copies of these so that the &'s don't force the real ones into memory. */
- YYSTYPE *yyvs1 = yyvs;
- short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
- YYLTYPE *yyls1 = yyls;
-#endif
-
- /* Get the current used size of the three stacks, in elements. */
- int size = yyssp - yyss + 1;
-
-#ifdef yyoverflow
- /* Each stack pointer address is followed by the size of
- the data in use in that stack, in bytes. */
-#ifdef YYLSP_NEEDED
- /* This used to be a conditional around just the two extra args,
- but that might be undefined if yyoverflow is a macro. */
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yyls1, size * sizeof (*yylsp),
- &yystacksize);
-#else
- yyoverflow("parser stack overflow",
- &yyss1, size * sizeof (*yyssp),
- &yyvs1, size * sizeof (*yyvsp),
- &yystacksize);
-#endif
-
- yyss = yyss1; yyvs = yyvs1;
-#ifdef YYLSP_NEEDED
- yyls = yyls1;
-#endif
-#else /* no yyoverflow */
- /* Extend the stack our own way. */
- if (yystacksize >= YYMAXDEPTH)
- {
- yyerror("parser stack overflow");
- return 2;
- }
- yystacksize *= 2;
- if (yystacksize > YYMAXDEPTH)
- yystacksize = YYMAXDEPTH;
- yyss = (short *) alloca (yystacksize * sizeof (*yyssp));
- __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp));
- yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp));
- __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp));
-#ifdef YYLSP_NEEDED
- yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp));
- __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp));
-#endif
-#endif /* no yyoverflow */
-
- yyssp = yyss + size - 1;
- yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
- yylsp = yyls + size - 1;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Stack size increased to %d\n", yystacksize);
-#endif
-
- if (yyssp >= yyss + yystacksize - 1)
- YYABORT;
- }
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Entering state %d\n", yystate);
-#endif
-
- goto yybackup;
- yybackup:
-
-/* Do appropriate processing given the current state. */
-/* Read a lookahead token if we need one and don't already have one. */
-/* yyresume: */
-
- /* First try to decide what to do without reference to lookahead token. */
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* yychar is either YYEMPTY or YYEOF
- or a valid token in external form. */
-
- if (yychar == YYEMPTY)
- {
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Reading a token: ");
-#endif
- yychar = YYLEX;
- }
-
- /* Convert token to internal form (in yychar1) for indexing tables with */
-
- if (yychar <= 0) /* This means end of input. */
- {
- yychar1 = 0;
- yychar = YYEOF; /* Don't call YYLEX any more */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Now at end of input.\n");
-#endif
- }
- else
- {
- yychar1 = YYTRANSLATE(yychar);
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
- /* Give the individual parser a way to print the precise meaning
- of a token, for further debugging info. */
-#ifdef YYPRINT
- YYPRINT (stderr, yychar, yylval);
-#endif
- fprintf (stderr, ")\n");
- }
-#endif
- }
-
- yyn += yychar1;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
- goto yydefault;
-
- yyn = yytable[yyn];
-
- /* yyn is what to do for this token type in this state.
- Negative => reduce, -yyn is rule number.
- Positive => shift, yyn is new state.
- New state is final state => don't bother to shift,
- just return success.
- 0, or most negative number => error. */
-
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrlab;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- /* Shift the lookahead token. */
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
-#endif
-
- /* Discard the token being shifted unless it is eof. */
- if (yychar != YYEOF)
- yychar = YYEMPTY;
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- /* count tokens shifted since error; after three, turn off error status. */
- if (yyerrstatus) yyerrstatus--;
-
- yystate = yyn;
- goto yynewstate;
-
-/* Do the default action for the current state. */
-yydefault:
-
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
-
-/* Do a reduction. yyn is the number of a rule to reduce with. */
-yyreduce:
- yylen = yyr2[yyn];
- if (yylen > 0)
- yyval = yyvsp[1-yylen]; /* implement default value of the action */
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- int i;
-
- fprintf (stderr, "Reducing via rule %d (line %d), ",
- yyn, yyrline[yyn]);
-
- /* Print the symbols being reduced, and their result. */
- for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
- fprintf (stderr, "%s ", yytname[yyrhs[i]]);
- fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
- }
-#endif
-
-
- switch (yyn) {
-
-case 5:
-#line 130 "./ldgram.y"
-{ ldlex_defsym(); ;
- break;}
-case 6:
-#line 132 "./ldgram.y"
-{
- ldlex_popstate();
- lang_add_assignment(exp_assop(yyvsp[-1].token,yyvsp[-2].name,yyvsp[0].etree));
- ;
- break;}
-case 7:
-#line 139 "./ldgram.y"
-{ ldlex_mri_script();
- PUSH_ERROR("MRI style script");
- ;
- break;}
-case 8:
-#line 143 "./ldgram.y"
-{ ldlex_popstate();
- POP_ERROR();
- ;
- break;}
-case 13:
-#line 156 "./ldgram.y"
-{
- einfo("%P%F: unrecognised keyword in MRI style script '%s'\n",yyvsp[0].name);
- ;
- break;}
-case 14:
-#line 159 "./ldgram.y"
-{
- config.map_filename = "-";
- ;
- break;}
-case 17:
-#line 165 "./ldgram.y"
-{ mri_public(yyvsp[-2].name, yyvsp[0].etree); ;
- break;}
-case 18:
-#line 167 "./ldgram.y"
-{ mri_public(yyvsp[-2].name, yyvsp[0].etree); ;
- break;}
-case 19:
-#line 169 "./ldgram.y"
-{ mri_public(yyvsp[-1].name, yyvsp[0].etree); ;
- break;}
-case 20:
-#line 171 "./ldgram.y"
-{ mri_format(yyvsp[0].name); ;
- break;}
-case 21:
-#line 173 "./ldgram.y"
-{ mri_output_section(yyvsp[-2].name, yyvsp[0].etree);;
- break;}
-case 22:
-#line 175 "./ldgram.y"
-{ mri_output_section(yyvsp[-1].name, yyvsp[0].etree);;
- break;}
-case 23:
-#line 177 "./ldgram.y"
-{ mri_output_section(yyvsp[-2].name, yyvsp[0].etree);;
- break;}
-case 24:
-#line 179 "./ldgram.y"
-{ mri_align(yyvsp[-2].name,yyvsp[0].etree); ;
- break;}
-case 25:
-#line 181 "./ldgram.y"
-{ mri_align(yyvsp[-2].name,yyvsp[0].etree); ;
- break;}
-case 26:
-#line 183 "./ldgram.y"
-{ mri_alignmod(yyvsp[-2].name,yyvsp[0].etree); ;
- break;}
-case 27:
-#line 185 "./ldgram.y"
-{ mri_alignmod(yyvsp[-2].name,yyvsp[0].etree); ;
- break;}
-case 30:
-#line 189 "./ldgram.y"
-{ mri_name(yyvsp[0].name); ;
- break;}
-case 31:
-#line 191 "./ldgram.y"
-{ mri_alias(yyvsp[-2].name,yyvsp[0].name,0);;
- break;}
-case 32:
-#line 193 "./ldgram.y"
-{ mri_alias(yyvsp[-2].name,0,(int) yyvsp[0].integer);;
- break;}
-case 33:
-#line 195 "./ldgram.y"
-{ mri_base(yyvsp[0].etree); ;
- break;}
-case 34:
-#line 197 "./ldgram.y"
-{ mri_truncate((unsigned int) yyvsp[0].integer); ;
- break;}
-case 37:
-#line 201 "./ldgram.y"
-{ ldfile_open_command_file (yyvsp[0].name); ;
- break;}
-case 39:
-#line 203 "./ldgram.y"
-{ lang_add_entry (yyvsp[0].name, false); ;
- break;}
-case 41:
-#line 208 "./ldgram.y"
-{ mri_order(yyvsp[0].name); ;
- break;}
-case 42:
-#line 209 "./ldgram.y"
-{ mri_order(yyvsp[0].name); ;
- break;}
-case 44:
-#line 215 "./ldgram.y"
-{ mri_load(yyvsp[0].name); ;
- break;}
-case 45:
-#line 216 "./ldgram.y"
-{ mri_load(yyvsp[0].name); ;
- break;}
-case 46:
-#line 221 "./ldgram.y"
-{ mri_only_load(yyvsp[0].name); ;
- break;}
-case 47:
-#line 223 "./ldgram.y"
-{ mri_only_load(yyvsp[0].name); ;
- break;}
-case 48:
-#line 227 "./ldgram.y"
-{ yyval.name = NULL; ;
- break;}
-case 51:
-#line 234 "./ldgram.y"
-{ ldlang_add_undef (yyvsp[0].name); ;
- break;}
-case 52:
-#line 236 "./ldgram.y"
-{ ldlang_add_undef (yyvsp[0].name); ;
- break;}
-case 53:
-#line 240 "./ldgram.y"
-{
- ldlex_both();
- ;
- break;}
-case 54:
-#line 244 "./ldgram.y"
-{
- ldlex_popstate();
- ;
- break;}
-case 65:
-#line 267 "./ldgram.y"
-{ lang_add_target(yyvsp[-1].name); ;
- break;}
-case 66:
-#line 269 "./ldgram.y"
-{ ldfile_add_library_path (yyvsp[-1].name, false); ;
- break;}
-case 67:
-#line 271 "./ldgram.y"
-{ lang_add_output(yyvsp[-1].name, 1); ;
- break;}
-case 68:
-#line 273 "./ldgram.y"
-{ lang_add_output_format (yyvsp[-1].name, (char *) NULL,
- (char *) NULL, 1); ;
- break;}
-case 69:
-#line 276 "./ldgram.y"
-{ lang_add_output_format (yyvsp[-5].name, yyvsp[-3].name, yyvsp[-1].name, 1); ;
- break;}
-case 70:
-#line 278 "./ldgram.y"
-{ ldfile_set_output_arch(yyvsp[-1].name); ;
- break;}
-case 71:
-#line 280 "./ldgram.y"
-{ command_line.force_common_definition = true ; ;
- break;}
-case 73:
-#line 283 "./ldgram.y"
-{ lang_enter_group (); ;
- break;}
-case 74:
-#line 285 "./ldgram.y"
-{ lang_leave_group (); ;
- break;}
-case 75:
-#line 287 "./ldgram.y"
-{ lang_add_map(yyvsp[-1].name); ;
- break;}
-case 76:
-#line 289 "./ldgram.y"
-{ ldfile_open_command_file(yyvsp[0].name); ;
- break;}
-case 78:
-#line 294 "./ldgram.y"
-{ lang_add_input_file(yyvsp[0].name,lang_input_file_is_search_file_enum,
- (char *)NULL); ;
- break;}
-case 79:
-#line 297 "./ldgram.y"
-{ lang_add_input_file(yyvsp[0].name,lang_input_file_is_search_file_enum,
- (char *)NULL); ;
- break;}
-case 80:
-#line 300 "./ldgram.y"
-{ lang_add_input_file(yyvsp[0].name,lang_input_file_is_search_file_enum,
- (char *)NULL); ;
- break;}
-case 81:
-#line 303 "./ldgram.y"
-{ lang_add_input_file(yyvsp[0].name,lang_input_file_is_l_enum,
- (char *)NULL); ;
- break;}
-case 82:
-#line 306 "./ldgram.y"
-{ lang_add_input_file(yyvsp[0].name,lang_input_file_is_l_enum,
- (char *)NULL); ;
- break;}
-case 83:
-#line 309 "./ldgram.y"
-{ lang_add_input_file(yyvsp[0].name,lang_input_file_is_l_enum,
- (char *)NULL); ;
- break;}
-case 88:
-#line 325 "./ldgram.y"
-{ lang_add_entry (yyvsp[-1].name, false); ;
- break;}
-case 90:
-#line 331 "./ldgram.y"
-{ lang_add_wild(yyvsp[0].name, current_file); ;
- break;}
-case 91:
-#line 333 "./ldgram.y"
-{ lang_add_wild(yyvsp[0].name, current_file); ;
- break;}
-case 92:
-#line 338 "./ldgram.y"
-{
- lang_add_wild((char *)NULL, yyvsp[0].name);
- ;
- break;}
-case 93:
-#line 342 "./ldgram.y"
-{
- current_file = (char *)NULL;
- ;
- break;}
-case 95:
-#line 348 "./ldgram.y"
-{
- current_file =yyvsp[0].name;
- ;
- break;}
-case 97:
-#line 353 "./ldgram.y"
-{
- current_file = (char *)NULL;
- ;
- break;}
-case 100:
-#line 362 "./ldgram.y"
-{
- lang_add_attribute(lang_object_symbols_statement_enum);
- ;
- break;}
-case 102:
-#line 367 "./ldgram.y"
-{
-
- lang_add_attribute(lang_constructors_statement_enum);
- ;
- break;}
-case 104:
-#line 373 "./ldgram.y"
-{
- lang_add_data((int) yyvsp[-3].integer,yyvsp[-1].etree);
- ;
- break;}
-case 105:
-#line 378 "./ldgram.y"
-{
- lang_add_fill
- (exp_get_value_int(yyvsp[-1].etree,
- 0,
- "fill value",
- lang_first_phase_enum));
- ;
- break;}
-case 110:
-#line 399 "./ldgram.y"
-{ yyval.integer = yyvsp[0].token; ;
- break;}
-case 111:
-#line 401 "./ldgram.y"
-{ yyval.integer = yyvsp[0].token; ;
- break;}
-case 112:
-#line 403 "./ldgram.y"
-{ yyval.integer = yyvsp[0].token; ;
- break;}
-case 113:
-#line 405 "./ldgram.y"
-{ yyval.integer = yyvsp[0].token; ;
- break;}
-case 114:
-#line 410 "./ldgram.y"
-{
- yyval.integer = exp_get_value_int(yyvsp[0].etree,
- 0,
- "fill value",
- lang_first_phase_enum);
- ;
- break;}
-case 115:
-#line 416 "./ldgram.y"
-{ yyval.integer = 0; ;
- break;}
-case 116:
-#line 423 "./ldgram.y"
-{ yyval.token = '+'; ;
- break;}
-case 117:
-#line 425 "./ldgram.y"
-{ yyval.token = '-'; ;
- break;}
-case 118:
-#line 427 "./ldgram.y"
-{ yyval.token = '*'; ;
- break;}
-case 119:
-#line 429 "./ldgram.y"
-{ yyval.token = '/'; ;
- break;}
-case 120:
-#line 431 "./ldgram.y"
-{ yyval.token = LSHIFT; ;
- break;}
-case 121:
-#line 433 "./ldgram.y"
-{ yyval.token = RSHIFT; ;
- break;}
-case 122:
-#line 435 "./ldgram.y"
-{ yyval.token = '&'; ;
- break;}
-case 123:
-#line 437 "./ldgram.y"
-{ yyval.token = '|'; ;
- break;}
-case 126:
-#line 447 "./ldgram.y"
-{
- lang_add_assignment (exp_assop (yyvsp[-1].token, yyvsp[-2].name, yyvsp[0].etree));
- ;
- break;}
-case 127:
-#line 451 "./ldgram.y"
-{
- lang_add_assignment (exp_assop ('=', yyvsp[-2].name,
- exp_binop (yyvsp[-1].token,
- exp_nameop (NAME,
- yyvsp[-2].name),
- yyvsp[0].etree)));
- ;
- break;}
-case 128:
-#line 459 "./ldgram.y"
-{
- lang_add_assignment (exp_provide (yyvsp[-3].name, yyvsp[-1].etree));
- ;
- break;}
-case 135:
-#line 481 "./ldgram.y"
-{ region = lang_memory_region_lookup(yyvsp[0].name); ;
- break;}
-case 137:
-#line 487 "./ldgram.y"
-{ region->current =
- region->origin =
- exp_get_vma(yyvsp[0].etree, 0L,"origin", lang_first_phase_enum);
-;
- break;}
-case 138:
-#line 493 "./ldgram.y"
-{ region->length = exp_get_vma(yyvsp[0].etree,
- ~((bfd_vma)0),
- "length",
- lang_first_phase_enum);
- ;
- break;}
-case 139:
-#line 502 "./ldgram.y"
-{
- lang_set_flags(&region->flags, yyvsp[-1].name);
- ;
- break;}
-case 141:
-#line 511 "./ldgram.y"
-{ lang_startup(yyvsp[-1].name); ;
- break;}
-case 143:
-#line 517 "./ldgram.y"
-{ ldemul_hll((char *)NULL); ;
- break;}
-case 144:
-#line 522 "./ldgram.y"
-{ ldemul_hll(yyvsp[0].name); ;
- break;}
-case 145:
-#line 524 "./ldgram.y"
-{ ldemul_hll(yyvsp[0].name); ;
- break;}
-case 147:
-#line 532 "./ldgram.y"
-{ ldemul_syslib(yyvsp[0].name); ;
- break;}
-case 149:
-#line 538 "./ldgram.y"
-{ lang_float(true); ;
- break;}
-case 150:
-#line 540 "./ldgram.y"
-{ lang_float(false); ;
- break;}
-case 151:
-#line 544 "./ldgram.y"
-{ ldlex_expression(); ;
- break;}
-case 152:
-#line 546 "./ldgram.y"
-{ ldlex_popstate(); yyval.etree=yyvsp[0].etree;;
- break;}
-case 153:
-#line 551 "./ldgram.y"
-{ yyval.etree = exp_unop('-', yyvsp[0].etree); ;
- break;}
-case 154:
-#line 553 "./ldgram.y"
-{ yyval.etree = yyvsp[-1].etree; ;
- break;}
-case 155:
-#line 555 "./ldgram.y"
-{ yyval.etree = exp_unop((int) yyvsp[-3].integer,yyvsp[-1].etree); ;
- break;}
-case 156:
-#line 557 "./ldgram.y"
-{ yyval.etree = exp_unop('!', yyvsp[0].etree); ;
- break;}
-case 157:
-#line 559 "./ldgram.y"
-{ yyval.etree = yyvsp[0].etree; ;
- break;}
-case 158:
-#line 561 "./ldgram.y"
-{ yyval.etree = exp_unop('~', yyvsp[0].etree);;
- break;}
-case 159:
-#line 564 "./ldgram.y"
-{ yyval.etree = exp_binop('*', yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 160:
-#line 566 "./ldgram.y"
-{ yyval.etree = exp_binop('/', yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 161:
-#line 568 "./ldgram.y"
-{ yyval.etree = exp_binop('%', yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 162:
-#line 570 "./ldgram.y"
-{ yyval.etree = exp_binop('+', yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 163:
-#line 572 "./ldgram.y"
-{ yyval.etree = exp_binop('-' , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 164:
-#line 574 "./ldgram.y"
-{ yyval.etree = exp_binop(LSHIFT , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 165:
-#line 576 "./ldgram.y"
-{ yyval.etree = exp_binop(RSHIFT , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 166:
-#line 578 "./ldgram.y"
-{ yyval.etree = exp_binop(EQ , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 167:
-#line 580 "./ldgram.y"
-{ yyval.etree = exp_binop(NE , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 168:
-#line 582 "./ldgram.y"
-{ yyval.etree = exp_binop(LE , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 169:
-#line 584 "./ldgram.y"
-{ yyval.etree = exp_binop(GE , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 170:
-#line 586 "./ldgram.y"
-{ yyval.etree = exp_binop('<' , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 171:
-#line 588 "./ldgram.y"
-{ yyval.etree = exp_binop('>' , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 172:
-#line 590 "./ldgram.y"
-{ yyval.etree = exp_binop('&' , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 173:
-#line 592 "./ldgram.y"
-{ yyval.etree = exp_binop('^' , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 174:
-#line 594 "./ldgram.y"
-{ yyval.etree = exp_binop('|' , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 175:
-#line 596 "./ldgram.y"
-{ yyval.etree = exp_trinop('?' , yyvsp[-4].etree, yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 176:
-#line 598 "./ldgram.y"
-{ yyval.etree = exp_binop(ANDAND , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 177:
-#line 600 "./ldgram.y"
-{ yyval.etree = exp_binop(OROR , yyvsp[-2].etree, yyvsp[0].etree); ;
- break;}
-case 178:
-#line 602 "./ldgram.y"
-{ yyval.etree = exp_nameop(DEFINED, yyvsp[-1].name); ;
- break;}
-case 179:
-#line 604 "./ldgram.y"
-{ yyval.etree = exp_intop(yyvsp[0].integer); ;
- break;}
-case 180:
-#line 606 "./ldgram.y"
-{ yyval.etree = exp_nameop(SIZEOF_HEADERS,0); ;
- break;}
-case 181:
-#line 609 "./ldgram.y"
-{ yyval.etree = exp_nameop(SIZEOF,yyvsp[-1].name); ;
- break;}
-case 182:
-#line 611 "./ldgram.y"
-{ yyval.etree = exp_nameop(ADDR,yyvsp[-1].name); ;
- break;}
-case 183:
-#line 613 "./ldgram.y"
-{ yyval.etree = exp_unop(ABSOLUTE, yyvsp[-1].etree); ;
- break;}
-case 184:
-#line 615 "./ldgram.y"
-{ yyval.etree = exp_unop(ALIGN_K,yyvsp[-1].etree); ;
- break;}
-case 185:
-#line 617 "./ldgram.y"
-{ yyval.etree = exp_unop(ALIGN_K,yyvsp[-1].etree); ;
- break;}
-case 186:
-#line 619 "./ldgram.y"
-{ yyval.etree = exp_nameop(NAME,yyvsp[0].name); ;
- break;}
-case 187:
-#line 624 "./ldgram.y"
-{ yyval.etree = yyvsp[-1].etree; ;
- break;}
-case 188:
-#line 625 "./ldgram.y"
-{ yyval.etree = 0; ;
- break;}
-case 189:
-#line 628 "./ldgram.y"
-{ ldlex_expression(); ;
- break;}
-case 190:
-#line 630 "./ldgram.y"
-{ ldlex_popstate(); ;
- break;}
-case 191:
-#line 632 "./ldgram.y"
-{
- lang_enter_output_section_statement(yyvsp[-5].name,yyvsp[-3].etree,typebits,0,0,0,yyvsp[-2].etree);
- ;
- break;}
-case 192:
-#line 636 "./ldgram.y"
-{ldlex_expression();;
- break;}
-case 193:
-#line 637 "./ldgram.y"
-{
- ldlex_popstate();
- lang_leave_output_section_statement(yyvsp[0].integer, yyvsp[-1].name);
- ;
- break;}
-case 195:
-#line 646 "./ldgram.y"
-{ typebits = SEC_NEVER_LOAD; ;
- break;}
-case 196:
-#line 647 "./ldgram.y"
-{ typebits = 0; ;
- break;}
-case 197:
-#line 648 "./ldgram.y"
-{ typebits = 0; ;
- break;}
-case 198:
-#line 649 "./ldgram.y"
-{ typebits = 0; ;
- break;}
-case 199:
-#line 650 "./ldgram.y"
-{ typebits = 0; ;
- break;}
-case 201:
-#line 655 "./ldgram.y"
-{ typebits = 0; ;
- break;}
-case 202:
-#line 660 "./ldgram.y"
-{ yyval.etree = yyvsp[-2].etree; ;;
- break;}
-case 203:
-#line 661 "./ldgram.y"
-{ yyval.etree= (etree_type *)NULL; ;
- break;}
-case 204:
-#line 666 "./ldgram.y"
-{ yyval.name = yyvsp[0].name; ;
- break;}
-case 205:
-#line 667 "./ldgram.y"
-{ yyval.name = "*default*"; ;
- break;}
-}
- /* the action file gets copied in in place of this dollarsign */
-#line 487 "/usr/unsupported/share/bison.simple"
-
- yyvsp -= yylen;
- yyssp -= yylen;
-#ifdef YYLSP_NEEDED
- yylsp -= yylen;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
- *++yyvsp = yyval;
-
-#ifdef YYLSP_NEEDED
- yylsp++;
- if (yylen == 0)
- {
- yylsp->first_line = yylloc.first_line;
- yylsp->first_column = yylloc.first_column;
- yylsp->last_line = (yylsp-1)->last_line;
- yylsp->last_column = (yylsp-1)->last_column;
- yylsp->text = 0;
- }
- else
- {
- yylsp->last_line = (yylsp+yylen-1)->last_line;
- yylsp->last_column = (yylsp+yylen-1)->last_column;
- }
-#endif
-
- /* Now "shift" the result of the reduction.
- Determine what state that goes to,
- based on the state we popped back to
- and the rule number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
- if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTBASE];
-
- goto yynewstate;
-
-yyerrlab: /* here on detecting error */
-
- if (! yyerrstatus)
- /* If not already recovering from an error, report this error. */
- {
- ++yynerrs;
-
-#ifdef YYERROR_VERBOSE
- yyn = yypact[yystate];
-
- if (yyn > YYFLAG && yyn < YYLAST)
- {
- int size = 0;
- char *msg;
- int x, count;
-
- count = 0;
- /* Start X at -yyn if nec to avoid negative indexes in yycheck. */
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- size += strlen(yytname[x]) + 15, count++;
- msg = (char *) malloc(size + 15);
- if (msg != 0)
- {
- strcpy(msg, "parse error");
-
- if (count < 5)
- {
- count = 0;
- for (x = (yyn < 0 ? -yyn : 0);
- x < (sizeof(yytname) / sizeof(char *)); x++)
- if (yycheck[x + yyn] == x)
- {
- strcat(msg, count == 0 ? ", expecting `" : " or `");
- strcat(msg, yytname[x]);
- strcat(msg, "'");
- count++;
- }
- }
- yyerror(msg);
- free(msg);
- }
- else
- yyerror ("parse error; also virtual memory exceeded");
- }
- else
-#endif /* YYERROR_VERBOSE */
- yyerror("parse error");
- }
-
- goto yyerrlab1;
-yyerrlab1: /* here on error raised explicitly by an action */
-
- if (yyerrstatus == 3)
- {
- /* if just tried and failed to reuse lookahead token after an error, discard it. */
-
- /* return failure if at end of input */
- if (yychar == YYEOF)
- YYABORT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
-#endif
-
- yychar = YYEMPTY;
- }
-
- /* Else will try to reuse lookahead token
- after shifting the error token. */
-
- yyerrstatus = 3; /* Each real token shifted decrements this */
-
- goto yyerrhandle;
-
-yyerrdefault: /* current state does not do anything special for the error token. */
-
-#if 0
- /* This is wrong; only states that explicitly want error tokens
- should shift them. */
- yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
- if (yyn) goto yydefault;
-#endif
-
-yyerrpop: /* pop the current state because it cannot handle the error token */
-
- if (yyssp == yyss) YYABORT;
- yyvsp--;
- yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
- yylsp--;
-#endif
-
-#if YYDEBUG != 0
- if (yydebug)
- {
- short *ssp1 = yyss - 1;
- fprintf (stderr, "Error: state stack now");
- while (ssp1 != yyssp)
- fprintf (stderr, " %d", *++ssp1);
- fprintf (stderr, "\n");
- }
-#endif
-
-yyerrhandle:
-
- yyn = yypact[yystate];
- if (yyn == YYFLAG)
- goto yyerrdefault;
-
- yyn += YYTERROR;
- if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
- goto yyerrdefault;
-
- yyn = yytable[yyn];
- if (yyn < 0)
- {
- if (yyn == YYFLAG)
- goto yyerrpop;
- yyn = -yyn;
- goto yyreduce;
- }
- else if (yyn == 0)
- goto yyerrpop;
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
-#if YYDEBUG != 0
- if (yydebug)
- fprintf(stderr, "Shifting error token, ");
-#endif
-
- *++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
- *++yylsp = yylloc;
-#endif
-
- yystate = yyn;
- goto yynewstate;
-}
-#line 669 "./ldgram.y"
-
-void
-yyerror(arg)
- const char *arg;
-{
- if (ldfile_assumed_script)
- einfo ("%P:%s: file format not recognized; treating as linker script\n",
- ldfile_input_filename);
- if (error_index > 0 && error_index < ERROR_NAME_MAX)
- einfo ("%P%F:%S: %s in %s\n", arg, error_names[error_index-1]);
- else
- einfo ("%P%F:%S: %s\n", arg);
-}
diff --git a/gnu/usr.bin/binutils/ld/ldgram.h b/gnu/usr.bin/binutils/ld/ldgram.h
deleted file mode 100644
index fb17b7797a0..00000000000
--- a/gnu/usr.bin/binutils/ld/ldgram.h
+++ /dev/null
@@ -1,94 +0,0 @@
-typedef union {
- bfd_vma integer;
- char *name;
- int token;
- union etree_union *etree;
-} YYSTYPE;
-#define INT 258
-#define NAME 259
-#define LNAME 260
-#define PLUSEQ 261
-#define MINUSEQ 262
-#define MULTEQ 263
-#define DIVEQ 264
-#define LSHIFTEQ 265
-#define RSHIFTEQ 266
-#define ANDEQ 267
-#define OREQ 268
-#define OROR 269
-#define ANDAND 270
-#define EQ 271
-#define NE 272
-#define LE 273
-#define GE 274
-#define LSHIFT 275
-#define RSHIFT 276
-#define UNARY 277
-#define END 278
-#define ALIGN_K 279
-#define BLOCK 280
-#define QUAD 281
-#define LONG 282
-#define SHORT 283
-#define BYTE 284
-#define SECTIONS 285
-#define SIZEOF_HEADERS 286
-#define OUTPUT_FORMAT 287
-#define FORCE_COMMON_ALLOCATION 288
-#define OUTPUT_ARCH 289
-#define INCLUDE 290
-#define MEMORY 291
-#define DEFSYMEND 292
-#define NOLOAD 293
-#define DSECT 294
-#define COPY 295
-#define INFO 296
-#define OVERLAY 297
-#define DEFINED 298
-#define TARGET_K 299
-#define SEARCH_DIR 300
-#define MAP 301
-#define ENTRY 302
-#define SIZEOF 303
-#define NEXT 304
-#define ADDR 305
-#define STARTUP 306
-#define HLL 307
-#define SYSLIB 308
-#define FLOAT 309
-#define NOFLOAT 310
-#define ORIGIN 311
-#define FILL 312
-#define LENGTH 313
-#define CREATE_OBJECT_SYMBOLS 314
-#define INPUT 315
-#define GROUP 316
-#define OUTPUT 317
-#define CONSTRUCTORS 318
-#define ALIGNMOD 319
-#define AT 320
-#define PROVIDE 321
-#define CHIP 322
-#define LIST 323
-#define SECT 324
-#define ABSOLUTE 325
-#define LOAD 326
-#define NEWLINE 327
-#define ENDWORD 328
-#define ORDER 329
-#define NAMEWORD 330
-#define FORMAT 331
-#define PUBLIC 332
-#define BASE 333
-#define ALIAS 334
-#define TRUNCATE 335
-#define REL 336
-#define INPUT_SCRIPT 337
-#define INPUT_MRI_SCRIPT 338
-#define INPUT_DEFSYM 339
-#define CASE 340
-#define EXTERN 341
-#define START 342
-
-
-extern YYSTYPE yylval;
diff --git a/gnu/usr.bin/binutils/ld/ldlex.c b/gnu/usr.bin/binutils/ld/ldlex.c
deleted file mode 100644
index 89483a13fa3..00000000000
--- a/gnu/usr.bin/binutils/ld/ldlex.c
+++ /dev/null
@@ -1,3270 +0,0 @@
-/* A lexical scanner generated by flex */
-
-/* Scanner skeleton version:
- * $Header: /home/cvs/src/gnu/usr.bin/binutils/ld/Attic/ldlex.c,v 1.1.1.1 1996/01/08 11:09:19 niklas Exp $
- */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 5
-
-#include <stdio.h>
-
-
-/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
-#ifdef c_plusplus
-#ifndef __cplusplus
-#define __cplusplus
-#endif
-#endif
-
-
-#ifdef __cplusplus
-
-#include <stdlib.h>
-#include <unistd.h>
-
-/* Use prototypes in function declarations. */
-#define YY_USE_PROTOS
-
-/* The "const" storage-class-modifier is valid. */
-#define YY_USE_CONST
-
-#else /* ! __cplusplus */
-
-#if __STDC__
-
-#define YY_USE_PROTOS
-#define YY_USE_CONST
-
-#endif /* __STDC__ */
-#endif /* ! __cplusplus */
-
-#ifdef __TURBOC__
- #pragma warn -rch
- #pragma warn -use
-#include <io.h>
-#include <stdlib.h>
-#define YY_USE_CONST
-#define YY_USE_PROTOS
-#endif
-
-#ifdef YY_USE_CONST
-#define yyconst const
-#else
-#define yyconst
-#endif
-
-
-#ifdef YY_USE_PROTOS
-#define YY_PROTO(proto) proto
-#else
-#define YY_PROTO(proto) ()
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an unsigned
- * integer for use as an array index. If the signed char is negative,
- * we want to instead treat it as an 8-bit unsigned char, hence the
- * double cast.
- */
-#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
-
-/* Enter a start condition. This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yy_start = 1 + 2 *
-
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state. The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yy_start - 1) / 2)
-#define YYSTATE YY_START
-
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin )
-
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#define YY_BUF_SIZE 16384
-
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-
-extern int yyleng;
-extern FILE *yyin, *yyout;
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
-/* The funky do-while in the following #define is used to turn the definition
- * int a single C statement (which needs a semi-colon terminator). This
- * avoids problems with code like:
- *
- * if ( condition_holds )
- * yyless( 5 );
- * else
- * do_something_else();
- *
- * Prior to using the do-while the compiler would get upset at the
- * "else" because it interpreted the "if" statement as being all
- * done when it reached the ';' after the yyless() call.
- */
-
-/* Return all but the first 'n' matched characters back to the input stream. */
-
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- *yy_cp = yy_hold_char; \
- yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- } \
- while ( 0 )
-
-#define unput(c) yyunput( c, yytext_ptr )
-
-/* The following is because we cannot portably get our hands on size_t
- * (without autoconf's help, which isn't available because we want
- * flex-generated scanners to compile on their own).
- */
-typedef unsigned int yy_size_t;
-
-
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- yy_size_t yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
- /* When an EOF's been seen but there's still some text to process
- * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- * shouldn't try reading from the input source any more. We might
- * still have a bunch of tokens to match, though, because of
- * possible backing-up.
- *
- * When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
- * just pointing yyin at a new input file.
- */
-#define YY_BUFFER_EOF_PENDING 2
- };
-
-static YY_BUFFER_STATE yy_current_buffer = 0;
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- */
-#define YY_CURRENT_BUFFER yy_current_buffer
-
-
-/* yy_hold_char holds the character lost when yytext is formed. */
-static char yy_hold_char;
-
-static int yy_n_chars; /* number of characters read into yy_ch_buf */
-
-
-int yyleng;
-
-/* Points to current character in buffer. */
-static char *yy_c_buf_p = (char *) 0;
-static int yy_init = 1; /* whether we need to initialize */
-static int yy_start = 0; /* start state number */
-
-/* Flag which is used to allow yywrap()'s to do buffer switches
- * instead of setting up a fresh yyin. A bit of a hack ...
- */
-static int yy_did_buffer_switch_on_eof;
-
-void yyrestart YY_PROTO(( FILE *input_file ));
-
-void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
-void yy_load_buffer_state YY_PROTO(( void ));
-YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
-void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
-void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-#define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
-
-YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
-YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *str ));
-YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
-
-static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
-static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
-static void yy_flex_free YY_PROTO(( void * ));
-
-#define yy_new_buffer yy_create_buffer
-
-#define yy_set_interactive(is_interactive) \
- { \
- if ( ! yy_current_buffer ) \
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
- yy_current_buffer->yy_is_interactive = is_interactive; \
- }
-
-#define yy_set_bol(at_bol) \
- { \
- if ( ! yy_current_buffer ) \
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
- yy_current_buffer->yy_at_bol = at_bol; \
- }
-
-#define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
-
-typedef unsigned char YY_CHAR;
-FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
-typedef int yy_state_type;
-extern char *yytext;
-#define yytext_ptr yytext
-
-static yy_state_type yy_get_previous_state YY_PROTO(( void ));
-static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
-static int yy_get_next_buffer YY_PROTO(( void ));
-static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
- yytext_ptr = yy_bp; \
- yyleng = (int) (yy_cp - yy_bp); \
- yy_hold_char = *yy_cp; \
- *yy_cp = '\0'; \
- yy_c_buf_p = yy_cp;
-
-#define YY_NUM_RULES 144
-#define YY_END_OF_BUFFER 145
-static yyconst short int yy_accept[895] =
- { 0,
- 0, 0, 137, 137, 0, 0, 0, 0, 0, 0,
- 0, 0, 145, 144, 142, 141, 139, 140, 32, 142,
- 137, 38, 29, 44, 43, 34, 35, 28, 36, 137,
- 37, 8, 8, 45, 46, 39, 40, 27, 33, 8,
- 8, 8, 8, 8, 8, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 10, 9, 8, 88,
- 86, 137, 42, 30, 41, 31, 143, 141, 140, 32,
- 143, 135, 38, 29, 44, 43, 34, 35, 28, 36,
- 135, 37, 8, 8, 45, 46, 39, 40, 27, 33,
- 8, 8, 8, 135, 135, 135, 10, 9, 8, 135,
-
- 42, 30, 41, 31, 135, 8, 8, 8, 8, 8,
- 8, 8, 8, 135, 135, 135, 135, 135, 135, 135,
- 135, 135, 135, 8, 8, 88, 86, 4, 3, 2,
- 4, 5, 4, 94, 95, 93, 134, 34, 35, 28,
- 36, 134, 37, 8, 8, 45, 46, 40, 8, 8,
- 8, 8, 8, 8, 134, 134, 134, 134, 134, 134,
- 10, 9, 8, 8, 8, 8, 8, 134, 134, 134,
- 134, 134, 134, 31, 15, 0, 138, 137, 8, 8,
- 26, 24, 22, 20, 21, 1, 23, 8, 137, 18,
- 17, 14, 16, 19, 8, 8, 137, 91, 137, 137,
-
- 137, 137, 8, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 8, 137,
- 137, 137, 25, 13, 135, 6, 6, 20, 21, 0,
- 23, 8, 7, 7, 8, 7, 14, 8, 7, 7,
- 7, 8, 135, 91, 7, 8, 135, 135, 135, 135,
- 7, 135, 8, 8, 8, 0, 8, 8, 135, 135,
- 135, 135, 8, 135, 135, 135, 135, 135, 135, 135,
- 135, 135, 135, 135, 135, 135, 135, 135, 135, 135,
- 135, 135, 135, 135, 135, 8, 135, 135, 4, 4,
-
- 4, 4, 93, 93, 134, 6, 6, 96, 22, 23,
- 97, 8, 7, 7, 7, 8, 134, 8, 8, 7,
- 134, 7, 7, 134, 134, 134, 134, 134, 134, 134,
- 134, 7, 134, 8, 8, 7, 134, 7, 7, 134,
- 134, 134, 134, 134, 134, 134, 134, 11, 12, 137,
- 8, 137, 137, 137, 137, 137, 137, 8, 137, 137,
- 137, 137, 137, 137, 73, 137, 137, 137, 137, 137,
- 57, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 89, 87,
- 137, 135, 136, 135, 7, 135, 8, 135, 135, 135,
-
- 135, 135, 135, 8, 135, 135, 135, 135, 135, 8,
- 135, 135, 135, 135, 135, 135, 73, 135, 135, 135,
- 135, 135, 57, 135, 135, 135, 135, 135, 135, 135,
- 135, 135, 135, 135, 135, 89, 87, 4, 93, 134,
- 134, 134, 134, 134, 134, 98, 134, 134, 134, 134,
- 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
- 134, 116, 134, 134, 134, 134, 134, 134, 134, 134,
- 134, 134, 137, 52, 137, 137, 79, 137, 83, 137,
- 137, 137, 137, 69, 137, 137, 137, 137, 84, 137,
- 137, 77, 137, 54, 137, 137, 137, 137, 137, 137,
-
- 76, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 135, 52, 135, 135, 54, 135, 135, 135, 135, 135,
- 135, 79, 135, 83, 135, 135, 135, 69, 135, 135,
- 135, 135, 84, 135, 135, 77, 135, 135, 135, 135,
- 135, 76, 135, 135, 135, 135, 135, 135, 8, 134,
- 134, 134, 102, 110, 101, 134, 134, 113, 105, 108,
- 134, 134, 114, 134, 134, 134, 134, 134, 120, 128,
- 119, 134, 134, 131, 123, 126, 134, 134, 132, 134,
- 134, 137, 51, 49, 137, 137, 137, 82, 53, 75,
- 137, 63, 137, 62, 137, 137, 137, 137, 137, 137,
-
- 137, 137, 137, 137, 78, 137, 137, 137, 137, 137,
- 137, 135, 51, 135, 135, 135, 135, 135, 135, 49,
- 135, 135, 82, 53, 75, 135, 63, 135, 62, 135,
- 135, 135, 135, 135, 135, 135, 135, 78, 135, 135,
- 135, 134, 103, 100, 134, 134, 113, 113, 107, 134,
- 112, 134, 134, 121, 118, 134, 134, 131, 131, 125,
- 134, 130, 134, 137, 137, 137, 137, 137, 137, 50,
- 47, 137, 81, 48, 61, 137, 137, 137, 137, 58,
- 137, 74, 59, 137, 137, 135, 135, 81, 135, 58,
- 135, 135, 135, 135, 135, 135, 50, 47, 135, 48,
-
- 61, 135, 135, 135, 135, 74, 59, 134, 134, 111,
- 109, 106, 134, 134, 134, 129, 127, 124, 134, 137,
- 137, 137, 64, 137, 90, 80, 137, 85, 92, 137,
- 137, 137, 70, 137, 137, 135, 64, 92, 135, 135,
- 135, 135, 135, 135, 90, 80, 135, 85, 135, 135,
- 70, 134, 134, 134, 134, 134, 134, 115, 137, 137,
- 137, 137, 137, 137, 68, 137, 133, 137, 115, 135,
- 133, 135, 135, 135, 135, 135, 135, 135, 68, 115,
- 99, 104, 133, 117, 122, 137, 137, 137, 137, 137,
- 137, 137, 137, 135, 135, 135, 135, 135, 135, 135,
-
- 135, 137, 137, 137, 137, 137, 60, 137, 137, 135,
- 135, 135, 135, 135, 135, 135, 60, 137, 137, 137,
- 72, 137, 137, 137, 135, 135, 135, 135, 135, 72,
- 135, 66, 137, 137, 137, 137, 137, 135, 135, 66,
- 135, 135, 135, 137, 137, 71, 137, 137, 135, 135,
- 135, 135, 71, 137, 137, 56, 55, 56, 55, 135,
- 135, 137, 137, 135, 135, 137, 137, 135, 135, 137,
- 137, 135, 135, 137, 137, 135, 135, 137, 137, 135,
- 135, 137, 137, 135, 135, 65, 137, 65, 135, 137,
- 135, 67, 67, 0
-
- } ;
-
-static yyconst int yy_ec[256] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
- 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 2, 5, 6, 7, 8, 9, 10, 1, 11,
- 12, 13, 14, 15, 16, 17, 18, 19, 20, 20,
- 20, 20, 20, 20, 20, 20, 20, 21, 22, 23,
- 24, 25, 26, 1, 27, 28, 29, 30, 31, 32,
- 33, 34, 35, 36, 37, 38, 39, 40, 41, 42,
- 43, 44, 45, 46, 47, 48, 17, 49, 50, 51,
- 52, 17, 53, 1, 54, 1, 55, 56, 57, 58,
-
- 59, 60, 61, 62, 63, 17, 64, 65, 66, 67,
- 68, 69, 17, 70, 71, 72, 73, 17, 17, 74,
- 17, 75, 76, 77, 78, 79, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1
- } ;
-
-static yyconst int yy_meta[80] =
- { 0,
- 1, 1, 2, 1, 1, 1, 1, 3, 1, 1,
- 1, 1, 1, 3, 4, 3, 5, 5, 6, 6,
- 3, 1, 1, 4, 1, 1, 6, 6, 6, 6,
- 6, 6, 5, 5, 5, 5, 6, 5, 6, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 3, 3, 5, 6, 6, 6, 6, 6, 6,
- 5, 5, 5, 6, 5, 6, 5, 5, 5, 5,
- 5, 5, 5, 6, 5, 1, 1, 1, 3
- } ;
-
-static yyconst short int yy_base[910] =
- { 0,
- 0, 0, 0, 0, 79, 0, 151, 0, 219, 0,
- 298, 0, 1628, 1629, 1629, 1629, 1629, 1629, 1603, 1620,
- 359, 1629, 150, 1629, 1629, 1601, 1600, 0, 1599, 0,
- 148, 401, 1548, 0, 1629, 139, 1597, 140, 1629, 365,
- 138, 125, 349, 127, 361, 1576, 1581, 1578, 146, 171,
- 162, 170, 1573, 1569, 391, 1588, 0, 0, 139, 1555,
- 1543, 1549, 1629, 357, 1629, 0, 1629, 1629, 1629, 1587,
- 1604, 457, 1629, 373, 1629, 1629, 1585, 1584, 1629, 377,
- 0, 191, 499, 1533, 1629, 1629, 361, 1582, 380, 1629,
- 555, 416, 417, 351, 1561, 1569, 1629, 1629, 436, 1540,
-
- 1629, 374, 1629, 0, 611, 431, 432, 504, 471, 558,
- 589, 485, 613, 1558, 1563, 1560, 369, 381, 412, 455,
- 1552, 626, 1571, 625, 541, 1538, 1526, 673, 1629, 1629,
- 0, 1629, 715, 1629, 1629, 1592, 763, 1570, 1569, 1629,
- 1568, 0, 1567, 0, 1516, 1629, 0, 1565, 805, 445,
- 473, 453, 541, 608, 372, 1561, 1543, 1539, 378, 1541,
- 1629, 1629, 560, 635, 656, 647, 538, 105, 1529, 1513,
- 1509, 377, 1511, 0, 1629, 1574, 1629, 0, 0, 1505,
- 1629, 1629, 1629, 0, 0, 1629, 0, 0, 643, 1554,
- 1629, 0, 1629, 1553, 405, 490, 1541, 0, 1534, 1528,
-
- 438, 1542, 420, 1541, 1525, 1532, 1528, 1524, 1526, 1528,
- 654, 1525, 1524, 1521, 1523, 1512, 507, 1525, 1513, 1527,
- 1516, 1529, 517, 1514, 1503, 1526, 1507, 1507, 529, 1483,
- 1488, 1473, 1629, 1629, 0, 861, 1473, 1629, 1629, 0,
- 0, 1472, 1471, 1629, 1629, 658, 1629, 710, 721, 730,
- 0, 0, 1509, 0, 750, 769, 1494, 1504, 1500, 1489,
- 770, 1464, 792, 791, 0, 0, 808, 864, 1497, 1491,
- 593, 1505, 865, 1504, 1488, 1495, 1491, 1487, 1489, 1491,
- 681, 1488, 1487, 1484, 1486, 515, 1489, 1477, 1491, 1494,
- 618, 1479, 1492, 1473, 1473, 868, 1449, 1454, 0, 1440,
-
- 0, 0, 1510, 1508, 0, 921, 1437, 0, 0, 1629,
- 0, 524, 670, 599, 0, 0, 1475, 840, 868, 1474,
- 1478, 1461, 1462, 1460, 1477, 1464, 1472, 1473, 1471, 1472,
- 1451, 698, 1434, 871, 884, 1433, 1437, 1422, 1423, 1421,
- 1436, 1424, 1431, 1432, 1430, 1431, 1412, 1629, 1629, 1443,
- 131, 1450, 1453, 1450, 1435, 1429, 1451, 653, 1448, 1432,
- 1437, 1447, 1444, 1425, 0, 1433, 1429, 1422, 1435, 1434,
- 0, 1425, 1419, 1426, 1422, 1429, 1419, 1416, 1411, 1428,
- 1413, 1406, 1402, 1409, 1390, 1386, 1385, 1346, 0, 0,
- 1322, 1361, 0, 1338, 926, 1345, 954, 1331, 1335, 1327,
-
- 1343, 1305, 1313, 924, 1342, 1339, 1324, 1318, 1340, 964,
- 1337, 1321, 1326, 1336, 1333, 1314, 0, 1322, 1318, 1311,
- 1324, 1323, 0, 1314, 1316, 1320, 1310, 1307, 1320, 1305,
- 1302, 1303, 1302, 1307, 1311, 0, 0, 748, 1629, 1012,
- 1302, 632, 1311, 1310, 1298, 0, 1308, 1299, 1291, 1306,
- 1304, 1303, 1295, 1281, 1282, 1285, 1256, 651, 1264, 1263,
- 1251, 0, 1255, 1243, 1231, 1244, 1242, 1241, 1234, 1226,
- 1227, 1229, 1257, 0, 1254, 1256, 0, 1246, 0, 1245,
- 1250, 1243, 1238, 0, 1241, 1255, 1243, 1237, 0, 1237,
- 1236, 0, 1237, 0, 1239, 1252, 1243, 1230, 1238, 1240,
-
- 0, 1245, 1238, 1226, 1230, 1224, 1234, 1237, 1202, 1198,
- 1227, 0, 1224, 1223, 0, 1235, 1226, 1219, 1194, 1190,
- 1220, 0, 1210, 0, 1209, 1203, 1198, 0, 1201, 1215,
- 1203, 1197, 0, 1196, 1190, 0, 1187, 1184, 1189, 1176,
- 1184, 0, 1192, 1185, 1173, 1172, 1182, 1185, 811, 1177,
- 1169, 1173, 0, 0, 0, 1168, 1184, 1072, 0, 0,
- 1166, 1174, 0, 1162, 1178, 1141, 1134, 1137, 0, 0,
- 0, 1133, 1147, 1150, 0, 0, 1131, 1137, 0, 1127,
- 1141, 1150, 0, 0, 1152, 1164, 1163, 0, 0, 0,
- 1139, 0, 1162, 0, 1157, 1140, 1162, 1158, 1147, 1140,
-
- 1158, 1154, 1149, 1141, 0, 1149, 1133, 1151, 1132, 1104,
- 1111, 1123, 0, 1138, 1138, 1137, 1134, 1091, 1098, 0,
- 1109, 1116, 0, 0, 0, 1092, 0, 1115, 0, 1110,
- 1093, 1115, 1101, 1094, 1112, 1104, 1096, 0, 1089, 1107,
- 1088, 1086, 0, 1093, 1091, 1084, 0, 1228, 0, 1100,
- 0, 1101, 1054, 0, 1060, 1058, 1052, 0, 1306, 0,
- 1066, 0, 1067, 1075, 1073, 1065, 1088, 1088, 1085, 0,
- 0, 1069, 0, 0, 1060, 1063, 1081, 1057, 1070, 1055,
- 1066, 0, 0, 1035, 1052, 1059, 1074, 0, 1072, 1048,
- 1029, 1046, 1052, 1039, 1063, 1060, 0, 0, 1044, 0,
-
- 1035, 1038, 1032, 1040, 1033, 0, 0, 1020, 1024, 0,
- 0, 0, 1018, 991, 994, 0, 0, 0, 989, 1029,
- 1030, 1017, 0, 1016, 0, 0, 693, 0, 0, 1026,
- 1010, 1020, 0, 994, 990, 1020, 0, 0, 1016, 990,
- 986, 1018, 1005, 1004, 0, 0, 723, 0, 1008, 992,
- 0, 1005, 1005, 1003, 974, 971, 968, 0, 980, 997,
- 985, 979, 981, 986, 0, 989, 0, 960, 0, 987,
- 0, 958, 970, 987, 975, 969, 971, 976, 0, 0,
- 0, 0, 0, 0, 0, 969, 973, 969, 978, 962,
- 961, 977, 947, 971, 942, 955, 958, 954, 962, 942,
-
- 931, 930, 942, 930, 935, 928, 0, 936, 907, 932,
- 901, 913, 916, 905, 911, 905, 0, 893, 908, 896,
- 0, 906, 895, 865, 892, 856, 869, 882, 870, 0,
- 881, 0, 154, 352, 381, 449, 501, 528, 521, 0,
- 563, 564, 610, 604, 647, 0, 633, 616, 654, 645,
- 665, 710, 0, 694, 703, 0, 0, 0, 0, 708,
- 719, 711, 724, 713, 726, 726, 736, 745, 745, 761,
- 773, 775, 775, 764, 779, 768, 786, 779, 780, 800,
- 794, 804, 816, 807, 824, 0, 829, 0, 835, 842,
- 846, 0, 0, 1629, 1384, 1390, 1394, 1398, 889, 1400,
-
- 1406, 1410, 1416, 1422, 1426, 1432, 1438, 1444, 1450
- } ;
-
-static yyconst short int yy_def[910] =
- { 0,
- 895, 895, 894, 3, 894, 5, 5, 7, 894, 9,
- 894, 11, 894, 894, 894, 894, 894, 894, 894, 896,
- 897, 894, 894, 894, 894, 894, 897, 897, 897, 897,
- 897, 897, 32, 897, 894, 894, 897, 894, 894, 32,
- 32, 32, 32, 32, 32, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 32, 897,
- 897, 897, 894, 894, 894, 897, 894, 894, 894, 894,
- 896, 898, 894, 894, 894, 894, 894, 894, 894, 894,
- 898, 898, 894, 83, 894, 894, 894, 894, 894, 894,
- 898, 91, 91, 898, 898, 898, 894, 894, 91, 898,
-
- 894, 894, 894, 898, 898, 899, 899, 105, 105, 105,
- 105, 105, 105, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 105, 105, 898, 898, 900, 894, 894,
- 900, 894, 900, 894, 894, 901, 902, 903, 894, 894,
- 894, 902, 902, 83, 83, 894, 904, 894, 902, 149,
- 149, 149, 149, 149, 902, 902, 902, 902, 902, 902,
- 894, 894, 149, 149, 149, 149, 149, 902, 902, 902,
- 902, 902, 902, 902, 894, 896, 894, 897, 32, 32,
- 894, 894, 894, 897, 897, 894, 897, 897, 32, 894,
- 894, 897, 894, 894, 32, 32, 897, 897, 897, 897,
-
- 897, 897, 32, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 32, 897,
- 897, 897, 894, 894, 898, 898, 236, 894, 894, 905,
- 898, 83, 83, 894, 894, 107, 894, 91, 91, 91,
- 898, 898, 898, 898, 91, 91, 898, 898, 898, 898,
- 91, 898, 105, 105, 107, 246, 105, 105, 898, 898,
- 898, 898, 105, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 105, 898, 898, 900, 133,
-
- 133, 900, 901, 894, 902, 902, 306, 903, 903, 894,
- 904, 149, 149, 149, 902, 902, 902, 149, 149, 902,
- 902, 902, 902, 902, 902, 902, 902, 902, 902, 902,
- 902, 149, 902, 149, 149, 902, 902, 902, 902, 902,
- 902, 902, 902, 902, 902, 902, 902, 894, 894, 897,
- 32, 897, 897, 897, 897, 897, 897, 32, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 105, 905, 898, 91, 898, 91, 898, 898, 898,
-
- 898, 898, 898, 105, 898, 898, 898, 898, 898, 105,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 133, 894, 902,
- 902, 902, 902, 902, 902, 902, 902, 902, 902, 902,
- 902, 902, 902, 902, 902, 902, 902, 902, 902, 902,
- 902, 902, 902, 902, 902, 902, 902, 902, 902, 902,
- 902, 902, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
-
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 440, 902,
- 902, 902, 902, 902, 902, 902, 902, 906, 902, 902,
- 902, 902, 902, 902, 902, 902, 902, 902, 902, 902,
- 902, 902, 902, 907, 902, 902, 902, 902, 902, 902,
- 902, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
-
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 902, 902, 902, 902, 902, 908, 906, 902, 902,
- 902, 902, 902, 902, 902, 902, 902, 909, 907, 902,
- 902, 902, 902, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
-
- 898, 898, 898, 898, 898, 898, 898, 902, 902, 902,
- 902, 902, 902, 902, 902, 902, 902, 902, 902, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 897, 897,
- 897, 897, 897, 897, 897, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 902, 902, 902, 902, 902, 902, 897, 897, 897,
- 897, 897, 897, 897, 897, 897, 897, 897, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898, 898, 902,
- 902, 902, 902, 902, 902, 897, 897, 897, 897, 897,
- 897, 897, 897, 898, 898, 898, 898, 898, 898, 898,
-
- 898, 897, 897, 897, 897, 897, 897, 897, 897, 898,
- 898, 898, 898, 898, 898, 898, 898, 897, 897, 897,
- 897, 897, 897, 897, 898, 898, 898, 898, 898, 898,
- 898, 897, 897, 897, 897, 897, 897, 898, 898, 898,
- 898, 898, 898, 897, 897, 897, 897, 897, 898, 898,
- 898, 898, 898, 897, 897, 897, 897, 898, 898, 898,
- 898, 897, 897, 898, 898, 897, 897, 898, 898, 897,
- 897, 898, 898, 897, 897, 898, 898, 897, 897, 898,
- 898, 897, 897, 898, 898, 897, 897, 898, 898, 897,
- 898, 897, 898, 0, 894, 894, 894, 894, 894, 894,
-
- 894, 894, 894, 894, 894, 894, 894, 894, 894
- } ;
-
-static yyconst short int yy_nxt[1709] =
- { 0,
- 15, 16, 17, 18, 19, 20, 15, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31, 32, 33,
- 34, 35, 36, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, 46, 47, 48, 30, 30, 49, 50, 51,
- 52, 53, 54, 30, 55, 56, 30, 30, 30, 30,
- 30, 57, 58, 30, 59, 33, 33, 33, 33, 33,
- 30, 30, 30, 30, 60, 30, 30, 61, 30, 30,
- 62, 30, 30, 30, 30, 63, 64, 65, 66, 67,
- 68, 17, 69, 70, 71, 67, 72, 73, 74, 75,
- 76, 77, 78, 79, 80, 81, 82, 83, 84, 85,
-
- 86, 87, 88, 89, 90, 91, 92, 92, 93, 92,
- 92, 81, 81, 81, 81, 81, 81, 81, 94, 81,
- 95, 81, 81, 96, 81, 81, 81, 81, 81, 81,
- 97, 98, 81, 99, 92, 92, 92, 92, 92, 81,
- 81, 81, 81, 81, 81, 81, 81, 81, 81, 100,
- 81, 81, 81, 81, 101, 102, 103, 104, 105, 181,
- 186, 190, 191, 193, 194, 201, 205, 340, 202, 106,
- 107, 187, 341, 182, 474, 199, 212, 108, 109, 110,
- 111, 112, 113, 114, 115, 116, 213, 200, 117, 118,
- 119, 120, 216, 121, 229, 122, 123, 214, 178, 844,
-
- 178, 215, 217, 186, 178, 124, 125, 125, 125, 125,
- 125, 178, 178, 218, 241, 126, 219, 220, 127, 67,
- 67, 14, 67, 67, 67, 67, 128, 67, 67, 67,
- 67, 67, 129, 67, 130, 131, 131, 106, 107, 67,
- 67, 67, 132, 67, 67, 133, 133, 133, 133, 133,
- 133, 131, 131, 131, 131, 131, 131, 131, 131, 131,
- 131, 131, 131, 131, 131, 131, 131, 131, 131, 131,
- 67, 67, 131, 133, 133, 133, 133, 133, 133, 131,
- 131, 131, 131, 131, 131, 131, 131, 131, 131, 131,
- 131, 131, 131, 131, 67, 67, 67, 131, 15, 16,
-
- 134, 135, 19, 15, 136, 137, 22, 23, 24, 25,
- 138, 139, 140, 141, 142, 143, 144, 145, 146, 147,
- 36, 148, 38, 39, 149, 150, 151, 152, 153, 154,
- 142, 142, 142, 142, 142, 155, 142, 156, 157, 158,
- 142, 142, 159, 160, 142, 142, 142, 142, 142, 161,
- 162, 142, 163, 164, 165, 152, 166, 167, 142, 142,
- 142, 142, 168, 142, 169, 170, 171, 142, 172, 173,
- 142, 142, 142, 63, 64, 65, 174, 179, 180, 203,
- 233, 257, 181, 190, 191, 180, 180, 180, 180, 180,
- 180, 258, 195, 204, 196, 206, 182, 233, 207, 282,
-
- 239, 208, 197, 193, 194, 845, 324, 284, 329, 283,
- 198, 285, 325, 180, 180, 180, 180, 180, 180, 180,
- 180, 223, 178, 330, 224, 225, 846, 180, 180, 180,
- 180, 180, 180, 234, 178, 345, 226, 188, 178, 188,
- 227, 240, 257, 255, 255, 255, 255, 256, 346, 350,
- 234, 358, 286, 235, 235, 180, 180, 180, 180, 180,
- 180, 235, 235, 255, 188, 255, 188, 245, 245, 245,
- 245, 318, 314, 235, 189, 236, 237, 355, 178, 356,
- 314, 235, 305, 237, 237, 237, 237, 237, 237, 264,
- 305, 261, 847, 178, 245, 245, 245, 245, 287, 319,
-
- 314, 288, 289, 264, 266, 894, 320, 252, 269, 252,
- 305, 237, 237, 237, 237, 237, 237, 242, 242, 351,
- 270, 252, 264, 252, 275, 242, 243, 242, 243, 242,
- 242, 267, 244, 268, 252, 245, 252, 245, 374, 244,
- 252, 253, 252, 381, 375, 382, 425, 244, 252, 254,
- 252, 314, 399, 242, 243, 242, 243, 242, 242, 264,
- 244, 305, 245, 178, 245, 314, 244, 252, 314, 252,
- 848, 849, 246, 248, 248, 305, 264, 252, 305, 252,
- 321, 248, 249, 248, 250, 248, 248, 314, 251, 322,
- 850, 252, 253, 252, 252, 251, 252, 305, 271, 388,
-
- 254, 272, 178, 251, 252, 339, 252, 264, 851, 248,
- 255, 248, 255, 248, 248, 332, 251, 852, 252, 273,
- 252, 252, 251, 252, 333, 252, 314, 252, 251, 263,
- 264, 264, 407, 274, 408, 314, 305, 264, 264, 264,
- 264, 264, 264, 264, 430, 305, 431, 276, 323, 252,
- 277, 252, 252, 278, 252, 853, 291, 854, 551, 292,
- 260, 252, 314, 252, 552, 264, 264, 264, 264, 264,
- 264, 293, 305, 855, 314, 294, 252, 856, 252, 178,
- 296, 178, 366, 314, 305, 367, 857, 481, 252, 334,
- 252, 300, 301, 305, 894, 368, 894, 314, 858, 301,
-
- 301, 301, 301, 301, 301, 567, 178, 305, 178, 418,
- 335, 568, 419, 337, 441, 859, 178, 336, 860, 762,
- 338, 894, 420, 894, 763, 314, 178, 301, 301, 301,
- 301, 301, 301, 301, 301, 305, 861, 255, 862, 255,
- 863, 301, 301, 301, 301, 301, 301, 235, 255, 776,
- 255, 302, 864, 302, 777, 235, 865, 255, 235, 395,
- 866, 867, 868, 869, 870, 394, 235, 235, 457, 301,
- 301, 301, 301, 301, 301, 235, 871, 255, 302, 255,
- 302, 306, 307, 872, 299, 873, 299, 235, 874, 307,
- 307, 307, 307, 307, 307, 235, 255, 255, 255, 255,
-
- 397, 875, 876, 877, 878, 879, 235, 235, 880, 264,
- 264, 299, 881, 299, 235, 235, 882, 307, 307, 307,
- 307, 307, 307, 312, 312, 883, 264, 252, 252, 252,
- 252, 312, 313, 312, 314, 312, 312, 884, 315, 885,
- 402, 316, 317, 316, 252, 315, 252, 316, 886, 316,
- 887, 888, 394, 315, 252, 252, 252, 252, 889, 312,
- 314, 312, 314, 312, 312, 392, 315, 314, 316, 890,
- 316, 252, 315, 252, 316, 891, 316, 305, 315, 237,
- 237, 892, 264, 264, 443, 893, 264, 237, 237, 237,
- 237, 237, 237, 404, 265, 314, 410, 252, 314, 252,
-
- 252, 252, 252, 252, 252, 305, 252, 843, 305, 842,
- 841, 314, 444, 840, 839, 237, 237, 237, 237, 237,
- 237, 305, 838, 837, 252, 836, 252, 252, 252, 252,
- 252, 252, 835, 252, 392, 834, 833, 832, 402, 307,
- 307, 459, 264, 831, 830, 829, 828, 307, 307, 307,
- 307, 307, 307, 255, 460, 255, 827, 316, 826, 316,
- 252, 825, 252, 235, 824, 823, 822, 512, 821, 512,
- 820, 235, 819, 818, 817, 307, 307, 307, 307, 307,
- 307, 255, 264, 255, 316, 816, 316, 252, 514, 252,
- 815, 235, 814, 813, 440, 812, 811, 810, 514, 235,
-
- 252, 809, 252, 808, 807, 806, 805, 804, 803, 802,
- 801, 800, 799, 798, 797, 796, 795, 794, 793, 792,
- 791, 790, 789, 788, 787, 786, 785, 252, 784, 252,
- 549, 549, 783, 782, 781, 780, 779, 778, 549, 549,
- 549, 549, 549, 549, 775, 774, 773, 772, 771, 770,
- 769, 768, 767, 766, 765, 764, 761, 760, 759, 758,
- 757, 756, 755, 754, 753, 752, 549, 549, 549, 549,
- 549, 549, 647, 647, 751, 647, 647, 647, 647, 750,
- 647, 647, 647, 647, 647, 749, 647, 748, 747, 746,
- 745, 744, 743, 647, 647, 647, 647, 647, 742, 741,
-
- 740, 739, 738, 737, 736, 735, 734, 733, 732, 731,
- 730, 729, 728, 727, 726, 725, 724, 723, 722, 721,
- 720, 719, 718, 717, 716, 715, 714, 713, 712, 711,
- 710, 709, 708, 707, 706, 705, 704, 703, 702, 701,
- 700, 699, 698, 697, 696, 695, 694, 647, 647, 647,
- 658, 658, 693, 658, 658, 658, 658, 692, 658, 658,
- 658, 658, 658, 691, 658, 690, 689, 688, 687, 686,
- 685, 658, 658, 658, 658, 658, 684, 683, 682, 681,
- 680, 679, 678, 677, 676, 675, 674, 673, 672, 671,
- 670, 669, 668, 667, 666, 665, 664, 663, 662, 661,
-
- 660, 657, 656, 655, 654, 653, 652, 651, 650, 649,
- 646, 645, 644, 643, 642, 641, 640, 639, 638, 637,
- 636, 635, 634, 633, 632, 658, 658, 658, 647, 647,
- 631, 647, 647, 647, 647, 630, 647, 647, 647, 647,
- 647, 629, 647, 628, 627, 626, 625, 624, 623, 647,
- 647, 647, 647, 647, 622, 621, 620, 619, 618, 617,
- 616, 615, 614, 613, 612, 611, 610, 609, 608, 607,
- 606, 605, 604, 603, 602, 601, 600, 599, 598, 597,
- 596, 595, 594, 593, 592, 591, 590, 589, 588, 587,
- 586, 585, 584, 583, 582, 581, 580, 579, 578, 577,
-
- 576, 575, 574, 647, 647, 647, 658, 658, 573, 658,
- 658, 658, 658, 572, 658, 658, 658, 658, 658, 571,
- 658, 570, 569, 566, 565, 564, 563, 658, 658, 658,
- 658, 658, 562, 561, 560, 559, 558, 557, 556, 555,
- 554, 553, 550, 548, 547, 546, 545, 544, 543, 542,
- 541, 540, 539, 538, 537, 536, 535, 534, 533, 532,
- 531, 530, 529, 528, 527, 526, 525, 524, 523, 522,
- 521, 520, 519, 518, 517, 516, 515, 513, 511, 264,
- 510, 658, 658, 658, 14, 14, 14, 14, 14, 14,
- 176, 176, 176, 176, 176, 176, 178, 178, 178, 178,
-
- 235, 235, 235, 235, 299, 299, 303, 303, 303, 303,
- 303, 303, 305, 509, 305, 305, 308, 508, 308, 308,
- 308, 308, 311, 507, 311, 311, 311, 311, 393, 393,
- 393, 393, 648, 506, 648, 648, 648, 648, 659, 505,
- 659, 659, 659, 659, 647, 504, 647, 647, 647, 647,
- 658, 503, 658, 658, 658, 658, 502, 501, 500, 499,
- 498, 497, 496, 495, 494, 493, 492, 491, 490, 489,
- 488, 487, 486, 485, 484, 483, 482, 480, 479, 478,
- 477, 476, 475, 473, 472, 471, 470, 469, 468, 467,
- 466, 465, 464, 463, 462, 461, 458, 456, 455, 454,
-
- 453, 452, 451, 450, 449, 448, 447, 446, 445, 442,
- 305, 439, 304, 438, 437, 436, 435, 434, 433, 432,
- 429, 428, 427, 426, 424, 423, 422, 421, 417, 416,
- 415, 414, 413, 412, 411, 409, 406, 405, 403, 401,
- 400, 399, 398, 396, 244, 244, 235, 391, 390, 389,
- 387, 386, 385, 384, 383, 380, 379, 378, 377, 376,
- 373, 372, 371, 370, 369, 365, 364, 363, 362, 361,
- 360, 359, 357, 354, 353, 352, 349, 348, 178, 177,
- 347, 344, 343, 342, 331, 328, 327, 326, 247, 244,
- 310, 239, 238, 309, 304, 298, 297, 295, 290, 281,
-
- 280, 279, 262, 260, 259, 247, 244, 238, 183, 177,
- 175, 232, 231, 230, 228, 222, 221, 211, 210, 209,
- 192, 178, 185, 184, 183, 177, 175, 894, 13, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
-
- 894, 894, 894, 894, 894, 894, 894, 894
- } ;
-
-static yyconst short int yy_chk[1709] =
- { 0,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
-
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
- 5, 5, 5, 5, 5, 5, 5, 5, 7, 23,
- 31, 36, 36, 38, 38, 42, 44, 168, 42, 7,
- 7, 31, 168, 23, 351, 41, 49, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 49, 41, 7, 7,
- 7, 7, 51, 7, 59, 7, 7, 50, 42, 833,
-
- 44, 50, 51, 82, 351, 7, 7, 7, 7, 7,
- 7, 41, 59, 52, 82, 7, 52, 52, 7, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 11, 11,
-
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 21, 21, 43,
- 64, 94, 74, 87, 87, 21, 21, 21, 21, 21,
- 21, 94, 40, 43, 40, 45, 74, 102, 45, 117,
-
- 80, 45, 40, 89, 89, 834, 155, 118, 159, 117,
- 40, 118, 155, 21, 21, 21, 21, 21, 21, 32,
- 32, 55, 43, 159, 55, 55, 835, 32, 32, 32,
- 32, 32, 32, 64, 45, 172, 55, 32, 40, 32,
- 55, 80, 119, 92, 93, 92, 93, 93, 172, 195,
- 102, 203, 119, 92, 93, 32, 32, 32, 32, 32,
- 32, 92, 93, 99, 32, 99, 32, 106, 107, 106,
- 107, 150, 150, 99, 32, 72, 72, 201, 195, 201,
- 152, 99, 150, 72, 72, 72, 72, 72, 72, 109,
- 152, 99, 836, 203, 106, 107, 106, 107, 120, 151,
-
- 151, 120, 120, 112, 106, 107, 151, 109, 109, 109,
- 151, 72, 72, 72, 72, 72, 72, 83, 83, 196,
- 109, 112, 108, 112, 112, 83, 83, 83, 83, 83,
- 83, 108, 83, 108, 109, 83, 109, 83, 217, 83,
- 108, 108, 108, 223, 217, 223, 286, 83, 112, 108,
- 112, 312, 286, 83, 83, 83, 83, 83, 83, 125,
- 83, 312, 83, 196, 83, 167, 83, 108, 153, 108,
- 837, 838, 83, 91, 91, 167, 110, 125, 153, 125,
- 153, 91, 91, 91, 91, 91, 91, 163, 91, 153,
- 839, 91, 91, 91, 110, 91, 110, 163, 110, 229,
-
- 91, 110, 229, 91, 125, 167, 125, 111, 841, 91,
- 91, 91, 91, 91, 91, 163, 91, 842, 91, 111,
- 91, 110, 91, 110, 163, 111, 314, 111, 91, 105,
- 105, 113, 271, 111, 271, 154, 314, 105, 105, 105,
- 105, 105, 105, 124, 291, 154, 291, 113, 154, 113,
- 113, 113, 111, 113, 111, 843, 122, 844, 442, 122,
- 122, 124, 164, 124, 442, 105, 105, 105, 105, 105,
- 105, 122, 164, 845, 166, 122, 113, 847, 113, 189,
- 124, 189, 211, 165, 166, 211, 848, 358, 124, 164,
- 124, 128, 128, 165, 246, 211, 246, 313, 849, 128,
-
- 128, 128, 128, 128, 128, 458, 189, 313, 189, 281,
- 165, 458, 281, 166, 313, 850, 189, 165, 851, 727,
- 166, 246, 281, 246, 727, 332, 358, 128, 128, 128,
- 128, 128, 128, 133, 133, 332, 852, 248, 854, 248,
- 855, 133, 133, 133, 133, 133, 133, 248, 249, 747,
- 249, 133, 860, 133, 747, 248, 861, 250, 249, 250,
- 862, 863, 864, 865, 866, 249, 249, 250, 332, 133,
- 133, 133, 133, 133, 133, 250, 867, 255, 133, 255,
- 133, 137, 137, 868, 438, 869, 438, 255, 870, 137,
- 137, 137, 137, 137, 137, 255, 256, 261, 256, 261,
-
- 256, 871, 872, 873, 874, 875, 256, 261, 876, 264,
- 263, 438, 877, 438, 256, 261, 878, 137, 137, 137,
- 137, 137, 137, 149, 149, 879, 267, 264, 263, 264,
- 263, 149, 149, 149, 149, 149, 149, 880, 149, 881,
- 261, 149, 149, 149, 267, 149, 267, 549, 882, 549,
- 883, 884, 267, 149, 264, 263, 264, 263, 885, 149,
- 149, 149, 149, 149, 149, 263, 149, 318, 149, 887,
- 149, 267, 149, 267, 549, 889, 549, 318, 149, 236,
- 236, 890, 268, 273, 318, 891, 296, 236, 236, 236,
- 236, 236, 236, 268, 899, 319, 273, 236, 334, 236,
-
- 268, 273, 268, 273, 296, 319, 296, 831, 334, 829,
- 828, 335, 319, 827, 826, 236, 236, 236, 236, 236,
- 236, 335, 825, 824, 236, 823, 236, 268, 273, 268,
- 273, 296, 822, 296, 236, 820, 819, 818, 296, 306,
- 306, 334, 404, 816, 815, 814, 813, 306, 306, 306,
- 306, 306, 306, 395, 335, 395, 812, 306, 811, 306,
- 404, 810, 404, 395, 809, 808, 806, 404, 805, 395,
- 804, 395, 803, 802, 801, 306, 306, 306, 306, 306,
- 306, 397, 410, 397, 306, 800, 306, 404, 397, 404,
- 799, 397, 798, 797, 306, 796, 795, 794, 410, 397,
-
- 410, 793, 410, 792, 791, 790, 789, 788, 787, 786,
- 778, 777, 776, 775, 774, 773, 772, 770, 768, 766,
- 764, 763, 762, 761, 760, 759, 757, 410, 756, 410,
- 440, 440, 755, 754, 753, 752, 750, 749, 440, 440,
- 440, 440, 440, 440, 744, 743, 742, 741, 740, 739,
- 736, 735, 734, 732, 731, 730, 724, 722, 721, 720,
- 719, 715, 714, 713, 709, 708, 440, 440, 440, 440,
- 440, 440, 558, 558, 705, 558, 558, 558, 558, 704,
- 558, 558, 558, 558, 558, 703, 558, 702, 701, 699,
- 696, 695, 694, 558, 558, 558, 558, 558, 693, 692,
-
- 691, 690, 689, 687, 686, 685, 684, 681, 680, 679,
- 678, 677, 676, 675, 672, 669, 668, 667, 666, 665,
- 664, 663, 661, 657, 656, 655, 653, 652, 650, 646,
- 645, 644, 642, 641, 640, 639, 637, 636, 635, 634,
- 633, 632, 631, 630, 628, 626, 622, 558, 558, 558,
- 574, 574, 621, 574, 574, 574, 574, 619, 574, 574,
- 574, 574, 574, 618, 574, 617, 616, 615, 614, 612,
- 611, 574, 574, 574, 574, 574, 610, 609, 608, 607,
- 606, 604, 603, 602, 601, 600, 599, 598, 597, 596,
- 595, 593, 591, 587, 586, 585, 582, 581, 580, 578,
-
- 577, 573, 572, 568, 567, 566, 565, 564, 562, 561,
- 557, 556, 552, 551, 550, 548, 547, 546, 545, 544,
- 543, 541, 540, 539, 538, 574, 574, 574, 648, 648,
- 537, 648, 648, 648, 648, 535, 648, 648, 648, 648,
- 648, 534, 648, 532, 531, 530, 529, 527, 526, 648,
- 648, 648, 648, 648, 525, 523, 521, 520, 519, 518,
- 517, 516, 514, 513, 511, 510, 509, 508, 507, 506,
- 505, 504, 503, 502, 500, 499, 498, 497, 496, 495,
- 493, 491, 490, 488, 487, 486, 485, 483, 482, 481,
- 480, 478, 476, 475, 473, 472, 471, 470, 469, 468,
-
- 467, 466, 465, 648, 648, 648, 659, 659, 464, 659,
- 659, 659, 659, 463, 659, 659, 659, 659, 659, 461,
- 659, 460, 459, 457, 456, 455, 454, 659, 659, 659,
- 659, 659, 453, 452, 451, 450, 449, 448, 447, 445,
- 444, 443, 441, 435, 434, 433, 432, 431, 430, 429,
- 428, 427, 426, 425, 424, 422, 421, 420, 419, 418,
- 416, 415, 414, 413, 412, 411, 409, 408, 407, 406,
- 405, 403, 402, 401, 400, 399, 398, 396, 394, 392,
- 391, 659, 659, 659, 895, 895, 895, 895, 895, 895,
- 896, 896, 896, 896, 896, 896, 897, 897, 897, 897,
-
- 898, 898, 898, 898, 900, 900, 901, 901, 901, 901,
- 901, 901, 902, 388, 902, 902, 903, 387, 903, 903,
- 903, 903, 904, 386, 904, 904, 904, 904, 905, 905,
- 905, 905, 906, 385, 906, 906, 906, 906, 907, 384,
- 907, 907, 907, 907, 908, 383, 908, 908, 908, 908,
- 909, 382, 909, 909, 909, 909, 381, 380, 379, 378,
- 377, 376, 375, 374, 373, 372, 370, 369, 368, 367,
- 366, 364, 363, 362, 361, 360, 359, 357, 356, 355,
- 354, 353, 352, 350, 347, 346, 345, 344, 343, 342,
- 341, 340, 339, 338, 337, 336, 333, 331, 330, 329,
-
- 328, 327, 326, 325, 324, 323, 322, 321, 320, 317,
- 307, 304, 303, 300, 298, 297, 295, 294, 293, 292,
- 290, 289, 288, 287, 285, 284, 283, 282, 280, 279,
- 278, 277, 276, 275, 274, 272, 270, 269, 262, 260,
- 259, 258, 257, 253, 243, 242, 237, 232, 231, 230,
- 228, 227, 226, 225, 224, 222, 221, 220, 219, 218,
- 216, 215, 214, 213, 212, 210, 209, 208, 207, 206,
- 205, 204, 202, 200, 199, 197, 194, 190, 180, 176,
- 173, 171, 170, 169, 160, 158, 157, 156, 148, 145,
- 143, 141, 139, 138, 136, 127, 126, 123, 121, 116,
-
- 115, 114, 100, 96, 95, 88, 84, 78, 77, 71,
- 70, 62, 61, 60, 56, 54, 53, 48, 47, 46,
- 37, 33, 29, 27, 26, 20, 19, 13, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
- 894, 894, 894, 894, 894, 894, 894, 894, 894, 894,
-
- 894, 894, 894, 894, 894, 894, 894, 894
- } ;
-
-static yy_state_type yy_last_accepting_state;
-static char *yy_last_accepting_cpos;
-
-/* The intent behind this definition is that it'll catch
- * any uses of REJECT which flex missed.
- */
-#define REJECT reject_used_but_not_detected
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-char *yytext;
-#line 1 "./ldlex.l"
-#define INITIAL 0
-#line 2 "./ldlex.l"
-
-/* Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
-
-This file is part of GLD, the Gnu Linker.
-
-GLD is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GLD is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GLD; see the file COPYING. If not, write to
-the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-/*
-This was written by steve chamberlain
- sac@cygnus.com
-*/
-
-
-#include <ansidecl.h>
-#include <stdio.h>
-#include <ctype.h>
-
-#ifdef MPW
-/* Prevent enum redefinition problems. */
-#define TRUE_FALSE_ALREADY_DEFINED
-#endif /* MPW */
-
-#include "bfd.h"
-#include "sysdep.h"
-#include "ld.h"
-#include "ldgram.h"
-#include "ldmisc.h"
-#include "ldexp.h"
-#include "ldlang.h"
-#include "ldfile.h"
-#include "ldlex.h"
-#include "ldmain.h"
-
-/* The type of top-level parser input.
- yylex and yyparse (indirectly) both check this. */
-input_type parser_input;
-
-/* Radix to use for bfd_scan_vma -- 0 (default to base 10) or 16. */
-int hex_mode;
-
-/* Line number in the current input file.
- (FIXME Actually, it doesn't appear to get reset for each file?) */
-unsigned int lineno = 1;
-
-/* The string we are currently lexing, or NULL if we are reading a
- file. */
-const char *lex_string = NULL;
-
-/* Support for flex reading from more than one input file (stream).
- `include_stack' is flex's input state for each open file;
- `file_name_stack' is the file names. `lineno_stack' is the current
- line numbers.
-
- If `include_stack_ptr' is 0, we haven't started reading anything yet.
- Otherwise, stack elements 0 through `include_stack_ptr - 1' are valid. */
-
-#undef YY_INPUT
-#define YY_INPUT(buf,result,max_size) yy_input(buf, &result, max_size)
-
-#define MAX_INCLUDE_DEPTH 10
-static YY_BUFFER_STATE include_stack[MAX_INCLUDE_DEPTH];
-static const char *file_name_stack[MAX_INCLUDE_DEPTH];
-static unsigned int lineno_stack[MAX_INCLUDE_DEPTH];
-static unsigned int include_stack_ptr = 0;
-
-static YY_BUFFER_STATE yy_create_string_buffer PARAMS ((const char *string,
- size_t size));
-static void yy_input PARAMS ((char *, int *result, int max_size));
-
-static void comment PARAMS ((void));
-static void lex_warn_invalid PARAMS ((char *where, char *what));
-
-/* STATES
- EXPRESSION definitely in an expression
- SCRIPT definitely in a script
- BOTH either EXPRESSION or SCRIPT
- DEFSYMEXP in an argument to -defsym
- MRI in an MRI script
-*/
-#define RTOKEN(x) { yylval.token = x; return x; }
-
-/* Some versions of flex want this. */
-#ifndef yywrap
-int yywrap () { return 1; }
-#endif
-#define SCRIPT 1
-
-#define EXPRESSION 2
-
-#define BOTH 3
-
-#define DEFSYMEXP 4
-
-#define MRI 5
-
-#line 1146 "lex.yy.c"
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap YY_PROTO(( void ));
-#else
-extern int yywrap YY_PROTO(( void ));
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-static void yyunput YY_PROTO(( int c, char *buf_ptr ));
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput YY_PROTO(( void ));
-#else
-static int input YY_PROTO(( void ));
-#endif
-#endif
-
-#if YY_STACK_USED
-static int yy_start_stack_ptr = 0;
-static int yy_start_stack_depth = 0;
-static int *yy_start_stack = 0;
-#ifndef YY_NO_PUSH_STATE
-static void yy_push_state YY_PROTO(( int new_state ));
-#endif
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state YY_PROTO(( void ));
-#endif
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state YY_PROTO(( void ));
-#endif
-
-#else
-#define YY_NO_PUSH_STATE 1
-#define YY_NO_POP_STATE 1
-#define YY_NO_TOP_STATE 1
-#endif
-
-#ifdef YY_MALLOC_DECL
-YY_MALLOC_DECL
-#else
-#if __STDC__
-#ifndef __cplusplus
-#include <stdlib.h>
-#endif
-#else
-/* Just try to get by without declaring the routines. This will fail
- * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
- * or sizeof(void*) != sizeof(int).
- */
-#endif
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#define YY_READ_BUF_SIZE 8192
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
-#endif
-
-/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
- if ( yy_current_buffer->yy_is_interactive ) \
- { \
- int c = '*', n; \
- for ( n = 0; n < max_size && \
- (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
- buf[n] = (char) c; \
- if ( c == '\n' ) \
- buf[n++] = (char) c; \
- if ( c == EOF && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- result = n; \
- } \
- else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
- && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" );
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL int yylex YY_PROTO(( void ))
-#endif
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK break;
-#endif
-
-#define YY_RULE_SETUP \
- YY_USER_ACTION
-
-YY_DECL
- {
- register yy_state_type yy_current_state;
- register char *yy_cp, *yy_bp;
- register int yy_act;
-
-#line 120 "./ldlex.l"
-
-
- if (parser_input != input_selected)
- {
- /* The first token of the input determines the initial parser state. */
- input_type t = parser_input;
- parser_input = input_selected;
- switch (t)
- {
- case input_script: return INPUT_SCRIPT; break;
- case input_mri_script: return INPUT_MRI_SCRIPT; break;
- case input_defsym: return INPUT_DEFSYM; break;
- default: abort ();
- }
- }
-
-#line 1310 "lex.yy.c"
-
- if ( yy_init )
- {
- yy_init = 0;
-
-#ifdef YY_USER_INIT
- YY_USER_INIT;
-#endif
-
- if ( ! yy_start )
- yy_start = 1; /* first start state */
-
- if ( ! yyin )
- yyin = stdin;
-
- if ( ! yyout )
- yyout = stdout;
-
- if ( ! yy_current_buffer )
- yy_current_buffer =
- yy_create_buffer( yyin, YY_BUF_SIZE );
-
- yy_load_buffer_state();
- }
-
- while ( 1 ) /* loops until end-of-file is reached */
- {
- yy_cp = yy_c_buf_p;
-
- /* Support of yytext. */
- *yy_cp = yy_hold_char;
-
- /* yy_bp points to the position in yy_ch_buf of the start of
- * the current run.
- */
- yy_bp = yy_cp;
-
- yy_current_state = yy_start;
-yy_match:
- do
- {
- register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 895 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- ++yy_cp;
- }
- while ( yy_base[yy_current_state] != 1629 );
-
-yy_find_action:
- yy_act = yy_accept[yy_current_state];
- if ( yy_act == 0 )
- { /* have to back up */
- yy_cp = yy_last_accepting_cpos;
- yy_current_state = yy_last_accepting_state;
- yy_act = yy_accept[yy_current_state];
- }
-
- YY_DO_BEFORE_ACTION;
-
-
-do_action: /* This label is used only to access EOF actions. */
-
-
- switch ( yy_act )
- { /* beginning of action switch */
- case 0: /* must back up */
- /* undo the effects of YY_DO_BEFORE_ACTION */
- *yy_cp = yy_hold_char;
- yy_cp = yy_last_accepting_cpos;
- yy_current_state = yy_last_accepting_state;
- goto yy_find_action;
-
-case 1:
-YY_RULE_SETUP
-#line 136 "./ldlex.l"
-{ comment(); }
- YY_BREAK
-case 2:
-YY_RULE_SETUP
-#line 139 "./ldlex.l"
-{ RTOKEN('-');}
- YY_BREAK
-case 3:
-YY_RULE_SETUP
-#line 140 "./ldlex.l"
-{ RTOKEN('+');}
- YY_BREAK
-case 4:
-YY_RULE_SETUP
-#line 141 "./ldlex.l"
-{ yylval.name = buystring(yytext); return NAME; }
- YY_BREAK
-case 5:
-YY_RULE_SETUP
-#line 142 "./ldlex.l"
-{ RTOKEN('='); }
- YY_BREAK
-case 6:
-YY_RULE_SETUP
-#line 144 "./ldlex.l"
-{
- yylval.integer = bfd_scan_vma (yytext+1, 0,16);
- return INT;
- }
- YY_BREAK
-case 7:
-YY_RULE_SETUP
-#line 149 "./ldlex.l"
-{
- int ibase ;
- switch (yytext[yyleng-1]) {
- case 'X':
- case 'x':
- case 'H':
- case 'h':
- ibase = 16;
- break;
- case 'O':
- case 'o':
- ibase = 8;
- break;
- case 'B':
- case 'b':
- ibase = 2;
- break;
- default:
- ibase = 10;
- }
- yylval.integer = bfd_scan_vma (yytext, 0,
- ibase);
- return INT;
- }
- YY_BREAK
-case 8:
-YY_RULE_SETUP
-#line 173 "./ldlex.l"
-{
- yylval.integer = bfd_scan_vma (yytext, 0,
- hex_mode);
- if (yytext[yyleng-1]=='M'
- || yytext[yyleng-1] == 'm') {
- yylval.integer *= 1024*1024;
- }
- if (yytext[yyleng-1]=='K'
- || yytext[yyleng-1]=='k') {
- yylval.integer *= 1024;
- }
- return INT;
- }
- YY_BREAK
-case 9:
-YY_RULE_SETUP
-#line 186 "./ldlex.l"
-{ RTOKEN(']');}
- YY_BREAK
-case 10:
-YY_RULE_SETUP
-#line 187 "./ldlex.l"
-{ RTOKEN('[');}
- YY_BREAK
-case 11:
-YY_RULE_SETUP
-#line 188 "./ldlex.l"
-{ RTOKEN(LSHIFTEQ);}
- YY_BREAK
-case 12:
-YY_RULE_SETUP
-#line 189 "./ldlex.l"
-{ RTOKEN(RSHIFTEQ);}
- YY_BREAK
-case 13:
-YY_RULE_SETUP
-#line 190 "./ldlex.l"
-{ RTOKEN(OROR);}
- YY_BREAK
-case 14:
-YY_RULE_SETUP
-#line 191 "./ldlex.l"
-{ RTOKEN(EQ);}
- YY_BREAK
-case 15:
-YY_RULE_SETUP
-#line 192 "./ldlex.l"
-{ RTOKEN(NE);}
- YY_BREAK
-case 16:
-YY_RULE_SETUP
-#line 193 "./ldlex.l"
-{ RTOKEN(GE);}
- YY_BREAK
-case 17:
-YY_RULE_SETUP
-#line 194 "./ldlex.l"
-{ RTOKEN(LE);}
- YY_BREAK
-case 18:
-YY_RULE_SETUP
-#line 195 "./ldlex.l"
-{ RTOKEN(LSHIFT);}
- YY_BREAK
-case 19:
-YY_RULE_SETUP
-#line 196 "./ldlex.l"
-{ RTOKEN(RSHIFT);}
- YY_BREAK
-case 20:
-YY_RULE_SETUP
-#line 197 "./ldlex.l"
-{ RTOKEN(PLUSEQ);}
- YY_BREAK
-case 21:
-YY_RULE_SETUP
-#line 198 "./ldlex.l"
-{ RTOKEN(MINUSEQ);}
- YY_BREAK
-case 22:
-YY_RULE_SETUP
-#line 199 "./ldlex.l"
-{ RTOKEN(MULTEQ);}
- YY_BREAK
-case 23:
-YY_RULE_SETUP
-#line 200 "./ldlex.l"
-{ RTOKEN(DIVEQ);}
- YY_BREAK
-case 24:
-YY_RULE_SETUP
-#line 201 "./ldlex.l"
-{ RTOKEN(ANDEQ);}
- YY_BREAK
-case 25:
-YY_RULE_SETUP
-#line 202 "./ldlex.l"
-{ RTOKEN(OREQ);}
- YY_BREAK
-case 26:
-YY_RULE_SETUP
-#line 203 "./ldlex.l"
-{ RTOKEN(ANDAND);}
- YY_BREAK
-case 27:
-YY_RULE_SETUP
-#line 204 "./ldlex.l"
-{ RTOKEN('>');}
- YY_BREAK
-case 28:
-YY_RULE_SETUP
-#line 205 "./ldlex.l"
-{ RTOKEN(',');}
- YY_BREAK
-case 29:
-YY_RULE_SETUP
-#line 206 "./ldlex.l"
-{ RTOKEN('&');}
- YY_BREAK
-case 30:
-YY_RULE_SETUP
-#line 207 "./ldlex.l"
-{ RTOKEN('|');}
- YY_BREAK
-case 31:
-YY_RULE_SETUP
-#line 208 "./ldlex.l"
-{ RTOKEN('~');}
- YY_BREAK
-case 32:
-YY_RULE_SETUP
-#line 209 "./ldlex.l"
-{ RTOKEN('!');}
- YY_BREAK
-case 33:
-YY_RULE_SETUP
-#line 210 "./ldlex.l"
-{ RTOKEN('?');}
- YY_BREAK
-case 34:
-YY_RULE_SETUP
-#line 211 "./ldlex.l"
-{ RTOKEN('*');}
- YY_BREAK
-case 35:
-YY_RULE_SETUP
-#line 212 "./ldlex.l"
-{ RTOKEN('+');}
- YY_BREAK
-case 36:
-YY_RULE_SETUP
-#line 213 "./ldlex.l"
-{ RTOKEN('-');}
- YY_BREAK
-case 37:
-YY_RULE_SETUP
-#line 214 "./ldlex.l"
-{ RTOKEN('/');}
- YY_BREAK
-case 38:
-YY_RULE_SETUP
-#line 215 "./ldlex.l"
-{ RTOKEN('%');}
- YY_BREAK
-case 39:
-YY_RULE_SETUP
-#line 216 "./ldlex.l"
-{ RTOKEN('<');}
- YY_BREAK
-case 40:
-YY_RULE_SETUP
-#line 217 "./ldlex.l"
-{ RTOKEN('=');}
- YY_BREAK
-case 41:
-YY_RULE_SETUP
-#line 218 "./ldlex.l"
-{ RTOKEN('}') ; }
- YY_BREAK
-case 42:
-YY_RULE_SETUP
-#line 219 "./ldlex.l"
-{ RTOKEN('{'); }
- YY_BREAK
-case 43:
-YY_RULE_SETUP
-#line 220 "./ldlex.l"
-{ RTOKEN(')');}
- YY_BREAK
-case 44:
-YY_RULE_SETUP
-#line 221 "./ldlex.l"
-{ RTOKEN('(');}
- YY_BREAK
-case 45:
-YY_RULE_SETUP
-#line 222 "./ldlex.l"
-{ RTOKEN(':'); }
- YY_BREAK
-case 46:
-YY_RULE_SETUP
-#line 223 "./ldlex.l"
-{ RTOKEN(';');}
- YY_BREAK
-case 47:
-YY_RULE_SETUP
-#line 224 "./ldlex.l"
-{ RTOKEN(MEMORY);}
- YY_BREAK
-case 48:
-YY_RULE_SETUP
-#line 225 "./ldlex.l"
-{ RTOKEN(ORIGIN);}
- YY_BREAK
-case 49:
-YY_RULE_SETUP
-#line 226 "./ldlex.l"
-{ RTOKEN(BLOCK);}
- YY_BREAK
-case 50:
-YY_RULE_SETUP
-#line 227 "./ldlex.l"
-{ RTOKEN(LENGTH);}
- YY_BREAK
-case 51:
-YY_RULE_SETUP
-#line 228 "./ldlex.l"
-{ RTOKEN(ALIGN_K);}
- YY_BREAK
-case 52:
-YY_RULE_SETUP
-#line 229 "./ldlex.l"
-{ RTOKEN(ADDR);}
- YY_BREAK
-case 53:
-YY_RULE_SETUP
-#line 230 "./ldlex.l"
-{ RTOKEN(ENTRY);}
- YY_BREAK
-case 54:
-YY_RULE_SETUP
-#line 231 "./ldlex.l"
-{ RTOKEN(NEXT);}
- YY_BREAK
-case 55:
-YY_RULE_SETUP
-#line 232 "./ldlex.l"
-{ RTOKEN(SIZEOF_HEADERS);}
- YY_BREAK
-case 56:
-YY_RULE_SETUP
-#line 233 "./ldlex.l"
-{ RTOKEN(SIZEOF_HEADERS);}
- YY_BREAK
-case 57:
-YY_RULE_SETUP
-#line 234 "./ldlex.l"
-{ RTOKEN(MAP);}
- YY_BREAK
-case 58:
-YY_RULE_SETUP
-#line 235 "./ldlex.l"
-{ RTOKEN(SIZEOF);}
- YY_BREAK
-case 59:
-YY_RULE_SETUP
-#line 236 "./ldlex.l"
-{ RTOKEN(TARGET_K);}
- YY_BREAK
-case 60:
-YY_RULE_SETUP
-#line 237 "./ldlex.l"
-{ RTOKEN(SEARCH_DIR);}
- YY_BREAK
-case 61:
-YY_RULE_SETUP
-#line 238 "./ldlex.l"
-{ RTOKEN(OUTPUT);}
- YY_BREAK
-case 62:
-YY_RULE_SETUP
-#line 239 "./ldlex.l"
-{ RTOKEN(INPUT);}
- YY_BREAK
-case 63:
-YY_RULE_SETUP
-#line 240 "./ldlex.l"
-{ RTOKEN(GROUP);}
- YY_BREAK
-case 64:
-YY_RULE_SETUP
-#line 241 "./ldlex.l"
-{ RTOKEN(DEFINED);}
- YY_BREAK
-case 65:
-YY_RULE_SETUP
-#line 242 "./ldlex.l"
-{ RTOKEN(CREATE_OBJECT_SYMBOLS);}
- YY_BREAK
-case 66:
-YY_RULE_SETUP
-#line 243 "./ldlex.l"
-{ RTOKEN( CONSTRUCTORS);}
- YY_BREAK
-case 67:
-YY_RULE_SETUP
-#line 244 "./ldlex.l"
-{ RTOKEN(FORCE_COMMON_ALLOCATION);}
- YY_BREAK
-case 68:
-YY_RULE_SETUP
-#line 245 "./ldlex.l"
-{ RTOKEN(SECTIONS);}
- YY_BREAK
-case 69:
-YY_RULE_SETUP
-#line 246 "./ldlex.l"
-{ RTOKEN(FILL);}
- YY_BREAK
-case 70:
-YY_RULE_SETUP
-#line 247 "./ldlex.l"
-{ RTOKEN(STARTUP);}
- YY_BREAK
-case 71:
-YY_RULE_SETUP
-#line 248 "./ldlex.l"
-{ RTOKEN(OUTPUT_FORMAT);}
- YY_BREAK
-case 72:
-YY_RULE_SETUP
-#line 249 "./ldlex.l"
-{ RTOKEN( OUTPUT_ARCH);}
- YY_BREAK
-case 73:
-YY_RULE_SETUP
-#line 250 "./ldlex.l"
-{ RTOKEN(HLL);}
- YY_BREAK
-case 74:
-YY_RULE_SETUP
-#line 251 "./ldlex.l"
-{ RTOKEN(SYSLIB);}
- YY_BREAK
-case 75:
-YY_RULE_SETUP
-#line 252 "./ldlex.l"
-{ RTOKEN(FLOAT);}
- YY_BREAK
-case 76:
-YY_RULE_SETUP
-#line 253 "./ldlex.l"
-{ RTOKEN( QUAD);}
- YY_BREAK
-case 77:
-YY_RULE_SETUP
-#line 254 "./ldlex.l"
-{ RTOKEN( LONG);}
- YY_BREAK
-case 78:
-YY_RULE_SETUP
-#line 255 "./ldlex.l"
-{ RTOKEN( SHORT);}
- YY_BREAK
-case 79:
-YY_RULE_SETUP
-#line 256 "./ldlex.l"
-{ RTOKEN( BYTE);}
- YY_BREAK
-case 80:
-YY_RULE_SETUP
-#line 257 "./ldlex.l"
-{ RTOKEN(NOFLOAT);}
- YY_BREAK
-case 81:
-YY_RULE_SETUP
-#line 258 "./ldlex.l"
-{ RTOKEN(NOLOAD);}
- YY_BREAK
-case 82:
-YY_RULE_SETUP
-#line 259 "./ldlex.l"
-{ RTOKEN(DSECT);}
- YY_BREAK
-case 83:
-YY_RULE_SETUP
-#line 260 "./ldlex.l"
-{ RTOKEN(COPY);}
- YY_BREAK
-case 84:
-YY_RULE_SETUP
-#line 261 "./ldlex.l"
-{ RTOKEN(INFO);}
- YY_BREAK
-case 85:
-YY_RULE_SETUP
-#line 262 "./ldlex.l"
-{ RTOKEN(OVERLAY);}
- YY_BREAK
-case 86:
-YY_RULE_SETUP
-#line 263 "./ldlex.l"
-{ RTOKEN(ORIGIN);}
- YY_BREAK
-case 87:
-YY_RULE_SETUP
-#line 264 "./ldlex.l"
-{ RTOKEN(ORIGIN);}
- YY_BREAK
-case 88:
-YY_RULE_SETUP
-#line 265 "./ldlex.l"
-{ RTOKEN( LENGTH);}
- YY_BREAK
-case 89:
-YY_RULE_SETUP
-#line 266 "./ldlex.l"
-{ RTOKEN( LENGTH);}
- YY_BREAK
-case 90:
-YY_RULE_SETUP
-#line 267 "./ldlex.l"
-{ RTOKEN(INCLUDE);}
- YY_BREAK
-case 91:
-YY_RULE_SETUP
-#line 268 "./ldlex.l"
-{ RTOKEN(AT);}
- YY_BREAK
-case 92:
-YY_RULE_SETUP
-#line 269 "./ldlex.l"
-{ RTOKEN(PROVIDE); }
- YY_BREAK
-case 93:
-YY_RULE_SETUP
-#line 270 "./ldlex.l"
-{ ++ lineno; }
- YY_BREAK
-case 94:
-YY_RULE_SETUP
-#line 271 "./ldlex.l"
-{ ++ lineno; RTOKEN(NEWLINE); }
- YY_BREAK
-case 95:
-YY_RULE_SETUP
-#line 272 "./ldlex.l"
-{ ++ lineno; RTOKEN(NEWLINE); }
- YY_BREAK
-case 96:
-YY_RULE_SETUP
-#line 273 "./ldlex.l"
-{ /* Mri comment line */ }
- YY_BREAK
-case 97:
-YY_RULE_SETUP
-#line 274 "./ldlex.l"
-{ /* Mri comment line */ }
- YY_BREAK
-case 98:
-YY_RULE_SETUP
-#line 275 "./ldlex.l"
-{ RTOKEN(ENDWORD); }
- YY_BREAK
-case 99:
-YY_RULE_SETUP
-#line 276 "./ldlex.l"
-{ RTOKEN(ALIGNMOD);}
- YY_BREAK
-case 100:
-YY_RULE_SETUP
-#line 277 "./ldlex.l"
-{ RTOKEN(ALIGN_K);}
- YY_BREAK
-case 101:
-YY_RULE_SETUP
-#line 278 "./ldlex.l"
-{ RTOKEN(CHIP); }
- YY_BREAK
-case 102:
-YY_RULE_SETUP
-#line 279 "./ldlex.l"
-{ RTOKEN(BASE); }
- YY_BREAK
-case 103:
-YY_RULE_SETUP
-#line 280 "./ldlex.l"
-{ RTOKEN(ALIAS); }
- YY_BREAK
-case 104:
-YY_RULE_SETUP
-#line 281 "./ldlex.l"
-{ RTOKEN(TRUNCATE); }
- YY_BREAK
-case 105:
-YY_RULE_SETUP
-#line 282 "./ldlex.l"
-{ RTOKEN(LOAD); }
- YY_BREAK
-case 106:
-YY_RULE_SETUP
-#line 283 "./ldlex.l"
-{ RTOKEN(PUBLIC); }
- YY_BREAK
-case 107:
-YY_RULE_SETUP
-#line 284 "./ldlex.l"
-{ RTOKEN(ORDER); }
- YY_BREAK
-case 108:
-YY_RULE_SETUP
-#line 285 "./ldlex.l"
-{ RTOKEN(NAMEWORD); }
- YY_BREAK
-case 109:
-YY_RULE_SETUP
-#line 286 "./ldlex.l"
-{ RTOKEN(FORMAT); }
- YY_BREAK
-case 110:
-YY_RULE_SETUP
-#line 287 "./ldlex.l"
-{ RTOKEN(CASE); }
- YY_BREAK
-case 111:
-YY_RULE_SETUP
-#line 288 "./ldlex.l"
-{ RTOKEN(EXTERN); }
- YY_BREAK
-case 112:
-YY_RULE_SETUP
-#line 289 "./ldlex.l"
-{ RTOKEN(START); }
- YY_BREAK
-case 113:
-YY_RULE_SETUP
-#line 290 "./ldlex.l"
-{ RTOKEN(LIST); /* LIST and ignore to end of line */ }
- YY_BREAK
-case 114:
-YY_RULE_SETUP
-#line 291 "./ldlex.l"
-{ RTOKEN(SECT); }
- YY_BREAK
-case 115:
-YY_RULE_SETUP
-#line 292 "./ldlex.l"
-{ RTOKEN(ABSOLUTE); }
- YY_BREAK
-case 116:
-YY_RULE_SETUP
-#line 293 "./ldlex.l"
-{ RTOKEN(ENDWORD); }
- YY_BREAK
-case 117:
-YY_RULE_SETUP
-#line 294 "./ldlex.l"
-{ RTOKEN(ALIGNMOD);}
- YY_BREAK
-case 118:
-YY_RULE_SETUP
-#line 295 "./ldlex.l"
-{ RTOKEN(ALIGN_K);}
- YY_BREAK
-case 119:
-YY_RULE_SETUP
-#line 296 "./ldlex.l"
-{ RTOKEN(CHIP); }
- YY_BREAK
-case 120:
-YY_RULE_SETUP
-#line 297 "./ldlex.l"
-{ RTOKEN(BASE); }
- YY_BREAK
-case 121:
-YY_RULE_SETUP
-#line 298 "./ldlex.l"
-{ RTOKEN(ALIAS); }
- YY_BREAK
-case 122:
-YY_RULE_SETUP
-#line 299 "./ldlex.l"
-{ RTOKEN(TRUNCATE); }
- YY_BREAK
-case 123:
-YY_RULE_SETUP
-#line 300 "./ldlex.l"
-{ RTOKEN(LOAD); }
- YY_BREAK
-case 124:
-YY_RULE_SETUP
-#line 301 "./ldlex.l"
-{ RTOKEN(PUBLIC); }
- YY_BREAK
-case 125:
-YY_RULE_SETUP
-#line 302 "./ldlex.l"
-{ RTOKEN(ORDER); }
- YY_BREAK
-case 126:
-YY_RULE_SETUP
-#line 303 "./ldlex.l"
-{ RTOKEN(NAMEWORD); }
- YY_BREAK
-case 127:
-YY_RULE_SETUP
-#line 304 "./ldlex.l"
-{ RTOKEN(FORMAT); }
- YY_BREAK
-case 128:
-YY_RULE_SETUP
-#line 305 "./ldlex.l"
-{ RTOKEN(CASE); }
- YY_BREAK
-case 129:
-YY_RULE_SETUP
-#line 306 "./ldlex.l"
-{ RTOKEN(EXTERN); }
- YY_BREAK
-case 130:
-YY_RULE_SETUP
-#line 307 "./ldlex.l"
-{ RTOKEN(START); }
- YY_BREAK
-case 131:
-YY_RULE_SETUP
-#line 308 "./ldlex.l"
-{ RTOKEN(LIST); /* LIST and ignore to end of line */ }
- YY_BREAK
-case 132:
-YY_RULE_SETUP
-#line 309 "./ldlex.l"
-{ RTOKEN(SECT); }
- YY_BREAK
-case 133:
-YY_RULE_SETUP
-#line 310 "./ldlex.l"
-{ RTOKEN(ABSOLUTE); }
- YY_BREAK
-case 134:
-YY_RULE_SETUP
-#line 312 "./ldlex.l"
-{
-/* Filename without commas, needed to parse mri stuff */
- yylval.name = buystring(yytext);
- return NAME;
- }
- YY_BREAK
-case 135:
-YY_RULE_SETUP
-#line 319 "./ldlex.l"
-{
- yylval.name = buystring(yytext);
- return NAME;
- }
- YY_BREAK
-case 136:
-YY_RULE_SETUP
-#line 323 "./ldlex.l"
-{
- yylval.name = buystring (yytext + 2);
- return LNAME;
- }
- YY_BREAK
-case 137:
-YY_RULE_SETUP
-#line 327 "./ldlex.l"
-{ yylval.name = buystring(yytext);
- return NAME;
- }
- YY_BREAK
-case 138:
-YY_RULE_SETUP
-#line 331 "./ldlex.l"
-{
- /* No matter the state, quotes
- give what's inside */
- yylval.name = buystring(yytext+1);
- yylval.name[yyleng-2] = 0;
- return NAME;
- }
- YY_BREAK
-case 139:
-YY_RULE_SETUP
-#line 338 "./ldlex.l"
-{ lineno++;}
- YY_BREAK
-case 140:
-YY_RULE_SETUP
-#line 339 "./ldlex.l"
-{ lineno++;}
- YY_BREAK
-case 141:
-YY_RULE_SETUP
-#line 340 "./ldlex.l"
-
- YY_BREAK
-case YY_STATE_EOF(INITIAL):
-case YY_STATE_EOF(SCRIPT):
-case YY_STATE_EOF(EXPRESSION):
-case YY_STATE_EOF(BOTH):
-case YY_STATE_EOF(DEFSYMEXP):
-case YY_STATE_EOF(MRI):
-#line 342 "./ldlex.l"
-{
- include_stack_ptr--;
-
- if (include_stack_ptr == 0)
- {
- yyterminate();
- }
- else
- {
- yy_switch_to_buffer(include_stack[include_stack_ptr]);
-
- }
- BEGIN(SCRIPT);
- ldfile_input_filename = file_name_stack[include_stack_ptr - 1];
- lineno = lineno_stack[include_stack_ptr - 1];
-
- return END;
-}
- YY_BREAK
-case 142:
-YY_RULE_SETUP
-#line 361 "./ldlex.l"
-lex_warn_invalid(" in script", yytext);
- YY_BREAK
-case 143:
-YY_RULE_SETUP
-#line 362 "./ldlex.l"
-lex_warn_invalid(" in expression", yytext);
- YY_BREAK
-case 144:
-YY_RULE_SETUP
-#line 364 "./ldlex.l"
-ECHO;
- YY_BREAK
-#line 2195 "lex.yy.c"
-
- case YY_END_OF_BUFFER:
- {
- /* Amount of text matched not including the EOB char. */
- int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
-
- /* Undo the effects of YY_DO_BEFORE_ACTION. */
- *yy_cp = yy_hold_char;
-
- if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
- {
- /* We're scanning a new file or input source. It's
- * possible that this happened because the user
- * just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
- * consistency between yy_current_buffer and our
- * globals. Here is the right place to do so, because
- * this is the first action (other than possibly a
- * back-up) that will match for the new input source.
- */
- yy_n_chars = yy_current_buffer->yy_n_chars;
- yy_current_buffer->yy_input_file = yyin;
- yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
- }
-
- /* Note that here we test for yy_c_buf_p "<=" to the position
- * of the first EOB in the buffer, since yy_c_buf_p will
- * already have been incremented past the NUL character
- * (since all states make transitions on EOB to the
- * end-of-buffer state). Contrast this with the test
- * in input().
- */
- if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- { /* This was really a NUL. */
- yy_state_type yy_next_state;
-
- yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state();
-
- /* Okay, we're now positioned to make the NUL
- * transition. We couldn't have
- * yy_get_previous_state() go ahead and do it
- * for us because it doesn't know how to deal
- * with the possibility of jamming (and we don't
- * want to build jamming into it because then it
- * will run more slowly).
- */
-
- yy_next_state = yy_try_NUL_trans( yy_current_state );
-
- yy_bp = yytext_ptr + YY_MORE_ADJ;
-
- if ( yy_next_state )
- {
- /* Consume the NUL. */
- yy_cp = ++yy_c_buf_p;
- yy_current_state = yy_next_state;
- goto yy_match;
- }
-
- else
- {
- yy_cp = yy_c_buf_p;
- goto yy_find_action;
- }
- }
-
- else switch ( yy_get_next_buffer() )
- {
- case EOB_ACT_END_OF_FILE:
- {
- yy_did_buffer_switch_on_eof = 0;
-
- if ( yywrap() )
- {
- /* Note: because we've taken care in
- * yy_get_next_buffer() to have set up
- * yytext, we can now set up
- * yy_c_buf_p so that if some total
- * hoser (like flex itself) wants to
- * call the scanner after we return the
- * YY_NULL, it'll still work - another
- * YY_NULL will get returned.
- */
- yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
-
- yy_act = YY_STATE_EOF(YY_START);
- goto do_action;
- }
-
- else
- {
- if ( ! yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
- }
- break;
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yy_c_buf_p =
- yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state();
-
- yy_cp = yy_c_buf_p;
- yy_bp = yytext_ptr + YY_MORE_ADJ;
- goto yy_match;
-
- case EOB_ACT_LAST_MATCH:
- yy_c_buf_p =
- &yy_current_buffer->yy_ch_buf[yy_n_chars];
-
- yy_current_state = yy_get_previous_state();
-
- yy_cp = yy_c_buf_p;
- yy_bp = yytext_ptr + YY_MORE_ADJ;
- goto yy_find_action;
- }
- break;
- }
-
- default:
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--no action found" );
- } /* end of action switch */
- } /* end of scanning one token */
- } /* end of yylex */
-
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- * EOB_ACT_LAST_MATCH -
- * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- * EOB_ACT_END_OF_FILE - end of file
- */
-
-static int yy_get_next_buffer()
- {
- register char *dest = yy_current_buffer->yy_ch_buf;
- register char *source = yytext_ptr;
- register int number_to_move, i;
- int ret_val;
-
- if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--end of buffer missed" );
-
- if ( yy_current_buffer->yy_fill_buffer == 0 )
- { /* Don't try to fill the buffer, so this is an EOF. */
- if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
- {
- /* We matched a singled characater, the EOB, so
- * treat this as a final EOF.
- */
- return EOB_ACT_END_OF_FILE;
- }
-
- else
- {
- /* We matched some text prior to the EOB, first
- * process it.
- */
- return EOB_ACT_LAST_MATCH;
- }
- }
-
- /* Try to read more data. */
-
- /* First move last chars to start of buffer. */
- number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
-
- for ( i = 0; i < number_to_move; ++i )
- *(dest++) = *(source++);
-
- if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
- /* don't do the read, it's not guaranteed to return an EOF,
- * just force an EOF
- */
- yy_n_chars = 0;
-
- else
- {
- int num_to_read =
- yy_current_buffer->yy_buf_size - number_to_move - 1;
-
- while ( num_to_read <= 0 )
- { /* Not enough room in the buffer - grow it. */
-#ifdef YY_USES_REJECT
- YY_FATAL_ERROR(
-"input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
-#else
-
- /* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = yy_current_buffer;
-
- int yy_c_buf_p_offset =
- (int) (yy_c_buf_p - b->yy_ch_buf);
-
- if ( b->yy_is_our_buffer )
- {
- int new_size = b->yy_buf_size * 2;
-
- if ( new_size <= 0 )
- b->yy_buf_size += b->yy_buf_size / 8;
- else
- b->yy_buf_size *= 2;
-
- b->yy_ch_buf = (char *)
- /* Include room in for 2 EOB chars. */
- yy_flex_realloc( (void *) b->yy_ch_buf,
- b->yy_buf_size + 2 );
- }
- else
- /* Can't grow it, we don't own it. */
- b->yy_ch_buf = 0;
-
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR(
- "fatal error - scanner input buffer overflow" );
-
- yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
- num_to_read = yy_current_buffer->yy_buf_size -
- number_to_move - 1;
-#endif
- }
-
- if ( num_to_read > YY_READ_BUF_SIZE )
- num_to_read = YY_READ_BUF_SIZE;
-
- /* Read in more data. */
- YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
- yy_n_chars, num_to_read );
- }
-
- if ( yy_n_chars == 0 )
- {
- if ( number_to_move == YY_MORE_ADJ )
- {
- ret_val = EOB_ACT_END_OF_FILE;
- yyrestart( yyin );
- }
-
- else
- {
- ret_val = EOB_ACT_LAST_MATCH;
- yy_current_buffer->yy_buffer_status =
- YY_BUFFER_EOF_PENDING;
- }
- }
-
- else
- ret_val = EOB_ACT_CONTINUE_SCAN;
-
- yy_n_chars += number_to_move;
- yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
- yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
-
- return ret_val;
- }
-
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-static yy_state_type yy_get_previous_state()
- {
- register yy_state_type yy_current_state;
- register char *yy_cp;
-
- yy_current_state = yy_start;
-
- for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
- {
- register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 895 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- }
-
- return yy_current_state;
- }
-
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- * next_state = yy_try_NUL_trans( current_state );
- */
-
-#ifdef YY_USE_PROTOS
-static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
-#else
-static yy_state_type yy_try_NUL_trans( yy_current_state )
-yy_state_type yy_current_state;
-#endif
- {
- register int yy_is_jam;
- register char *yy_cp = yy_c_buf_p;
-
- register YY_CHAR yy_c = 1;
- if ( yy_accept[yy_current_state] )
- {
- yy_last_accepting_state = yy_current_state;
- yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 895 )
- yy_c = yy_meta[(unsigned int) yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- yy_is_jam = (yy_current_state == 894);
-
- return yy_is_jam ? 0 : yy_current_state;
- }
-
-
-#ifndef YY_NO_UNPUT
-#ifdef YY_USE_PROTOS
-static void yyunput( int c, register char *yy_bp )
-#else
-static void yyunput( c, yy_bp )
-int c;
-register char *yy_bp;
-#endif
- {
- register char *yy_cp = yy_c_buf_p;
-
- /* undo effects of setting up yytext */
- *yy_cp = yy_hold_char;
-
- if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- { /* need to shift things up to make room */
- /* +2 for EOB chars. */
- register int number_to_move = yy_n_chars + 2;
- register char *dest = &yy_current_buffer->yy_ch_buf[
- yy_current_buffer->yy_buf_size + 2];
- register char *source =
- &yy_current_buffer->yy_ch_buf[number_to_move];
-
- while ( source > yy_current_buffer->yy_ch_buf )
- *--dest = *--source;
-
- yy_cp += (int) (dest - source);
- yy_bp += (int) (dest - source);
- yy_n_chars = yy_current_buffer->yy_buf_size;
-
- if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- YY_FATAL_ERROR( "flex scanner push-back overflow" );
- }
-
- *--yy_cp = (char) c;
-
-
- yytext_ptr = yy_bp;
- yy_hold_char = *yy_cp;
- yy_c_buf_p = yy_cp;
- }
-#endif /* ifndef YY_NO_UNPUT */
-
-
-#ifdef __cplusplus
-static int yyinput()
-#else
-static int input()
-#endif
- {
- int c;
-
- *yy_c_buf_p = yy_hold_char;
-
- if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- {
- /* yy_c_buf_p now points to the character we want to return.
- * If this occurs *before* the EOB characters, then it's a
- * valid NUL; if not, then we've hit the end of the buffer.
- */
- if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- /* This was really a NUL. */
- *yy_c_buf_p = '\0';
-
- else
- { /* need more input */
- yytext_ptr = yy_c_buf_p;
- ++yy_c_buf_p;
-
- switch ( yy_get_next_buffer() )
- {
- case EOB_ACT_END_OF_FILE:
- {
- if ( yywrap() )
- {
- yy_c_buf_p =
- yytext_ptr + YY_MORE_ADJ;
- return EOF;
- }
-
- if ( ! yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
-#ifdef __cplusplus
- return yyinput();
-#else
- return input();
-#endif
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
- break;
-
- case EOB_ACT_LAST_MATCH:
-#ifdef __cplusplus
- YY_FATAL_ERROR(
- "unexpected last match in yyinput()" );
-#else
- YY_FATAL_ERROR(
- "unexpected last match in input()" );
-#endif
- }
- }
- }
-
- c = *(unsigned char *) yy_c_buf_p; /* cast for 8-bit char's */
- *yy_c_buf_p = '\0'; /* preserve yytext */
- yy_hold_char = *++yy_c_buf_p;
-
-
- return c;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yyrestart( FILE *input_file )
-#else
-void yyrestart( input_file )
-FILE *input_file;
-#endif
- {
- if ( ! yy_current_buffer )
- yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
-
- yy_init_buffer( yy_current_buffer, input_file );
- yy_load_buffer_state();
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
-#else
-void yy_switch_to_buffer( new_buffer )
-YY_BUFFER_STATE new_buffer;
-#endif
- {
- if ( yy_current_buffer == new_buffer )
- return;
-
- if ( yy_current_buffer )
- {
- /* Flush out information for old buffer. */
- *yy_c_buf_p = yy_hold_char;
- yy_current_buffer->yy_buf_pos = yy_c_buf_p;
- yy_current_buffer->yy_n_chars = yy_n_chars;
- }
-
- yy_current_buffer = new_buffer;
- yy_load_buffer_state();
-
- /* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
- * to go ahead and always set it.
- */
- yy_did_buffer_switch_on_eof = 1;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_load_buffer_state( void )
-#else
-void yy_load_buffer_state()
-#endif
- {
- yy_n_chars = yy_current_buffer->yy_n_chars;
- yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
- yyin = yy_current_buffer->yy_input_file;
- yy_hold_char = *yy_c_buf_p;
- }
-
-
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
-#else
-YY_BUFFER_STATE yy_create_buffer( file, size )
-FILE *file;
-int size;
-#endif
- {
- YY_BUFFER_STATE b;
-
- b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- * we need to put in 2 end-of-buffer characters.
- */
- b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_is_our_buffer = 1;
-
- yy_init_buffer( b, file );
-
- return b;
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_delete_buffer( YY_BUFFER_STATE b )
-#else
-void yy_delete_buffer( b )
-YY_BUFFER_STATE b;
-#endif
- {
- if ( ! b )
- return;
-
- if ( b == yy_current_buffer )
- yy_current_buffer = (YY_BUFFER_STATE) 0;
-
- if ( b->yy_is_our_buffer )
- yy_flex_free( (void *) b->yy_ch_buf );
-
- yy_flex_free( (void *) b );
- }
-
-
-#ifndef YY_ALWAYS_INTERACTIVE
-#ifndef YY_NEVER_INTERACTIVE
-extern int isatty YY_PROTO(( int ));
-#endif
-#endif
-
-#ifdef YY_USE_PROTOS
-void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
-#else
-void yy_init_buffer( b, file )
-YY_BUFFER_STATE b;
-FILE *file;
-#endif
-
-
- {
- yy_flush_buffer( b );
-
- b->yy_input_file = file;
- b->yy_fill_buffer = 1;
-
-#if YY_ALWAYS_INTERACTIVE
- b->yy_is_interactive = 1;
-#else
-#if YY_NEVER_INTERACTIVE
- b->yy_is_interactive = 0;
-#else
- b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-#endif
-#endif
- }
-
-
-#ifdef YY_USE_PROTOS
-void yy_flush_buffer( YY_BUFFER_STATE b )
-#else
-void yy_flush_buffer( b )
-YY_BUFFER_STATE b;
-#endif
-
- {
- b->yy_n_chars = 0;
-
- /* We always need two end-of-buffer characters. The first causes
- * a transition to the end-of-buffer state. The second causes
- * a jam in that state.
- */
- b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
- b->yy_buf_pos = &b->yy_ch_buf[0];
-
- b->yy_at_bol = 1;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- if ( b == yy_current_buffer )
- yy_load_buffer_state();
- }
-
-
-#ifndef YY_NO_SCAN_BUFFER
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
-#else
-YY_BUFFER_STATE yy_scan_buffer( base, size )
-char *base;
-yy_size_t size;
-#endif
- {
- YY_BUFFER_STATE b;
-
- if ( size < 2 ||
- base[size-2] != YY_END_OF_BUFFER_CHAR ||
- base[size-1] != YY_END_OF_BUFFER_CHAR )
- /* They forgot to leave room for the EOB's. */
- return 0;
-
- b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
- b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
- b->yy_buf_pos = b->yy_ch_buf = base;
- b->yy_is_our_buffer = 0;
- b->yy_input_file = 0;
- b->yy_n_chars = b->yy_buf_size;
- b->yy_is_interactive = 0;
- b->yy_at_bol = 1;
- b->yy_fill_buffer = 0;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- yy_switch_to_buffer( b );
-
- return b;
- }
-#endif
-
-
-#ifndef YY_NO_SCAN_STRING
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_string( yyconst char *str )
-#else
-YY_BUFFER_STATE yy_scan_string( str )
-yyconst char *str;
-#endif
- {
- int len;
- for ( len = 0; str[len]; ++len )
- ;
-
- return yy_scan_bytes( str, len );
- }
-#endif
-
-
-#ifndef YY_NO_SCAN_BYTES
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
-#else
-YY_BUFFER_STATE yy_scan_bytes( bytes, len )
-yyconst char *bytes;
-int len;
-#endif
- {
- YY_BUFFER_STATE b;
- char *buf;
- yy_size_t n;
- int i;
-
- /* Get memory for full buffer, including space for trailing EOB's. */
- n = len + 2;
- buf = (char *) yy_flex_alloc( n );
- if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
- for ( i = 0; i < len; ++i )
- buf[i] = bytes[i];
-
- buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
-
- b = yy_scan_buffer( buf, n );
- if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
- /* It's okay to grow etc. this buffer, and we should throw it
- * away when we're done.
- */
- b->yy_is_our_buffer = 1;
-
- return b;
- }
-#endif
-
-
-#ifndef YY_NO_PUSH_STATE
-#ifdef YY_USE_PROTOS
-static void yy_push_state( int new_state )
-#else
-static void yy_push_state( new_state )
-int new_state;
-#endif
- {
- if ( yy_start_stack_ptr >= yy_start_stack_depth )
- {
- yy_size_t new_size;
-
- yy_start_stack_depth += YY_START_STACK_INCR;
- new_size = yy_start_stack_depth * sizeof( int );
-
- if ( ! yy_start_stack )
- yy_start_stack = (int *) yy_flex_alloc( new_size );
-
- else
- yy_start_stack = (int *) yy_flex_realloc(
- (void *) yy_start_stack, new_size );
-
- if ( ! yy_start_stack )
- YY_FATAL_ERROR(
- "out of memory expanding start-condition stack" );
- }
-
- yy_start_stack[yy_start_stack_ptr++] = YY_START;
-
- BEGIN(new_state);
- }
-#endif
-
-
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state()
- {
- if ( --yy_start_stack_ptr < 0 )
- YY_FATAL_ERROR( "start-condition stack underflow" );
-
- BEGIN(yy_start_stack[yy_start_stack_ptr]);
- }
-#endif
-
-
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state()
- {
- return yy_start_stack[yy_start_stack_ptr - 1];
- }
-#endif
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-#ifdef YY_USE_PROTOS
-static void yy_fatal_error( yyconst char msg[] )
-#else
-static void yy_fatal_error( msg )
-char msg[];
-#endif
- {
- (void) fprintf( stderr, "%s\n", msg );
- exit( YY_EXIT_FAILURE );
- }
-
-
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- yytext[yyleng] = yy_hold_char; \
- yy_c_buf_p = yytext + n - YY_MORE_ADJ; \
- yy_hold_char = *yy_c_buf_p; \
- *yy_c_buf_p = '\0'; \
- yyleng = n; \
- } \
- while ( 0 )
-
-
-/* Internal utility routines. */
-
-#ifndef yytext_ptr
-#ifdef YY_USE_PROTOS
-static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
-#else
-static void yy_flex_strncpy( s1, s2, n )
-char *s1;
-yyconst char *s2;
-int n;
-#endif
- {
- register int i;
- for ( i = 0; i < n; ++i )
- s1[i] = s2[i];
- }
-#endif
-
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_alloc( yy_size_t size )
-#else
-static void *yy_flex_alloc( size )
-yy_size_t size;
-#endif
- {
- return (void *) xmalloc( size );
- }
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_realloc( void *ptr, yy_size_t size )
-#else
-static void *yy_flex_realloc( ptr, size )
-void *ptr;
-yy_size_t size;
-#endif
- {
- /* The cast to (char *) in the following accommodates both
- * implementations that use char* generic pointers, and those
- * that use void* generic pointers. It works with the latter
- * because both ANSI C and C++ allow castless assignment from
- * any pointer type to void*, and deal with argument conversions
- * as though doing an assignment.
- */
- return (void *) realloc( (char *) ptr, size );
- }
-
-#ifdef YY_USE_PROTOS
-static void yy_flex_free( void *ptr )
-#else
-static void yy_flex_free( ptr )
-void *ptr;
-#endif
- {
- free( ptr );
- }
-
-#if YY_MAIN
-int main()
- {
- yylex();
- return 0;
- }
-#endif
-#line 364 "./ldlex.l"
-
-
-
-/* Switch flex to reading script file NAME, open on FILE,
- saving the current input info on the include stack. */
-
-void
-lex_push_file (file, name)
- FILE *file;
- const char *name;
-{
- if (include_stack_ptr >= MAX_INCLUDE_DEPTH)
- {
- einfo("%F:includes nested too deeply\n");
- }
- file_name_stack[include_stack_ptr] = name;
- lineno_stack[include_stack_ptr] = 1;
- include_stack[include_stack_ptr] = YY_CURRENT_BUFFER;
-
- include_stack_ptr++;
- yyin = file;
- yy_switch_to_buffer(yy_create_buffer(yyin, YY_BUF_SIZE));
- BEGIN (SCRIPT);
-}
-
-/* Return a newly created flex input buffer containing STRING,
- which is SIZE bytes long. */
-
-static YY_BUFFER_STATE
-yy_create_string_buffer (string, size)
- CONST char *string;
- size_t size;
-{
- YY_BUFFER_STATE b;
-
- /* Calls to m-alloc get turned by sed into xm-alloc. */
- b = (YY_BUFFER_STATE) xmalloc (sizeof (struct yy_buffer_state));
- b->yy_input_file = 0;
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- we need to put in 2 end-of-buffer characters. */
- b->yy_ch_buf = (char *) xmalloc ((unsigned) (b->yy_buf_size + 3));
-
- b->yy_ch_buf[0] = '\n';
- strcpy (b->yy_ch_buf+1, string);
- b->yy_ch_buf[size+1] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[size+2] = YY_END_OF_BUFFER_CHAR;
- b->yy_n_chars = size+1;
- b->yy_buf_pos = &b->yy_ch_buf[1];
-
- /* flex 2.4.7 changed the interface. FIXME: We should not be using
- a flex internal interface in the first place! */
-#ifdef YY_BUFFER_NEW
- b->yy_buffer_status = YY_BUFFER_NEW;
-#else
- b->yy_eof_status = EOF_NOT_SEEN;
-#endif
-
- return b;
-}
-
-/* Switch flex to reading from STRING, saving the current input info
- on the include stack. */
-
-void
-lex_redirect (string)
- CONST char *string;
-{
- YY_BUFFER_STATE tmp;
-
- yy_init = 0;
- if (include_stack_ptr >= MAX_INCLUDE_DEPTH)
- {
- einfo("%F: macros nested too deeply\n");
- }
- file_name_stack[include_stack_ptr] = "redirect";
- lineno_stack[include_stack_ptr] = 0;
- include_stack[include_stack_ptr] = YY_CURRENT_BUFFER;
- include_stack_ptr++;
- tmp = yy_create_string_buffer (string, strlen (string));
- yy_switch_to_buffer (tmp);
- BEGIN (SCRIPT);
-}
-
-/* Functions to switch to a different flex start condition,
- saving the current start condition on `state_stack'. */
-
-static int state_stack[MAX_INCLUDE_DEPTH * 2];
-static int *state_stack_p = state_stack;
-
-void
-ldlex_script ()
-{
- *(state_stack_p)++ = yy_start;
- BEGIN (SCRIPT);
-}
-
-void
-ldlex_mri_script ()
-{
- *(state_stack_p)++ = yy_start;
- BEGIN (MRI);
-}
-
-void
-ldlex_defsym ()
-{
- *(state_stack_p)++ = yy_start;
- BEGIN (DEFSYMEXP);
-}
-
-void
-ldlex_expression ()
-{
- *(state_stack_p)++ = yy_start;
- BEGIN (EXPRESSION);
-}
-
-void
-ldlex_both ()
-{
- *(state_stack_p)++ = yy_start;
- BEGIN (BOTH);
-}
-
-void
-ldlex_popstate ()
-{
- yy_start = *(--state_stack_p);
-}
-
-
-/* Place up to MAX_SIZE characters in BUF and return in *RESULT
- either the number of characters read, or 0 to indicate EOF. */
-
-static void
-yy_input (buf, result, max_size)
- char *buf;
- int *result;
- int max_size;
-{
- *result = 0;
- if (yy_current_buffer->yy_input_file)
- {
- if (yyin)
- {
- *result = read (fileno (yyin), (char *) buf, max_size);
- if (*result < 0)
- einfo ("%F%P: read in flex scanner failed");
- }
- }
-}
-
-/* Eat the rest of a C-style comment. */
-
-static void
-comment ()
-{
- int c;
-
- while (1)
- {
- c = input();
- while (c != '*' && c != EOF)
- {
- if (c == '\n' || c == '\r')
- lineno++;
- c = input();
- }
-
- if (c == '*')
- {
- c = input();
- while (c == '*')
- c = input();
- if (c == '/')
- break; /* found the end */
- }
-
- if (c == '\n' || c == '\r')
- lineno++;
-
- if (c == EOF)
- {
- einfo( "%F%P: EOF in comment\n");
- break;
- }
- }
-}
-
-/* Warn the user about a garbage character WHAT in the input
- in context WHERE. */
-
-static void
-lex_warn_invalid (where, what)
- char *where, *what;
-{
- char buf[5];
-
- /* If we have found an input file whose format we do not recognize,
- and we are therefore treating it as a linker script, and we find
- an invalid character, then most likely this is a real object file
- of some different format. Treat it as such. */
- if (ldfile_assumed_script)
- {
- bfd_set_error (bfd_error_file_not_recognized);
- einfo ("%F%s: file not recognized: %E\n", ldfile_input_filename);
- }
-
- if (! isprint ((unsigned char) *what))
- {
- sprintf (buf, "\\%03o", (unsigned int) *what);
- what = buf;
- }
-
- einfo ("%P:%S: ignoring invalid character `%s'%s\n", what, where);
-}
diff --git a/gnu/usr.bin/binutils/ld/mpw-eppcmacos.c b/gnu/usr.bin/binutils/ld/mpw-eppcmacos.c
deleted file mode 100644
index 9bc98127368..00000000000
--- a/gnu/usr.bin/binutils/ld/mpw-eppcmacos.c
+++ /dev/null
@@ -1,841 +0,0 @@
-/* This file is is generated by a shell script. DO NOT EDIT! */
-
-/* AIX emulation code for ppcmacos
- Copyright (C) 1991, 1993, 1995 Free Software Foundation, Inc.
- Written by Steve Chamberlain <sac@cygnus.com>
- AIX support by Ian Lance Taylor <ian@cygnus.com>
-
-This file is part of GLD, the Gnu Linker.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-#define TARGET_IS_ppcmacos
-
-#include "bfd.h"
-#include "sysdep.h"
-#include "libiberty.h"
-#include "getopt.h"
-#include "bfdlink.h"
-
-#include <ctype.h>
-
-#include "ld.h"
-#include "ldmain.h"
-#include "ldemul.h"
-#include "ldfile.h"
-#include "ldmisc.h"
-#include "ldexp.h"
-#include "ldlang.h"
-
-static void gldppcmacos_before_parse PARAMS ((void));
-static int gldppcmacos_parse_args PARAMS ((int, char **));
-static void gldppcmacos_before_allocation PARAMS ((void));
-static void gldppcmacos_read_file PARAMS ((const char *, boolean));
-static void gldppcmacos_free PARAMS ((PTR));
-static char *gldppcmacos_get_script PARAMS ((int *isfile));
-
-/* The file alignment required for each section. */
-static unsigned long file_align;
-
-/* The maximum size the stack is permitted to grow. This is stored in
- the a.out header. */
-static unsigned long maxstack;
-
-/* The maximum data size. This is stored in the a.out header. */
-static unsigned long maxdata;
-
-/* Whether to perform garbage collection. */
-static int gc = 1;
-
-/* The module type to use. */
-static unsigned short modtype = ('1' << 8) | 'L';
-
-/* Whether the .text section must be read-only (i.e., no relocs
- permitted). */
-static int textro;
-
-/* Structure used to hold import or export file list. */
-
-struct filelist
-{
- struct filelist *next;
- const char *name;
-};
-
-/* List of import files. */
-struct filelist *import_files;
-
-/* List of export files. */
-struct filelist *export_files;
-
-static void
-gldppcmacos_before_parse()
-{
-#ifndef TARGET_ /* I.e., if not generic. */
- ldfile_output_architecture = bfd_arch_powerpc;
-#endif /* not TARGET_ */
-}
-
-/* Handle AIX specific options. */
-
-static int
-gldppcmacos_parse_args (argc, argv)
- int argc;
- char **argv;
-{
- int prevoptind = optind;
- int prevopterr = opterr;
- int longind;
- int optc;
- long val;
- char *end;
-
-#define OPTION_IGNORE (300)
-#define OPTION_AUTOIMP (OPTION_IGNORE + 1)
-#define OPTION_ERNOTOK (OPTION_AUTOIMP + 1)
-#define OPTION_EROK (OPTION_ERNOTOK + 1)
-#define OPTION_EXPORT (OPTION_EROK + 1)
-#define OPTION_IMPORT (OPTION_EXPORT + 1)
-#define OPTION_MAXDATA (OPTION_IMPORT + 1)
-#define OPTION_MAXSTACK (OPTION_MAXDATA + 1)
-#define OPTION_MODTYPE (OPTION_MAXSTACK + 1)
-#define OPTION_NOAUTOIMP (OPTION_MODTYPE + 1)
-#define OPTION_NOSTRCMPCT (OPTION_NOAUTOIMP + 1)
-#define OPTION_STRCMPCT (OPTION_NOSTRCMPCT + 1)
-
- static struct option longopts[] = {
- {"basis", no_argument, NULL, OPTION_IGNORE},
- {"bautoimp", no_argument, NULL, OPTION_AUTOIMP},
- {"bcomprld", no_argument, NULL, OPTION_IGNORE},
- {"bcrld", no_argument, NULL, OPTION_IGNORE},
- {"bcror31", no_argument, NULL, OPTION_IGNORE},
- {"bD", required_argument, NULL, OPTION_MAXDATA},
- {"bE", required_argument, NULL, OPTION_EXPORT},
- {"bernotok", no_argument, NULL, OPTION_ERNOTOK},
- {"berok", no_argument, NULL, OPTION_EROK},
- {"berrmsg", no_argument, NULL, OPTION_IGNORE},
- {"bexport", required_argument, NULL, OPTION_EXPORT},
- {"bf", no_argument, NULL, OPTION_ERNOTOK},
- {"bgc", no_argument, &gc, 1},
- {"bh", required_argument, NULL, OPTION_IGNORE},
- {"bhalt", required_argument, NULL, OPTION_IGNORE},
- {"bI", required_argument, NULL, OPTION_IMPORT},
- {"bimport", required_argument, NULL, OPTION_IMPORT},
- {"bmaxdata", required_argument, NULL, OPTION_MAXDATA},
- {"bmaxstack", required_argument, NULL, OPTION_MAXSTACK},
- {"bM", required_argument, NULL, OPTION_MODTYPE},
- {"bmodtype", required_argument, NULL, OPTION_MODTYPE},
- {"bnoautoimp", no_argument, NULL, OPTION_NOAUTOIMP},
- {"bnodelcsect", no_argument, NULL, OPTION_IGNORE},
- {"bnogc", no_argument, &gc, 0},
- {"bnso", no_argument, NULL, OPTION_NOAUTOIMP},
- {"bnostrcmpct", no_argument, NULL, OPTION_NOSTRCMPCT},
- {"bnotextro", no_argument, &textro, 0},
- {"bnro", no_argument, &textro, 0},
- {"bro", no_argument, &textro, 1},
- {"bS", required_argument, NULL, OPTION_MAXSTACK},
- {"bso", no_argument, NULL, OPTION_AUTOIMP},
- {"bstrcmpct", no_argument, NULL, OPTION_STRCMPCT},
- {"btextro", no_argument, &textro, 1},
- {NULL, no_argument, NULL, 0}
- };
-
- /* Options supported by the AIX linker which we do not support: -f,
- -S, -v, -Z, -bbindcmds, -bbinder, -bbindopts, -bcalls, -bcaps,
- -bcror15, -bdebugopt, -bdbg, -bdelcsect, -bex?, -bfilelist, -bfl,
- -bgcbypass, -bglink, -binsert, -bi, -bloadmap, -bl, -bmap, -bnl,
- -bnobind, -bnocomprld, -bnocrld, -bnoerrmsg, -bnoglink,
- -bnoloadmap, -bnl, -bnoobjreorder, -bnoquiet, -bnoreorder,
- -bnotypchk, -bnox, -bquiet, -bR, -brename, -breorder, -btypchk,
- -bx, -bX, -bxref. */
-
- /* If the first option starts with -b, change the first : to an =.
- The AIX linker uses : to separate the option from the argument;
- changing it to = lets us treat it as a getopt option. */
- if (optind < argc && strncmp (argv[optind], "-b", 2) == 0)
- {
- char *s;
-
- for (s = argv[optind]; *s != '\0'; s++)
- {
- if (*s == ':')
- {
- *s = '=';
- break;
- }
- }
- }
-
- opterr = 0;
- optc = getopt_long_only (argc, argv, "-D:H:KT:z", longopts, &longind);
- opterr = prevopterr;
-
- switch (optc)
- {
- default:
- optind = prevoptind;
- return 0;
-
- case 0:
- /* Long option which just sets a flag. */
- break;
-
- case 'D':
- val = strtol (optarg, &end, 0);
- if (*end != '\0')
- einfo ("%P: warning: ignoring invalid -D number %s\n", optarg);
- else if (val != -1)
- lang_section_start (".data", exp_intop (val));
- break;
-
- case 'H':
- val = strtoul (optarg, &end, 0);
- if (*end != '\0'
- || (val & (val - 1)) != 0)
- einfo ("%P: warning: ignoring invalid -H number %s\n", optarg);
- else
- file_align = val;
- break;
-
- case 'K':
- case 'z':
- /* FIXME: This should use the page size for the target system. */
- file_align = 4096;
- break;
-
- case 'T':
- /* On AIX this is the same as GNU ld -Ttext. When we see -T
- number, we assume the AIX option is intended. Otherwise, we
- assume the usual GNU ld -T option is intended. We can't just
- ignore the AIX option, because gcc passes it to the linker. */
- val = strtoul (optarg, &end, 0);
- if (*end != '\0')
- {
- optind = prevoptind;
- return 0;
- }
- lang_section_start (".text", exp_intop (val));
- break;
-
- case OPTION_IGNORE:
- break;
-
- case OPTION_AUTOIMP:
- link_info.static_link = false;
- break;
-
- case OPTION_ERNOTOK:
- force_make_executable = false;
- break;
-
- case OPTION_EROK:
- force_make_executable = true;
- break;
-
- case OPTION_EXPORT:
- case OPTION_IMPORT:
- {
- struct filelist *n;
- struct filelist **flpp;
-
- n = (struct filelist *) xmalloc (sizeof (struct filelist));
- n->next = NULL;
- n->name = optarg;
- if (optc == OPTION_EXPORT)
- flpp = &export_files;
- else
- flpp = &import_files;
- while (*flpp != NULL)
- flpp = &(*flpp)->next;
- *flpp = n;
- }
- break;
-
- case OPTION_MAXDATA:
- val = strtoul (optarg, &end, 0);
- if (*end != '\0')
- einfo ("%P: warning: ignoring invalid -bmaxdata number %s\n",
- optarg);
- else
- maxdata = val;
- break;
-
- case OPTION_MAXSTACK:
- val = strtoul (optarg, &end, 0);
- if (*end != '\0')
- einfo ("%P: warning: ignoring invalid -bmaxstack number %s\n",
- optarg);
- else
- maxstack = val;
- break;
-
- case OPTION_MODTYPE:
- if (*optarg == 'S')
- {
- link_info.shared = true;
- ++optarg;
- }
- if (*optarg == '\0' || optarg[1] == '\0')
- einfo ("%P: warning: ignoring invalid module type %s\n", optarg);
- else
- modtype = (*optarg << 8) | optarg[1];
- break;
-
- case OPTION_NOAUTOIMP:
- link_info.static_link = true;
- break;
-
- case OPTION_NOSTRCMPCT:
- config.traditional_format = true;
- break;
-
- case OPTION_STRCMPCT:
- config.traditional_format = false;
- break;
- }
-
- return 1;
-}
-
-/* This is called after the sections have been attached to output
- sections, but before any sizes or addresses have been set. */
-
-static void
-gldppcmacos_before_allocation ()
-{
- struct filelist *fl;
- char *libpath;
-
- /* Handle the import and export files, if any. */
- for (fl = import_files; fl != NULL; fl = fl->next)
- gldppcmacos_read_file (fl->name, true);
- for (fl = export_files; fl != NULL; fl = fl->next)
- gldppcmacos_read_file (fl->name, false);
-
- /* We need to build LIBPATH from the -L arguments. If any -rpath
- arguments were used, though, we use -rpath instead, as a GNU
- extension. */
- if (command_line.rpath != NULL)
- libpath = command_line.rpath;
- else if (search_head == NULL)
- libpath = (char *) "";
- else
- {
- size_t len;
- search_dirs_type *search;
-
- len = strlen (search_head->name);
- libpath = xmalloc (len + 1);
- strcpy (libpath, search_head->name);
- for (search = search_head->next; search != NULL; search = search->next)
- {
- size_t nlen;
-
- nlen = strlen (search->name);
- libpath = xrealloc (libpath, len + nlen + 2);
- libpath[len] = ':';
- strcpy (libpath + len + 1, search->name);
- len += nlen + 1;
- }
- }
-
- /* Let the XCOFF backend set up the .loader section. */
- if (! bfd_xcoff_size_dynamic_sections (output_bfd, &link_info, libpath,
- entry_symbol, file_align,
- maxstack, maxdata,
- gc ? true : false,
- modtype,
- textro ? true : false))
- einfo ("%P%F: failed to set dynamic section sizes: %E\n");
-}
-
-/* Read an import or export file. */
-
-static void
-gldppcmacos_read_file (filename, import)
- const char *filename;
- boolean import;
-{
- struct obstack *o;
- FILE *f;
- int lineno;
- int c;
- boolean keep;
- const char *imppath;
- const char *impfile;
- const char *impmember;
-
- o = (struct obstack *) xmalloc (sizeof (struct obstack));
- obstack_specify_allocation (o, 0, 0, xmalloc, gldppcmacos_free);
-
- f = fopen (filename, "r");
- if (f == NULL)
- {
- bfd_set_error (bfd_error_system_call);
- einfo ("%F%s: %E\n", filename);
- }
-
- keep = false;
-
- imppath = NULL;
- impfile = NULL;
- impmember = NULL;
-
- lineno = 0;
- while ((c = getc (f)) != EOF)
- {
- char *s;
- char *symname;
- boolean syscall;
- bfd_vma address;
- struct bfd_link_hash_entry *h;
-
- if (c != '\n')
- {
- obstack_1grow (o, c);
- continue;
- }
-
- obstack_1grow (o, '\0');
- ++lineno;
-
- s = (char *) obstack_base (o);
- while (isspace ((unsigned char) *s))
- ++s;
- if (*s == '\0'
- || *s == '*'
- || (*s == '#' && s[1] == ' ')
- || (! import && *s == '#' && s[1] == '!'))
- {
- obstack_free (o, obstack_base (o));
- continue;
- }
-
- if (*s == '#' && s[1] == '!')
- {
- s += 2;
- while (isspace ((unsigned char) *s))
- ++s;
- if (*s == '\0')
- {
- imppath = NULL;
- impfile = NULL;
- impmember = NULL;
- obstack_free (o, obstack_base (o));
- }
- else if (*s == '(')
- einfo ("%F%s%d: #! ([member]) is not supported in import files",
- filename, lineno);
- else
- {
- char cs;
- char *file;
-
- (void) obstack_finish (o);
- keep = true;
- imppath = s;
- impfile = NULL;
- while (! isspace ((unsigned char) *s) && *s != '(' && *s != '\0')
- {
- if (*s == '/')
- file = s + 1;
- ++s;
- }
- if (file != NULL)
- {
- file[-1] = '\0';
- impfile = file;
- if (imppath == file - 1)
- imppath = "/";
- }
- else
- {
- impfile = imppath;
- imppath = "";
- }
- cs = *s;
- *s = '\0';
- while (isspace ((unsigned char) cs))
- {
- ++s;
- cs = *s;
- }
- if (cs != '(')
- {
- impmember = "";
- if (cs != '\0')
- einfo ("%s:%d: warning: syntax error in import file\n",
- filename, lineno);
- }
- else
- {
- ++s;
- impmember = s;
- while (*s != ')' && *s != '\0')
- ++s;
- if (*s == ')')
- *s = '\0';
- else
- einfo ("%s:%d: warning: syntax error in import file\n",
- filename, lineno);
- }
- }
-
- continue;
- }
-
- /* This is a symbol to be imported or exported. */
- symname = s;
- syscall = false;
- address = (bfd_vma) -1;
-
- while (! isspace ((unsigned char) *s) && *s != '\0')
- ++s;
- if (*s != '\0')
- {
- char *se;
-
- *s++ = '\0';
-
- while (isspace ((unsigned char) *s))
- ++s;
-
- se = s;
- while (! isspace ((unsigned char) *se) && *se != '\0')
- ++se;
- if (*se != '\0')
- {
- *se++ = '\0';
- while (isspace ((unsigned char) *se))
- ++se;
- if (*se != '\0')
- einfo ("%s%d: warning: syntax error in import/export file\n",
- filename, lineno);
- }
-
- if (strcasecmp (s, "svc") == 0
- || strcasecmp (s, "syscall") == 0)
- syscall = true;
- else
- {
- char *end;
-
- address = strtoul (s, &end, 0);
- if (*end != '\0')
- einfo ("%s:%d: warning: syntax error in import/export file\n",
- filename, lineno);
- }
- }
-
- h = bfd_link_hash_lookup (link_info.hash, symname, false, false, true);
- if (h == NULL || h->type == bfd_link_hash_new)
- {
- /* We can just ignore attempts to import an unreferenced
- symbol. */
- if (! import)
- einfo ("%X%s:%d: attempt to export undefined symbol %s\n",
- filename, lineno, symname);
- }
- else if (import)
- {
- if (! bfd_xcoff_import_symbol (output_bfd, &link_info, h, address,
- imppath, impfile, impmember))
- einfo ("%X%s:%d: failed to import symbol %s: %E\n",
- filename, lineno, symname);
- }
- else
- {
- if (! bfd_xcoff_export_symbol (output_bfd, &link_info, h, syscall))
- einfo ("%X%s:%d: failed to export symbol %s: %E\n",
- filename, lineno, symname);
- }
-
- obstack_free (o, obstack_base (o));
- }
-
- if (obstack_object_size (o) > 0)
- {
- einfo ("%s:%d: warning: ignoring unterminated last line\n",
- filename, lineno);
- obstack_free (o, obstack_base (o));
- }
-
- if (! keep)
- {
- obstack_free (o, NULL);
- free (o);
- }
-}
-
-/* This routine saves us from worrying about declaring free. */
-
-static void
-gldppcmacos_free (p)
- PTR p;
-{
- free (p);
-}
-
-static char *
-gldppcmacos_get_script(isfile)
- int *isfile;
-{
- *isfile = 0;
-
- if (link_info.relocateable == true && config.build_constructors == true)
- return
-"OUTPUT_FORMAT(\"xcoff-powermac\")\n\
-OUTPUT_ARCH(powerpc)\n\
-ENTRY(__start)\n\
-SECTIONS\n\
-{\n\
- .pad 0 : { *(.pad) }\n\
- .text 0 : {\n\
- *(.text)\n\
- *(.pr)\n\
- *(.ro)\n\
- *(.db)\n\
- *(.gl)\n\
- *(.xo)\n\
- *(.ti)\n\
- *(.tb)\n\
- }\n\
- .data 0 : {\n\
- *(.data)\n\
- *(.rw)\n\
- *(.sv)\n\
- *(.ua)\n\
- *(.ds)\n\
- *(.tc0)\n\
- *(.tc)\n\
- *(.td)\n\
- }\n\
- .bss : {\n\
- *(.bss)\n\
- *(.bs)\n\
- *(.uc)\n\
- *(COMMON)\n\
- }\n\
- .loader 0 : {\n\
- *(.loader)\n\
- }\n\
- .debug 0 : {\n\
- *(.debug)\n\
- }\n\
-}\n\n"
- ; else if (link_info.relocateable == true) return
-"OUTPUT_FORMAT(\"xcoff-powermac\")\n\
-OUTPUT_ARCH(powerpc)\n\
-ENTRY(__start)\n\
-SECTIONS\n\
-{\n\
- .pad 0 : { *(.pad) }\n\
- .text 0 : {\n\
- *(.text)\n\
- *(.pr)\n\
- *(.ro)\n\
- *(.db)\n\
- *(.gl)\n\
- *(.xo)\n\
- *(.ti)\n\
- *(.tb)\n\
- }\n\
- .data 0 : {\n\
- *(.data)\n\
- *(.rw)\n\
- *(.sv)\n\
- *(.ua)\n\
- *(.ds)\n\
- *(.tc0)\n\
- *(.tc)\n\
- *(.td)\n\
- }\n\
- .bss : {\n\
- *(.bss)\n\
- *(.bs)\n\
- *(.uc)\n\
- *(COMMON)\n\
- }\n\
- .loader 0 : {\n\
- *(.loader)\n\
- }\n\
- .debug 0 : {\n\
- *(.debug)\n\
- }\n\
-}\n\n"
- ; else if (!config.text_read_only) return
-"OUTPUT_FORMAT(\"xcoff-powermac\")\n\
-OUTPUT_ARCH(powerpc)\n\
- SEARCH_DIR(/usr/local/powerpc-apple-macos/lib);\n\
-ENTRY(__start)\n\
-SECTIONS\n\
-{\n\
- .pad 0 : { *(.pad) }\n\
- .text : {\n\
- PROVIDE (_text = .);\n\
- *(.text)\n\
- *(.pr)\n\
- *(.ro)\n\
- *(.db)\n\
- *(.gl)\n\
- *(.xo)\n\
- *(.ti)\n\
- *(.tb)\n\
- PROVIDE (_etext = .);\n\
- }\n\
- .data 0 : {\n\
- PROVIDE (_data = .);\n\
- *(.data)\n\
- *(.rw)\n\
- *(.sv)\n\
- *(.ua)\n\
- *(.ds)\n\
- *(.tc0)\n\
- *(.tc)\n\
- *(.td)\n\
- PROVIDE (_edata = .);\n\
- }\n\
- .bss : {\n\
- *(.bss)\n\
- *(.bs)\n\
- *(.uc)\n\
- *(COMMON)\n\
- PROVIDE (_end = .);\n\
- PROVIDE (end = .);\n\
- }\n\
- .loader 0 : {\n\
- *(.loader)\n\
- }\n\
- .debug 0 : {\n\
- *(.debug)\n\
- }\n\
-}\n\n"
- ; else if (!config.magic_demand_paged) return
-"OUTPUT_FORMAT(\"xcoff-powermac\")\n\
-OUTPUT_ARCH(powerpc)\n\
- SEARCH_DIR(/usr/local/powerpc-apple-macos/lib);\n\
-ENTRY(__start)\n\
-SECTIONS\n\
-{\n\
- .pad 0 : { *(.pad) }\n\
- .text : {\n\
- PROVIDE (_text = .);\n\
- *(.text)\n\
- *(.pr)\n\
- *(.ro)\n\
- *(.db)\n\
- *(.gl)\n\
- *(.xo)\n\
- *(.ti)\n\
- *(.tb)\n\
- PROVIDE (_etext = .);\n\
- }\n\
- .data 0 : {\n\
- PROVIDE (_data = .);\n\
- *(.data)\n\
- *(.rw)\n\
- *(.sv)\n\
- *(.ua)\n\
- *(.ds)\n\
- *(.tc0)\n\
- *(.tc)\n\
- *(.td)\n\
- PROVIDE (_edata = .);\n\
- }\n\
- .bss : {\n\
- *(.bss)\n\
- *(.bs)\n\
- *(.uc)\n\
- *(COMMON)\n\
- PROVIDE (_end = .);\n\
- PROVIDE (end = .);\n\
- }\n\
- .loader 0 : {\n\
- *(.loader)\n\
- }\n\
- .debug 0 : {\n\
- *(.debug)\n\
- }\n\
-}\n\n"
- ; else return
-"OUTPUT_FORMAT(\"xcoff-powermac\")\n\
-OUTPUT_ARCH(powerpc)\n\
- SEARCH_DIR(/usr/local/powerpc-apple-macos/lib);\n\
-ENTRY(__start)\n\
-SECTIONS\n\
-{\n\
- .pad 0 : { *(.pad) }\n\
- .text : {\n\
- PROVIDE (_text = .);\n\
- *(.text)\n\
- *(.pr)\n\
- *(.ro)\n\
- *(.db)\n\
- *(.gl)\n\
- *(.xo)\n\
- *(.ti)\n\
- *(.tb)\n\
- PROVIDE (_etext = .);\n\
- }\n\
- .data 0 : {\n\
- PROVIDE (_data = .);\n\
- *(.data)\n\
- *(.rw)\n\
- *(.sv)\n\
- *(.ua)\n\
- *(.ds)\n\
- *(.tc0)\n\
- *(.tc)\n\
- *(.td)\n\
- PROVIDE (_edata = .);\n\
- }\n\
- .bss : {\n\
- *(.bss)\n\
- *(.bs)\n\
- *(.uc)\n\
- *(COMMON)\n\
- PROVIDE (_end = .);\n\
- PROVIDE (end = .);\n\
- }\n\
- .loader 0 : {\n\
- *(.loader)\n\
- }\n\
- .debug 0 : {\n\
- *(.debug)\n\
- }\n\
-}\n\n"
-; }
-
-struct ld_emulation_xfer_struct ld_ppcmacos_emulation =
-{
- gldppcmacos_before_parse,
- syslib_default,
- hll_default,
- after_parse_default,
- after_open_default,
- after_allocation_default,
- set_output_arch_default,
- ldemul_default_target,
- gldppcmacos_before_allocation,
- gldppcmacos_get_script,
- "ppcmacos",
- "xcoff-powermac",
- 0, /* finish */
- 0, /* create_output_section_statements */
- 0, /* open_dynamic_archive */
- 0, /* place_orphan */
- 0, /* set_symbols */
- gldppcmacos_parse_args,
-};
diff --git a/gnu/usr.bin/binutils/libiberty/config/mh-hpux b/gnu/usr.bin/binutils/libiberty/config/mh-hpux
deleted file mode 100644
index ed4a269b265..00000000000
--- a/gnu/usr.bin/binutils/libiberty/config/mh-hpux
+++ /dev/null
@@ -1 +0,0 @@
-EXTRA_OFILES = alloca.o
diff --git a/gnu/usr.bin/binutils/libiberty/config/mh-i386win32 b/gnu/usr.bin/binutils/libiberty/config/mh-i386win32
deleted file mode 100644
index 6b0856965f7..00000000000
--- a/gnu/usr.bin/binutils/libiberty/config/mh-i386win32
+++ /dev/null
@@ -1,5 +0,0 @@
-HDEFINES=-DHAVE_GETRUSAGE
-CC=i386-win32-gcc -O2
-AR=i386-win32-ar
-RANLIB=i386-win32-ranlib
-CFLAGS=
diff --git a/gnu/usr.bin/binutils/libiberty/win32.c b/gnu/usr.bin/binutils/libiberty/win32.c
deleted file mode 100644
index b10e2d3170c..00000000000
--- a/gnu/usr.bin/binutils/libiberty/win32.c
+++ /dev/null
@@ -1,64 +0,0 @@
-
-/* Win32-Unix compatibility library.
- Copyright (C) 1995 Free Software Foundation, Inc.
-
-This file is part of the libiberty library.
-Libiberty is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public
-License as published by the Free Software Foundation; either
-version 2 of the License, or (at your option) any later version.
-
-Libiberty is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with libiberty; see the file COPYING.LIB. If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA. */
-
-/* sac@cygnus.com */
-
-/* This should only be compiled and linked under Win32. */
-
-#include <stdio.h>
-#include <stdlib.h>
-
-/*
-
-NAME
-
- basename -- return pointer to last component of a pathname
-
-SYNOPSIS
-
- char *basename (const char *name)
-
-DESCRIPTION
-
- Given a pointer to a string containing a typical pathname
- (/usr/src/cmd/ls/ls.c for example), returns a pointer to the
- last component of the pathname ("ls.c" in this case).
-
-
-*/
-
-
-char *
-basename (name)
- const char *name;
-{
- const char *base = name;
-
- while (*name)
- {
- if (*name == '/'
- || *name == '\\')
- {
- base = name+1;
- }
- name++;
- }
- return (char *) base;
-}
diff --git a/gnu/usr.bin/binutils/makeall.bat b/gnu/usr.bin/binutils/makeall.bat
deleted file mode 100644
index d2d415f0a49..00000000000
--- a/gnu/usr.bin/binutils/makeall.bat
+++ /dev/null
@@ -1,16 +0,0 @@
-@echo off
-chdir libiberty
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\bfd
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\opcodes
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\gprof
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\binutils
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\gas
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..\ld
-make %1 %2 %3 %4 %5 %6 %7 %8 %9
-chdir ..
diff --git a/gnu/usr.bin/binutils/opcodes/stamp-h b/gnu/usr.bin/binutils/opcodes/stamp-h
deleted file mode 100644
index 8b137891791..00000000000
--- a/gnu/usr.bin/binutils/opcodes/stamp-h
+++ /dev/null
@@ -1 +0,0 @@
-