Commit 4e64ba00 by Paul Thomas

re PR fortran/80440 (Slow compile when USEing modules)

2017-04-17  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/80440
	* module.c (find_symtree_for_symbol): Delete.
	(read_module): Remove the call to the above.

From-SVN: r246952
parent fb5e5621
2017-04-17 Paul Thomas <pault@gcc.gnu.org>
PR fortran/80440
* module.c (find_symtree_for_symbol): Delete.
(read_module): Remove the call to the above.
2017-04-14 Janus Weil <janus@gcc.gnu.org> 2017-04-14 Janus Weil <janus@gcc.gnu.org>
PR fortran/80361 PR fortran/80361
...@@ -5,9 +11,9 @@ ...@@ -5,9 +11,9 @@
the recursive attribute. the recursive attribute.
2017-04-10 Nicolas Koenig <koenigni@student.ethz.ch> 2017-04-10 Nicolas Koenig <koenigni@student.ethz.ch>
Paul Thomas <pault@gcc.gnu.org> Paul Thomas <pault@gcc.gnu.org>
PR fortran/69498 PR fortran/69498
* module.c (gfc_match_submodule): Add error * module.c (gfc_match_submodule): Add error
if function is called in the wrong state. if function is called in the wrong state.
...@@ -17,7 +23,7 @@ ...@@ -17,7 +23,7 @@
* expr.c (gfc_check_pointer_assign): Check if procedure pointer * expr.c (gfc_check_pointer_assign): Check if procedure pointer
components in a pointer assignment need an explicit interface. components in a pointer assignment need an explicit interface.
2017-03-18 Nicolas Koenig <koenigni@student.ethz.ch> 2017-03-18 Nicolas Koenig <koenigni@student.ethz.ch>
PR fortran/69498 PR fortran/69498
* symbol.c (gfc_delete_symtree): If there is a period in the name, ignore * symbol.c (gfc_delete_symtree): If there is a period in the name, ignore
......
...@@ -4292,31 +4292,6 @@ mio_symbol (gfc_symbol *sym) ...@@ -4292,31 +4292,6 @@ mio_symbol (gfc_symbol *sym)
/************************* Top level subroutines *************************/ /************************* Top level subroutines *************************/
/* Given a root symtree node and a symbol, try to find a symtree that
references the symbol that is not a unique name. */
static gfc_symtree *
find_symtree_for_symbol (gfc_symtree *st, gfc_symbol *sym)
{
gfc_symtree *s = NULL;
if (st == NULL)
return s;
s = find_symtree_for_symbol (st->right, sym);
if (s != NULL)
return s;
s = find_symtree_for_symbol (st->left, sym);
if (s != NULL)
return s;
if (st->n.sym == sym && !check_unique_name (st->name))
return st;
return s;
}
/* A recursive function to look for a specific symbol by name and by /* A recursive function to look for a specific symbol by name and by
module. Whilst several symtrees might point to one symbol, its module. Whilst several symtrees might point to one symbol, its
is sufficient for the purposes here than one exist. Note that is sufficient for the purposes here than one exist. Note that
...@@ -5119,16 +5094,6 @@ read_module (void) ...@@ -5119,16 +5094,6 @@ read_module (void)
info->u.rsym.referenced = 1; info->u.rsym.referenced = 1;
continue; continue;
} }
/* If possible recycle the symtree that references the symbol.
If a symtree is not found and the module does not import one,
a unique-name symtree is found by read_cleanup. */
st = find_symtree_for_symbol (gfc_current_ns->sym_root, sym);
if (st != NULL)
{
info->u.rsym.symtree = st;
info->u.rsym.referenced = 1;
}
} }
mio_rparen (); mio_rparen ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment