diff options
author | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-11-02 19:19:15 +0000 |
---|---|---|
committer | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-11-02 19:19:15 +0000 |
commit | 5d8653611d40662f3ab728f64ddc7c692c5906f6 (patch) | |
tree | 0c4c2726c2bba5fd6d40290ce905447cc4decec4 /gcc/predict.c | |
parent | 88fa2d281161143bcd2be3a6073c7e5b6585700c (diff) | |
download | gcc-5d8653611d40662f3ab728f64ddc7c692c5906f6.tar.gz |
* predict.c (predict_loops): Do not predict infinite loops.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@193101 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/predict.c')
-rw-r--r-- | gcc/predict.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/predict.c b/gcc/predict.c index 9fc3e71e7b2..d27e04316ca 100644 --- a/gcc/predict.c +++ b/gcc/predict.c @@ -1403,6 +1403,11 @@ predict_loops (void) exits = get_loop_exit_edges (loop); n_exits = VEC_length (edge, exits); + if (!n_exits) + { + VEC_free (edge, heap, exits); + continue; + } FOR_EACH_VEC_ELT (edge, exits, j, ex) { |