This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] Fix PR rtl-optimization/68287
- From: Martin LiÅka <mliska at suse dot cz>
- To: Richard Biener <richard dot guenther at gmail dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 11 Nov 2015 12:18:25 +0100
- Subject: [PATCH] Fix PR rtl-optimization/68287
- Authentication-results: sourceware.org; auth=none
- References: <564081EF dot 7030003 at suse dot cz> <CAFiYyc2HnSMgWcPyrw6wKMKLqwZdSY0ZVDUR+WBLSz3gvN3aaQ at mail dot gmail dot com> <56409EEC dot 50803 at suse dot cz> <CAFiYyc0F2gUP3AEaPK9szUevia4pHEW9u1sVu=k4AbcDJ_wTUQ at mail dot gmail dot com>
Hi.
There's a fix for fallout of r230027.
Patch can bootstrap and survives regression tests on x86_64-linux-gnu.
Ready for trunk?
Thanks,
Martin
>From 127d629991d92ea42a87b84e9d88612b84dbec03 Mon Sep 17 00:00:00 2001
From: marxin <mliska@suse.cz>
Date: Wed, 11 Nov 2015 10:11:20 +0100
Subject: [PATCH 1/2] Fix PR rtl-optimization/68287
gcc/ChangeLog:
2015-11-11 Martin Liska <mliska@suse.cz>
PR rtl-optimization/68287
* lra-lives.c (lra_create_live_ranges_1): Clear the vector
with zeros.
---
gcc/lra-lives.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/lra-lives.c b/gcc/lra-lives.c
index 9453759..27887de 100644
--- a/gcc/lra-lives.c
+++ b/gcc/lra-lives.c
@@ -1242,7 +1242,7 @@ lra_create_live_ranges_1 (bool all_p, bool dead_insn_p)
curr_point = 0;
unsigned new_length = get_max_uid () * 2;
if (point_freq_vec.length () < new_length)
- point_freq_vec.safe_grow (new_length);
+ point_freq_vec.safe_grow_cleared (new_length);
lra_point_freq = point_freq_vec.address ();
int *post_order_rev_cfg = XNEWVEC (int, last_basic_block_for_fn (cfun));
int n_blocks_inverted = inverted_post_order_compute (post_order_rev_cfg);
--
2.6.2