diff options
author | Paul Thomas <pault@gcc.gnu.org> | 2017-04-17 18:22:03 +0000 |
---|---|---|
committer | Paul Thomas <pault@gcc.gnu.org> | 2017-04-17 18:22:03 +0000 |
commit | 4e64ba0091fe74dc3835d7d13eab011113840ab6 (patch) | |
tree | 8f8c91fca83f542ab8f43778c8026cf10c76b5b3 /gcc/fortran/module.c | |
parent | fb5e5621003312f08d6a50c5043cbc43aa6709d1 (diff) | |
download | gcc-4e64ba0091fe74dc3835d7d13eab011113840ab6.zip gcc-4e64ba0091fe74dc3835d7d13eab011113840ab6.tar.gz gcc-4e64ba0091fe74dc3835d7d13eab011113840ab6.tar.bz2 |
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
Diffstat (limited to 'gcc/fortran/module.c')
-rw-r--r-- | gcc/fortran/module.c | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/gcc/fortran/module.c b/gcc/fortran/module.c index 28b8ea1..4d6afa5 100644 --- a/gcc/fortran/module.c +++ b/gcc/fortran/module.c @@ -4292,31 +4292,6 @@ mio_symbol (gfc_symbol *sym) /************************* 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 module. Whilst several symtrees might point to one symbol, its is sufficient for the purposes here than one exist. Note that @@ -5119,16 +5094,6 @@ read_module (void) info->u.rsym.referenced = 1; 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 (); |