Patchwork Fix vectorizable_reduction leak (PR middle-end/56461)

login
register
mail settings
Submitter Jakub Jelinek
Date Feb. 27, 2013, 8:22 p.m.
Message ID <20130227202256.GR12913@tucnak.redhat.com>
Download mbox | patch
Permalink /patch/223697/
State New
Headers show

Comments

Jakub Jelinek - Feb. 27, 2013, 8:22 p.m.
Hi!

Another leak, this time in vectorizable_reduction.

Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?

2013-02-27  Jakub Jelinek  <jakub@redhat.com>

	PR middle-end/56461
	* tree-vect-loop.c (vectorizable_reduction): Release vect_defs
	vector.


	Jakub
Jeff Law - Feb. 27, 2013, 9:37 p.m.
On 02/27/2013 01:22 PM, Jakub Jelinek wrote:
> Hi!
>
> Another leak, this time in vectorizable_reduction.
>
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
>
> 2013-02-27  Jakub Jelinek  <jakub@redhat.com>
>
> 	PR middle-end/56461
> 	* tree-vect-loop.c (vectorizable_reduction): Release vect_defs
> 	vector.
>
> --- gcc/tree-vect-loop.c.jj	2013-02-19 10:11:50.000000000 +0100
> +++ gcc/tree-vect-loop.c	2013-02-27 18:15:48.981253386 +0100
> @@ -5209,6 +5209,7 @@ vectorizable_reduction (gimple stmt, gim
>                                       double_reduc, slp_node);
>
>     phis.release ();
> +  vect_defs.release ();
>     vec_oprnds0.release ();
>     vec_oprnds1.release ();
OK.
jeff

Patch

--- gcc/tree-vect-loop.c.jj	2013-02-19 10:11:50.000000000 +0100
+++ gcc/tree-vect-loop.c	2013-02-27 18:15:48.981253386 +0100
@@ -5209,6 +5209,7 @@  vectorizable_reduction (gimple stmt, gim
                                     double_reduc, slp_node);
 
   phis.release ();
+  vect_defs.release ();
   vec_oprnds0.release ();
   vec_oprnds1.release ();