Hi
Please ignore the previous mail.
在 2019/3/1 下午10:17, Segher Boessenkool 写道:
Hi!
On Fri, Mar 01, 2019 at 04:39:38PM +0800, JunMa wrote:
Since MAX_INLINE_INSNS_AUTO should be below or equal to
MAX_INLINE_INSNS_SINGLE (see params.def), there is no need
to do second inlining limit check on growth when function not
declared inline, this patch removes it.
Bootstrapped and tested on x86_64-unknown-linux-gnu, is it ok for trunk?
Your mail subject says this is for GCC 10, but you are asking for GCC 9
now; which is it?
Since we are in GCC9 stage4 now, also it's not for regression fix.
So, it's for GCC 10.
2019-03-01 Jun Ma <ju...@linux.alibaba.com>
*ipa-inline.c(want_inline_small_function_p): Remove
redundant growth check when function not declared
inline
Some spaces were lost in the first line. Trailing space. Sentences
should end with a full stop (or similar).
Don't send patches (or pretty much anything else) as
application/octet-stream attachments.
Segher
Sorry again for this. Here is the full change.
JunMa
2019-03-01 Jun Ma<ju...@linux.alibaba.com>
* ipa-inline.c(want_inline_small_function_p): Remove
redundant growth check when function not declared
inline.
diff --git a/gcc/ipa-inline.c b/gcc/ipa-inline.c
index 360c3de..ff9bc9e 100644
--- a/gcc/ipa-inline.c
+++ b/gcc/ipa-inline.c
@@ -837,15 +837,11 @@ want_inline_small_function_p (struct cgraph_edge *e, bool
report)
? MAX (MAX_INLINE_INSNS_AUTO,
MAX_INLINE_INSNS_SINGLE)
: MAX_INLINE_INSNS_AUTO)
- && !(big_speedup == -1 ? big_speedup_p (e) : big_speedup))
+ && !(big_speedup == -1 ? big_speedup_p (e) : big_speedup)
+ && growth_likely_positive (callee, growth))
{
- /* growth_likely_positive is expensive, always test it last. */
- if (growth >= MAX_INLINE_INSNS_SINGLE
- || growth_likely_positive (callee, growth))
- {
- e->inline_failed = CIF_MAX_INLINE_INSNS_AUTO_LIMIT;
- want_inline = false;
- }
+ e->inline_failed = CIF_MAX_INLINE_INSNS_AUTO_LIMIT;
+ want_inline = false;
}
/* If call is cold, do not inline when function body would grow. */
else if (!e->maybe_hot_p ()