This is the mail archive of the gcc@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]

Re: basic_block index negative?


On Wed, 17 Oct 2001, Daniel Egger wrote:

> Am Mit, 2001-10-17 um 19.46 schrieb 1003340807:
> 
> > Dunno.  I guess because they're special and contain no program
> > instructions.  The tree SSA code uses it to tell whether it found
> > a ghost definition (artificial definitions created by SSA).
> 
> I find it quite odd and distracting to have negative indices. This
> also forbids using them for arrays.
> 
True.

> I think it would be really nice to mostly unsigned variables; this
> makes it easy to prevent nasty sideeffects when dealing with them
> and quite frankly I don't like the just of casts in the code. Maybe
> gcc could also create better code but this is just a speculation
> for recent versions, it worked on older versions though.
> 
Even if you didn't allow negative indices, reverse traversals are
important.  Making the index unsigned would make them more
interesting than they need to be.

Diego.


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