aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/pt.c
diff options
context:
space:
mode:
authorMark Mitchell <mark@codesourcery.com>2001-03-15 02:51:03 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>2001-03-15 02:51:03 +0000
commit19e7881c81752c856edb9f71db93805ce0416be6 (patch)
treee937810f6aadde94067b96c8f65cc56fba667d87 /gcc/cp/pt.c
parentb894530e6d9633fc6497b3c404a3ec1bd1a341df (diff)
downloadgcc-19e7881c81752c856edb9f71db93805ce0416be6.zip
gcc-19e7881c81752c856edb9f71db93805ce0416be6.tar.gz
gcc-19e7881c81752c856edb9f71db93805ce0416be6.tar.bz2
varasm.c (assemble_alias): Use DECL_ASSEMBLER_NAME...
* varasm.c (assemble_alias): Use DECL_ASSEMBLER_NAME, not the contents of the RTL, to determine the name of the object. * tree.h (DECL_RTL): Allocate RTL lazily. (SET_DECL_RTL): New macro. (DECL_RTL_SET_P): Likewise. (COPY_DECL_RTL): Likewise. (DECL_RTL_IF_SET): Likewise. * varasm.c (make_decl_rtl): Add assertions about the kind of declaration we are processing. * c-decl.c (duplicate_decls): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc. (start_decl): Likewise. (finish_decl): Likewise. * c-semantics.c (emit_local_var): Likewise. * calls.c (expand_call): Likewise. * dbxout.c (dbxout_symbol): Likewise. * emit-rtl.c (unshare_all_rtl): Likewise. (unshare_all_decls): Likewise. (reset_used_decls): Likewise. * expr.c (store_constructor): Likewise. (safe_from_p): Likewise. (expand_expr): Likewise. * function.c (put_var_into_stack): Likewise. (instantiate_decls_1): Likewise. (assign_parms): Likewise. (expand_function_start): Likewise. (expand_function_end): Likewise. * ggc-common.c (gcc_mark_trees): Likewise. * integrate.c (function_cannot_inline_p): Likewise. (copy_decl_for_inlining): Likewise. (expand_inline_function): Likewise. (integrate_parm_decls): Likewise. (integrate_decl_tree): Likewise. * print-tree.c (print_node): Likewise. * reg-stack.c (stack_result): Likewise. * stmt.c (label_rtx): Likewise. (expand_return): Likewise. (expand_decl): Likewise. (expand_decl_cleanup): Likewise. (expand_anon_union_decl): Likewise. * toplev.c (check_global_declarations): Likewise. (rest_of_decl_compilation): Likewise. * tree.c (simple_cst_equal): Likewise. * objc/objc-act.c (generate_static_references): Likewise. * class.c (build_clone): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc. * cp-tree.h (DECL_IN_MEMORY_P): Likewise. * decl.c (duplicate_decls): Likewise. (builtin_function): Likewise. (build_library_fn): Likewise. (build_cp_library_fn): Likewise. (check_initializer): Likewise. (cp_finish_decl): Likewise. * decl2.c (grokfield): Likewise. (grok_function_init): Remove #if 0'd code. (finish_anon_union): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc. * friend.c (do_friend): Likewise. * init.c (get_temp_regvar): Likewise. * method.c (make_thunk): Likewise. * pt.c (tsubst_friend_function): Likewise. (tsubst_decl): Likewise. (regenerate_decl_from_template): Likewise. * semantics.c (genrtl_named_return_value): Likewise. (expand_body): Likewise. (genrtl_finish_function): Likewise. * tree.c (cp_tree_equal): Likewise. * com.c (ffecom_member_phase_2): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc. (duplicate_decls): Likewise. (start_decl): Likewise. * class.c (build_static_field_ref): Likewise. (make_method_value): Likewise. (get_dispatch_table): Likewise. * decl.c (push_jvm_slot): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc. From-SVN: r40482
Diffstat (limited to 'gcc/cp/pt.c')
-rw-r--r--gcc/cp/pt.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c
index 0994d67..3fa1cde 100644
--- a/gcc/cp/pt.c
+++ b/gcc/cp/pt.c
@@ -4617,8 +4617,7 @@ tsubst_friend_function (decl, args)
if (TREE_CODE (new_friend) != TEMPLATE_DECL)
{
set_mangled_name_for_decl (new_friend);
- DECL_RTL (new_friend) = 0;
- make_decl_rtl (new_friend, NULL_PTR);
+ SET_DECL_RTL (new_friend, NULL_RTX);
}
if (DECL_NAMESPACE_SCOPE_P (new_friend))
@@ -5870,8 +5869,7 @@ tsubst_decl (t, args, type)
set_mangled_name_for_template_decl (r);
}
- DECL_RTL (r) = 0;
- make_decl_rtl (r, NULL_PTR);
+ SET_DECL_RTL (r, NULL_RTX);
/* Like grokfndecl. If we don't do this, pushdecl will
mess up our TREE_CHAIN because it doesn't find a
@@ -6038,7 +6036,7 @@ tsubst_decl (t, args, type)
/* Don't try to expand the initializer until someone tries to use
this variable; otherwise we run into circular dependencies. */
DECL_INITIAL (r) = NULL_TREE;
- DECL_RTL (r) = 0;
+ SET_DECL_RTL (r, NULL_RTX);
DECL_SIZE (r) = DECL_SIZE_UNIT (r) = 0;
/* For __PRETTY_FUNCTION__ we have to adjust the initializer. */
@@ -9765,7 +9763,7 @@ regenerate_decl_from_template (decl, tmpl)
details. */
DECL_TI_TEMPLATE (new_decl) = DECL_TI_TEMPLATE (decl);
DECL_ASSEMBLER_NAME (new_decl) = DECL_ASSEMBLER_NAME (decl);
- DECL_RTL (new_decl) = DECL_RTL (decl);
+ COPY_DECL_RTL (decl, new_decl);
DECL_USE_TEMPLATE (new_decl) = DECL_USE_TEMPLATE (decl);
/* Call duplicate decls to merge the old and new declarations. */