This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: COND_EXPRs in GIMPLE code and vectorizer
- From: "Daniel Berlin" <dberlin at dberlin dot org>
- To: "Roberto COSTA" <roberto dot costa at st dot com>
- Cc: "GCC mailing list" <gcc at gcc dot gnu dot org>
- Date: Wed, 27 Sep 2006 09:04:48 -0400
- Subject: Re: COND_EXPRs in GIMPLE code and vectorizer
- References: <451A6B85.2060604@st.com>
On 9/27/06, Roberto COSTA <roberto.costa@st.com> wrote:
Hello,
I have a question about the form of COND_EXPR nodes allowed in GIMPLE
representation.
By looking at what gimplify.c does (more precisely, at function
gimplify_cond_expr (...) ), I understood that GIMPLE only allows a
restricted form of COND_EXPR, in which both 'then' and 'else' operands
are GOTO_EXPR nodes.
This is true for the conditional form that appears as a statement
However, when compiling with -ftree-vectorize command-line option, there
are cases of COND_EXPR nodes generated and not gimplified (in the sense
of my previous sentence).
However, it is possible for them to also appear on the RHS of a
MODIFY_EXPR in order to represent the results of if-conversion.
IE
a = b ? c : d
In this form, I believe each arm is required to be an SSA_VAR_P
The way to differentiate the two is that the first form *only* appears
as a statement, and the second form *only* appears on the RHS of a
MODIFY_EXPR.
HTH,
Dan