This is the mail archive of the
mailing list for the GCC project.
Re: [tree-ssa] SWITCH_EXPR lowering
- From: Richard Henderson <rth at redhat dot com>
- To: Jan Hubicka <jh at suse dot cz>
- Cc: Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dot cz>, Andrew MacLeod <amacleod at redhat dot com>, gcc-patches <gcc-patches at gcc dot gnu dot org>, Jeff Law <law at redhat dot com>, Diego Novillo <dnovillo at redhat dot com>
- Date: Sat, 1 Nov 2003 11:50:19 -0800
- Subject: Re: [tree-ssa] SWITCH_EXPR lowering
- References: <1067017615.14175.3094.camel@p4> <20031024175758.GB17291@atrey.karlin.mff.cuni.cz> <1067030697.14175.3476.camel@p4> <20031024213156.GA22864@atrey.karlin.mff.cuni.cz> <1067032171.21257.3504.camel@p4> <1067032627.14404.3520.camel@p4> <20031025221955.GA16508@atrey.karlin.mff.cuni.cz> <20031026080601.GA31855@redhat.com> <20031101141341.GA7363@atrey.karlin.mff.cuni.cz> <20031101155500.GE14974@kam.mff.cuni.cz>
On Sat, Nov 01, 2003 at 04:55:00PM +0100, Jan Hubicka wrote:
> > what advantage does this exactly have? I have no objections against
> > this or any other scheme, but it seems largely equivalent with my
> > approach (except that it is less consistent with the way how COND_EXPRs
> > are handled).
Yours seemd unnecessarily complex. Maintaining the correspondence
took a lot of code and a lot of memory references.
> > If we want to break this consistency, would not it be
> > better to rather implement some representation that will make the
> > manipulation with switch_exprs easier?
I can't think of any way that would be easier. A vector with
all of the cases. What could be simpler?
> I was just playing around the idea of replacing these low level control
> branches by specialized nodes, like COND_JUMP taking arugment of
> condition and two CFG edges. In such was we avoid a lot of unnecesary
> memory references (the goto statements and labels).