This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] Use of build_binary_op
On Wed, 25 Sep 2002 17:19:18 +0200, Pop Sébastian <pop@gauvain.u-strasbg.fr> wrote:
> On Wed, Sep 25, 2002 at 01:57:08PM +0100, Jason Merrill wrote:
>> On Wed, 25 Sep 2002 01:55:53 +0200, Pop Sébastian <pop@gauvain.u-strasbg.fr> wrote:
>>
>> > I think we'll need an interface for building GIMPLE trees instead of
>> > using generic functions as build or build1 ...
>>
>> What do you have in mind?
>>
>
> It is possible to provide functions like:
>
> tree gimple_build_if (tree cond, tree then_clause, tree else_clause)
> tree gimple_build_loop (tree stop_cond, tree)
> ...
Sure, that makes sense.
> All these functions guarantee that the result belongs to GIMPLE.
> Instead of verifying that a tree is under its simple form (is_simple_* interface),
> you just build the correct simple form.
I'm planning to do away with is_simple_* soon.
> I don't say that we have to switch from the lowering of C/C++ trees to
> this translation point of view
I don't see the distinction. Lowering of C/C++ trees involves this sort of
translation...
> but I just say that this interface could be useful
> - for other front-ends that cannot lower their initial AST into GIMPLE,
...as would lowering other sorts of trees.
Jason