This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Fix scope tree for versioned functions


I'm testing this separately currently and will apply if it succeeds.
Otherwise we'll end up with BLOCKs w/o a supercontext.

Richard.

2011-02-25  Richard Guenther  <rguenther@suse.de>

	* tree-inline.c (tree_function_versioning): Set BLOCK_SUPERCONTEXT
	of the copied scope tree.

Index: gcc/tree-inline.c
===================================================================
*** gcc/tree-inline.c	(revision 170492)
--- gcc/tree-inline.c	(working copy)
*************** tree_function_versioning (tree old_decl,
*** 5156,5161 ****
--- 5156,5162 ----
        				     args_to_skip, &vars);
  
    DECL_INITIAL (new_decl) = remap_blocks (DECL_INITIAL (id.src_fn), &id);
+   BLOCK_SUPERCONTEXT (DECL_INITIAL (new_decl)) = new_decl;
  
    declare_inline_vars (DECL_INITIAL (new_decl), vars);
  


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]