diff options
author | Ken Raeburn <raeburn@cygnus> | 1994-12-20 22:42:03 +0000 |
---|---|---|
committer | Ken Raeburn <raeburn@cygnus> | 1994-12-20 22:42:03 +0000 |
commit | 87e48495014d9a1d075e7c99aeb9cb29daccc796 (patch) | |
tree | 12f68295b61f65ec259118b7107e7b7ed9d9e418 /gas/as.c | |
parent | 0427f3ec1c0f0d356e6c1e4a91e8ff116f0c3ee8 (diff) | |
download | gdb-87e48495014d9a1d075e7c99aeb9cb29daccc796.zip gdb-87e48495014d9a1d075e7c99aeb9cb29daccc796.tar.gz gdb-87e48495014d9a1d075e7c99aeb9cb29daccc796.tar.bz2 |
* frags.c (frag_init): Call obstack_begin on `frags'.
* subsegs.c (subsegs_begin): Don't do it here.
* as.c (main): Call frag_init before subsegs_begin.
* frags.c (frag_append_1_char): New function.
* frags.h (frag_append_1_char): Declare it.
(FRAG_APPEND_1_CHAR): Call it. Old definition is commented out for now.
* as.h (struct frag): Added (but commented out) new fields for tracking current
alignment.
(frag_now_fix): Changed macro to function declaration.
* frags.c (frag_now_fix): Define function here.
(frag_new): Use it instead of accessing `frags' directly.
* frags.h (frags): Change comment to indicate it shouldn't be accessed directly.
* subsegs.h (struct frchain): New field frch_obstack, intended to eventually
replace global `frags' obstack.
* subsegs.c (subseg_set_rest): Use frag_now_fix instead of accessing `frags'
directly. Initialize fields of new frchainS explicitly instead of with memset.
* config/obj-coff.c (obj_coff_ln) [!BFD_ASSEMBLER]: Use frag_now_fix.
* config/tc-mips.c (s_loc), config/obj-vms.c (vms_resolve_symbol_redef),
symbols.c (colon): Likewise.
Diffstat (limited to 'gas/as.c')
-rw-r--r-- | gas/as.c | 55 |
1 files changed, 12 insertions, 43 deletions
@@ -41,20 +41,6 @@ #include "subsegs.h" #include "output-file.h" -#include <signal.h> - -#ifndef SIGTY -#ifdef __STDC__ -#define SIGTY void -#else -#define SIGTY int -#endif /* __STDC__ */ -#endif /* SIGTY */ - -#if 0 -/* Not currently used. */ -static SIGTY got_sig PARAMS ((int sig)); -#endif static void perform_an_assembly_pass PARAMS ((int argc, char **argv)); int listing; /* true if a listing is wanted */ @@ -373,20 +359,11 @@ main (argc, argv) HOST_SPECIAL_INIT (argc, argv); #endif -#if 0 /* do we need any of this?? */ - { - static const int sig[] = {SIGHUP, SIGINT, SIGPIPE, SIGTERM, 0}; - int a; - - for (a = 0; sig[a] != 0; a++) - if (signal (sig[a], SIG_IGN) != SIG_IGN) - signal (sig[a], got_sig); - } -#endif - myname = argv[0]; xmalloc_set_program_name (myname); + START_PROGRESS (myname, 0); + #ifndef OBJ_DEFAULT_OUTPUT_FILE_NAME #define OBJ_DEFAULT_OUTPUT_FILE_NAME "a.out" #endif @@ -397,13 +374,17 @@ main (argc, argv) bfd_init (); #endif + PROGRESS (1); symbol_begin (); + frag_init (); subsegs_begin (); read_begin (); input_scrub_begin (); - frag_init (); + PROGRESS (1); parse_args (&argc, &argv); + PROGRESS (1); + #ifdef BFD_ASSEMBLER output_file_create (out_file_name); assert (stdoutput != 0); @@ -413,6 +394,8 @@ main (argc, argv) tc_init_after_args (); #endif + PROGRESS (1); + perform_an_assembly_pass (argc, argv); /* Assemble it. */ #ifdef TC_I960 brtab_emit (); @@ -452,6 +435,8 @@ main (argc, argv) md_end (); #endif + END_PROGRESS (myname); + if (flag_print_statistics) { extern char **environ; @@ -563,6 +548,7 @@ perform_an_assembly_pass (argc, argv) { if (*argv) { /* Is it a file-name argument? */ + PROGRESS (1); saw_a_file++; /* argv->"" if stdin desired, else->filename */ read_a_source_file (*argv); @@ -572,22 +558,5 @@ perform_an_assembly_pass (argc, argv) if (!saw_a_file) read_a_source_file (""); } /* perform_an_assembly_pass() */ - -#if 0 -/* This is not currently used. */ -static SIGTY -got_sig (sig) - int sig; -{ - static here_before = 0; - - as_bad ("Interrupted by signal %d", sig); - if (here_before++) - exit (EXIT_FAILURE); -#if 0 /* If SIGTY is void, this produces warnings. */ - return ((SIGTY) 0); -#endif -} -#endif /* end of as.c */ |