GCC 4.3.4 is casting my QImode vars to SImode for libcall

Paolo Bonzini bonzini@gnu.org
Wed Jun 16 13:04:00 GMT 2010


On 06/15/2010 11:02 AM, Paulo J. Matos wrote:
> Just noticed the following also in optabs.c:
>
>    /* We can't do it with an insn, so use a library call.  But first ensure
>       that the mode of TO is at least as wide as SImode, since those are the
>       only library calls we know about.  */
>
>    if (GET_MODE_SIZE (GET_MODE (to))<  GET_MODE_SIZE (SImode))
>      {
>        target = gen_reg_rtx (SImode);
>        expand_fix (target, from, unsignedp);
>      }
>
> This comment provides some insight on to why gcc keeps converting to
> SImode.

I think the comment dates back to before the introduction of conversion 
optabs.

Maybe the right thing to compare with is the size of an int in bytes?

Paolo



More information about the Gcc mailing list