Re: [rfa] more lookup_symbol_aux_minsyms futzing

David Carlton
2003-02-20T21:35:35Z

On Thu, 20 Feb 2003 16:16:42 -0500, Daniel Jacobowitz <drow@mvista.com> said:
> On Thu, Feb 20, 2003 at 12:57:37PM -0800, David Carlton wrote:

>> (Incidentally, I'm curious if Daniel considers the patch in
>> symtab/1070 to still be active: if so, please review the e-mail
>> discussion that Daniel and I had about this. I actually have more
>> to say about that if you're considering approving that patch.)

> Yes, I never withdrew it; that's why I forwarded it to GNATS.

Ah, I wasn't sure if you'd forwarded it or if Andrew and his nefarious
gang of shell scripts had forwarded it.

>> 1) A patch to correct a slight bug that remains in
>> lookup_partial_symbol. Basically, partial symbols are sorted via
>> strcmp but we want to use strcmp_iw as our matching criterion;
>> strcmp and strcmp_iw aren't _quite_ suitable to be used together in
>> this way.

> Should they be sorted via strcmp_iw instead?

That would be the obvious thing to do; unfortunately, strcmp_iw
doesn't define an ordering. (It defines an asymmetric equality
relationship, but doesn't give you a way to order names that aren't
strcmp_iw.) So you need to come up with an ordering function that can
be passed to qsort that is compatible with strcmp_iw's quirks.

Not too hard; I've done it, I just need to submit it as a patch.
It'll happen as soon as I've submitted my first namespace patch, no
later than Monday.

(And, as you said elsewhere, we should just hash partial symbols, like
we do with everything else, but that takes more work; eventually, one
of us will find some time to do it.)