This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


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

Re: RFC: partial symbol table address range generalization



Daniel Berlin <dan@cgsoftware.com> writes:
> Errr, why should it be obstack friendly?
> An interval tree without obstacks will be more efficient in terms of speed
> and memory than something else with obstacks.

Putting the addrmap for psymtabs on the obstack would simplify
bookkeeping.  I agree that obstacks' speed and memory consumption
properties aren't the big issue here.

What I think is important is that the data structure run at an
acceptable speed, and that it be simple enough that people with other
stuff on their minds won't break it.

> If it's really necessary, You could also use a interval stabbing skiplist,
> which would be obstack friendly. At least, moreso than the tree.
> You can just throw elements on a free list, and reuse them.
>
> If you don't want an interval structure, a skiplist with probability .25
> will give you 1.33 pointers average per element, rather than 2 for a tree.
> They are also much easier to maintain.

Sure, those seem like good suggestions.


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