This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] [tuples] some aux functions


On Fri, Feb 22, 2008 at 1:30 PM, Diego Novillo <dnovillo@google.com> wrote:
> On Fri, Feb 22, 2008 at 4:28 AM, Richard Guenther
>
> <richard.guenther@gmail.com> wrote:
>
>
> >  >  Good point.  In this case, all uses must be updated because it is no
>  >  >  longer possible to have conditionals of the form 'if (constant)'
>  >  >  anymore.
>  >
>  >  How are they represented now?
>
>  GIMPLE_COND <PREDICATE_CODE, LHS, RHS>

I see.  So in theory we could just add two new predicate codes
'TRUE' and 'FALSE', which regardless of LHS or RHS evaluate
to true or false.

Of course using 0 == 0 and 1 == 0 (or similar) would do also, though
that raises the question of what is the canonical form.  Is there
a gimple_set_cond_predicate() that accepts a tree (thus a result
from fold) that might be a simple 1 or 0?

Richard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]