diff options
author | Richard Henderson <rth@redhat.com> | 2001-10-08 09:46:24 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2001-10-08 09:46:24 -0700 |
commit | 6ba3b2142afa6dc34bc4946e3d147d768a5523b7 (patch) | |
tree | 1ef7f51a92bb7772d1a5442e68d47fb8473a35f9 /gcc | |
parent | 31ed8fea3d618377c79be11b05f41539df915cc4 (diff) | |
download | gcc-6ba3b2142afa6dc34bc4946e3d147d768a5523b7.zip gcc-6ba3b2142afa6dc34bc4946e3d147d768a5523b7.tar.gz gcc-6ba3b2142afa6dc34bc4946e3d147d768a5523b7.tar.bz2 |
varasm.c (restore_varasm_status): New.
* varasm.c (restore_varasm_status): New.
* function.h: Declare it.
* function.c (pop_function_context_from): Call it.
From-SVN: r46080
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/function.c | 1 | ||||
-rw-r--r-- | gcc/function.h | 1 | ||||
-rw-r--r-- | gcc/varasm.c | 17 |
4 files changed, 25 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 353151b..182fd9c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,11 @@ 2001-10-08 Richard Henderson <rth@redhat.com> + * varasm.c (restore_varasm_status): New. + * function.h: Declare it. + * function.c (pop_function_context_from): Call it. + +2001-10-08 Richard Henderson <rth@redhat.com> + * c-common.h (struct c_lang_decl): Add declared_inline. * c-tree.h (DECL_DECLARED_INLINE_P): New. * c-lang.c (c_disregard_inline_limits): Use it. diff --git a/gcc/function.c b/gcc/function.c index fed2b3b..086fdc6 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -386,6 +386,7 @@ pop_function_context_from (context) reg_renumber = 0; restore_emit_status (p); + restore_varasm_status (p); if (restore_lang_status) (*restore_lang_status) (p); diff --git a/gcc/function.h b/gcc/function.h index 8eeda3a..c441960 100644 --- a/gcc/function.h +++ b/gcc/function.h @@ -592,6 +592,7 @@ extern void free_after_parsing PARAMS ((struct function *)); extern void free_after_compilation PARAMS ((struct function *)); extern void init_varasm_status PARAMS ((struct function *)); +extern void restore_varasm_status PARAMS ((struct function *)); extern void free_varasm_status PARAMS ((struct function *)); extern void free_emit_status PARAMS ((struct function *)); extern void free_stmt_status PARAMS ((struct function *)); diff --git a/gcc/varasm.c b/gcc/varasm.c index b2ce9a6..d2a59d8 100644 --- a/gcc/varasm.c +++ b/gcc/varasm.c @@ -3493,6 +3493,23 @@ init_varasm_status (f) p->x_const_double_chain = 0; } +/* Nested functions diddle with our const_double_chain via + clear_const_double_mem and const_tiny_rtx. Remove these + entries from our const_double_chain. */ + +void +restore_varasm_status (f) + struct function *f; +{ + rtx *p = &f->varasm->x_const_double_chain; + + while (*p) + if (CONST_DOUBLE_MEM (*p) == cc0_rtx) + *p = CONST_DOUBLE_CHAIN (*p); + else + p = &CONST_DOUBLE_CHAIN (*p); +} + /* Mark PC for GC. */ static void |