diff options
author | Jason Merrill <jason@redhat.com> | 2001-11-19 06:28:52 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2001-11-19 06:28:52 -0500 |
commit | aa6ad1a68bf94672cbc9f4c3aef60640cbc95a0a (patch) | |
tree | 4656c8e74eb6eaa6a7769cb24904b1f293ae4ef4 | |
parent | 55d56a9096cc459870a18fdef5c8fcfdd270ba9a (diff) | |
download | gcc-aa6ad1a68bf94672cbc9f4c3aef60640cbc95a0a.zip gcc-aa6ad1a68bf94672cbc9f4c3aef60640cbc95a0a.tar.gz gcc-aa6ad1a68bf94672cbc9f4c3aef60640cbc95a0a.tar.bz2 |
cppmacro.c (_cpp_backup_tokens): Pop cur_run before decrementing cur_token, not after.
* cppmacro.c (_cpp_backup_tokens): Pop cur_run before decrementing
cur_token, not after.
* config/clipper/clix.h, config/h8300/elf.h, config/mips/linux.h:
Lose ASM_OUTPUT_CONSTRUCTOR.
* system.h: Poison it and INT_ASM_OP.
* c-lang.c (finish_file): Don't check for it.
* libgcc2.c (L_ctors): Check TARGET_ASM_CONSTRUCTOR instead.
From-SVN: r47169
-rw-r--r-- | gcc/ChangeLog | 11 | ||||
-rw-r--r-- | gcc/c-lang.c | 6 | ||||
-rw-r--r-- | gcc/config/clipper/clix.h | 2 | ||||
-rw-r--r-- | gcc/config/h8300/elf.h | 2 | ||||
-rw-r--r-- | gcc/config/mips/linux.h | 23 | ||||
-rw-r--r-- | gcc/cppmacro.c | 2 | ||||
-rw-r--r-- | gcc/libgcc2.c | 2 | ||||
-rw-r--r-- | gcc/system.h | 7 |
8 files changed, 20 insertions, 35 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a3fd987..cdce1b9 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,14 @@ +2001-11-19 Jason Merrill <jason@redhat.com> + + * cppmacro.c (_cpp_backup_tokens): Pop cur_run before decrementing + cur_token, not after. + + * config/clipper/clix.h, config/h8300/elf.h, config/mips/linux.h: + Lose ASM_OUTPUT_CONSTRUCTOR. + * system.h: Poison it and INT_ASM_OP. + * c-lang.c (finish_file): Don't check for it. + * libgcc2.c (L_ctors): Check TARGET_ASM_CONSTRUCTOR instead. + 2001-11-18 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> * mmix.c (mmix_cc1_ignored_option): Const-ify. diff --git a/gcc/c-lang.c b/gcc/c-lang.c index 5a82c59..54f86df 100644 --- a/gcc/c-lang.c +++ b/gcc/c-lang.c @@ -203,7 +203,6 @@ lookup_objc_ivar (id) return 0; } -#if !defined(ASM_OUTPUT_CONSTRUCTOR) || !defined(ASM_OUTPUT_DESTRUCTOR) extern tree static_ctors; extern tree static_dtors; @@ -253,7 +252,6 @@ finish_cdtor (body) finish_function (0); } -#endif /* Register a function tree, so that its optimization and conversion to RTL is only done at the end of the compilation. */ @@ -307,7 +305,6 @@ finish_file () VARRAY_FREE (deferred_fns); -#ifndef ASM_OUTPUT_CONSTRUCTOR if (static_ctors) { tree body = start_cdtor ('I'); @@ -318,8 +315,6 @@ finish_file () finish_cdtor (body); } -#endif -#ifndef ASM_OUTPUT_DESTRUCTOR if (static_dtors) { tree body = start_cdtor ('D'); @@ -330,7 +325,6 @@ finish_file () finish_cdtor (body); } -#endif if (back_end_hook) (*back_end_hook) (getdecls ()); diff --git a/gcc/config/clipper/clix.h b/gcc/config/clipper/clix.h index bce6979..b066754 100644 --- a/gcc/config/clipper/clix.h +++ b/gcc/config/clipper/clix.h @@ -83,7 +83,7 @@ do { \ and CTOR_LIST_END to contribute to the .init section an instruction to push a word containing 0 (or some equivalent of that). - ASM_OUTPUT_CONSTRUCTOR should be defined to push the address of the + TARGET_ASM_CONSTRUCTOR should be defined to push the address of the constructor. */ #define CTOR_LIST_BEGIN \ diff --git a/gcc/config/h8300/elf.h b/gcc/config/h8300/elf.h index 20aa4cf..dcfb5e9 100644 --- a/gcc/config/h8300/elf.h +++ b/gcc/config/h8300/elf.h @@ -10,8 +10,6 @@ #undef DTORS_SECTION_ASM_OP #undef INIT_SECTION_ASM_OP #undef READONLY_DATA_SECTION -#undef ASM_OUTPUT_CONSTRUCTOR -#undef ASM_OUTPUT_DESTRUCTOR #undef TARGET_ASM_NAMED_SECTION #undef TARGET_MEM_FUNCTIONS #undef PREFERRED_DEBUGGING_TYPE diff --git a/gcc/config/mips/linux.h b/gcc/config/mips/linux.h index b51ee2b..2dad6a0 100644 --- a/gcc/config/mips/linux.h +++ b/gcc/config/mips/linux.h @@ -117,29 +117,6 @@ void FN () \ } \ } -/* A C statement (sans semicolon) to output an element in the table of - global constructors. */ -#undef ASM_OUTPUT_CONSTRUCTOR -#define ASM_OUTPUT_CONSTRUCTOR(FILE,NAME) \ - do { \ - ctors_section (); \ - fprintf (FILE, "\t%s\t", TARGET_LONG64 ? ".dword" : ".word"); \ - assemble_name (FILE, NAME); \ - fprintf (FILE, "\n"); \ - } while (0) - - -/* A C statement (sans semicolon) to output an element in the table of - global destructors. */ -#undef ASM_OUTPUT_DESTRUCTOR -#define ASM_OUTPUT_DESTRUCTOR(FILE,NAME) \ - do { \ - dtors_section (); \ - fprintf (FILE, "\t%s\t", TARGET_LONG64 ? ".dword" : ".word"); \ - assemble_name (FILE, NAME); \ - fprintf (FILE, "\n"); \ - } while (0) - #undef TARGET_VERSION #if TARGET_ENDIAN_DEFAULT == 0 #define TARGET_VERSION fprintf (stderr, " (MIPSel GNU/Linux with ELF)"); diff --git a/gcc/cppmacro.c b/gcc/cppmacro.c index 4fb2df9..dbee62d 100644 --- a/gcc/cppmacro.c +++ b/gcc/cppmacro.c @@ -1087,12 +1087,12 @@ _cpp_backup_tokens (pfile, count) pfile->lookaheads += count; while (count--) { - pfile->cur_token--; if (pfile->cur_token == pfile->cur_run->base) { pfile->cur_run = pfile->cur_run->prev; pfile->cur_token = pfile->cur_run->limit; } + pfile->cur_token--; } } else diff --git a/gcc/libgcc2.c b/gcc/libgcc2.c index 2ac66b1..5d42436 100644 --- a/gcc/libgcc2.c +++ b/gcc/libgcc2.c @@ -2834,7 +2834,7 @@ SYMBOL__MAIN () Long term no port should use those extensions. But many still do. */ #if !defined(INIT_SECTION_ASM_OP) && !defined(CTOR_LISTS_DEFINED_EXTERNALLY) -#if defined (ASM_OUTPUT_CONSTRUCTOR) || defined (USE_COLLECT2) +#if defined (TARGET_ASM_CONSTRUCTOR) || defined (USE_COLLECT2) func_ptr __CTOR_LIST__[2] = {0, 0}; func_ptr __DTOR_LIST__[2] = {0, 0}; #else diff --git a/gcc/system.h b/gcc/system.h index aaec2f8..03c3223 100644 --- a/gcc/system.h +++ b/gcc/system.h @@ -603,7 +603,12 @@ typedef union tree_node *tree; VALID_MACHINE_DECL_ATTRIBUTE VALID_MACHINE_TYPE_ATTRIBUTE \ SET_DEFAULT_TYPE_ATTRIBUTES SET_DEFAULT_DECL_ATTRIBUTES \ MERGE_MACHINE_TYPE_ATTRIBUTES MERGE_MACHINE_DECL_ATTRIBUTES \ - MD_INIT_BUILTINS MD_EXPAND_BUILTIN + MD_INIT_BUILTINS MD_EXPAND_BUILTIN ASM_OUTPUT_CONSTRUCTOR \ + ASM_OUTPUT_DESTRUCTOR + +/* And other obsolete target macros. */ + #pragma GCC poison INT_ASM_OP + #endif /* IN_GCC */ /* Note: not all uses of the `index' token (e.g. variable names and |