diff options
author | vries <vries@138bc75d-0d04-0410-961f-82ee72b054a4> | 2017-08-06 09:56:25 +0000 |
---|---|---|
committer | vries <vries@138bc75d-0d04-0410-961f-82ee72b054a4> | 2017-08-06 09:56:25 +0000 |
commit | a2054420bcc321f13e17b3b76fcdc23c6fbc2457 (patch) | |
tree | c90229e1486a50867c66bff04e2d198839d7f365 | |
parent | 59cad7059ca27e14f9f7e248929165b0afd36f24 (diff) | |
download | gcc-a2054420bcc321f13e17b3b76fcdc23c6fbc2457.tar.gz |
Add missing edge probability in expand_oacc_for
;; basic block 10, loop depth 1, freq 0, maybe hot
;; prev block 9, next block 19, flags: (NEW, REACHABLE)
;; pred: 18 (FALSE_VALUE)
;; 9 (FALSE_VALUE)
GIMPLE_NOP
.chunk_no.7D.1948 = .chunk_no.7D.1948 + 1;
if (.chunk_no.7D.1948 < .chunk_max.6D.1949)
- goto <bb 18>; [INV] [count: INV]
+ goto <bb 18>; [80.01%] [count: INV]
else
- goto <bb 19>; [100.00%] [count: INV]
+ goto <bb 19>; [19.99%] [count: INV]
2017-08-06 Tom de Vries <tom@codesourcery.com>
* omp-expand.c (expand_oacc_for): Add missing edge probability for chunk
loop.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@250899 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/omp-expand.c | 4 |
2 files changed, 8 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index ea3b2e327bd..c06ef3f3633 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2017-08-06 Tom de Vries <tom@codesourcery.com> + + * omp-expand.c (expand_oacc_for): Add missing edge probability for chunk + loop. + 2017-08-04 Yury Gribov <tetra2005@gmail.com> PR tree-optimization/57371 diff --git a/gcc/omp-expand.c b/gcc/omp-expand.c index 970e04f71f8..5772bd9e4a3 100644 --- a/gcc/omp-expand.c +++ b/gcc/omp-expand.c @@ -5718,7 +5718,9 @@ expand_oacc_for (struct omp_region *region, struct omp_for_data *fd) /* Fixup edges from bottom_bb. */ split->flags ^= EDGE_FALLTHRU | EDGE_FALSE_VALUE; - make_edge (bottom_bb, head_bb, EDGE_TRUE_VALUE); + split->probability = profile_probability::unlikely ().guessed (); + edge latch_edge = make_edge (bottom_bb, head_bb, EDGE_TRUE_VALUE); + latch_edge->probability = profile_probability::likely ().guessed (); } } |