public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH GCC][02/13]Skip distribution if there is no loop
@ 2017-06-12 17:02 Bin Cheng
  2017-06-13 10:45 ` Richard Biener
  2017-06-27 17:07 ` Jeff Law
  0 siblings, 2 replies; 3+ messages in thread
From: Bin Cheng @ 2017-06-12 17:02 UTC (permalink / raw)
  To: gcc-patches; +Cc: nd

[-- Attachment #1: Type: text/plain, Size: 264 bytes --]

Hi,
this is a simple patch skipping distribution if there is no loop at all.

Bootstrap and test on x86_64 and AArch64.  Is it OK?

Thanks,
bin

2017-06-07  Bin Cheng  <bin.cheng@arm.com>

	* cfgloop.h (pass_loop_distribution::execute): Skip if no loops.

[-- Attachment #2: 0002-fast-return-20170607.txt --]
[-- Type: text/plain, Size: 743 bytes --]

From eb6a795331efde92fd6df1c6e612fb1ffa9f482f Mon Sep 17 00:00:00 2001
From: Bin Cheng <binche01@e108451-lin.cambridge.arm.com>
Date: Fri, 9 Jun 2017 09:30:40 +0100
Subject: [PATCH 02/14] fast-return-20170607.txt

---
 gcc/tree-loop-distribution.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gcc/tree-loop-distribution.c b/gcc/tree-loop-distribution.c
index a60454b..9f0c801 100644
--- a/gcc/tree-loop-distribution.c
+++ b/gcc/tree-loop-distribution.c
@@ -1758,6 +1758,9 @@ pass_loop_distribution::execute (function *fun)
   control_dependences *cd = NULL;
   auto_vec<loop_p> loops_to_be_destroyed;
 
+  if (number_of_loops (fun) <= 1)
+    return 0;
+
   FOR_ALL_BB_FN (bb, fun)
     {
       gimple_stmt_iterator gsi;
-- 
1.9.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH GCC][02/13]Skip distribution if there is no loop
  2017-06-12 17:02 [PATCH GCC][02/13]Skip distribution if there is no loop Bin Cheng
@ 2017-06-13 10:45 ` Richard Biener
  2017-06-27 17:07 ` Jeff Law
  1 sibling, 0 replies; 3+ messages in thread
From: Richard Biener @ 2017-06-13 10:45 UTC (permalink / raw)
  To: Bin Cheng; +Cc: gcc-patches, nd

On Mon, Jun 12, 2017 at 7:02 PM, Bin Cheng <Bin.Cheng@arm.com> wrote:
> Hi,
> this is a simple patch skipping distribution if there is no loop at all.
>
> Bootstrap and test on x86_64 and AArch64.  Is it OK?
> Thanks,
> bin
>
> 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
>
>         * cfgloop.h (pass_loop_distribution::execute): Skip if no loops.

tree-loop-distribution.c

Ok.

Richard.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH GCC][02/13]Skip distribution if there is no loop
  2017-06-12 17:02 [PATCH GCC][02/13]Skip distribution if there is no loop Bin Cheng
  2017-06-13 10:45 ` Richard Biener
@ 2017-06-27 17:07 ` Jeff Law
  1 sibling, 0 replies; 3+ messages in thread
From: Jeff Law @ 2017-06-27 17:07 UTC (permalink / raw)
  To: Bin Cheng, gcc-patches; +Cc: nd

On 06/12/2017 11:02 AM, Bin Cheng wrote:
> Hi,
> this is a simple patch skipping distribution if there is no loop at all.
> 
> Bootstrap and test on x86_64 and AArch64.  Is it OK?
> 
> Thanks,
> bin
> 
> 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
> 
> 	* cfgloop.h (pass_loop_distribution::execute): Skip if no loops.
> 
OK.
jeff

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-06-27 17:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-12 17:02 [PATCH GCC][02/13]Skip distribution if there is no loop Bin Cheng
2017-06-13 10:45 ` Richard Biener
2017-06-27 17:07 ` Jeff Law

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).