read.h revision 78828
133965Sjdp/* read.h - of read.c
278828Sobrien   Copyright 1986, 1990, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
378828Sobrien   2000
438889Sjdp   Free Software Foundation, Inc.
533965Sjdp
633965Sjdp   This file is part of GAS, the GNU Assembler.
733965Sjdp
833965Sjdp   GAS is free software; you can redistribute it and/or modify
933965Sjdp   it under the terms of the GNU General Public License as published by
1033965Sjdp   the Free Software Foundation; either version 2, or (at your option)
1133965Sjdp   any later version.
1233965Sjdp
1333965Sjdp   GAS is distributed in the hope that it will be useful,
1433965Sjdp   but WITHOUT ANY WARRANTY; without even the implied warranty of
1533965Sjdp   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1633965Sjdp   GNU General Public License for more details.
1733965Sjdp
1833965Sjdp   You should have received a copy of the GNU General Public License
1977298Sobrien   along with GAS; see the file COPYING.  If not, write to the Free
2077298Sobrien   Software Foundation, 59 Temple Place - Suite 330, Boston, MA
2177298Sobrien   02111-1307, USA.  */
2233965Sjdp
2377298Sobrienextern char *input_line_pointer;	/* -> char we are parsing now.  */
2433965Sjdp
2577298Sobrien/* Define to make whitespace be allowed in many syntactically
2677298Sobrien   unnecessary places.  Normally undefined.  For compatibility with
2777298Sobrien   ancient GNU cc.  */
2833965Sjdp/* #undef PERMIT_WHITESPACE */
2977298Sobrien#define PERMIT_WHITESPACE
3033965Sjdp
3133965Sjdp#ifdef PERMIT_WHITESPACE
3277298Sobrien#define SKIP_WHITESPACE()			\
3377298Sobrien  {						\
3477298Sobrien    if (* input_line_pointer == ' ')		\
3577298Sobrien      ++ input_line_pointer;			\
3677298Sobrien  }
3733965Sjdp#else
3833965Sjdp#define SKIP_WHITESPACE() know(*input_line_pointer != ' ' )
3933965Sjdp#endif
4033965Sjdp
4133965Sjdp#define	LEX_NAME	(1)	/* may continue a name */
4233965Sjdp#define LEX_BEGIN_NAME	(2)	/* may begin a name */
4360484Sobrien#define LEX_END_NAME	(4)	/* ends a name */
4433965Sjdp
4533965Sjdp#define is_name_beginner(c) \
4633965Sjdp  ( lex_type[(unsigned char) (c)] & LEX_BEGIN_NAME )
4733965Sjdp#define is_part_of_name(c) \
4833965Sjdp  ( lex_type[(unsigned char) (c)] & LEX_NAME       )
4960484Sobrien#define is_name_ender(c) \
5060484Sobrien  ( lex_type[(unsigned char) (c)] & LEX_END_NAME   )
5133965Sjdp
5233965Sjdp#ifndef is_a_char
5333965Sjdp#define CHAR_MASK	(0xff)
5433965Sjdp#define NOT_A_CHAR	(CHAR_MASK+1)
5577298Sobrien#define is_a_char(c)	(((unsigned) (c)) <= CHAR_MASK)
5633965Sjdp#endif /* is_a_char() */
5733965Sjdp
5833965Sjdpextern char lex_type[];
5933965Sjdpextern char is_end_of_line[];
6033965Sjdp
6133965Sjdpextern int is_it_end_of_statement PARAMS ((void));
6233965Sjdp
6333965Sjdpextern int target_big_endian;
6433965Sjdp
6533965Sjdp/* These are initialized by the CPU specific target files (tc-*.c).  */
6633965Sjdpextern const char comment_chars[];
6733965Sjdpextern const char line_comment_chars[];
6833965Sjdpextern const char line_separator_chars[];
6933965Sjdp
7038889Sjdp/* Table of -I directories.  */
7138889Sjdpextern char **include_dirs;
7238889Sjdpextern int include_dir_count;
7338889Sjdpextern int include_dir_maxlen;
7433965Sjdp
7533965Sjdp/* The offset in the absolute section.  */
7633965Sjdpextern addressT abs_section_offset;
7733965Sjdp
7833965Sjdp/* The label on a line, used by some of the pseudo-ops.  */
7933965Sjdpextern symbolS *line_label;
8033965Sjdp
8133965Sjdp/* This is used to support MRI common sections.  */
8233965Sjdpextern symbolS *mri_common_symbol;
8333965Sjdp
8477298Sobrien/* True if a stabs line debug statement is currently being emitted.  */
8577298Sobrienextern int outputting_stabs_line_debug;
8677298Sobrien
8733965Sjdp/* Possible arguments to .linkonce.  */
8877298Sobrienenum linkonce_type {
8933965Sjdp  LINKONCE_UNSET = 0,
9033965Sjdp  LINKONCE_DISCARD,
9133965Sjdp  LINKONCE_ONE_ONLY,
9233965Sjdp  LINKONCE_SAME_SIZE,
9333965Sjdp  LINKONCE_SAME_CONTENTS
9433965Sjdp};
9533965Sjdp
9677298Sobrien#define IGNORE_OPCODE_CASE
9777298Sobrien#ifdef  IGNORE_OPCODE_CASE
9877298Sobrienextern char original_case_string[];
9977298Sobrien#endif
10077298Sobrien
10133965Sjdpextern void pop_insert PARAMS ((const pseudo_typeS *));
10233965Sjdpextern unsigned int get_stab_string_offset
10333965Sjdp  PARAMS ((const char *string, const char *stabstr_secname));
10477298Sobrienextern void aout_process_stab PARAMS ((int, const char *, int, int, int));
10533965Sjdpextern char *demand_copy_C_string PARAMS ((int *len_pointer));
10633965Sjdpextern char get_absolute_expression_and_terminator
10733965Sjdp  PARAMS ((long *val_pointer));
10833965Sjdpextern offsetT get_absolute_expression PARAMS ((void));
10933965Sjdpextern unsigned int next_char_of_string PARAMS ((void));
11033965Sjdpextern void s_mri_sect PARAMS ((char *));
11133965Sjdpextern char *mri_comment_field PARAMS ((char *));
11233965Sjdpextern void mri_comment_end PARAMS ((char *, int));
11333965Sjdpextern void add_include_dir PARAMS ((char *path));
11433965Sjdpextern void cons PARAMS ((int nbytes));
11533965Sjdpextern void demand_empty_rest_of_line PARAMS ((void));
11633965Sjdpextern void emit_expr PARAMS ((expressionS *exp, unsigned int nbytes));
11738889Sjdpextern void emit_leb128_expr PARAMS ((expressionS *, int));
11833965Sjdpextern void equals PARAMS ((char *sym_name, int reassign));
11933965Sjdpextern void float_cons PARAMS ((int float_type));
12033965Sjdpextern void ignore_rest_of_line PARAMS ((void));
12160484Sobrienextern void discard_rest_of_line PARAMS ((void));
12238889Sjdpextern int output_leb128 PARAMS ((char *, valueT, int sign));
12333965Sjdpextern void pseudo_set PARAMS ((symbolS * symbolP));
12433965Sjdpextern void read_a_source_file PARAMS ((char *name));
12533965Sjdpextern void read_begin PARAMS ((void));
12638889Sjdpextern void read_print_statistics PARAMS ((FILE *));
12738889Sjdpextern int sizeof_leb128 PARAMS ((valueT, int sign));
12860484Sobrienextern void stabs_generate_asm_file PARAMS ((void));
12938889Sjdpextern void stabs_generate_asm_lineno PARAMS ((void));
13060484Sobrienextern void stabs_generate_asm_func PARAMS ((const char *, const char *));
13160484Sobrienextern void stabs_generate_asm_endfunc PARAMS ((const char *, const char *));
13260484Sobrienextern void do_repeat PARAMS((int,const char *,const char *));
13360484Sobrienextern void end_repeat PARAMS((int));
13438889Sjdp
13560484Sobrienextern void generate_lineno_debug PARAMS ((void));
13660484Sobrien
13777298Sobrienextern void s_abort PARAMS ((int)) ATTRIBUTE_NORETURN;
13833965Sjdpextern void s_align_bytes PARAMS ((int arg));
13933965Sjdpextern void s_align_ptwo PARAMS ((int));
14033965Sjdpextern void s_app_file PARAMS ((int));
14133965Sjdpextern void s_app_line PARAMS ((int));
14233965Sjdpextern void s_comm PARAMS ((int));
14333965Sjdpextern void s_data PARAMS ((int));
14433965Sjdpextern void s_desc PARAMS ((int));
14533965Sjdpextern void s_else PARAMS ((int arg));
14660484Sobrienextern void s_elseif PARAMS ((int arg));
14733965Sjdpextern void s_end PARAMS ((int arg));
14833965Sjdpextern void s_endif PARAMS ((int arg));
14933965Sjdpextern void s_err PARAMS ((int));
15033965Sjdpextern void s_fail PARAMS ((int));
15133965Sjdpextern void s_fill PARAMS ((int));
15233965Sjdpextern void s_float_space PARAMS ((int mult));
15360484Sobrienextern void s_func PARAMS ((int));
15460484Sobrienextern void do_s_func PARAMS ((int, const char *));
15533965Sjdpextern void s_globl PARAMS ((int arg));
15633965Sjdpextern void s_if PARAMS ((int arg));
15733965Sjdpextern void s_ifc PARAMS ((int arg));
15833965Sjdpextern void s_ifdef PARAMS ((int arg));
15933965Sjdpextern void s_ifeqs PARAMS ((int arg));
16033965Sjdpextern void s_ignore PARAMS ((int arg));
16133965Sjdpextern void s_include PARAMS ((int arg));
16233965Sjdpextern void s_irp PARAMS ((int arg));
16333965Sjdpextern void s_lcomm PARAMS ((int needs_align));
16438889Sjdpextern void s_lcomm_bytes PARAMS ((int needs_align));
16538889Sjdpextern void s_leb128 PARAMS ((int sign));
16633965Sjdpextern void s_linkonce PARAMS ((int));
16733965Sjdpextern void s_lsym PARAMS ((int));
16833965Sjdpextern void s_macro PARAMS ((int));
16933965Sjdpextern void s_mexit PARAMS ((int));
17033965Sjdpextern void s_mri PARAMS ((int));
17133965Sjdpextern void s_mri_common PARAMS ((int));
17233965Sjdpextern void s_org PARAMS ((int));
17333965Sjdpextern void s_print PARAMS ((int));
17433965Sjdpextern void s_purgem PARAMS ((int));
17533965Sjdpextern void s_rept PARAMS ((int));
17633965Sjdpextern void s_set PARAMS ((int));
17733965Sjdpextern void s_space PARAMS ((int mult));
17833965Sjdpextern void s_stab PARAMS ((int what));
17933965Sjdpextern void s_struct PARAMS ((int));
18033965Sjdpextern void s_text PARAMS ((int));
18133965Sjdpextern void stringer PARAMS ((int append_zero));
18233965Sjdpextern void s_xstab PARAMS ((int what));
18333965Sjdpextern void s_rva PARAMS ((int));
184