#include "compiler.h"
#include "nasm.h"
#include "nasmlib.h"
#include "nctype.h"
#include "error.h"
#include "saa.h"
#include "raa.h"
#include "floats.h"
#include "stdscan.h"
#include "insns.h"
#include "preproc.h"
#include "parser.h"
#include "eval.h"
#include "assemble.h"
#include "labels.h"
#include "outform.h"
#include "listing.h"
#include "iflag.h"
#include "quote.h"
#include "ver.h"
#define MAX_OPTIMIZE …
struct forwrefinfo { … };
const char *_progname;
static void parse_cmdline(int, char **, int);
static void assemble_file(const char *, struct strlist *);
static bool skip_this_pass(errflags severity);
static void usage(void);
static void help(FILE *);
struct error_format { … };
static const struct error_format errfmt_gnu = …;
static const struct error_format errfmt_msvc = …;
static const struct error_format *errfmt = …;
static struct strlist *warn_list;
static struct nasm_errhold *errhold_stack;
unsigned int debug_nasm;
static bool using_debug_info, opt_verbose_info;
static const char *debug_format;
#ifndef ABORT_ON_PANIC
#define ABORT_ON_PANIC …
#endif
static bool abort_on_panic = …;
static bool keep_all;
bool tasm_compatible_mode = …;
enum pass_type _pass_type;
const char * const _pass_types[] = …;
int64_t _passn;
int globalrel = …;
int globalbnd = …;
struct compile_time official_compile_time;
const char *inname;
const char *outname;
static const char *listname;
static const char *errname;
static int64_t globallineno;
const struct ofmt *ofmt = …;
const struct ofmt_alias *ofmt_alias = …;
const struct dfmt *dfmt;
FILE *error_file;
FILE *ofile = …;
struct optimization optimizing = …;
static int cmd_sb = …;
iflag_t cpu;
static iflag_t cmd_cpu;
struct location location;
bool in_absolute;
struct location absolute;
static struct RAA *offsets;
static struct SAA *forwrefs;
static const struct forwrefinfo *forwref;
static const struct preproc_ops *preproc;
static struct strlist *include_path;
bool pp_noline;
#define OP_NORMAL …
#define OP_PREPROCESS …
#define OP_DEPEND …
static unsigned int operating_mode;
static bool depend_emit_phony = …;
static bool depend_missing_ok = …;
static const char *depend_target = …;
static const char *depend_file = …;
struct strlist *depend_list;
static bool want_usage;
static bool terminate_after_phase;
bool user_nolist = …;
static char *quote_for_pmake(const char *str);
static char *quote_for_wmake(const char *str);
static char *(*quote_for_make)(const char *) = …;
#if defined(OF_MACHO) || defined(OF_MACHO64)
extern bool macho_set_min_os(const char *str);
#endif
#define LIMIT_MAX_VAL …
int64_t nasm_limit[LIMIT_MAX+1];
struct limit_info { … };
static const struct limit_info limit_info[LIMIT_MAX+1] = …;
static void set_default_limits(void)
{ … }
enum directive_result
nasm_set_limit(const char *limit, const char *valstr)
{ … }
int64_t switch_segment(int32_t segment)
{ … }
static void set_curr_offs(int64_t l_off)
{ … }
static void increment_offset(int64_t delta)
{ … }
static void define_macros(void)
{ … }
static void preproc_init(struct strlist *ipath)
{ … }
static void emit_dependencies(struct strlist *list)
{ … }
static int64_t make_posix_time(const struct tm *tm)
{ … }
static char *nasm_quote_filename(const char *fn)
{ … }
static void timestamp(void)
{ … }
int main(int argc, char **argv)
{ … }
static char *get_param(char *p, char *q, bool *advance)
{ … }
static void copy_filename(const char **dst, const char *src, const char *what)
{ … }
static char *quote_for_pmake(const char *str)
{ … }
static char *quote_for_wmake(const char *str)
{ … }
enum text_options { … };
enum need_arg { … };
struct textargs { … };
static const struct textargs textopts[] = …;
static void show_version(void)
{ … }
static bool stopoptions = …;
static bool process_arg(char *p, char *q, int pass)
{ … }
#define ARG_BUF_DELTA …
static void process_respfile(FILE * rfile, int pass)
{ … }
static void process_args(char *args, int pass)
{ … }
static void process_response_file(const char *file, int pass)
{ … }
static void parse_cmdline(int argc, char **argv, int pass)
{ … }
static void forward_refs(insn *instruction)
{ … }
static void process_insn(insn *instruction)
{ … }
static void assemble_file(const char *fname, struct strlist *depend_list)
{ … }
static size_t warn_index(errflags severity)
{ … }
static bool skip_this_pass(errflags severity)
{ … }
static bool is_suppressed(errflags severity)
{ … }
static errflags true_error_type(errflags severity)
{ … }
static const char * const error_pfx_table[ERR_MASK+1] = …;
static const char no_file_name[] = …;
static fatal_func die_hard(errflags true_type, errflags severity)
{ … }
static struct src_location error_where(errflags severity)
{ … }
fatal_func nasm_verror_critical(errflags severity, const char *fmt, va_list args)
{ … }
struct nasm_errtext { … };
struct nasm_errhold { … };
static void nasm_free_error(struct nasm_errtext *et)
{ … }
static void nasm_issue_error(struct nasm_errtext *et);
struct nasm_errhold *nasm_error_hold_push(void)
{ … }
void nasm_error_hold_pop(struct nasm_errhold *eh, bool issue)
{ … }
void nasm_verror(errflags severity, const char *fmt, va_list args)
{ … }
static void nasm_issue_error(struct nasm_errtext *et)
{ … }
static void usage(void)
{ … }
static void help(FILE *out)
{ … }