diff options
Diffstat (limited to 'gcc/ipa-inline.c')
-rw-r--r-- | gcc/ipa-inline.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ipa-inline.c b/gcc/ipa-inline.c index 5d50bb43604..d1f0089eb83 100644 --- a/gcc/ipa-inline.c +++ b/gcc/ipa-inline.c @@ -1911,7 +1911,15 @@ inline_always_inline_functions (struct cgraph_node *node) } if (!can_early_inline_edge_p (e)) - continue; + { + /* Set inlined to true if the callee is marked "always_inline" but + is not inlinable. This will allow flagging an error later in + expand_call_inline in tree-inline.c. */ + if (lookup_attribute ("always_inline", + DECL_ATTRIBUTES (callee->symbol.decl)) != NULL) + inlined = true; + continue; + } if (dump_file) fprintf (dump_file, " Inlining %s into %s (always_inline).\n", |