+
+static void fail (const char *, ...) ATTRIBUTE_PRINTF_1;
+static void warn (const char *, ...) ATTRIBUTE_PRINTF_1;
+static struct rdep * insert_resource (const char *, enum ia64_dependency_mode);
+static int deplist_equals (struct deplist *, struct deplist *);
+static short insert_deplist (int, unsigned short *);
+static short insert_dependencies (int, unsigned short *, int, unsigned short *);
+static void mark_used (struct iclass *, int);
+static int fetch_insn_class (const char *, int);
+static int sub_compare (const void *, const void *);
+static void load_insn_classes (void);
+static void parse_resource_users (const char *, int **, int *, int **);
+static int parse_semantics (char *);
+static void add_dep (const char *, const char *, const char *, int, int, char *, int);
+static void load_depfile (const char *, enum ia64_dependency_mode);
+static void load_dependencies (void);
+static int irf_operand (int, const char *);
+static int in_iclass_mov_x (struct ia64_opcode *, struct iclass *, const char *, const char *);
+static int in_iclass (struct ia64_opcode *, struct iclass *, const char *, const char *, int *);
+static int lookup_regindex (const char *, int);
+static int lookup_specifier (const char *);
+static void print_dependency_table (void);
+static struct string_entry * insert_string (char *);
+static void gen_dis_table (struct bittree *);
+static void print_dis_table (void);
+static void generate_disassembler (void);
+static void print_string_table (void);
+static int completer_entries_eq (struct completer_entry *, struct completer_entry *);
+static struct completer_entry * insert_gclist (struct completer_entry *);
+static int get_prefix_len (const char *);
+static void compute_completer_bits (struct main_entry *, struct completer_entry *);
+static void collapse_redundant_completers (void);
+static int insert_opcode_dependencies (struct ia64_opcode *, struct completer_entry *);
+static void insert_completer_entry (struct ia64_opcode *, struct main_entry *, int);
+static void print_completer_entry (struct completer_entry *);
+static void print_completer_table (void);
+static int opcodes_eq (struct ia64_opcode *, struct ia64_opcode *);
+static void add_opcode_entry (struct ia64_opcode *);
+static void print_main_table (void);
+static void shrink (struct ia64_opcode *);
+static void print_version (void);
+static void usage (FILE *, int);
+static void finish_distable (void);
+static void insert_bit_table_ent (struct bittree *, int, ia64_insn, ia64_insn, int, int, ci_t);
+static void add_dis_entry (struct bittree *, ia64_insn, ia64_insn, int, struct completer_entry *, ci_t);
+static void compact_distree (struct bittree *);
+static struct bittree * make_bittree_entry (void);
+static struct disent * add_dis_table_ent (struct disent *, int, int, ci_t);
+
+\f
+static void
+fail (const char *message, ...)
+{
+ va_list args;
+
+ va_start (args, message);
+ fprintf (stderr, _("%s: Error: "), program_name);
+ vfprintf (stderr, message, args);
+ va_end (args);
+ xexit (1);
+}
+
+static void
+warn (const char *message, ...)
+{
+ va_list args;
+
+ va_start (args, message);
+
+ fprintf (stderr, _("%s: Warning: "), program_name);
+ vfprintf (stderr, message, args);
+ va_end (args);
+}
+
+/* Add NAME to the resource table, where TYPE is RAW or WAW. */