On Tue, 2007-04-10 at 20:39 +0100, Dave Korn wrote: > On 10 April 2007 20:02, Diego Novillo wrote: > > >> The obvious way to make the proposed tuples position independent would > >> be to use array offsets rather than pointers. This has the obvious > >> disadvantage that every access through a pointer requires an > >> additional memory reference. On the other hand, it has some other > >> advantages: it may no longer be necessary to keep a previous pointer > > > > I doubt this. We had started with single-linked chains but reverse > > traversals do occur, and they were very painful and slow. > > Reverse-traversing an array really isn't all that painful or slow!
I don't think we're talking about traversing an array, but rather a linked list which uses an array index rather than a pointer. You don't want to go moving around array slices everytime you add instructions. You will still need a PREV index if you want to avoid finding prev's by starting at the beginning of a BB and scanning forward. We've already done this in tree-ssa and it is a big loss on passes which work on the instruction stream in reverse. Andrew