[gcc r11-3255] Fix availability of functions in other partitions
Jan Hubicka
hubicka@gcc.gnu.org
Thu Sep 17 10:41:32 GMT 2020
https://gcc.gnu.org/g:27eac88a3f23ef7efbbd725504963cffc71dcad4
commit r11-3255-g27eac88a3f23ef7efbbd725504963cffc71dcad4
Author: Jan Hubicka <jh@suse.cz>
Date: Thu Sep 17 12:41:07 2020 +0200
Fix availability of functions in other partitions
* cgraph.c (cgraph_node::get_availability): Fix availability of
functions in other partitions
* varpool.c (varpool_node::get_availability): Likewise.
Diff:
---
gcc/cgraph.c | 2 +-
gcc/varpool.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gcc/cgraph.c b/gcc/cgraph.c
index c0b45795059..b43adaac7c0 100644
--- a/gcc/cgraph.c
+++ b/gcc/cgraph.c
@@ -2360,7 +2360,7 @@ cgraph_node::get_availability (symtab_node *ref)
ref = cref->inlined_to;
}
enum availability avail;
- if (!analyzed)
+ if (!analyzed && !in_other_partition)
avail = AVAIL_NOT_AVAILABLE;
else if (local)
avail = AVAIL_LOCAL;
diff --git a/gcc/varpool.c b/gcc/varpool.c
index 458cdf1bf37..31ea2132331 100644
--- a/gcc/varpool.c
+++ b/gcc/varpool.c
@@ -479,7 +479,7 @@ varpool_node::add (tree decl)
enum availability
varpool_node::get_availability (symtab_node *ref)
{
- if (!definition)
+ if (!definition && !in_other_partition)
return AVAIL_NOT_AVAILABLE;
if (!TREE_PUBLIC (decl))
return AVAIL_AVAILABLE;
More information about the Gcc-cvs
mailing list