Patchwork Always make complex & vector variables registers

login
register
mail settings
Submitter Richard Guenther
Date June 16, 2010, 2:25 p.m.
Message ID <alpine.LNX.2.00.1006161624590.1429@zhemvz.fhfr.qr>
Download mbox | patch
Permalink /patch/55888/
State New
Headers show

Comments

Richard Guenther - June 16, 2010, 2:25 p.m.
The need to conditionalize on optimization is gone after we now
go into SSA at -O0.

Bootstrapped and tested on x86_64-unknown-linux-gnu, will apply
to trunk tomorrow if there aren't serious concerns.

Richard.

2010-06-16  Richard Guenther  <rguenther@suse.de>

	* gimplify.c (gimplify_bind_expr): Always promote complex
	and vector variables to registers if possible.

Patch

Index: gcc/gimplify.c
===================================================================
--- gcc/gimplify.c	(revision 160835)
+++ gcc/gimplify.c	(working copy)
@@ -1153,14 +1153,9 @@  gimplify_bind_expr (tree *expr_p, gimple
 
       /* Preliminarily mark non-addressed complex variables as eligible
 	 for promotion to gimple registers.  We'll transform their uses
-	 as we find them.
-	 We exclude complex types if not optimizing because they can be
-	 subject to partial stores in GNU C by means of the __real__ and
-	 __imag__ operators and we cannot promote them to total stores
-	 (see gimplify_modify_expr_complex_part).  */
-      if (optimize
-	  && (TREE_CODE (TREE_TYPE (t)) == COMPLEX_TYPE
-	      || TREE_CODE (TREE_TYPE (t)) == VECTOR_TYPE)
+	 as we find them.  */
+      if ((TREE_CODE (TREE_TYPE (t)) == COMPLEX_TYPE
+	   || TREE_CODE (TREE_TYPE (t)) == VECTOR_TYPE)
 	  && !TREE_THIS_VOLATILE (t)
 	  && (TREE_CODE (t) == VAR_DECL && !DECL_HARD_REGISTER (t))
 	  && !needs_to_live_in_memory (t))