This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] Always make complex & vector variables registers
- From: Richard Guenther <rguenther at suse dot de>
- To: gcc-patches at gcc dot gnu dot org
- Date: Wed, 16 Jun 2010 16:25:59 +0200 (CEST)
- Subject: [PATCH] Always make complex & vector variables registers
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.
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))