This is the mail archive of the gcc-patches@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]
Other format: [Raw text]

Re: [PATCH] Canonicalize comparisons, fix PR26899


On Sat, 2006-10-28 at 09:32 -0600, Roger Sayle wrote:
> This is OK for mainline.  Thanks for the clean-up, and my apologies again
> for missing that it was the magnitude of the constant you're reducing/
> canonicalizing.


And this causes a bootstrap regression, compile the following code at
-O2:
extern unsigned short _sch_istable[256];
__gnat_decode (const char *coded_name, char *ada_name, int verbose)
{
    int len = strlen (ada_name);
    int n_digits = 0;
    if (len > 1)
      while ((_sch_istable[((int) ada_name[ len - 1 - n_digits]) ] ))
        n_digits++;
    if (ada_name[len - 1 - n_digits] == '$')
      strcat (ada_name, ")");
}

Thanks,
Andrew Pinski


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