aboutsummaryrefslogtreecommitdiff
path: root/gcc/symtab.c
diff options
context:
space:
mode:
authorJan Hubicka <hubicka@ucw.cz>2017-01-02 00:31:53 +0100
committerJan Hubicka <hubicka@gcc.gnu.org>2017-01-01 23:31:53 +0000
commite2940b9866250249d464d3c4bef6ae1ecbcc74e5 (patch)
tree542aae0715cf7464cfdd0d4bca7550402fe7bf6f /gcc/symtab.c
parent613be1c85d462313bcecd471a3b17802a4aaab7e (diff)
downloadgcc-e2940b9866250249d464d3c4bef6ae1ecbcc74e5.zip
gcc-e2940b9866250249d464d3c4bef6ae1ecbcc74e5.tar.gz
gcc-e2940b9866250249d464d3c4bef6ae1ecbcc74e5.tar.bz2
re PR ipa/77674 (ICE in binds_to_current_def_p with -fkeep-inline-functions)
PR middle-end/77674 * symtab.c (symtab_node::binds_to_current_def_p): Fix handling of transparent aliases. PR middle-end/77674 * g++.dg/torture/pr77674.C: New testcase. From-SVN: r243997
Diffstat (limited to 'gcc/symtab.c')
-rw-r--r--gcc/symtab.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/symtab.c b/gcc/symtab.c
index 1c2ada4..de87b5e 100644
--- a/gcc/symtab.c
+++ b/gcc/symtab.c
@@ -2214,6 +2214,9 @@ symtab_node::binds_to_current_def_p (symtab_node *ref)
{
if (!definition)
return false;
+ if (transparent_alias)
+ return definition
+ && get_alias_target()->binds_to_current_def_p (ref);
if (decl_binds_to_current_def_p (decl))
return true;
@@ -2225,8 +2228,6 @@ symtab_node::binds_to_current_def_p (symtab_node *ref)
if (DECL_EXTERNAL (decl))
return false;
- if (!externally_visible)
- debug ();
gcc_assert (externally_visible);
if (ref)