Genrecog bugfix version 2

Jan Hubicka
Sat Aug 7 06:33:00 GMT 1999

> On Sun, Jul 25, 1999 at 03:12:25AM +0200, Jan Hubicka wrote:
> > +   int cmp = strcmp (d1->position, d2->position);
> ...
> > +        /* Try to find corresponding position in the second.  */
> > +        if (cmp < 0)
> I don't understand the use of strcmp to determine which
> of d1 or d2 to back out and test.  Perhaps you were looking
> for the longer of two strings?  Or perhaps we always know
> that one is a prefix of the longer?
After looking at the strings I've got impression that they contaions
letters and numbers to represent position in the insn and when I sort
them alphabetically I get exactly the order recog uses to match constraints.
In the situation I am shooting for, one string is longer, because it's tree
is deeper and second is "almost prefix" except it is one branch later.
I think we can use strlen comparison as well, but strcmp seems to be more
clear to me to represent that I need to syncronize.

> r~

                       OK. Lets make a signature file.
|        Jan Hubicka (Jan Hubi\v{c}ka in TeX)         |
|         Czech free software foundation:          |
|AA project - the new way for computer graphics - |
|  homepage: , games koules, Xonix, fast  |
|  fractal zoomer XaoS, index of Czech GNU/Linux/UN*X documentation etc.  | 

More information about the Gcc-patches mailing list