PATCH: Enable TFmode for x86

Uros Bizjak ubizjak@gmail.com
Mon Jun 30 19:33:00 GMT 2008


H.J. Lu wrote:

> Here is the updated patch. I had to comment out __FP_FRAC_SUB_4
> since I got
>
> /export/gnu/src/gcc/gcc/libgcc/../gcc/config/soft-fp/divtf3.c:44:
> error: can't find a register in class ‘GENERAL_REGS’ while reloading ‘asm’
> /export/gnu/src/gcc/gcc/libgcc/../gcc/config/soft-fp/divtf3.c:44: error: ‘asm’ operand has impossible constraints
>   

Just change the last "g" into "im" in __FP_FRAC_SUB_4 and it will work. 
I hope that IRA solves this annoyance.

> +#if 0
> +/* FIXME: Reload doesn't work with it.  */
> +#define __FP_FRAC_SUB_4(r3,r2,r1,r0,x3,x2,x1,x0,y3,y2,y1,y0)		\
> +  __asm__ ("sub{l} {%11,%3|%3,%11}\n\t"					\
> +	   "sbb{l} {%9,%2|%2,%9}\n\t"					\
> +	   "sbb{l} {%7,%1|%1,%7}\n\t"					\
> +	   "sbb{l} {%5,%0|%0,%5}"					\
> +	   : "=r" ((USItype) (r3)),					\
> +	     "=&r" ((USItype) (r2)),					\
> +	     "=&r" ((USItype) (r1)),					\
> +	     "=&r" ((USItype) (r0))					\
> +	   : "0" ((USItype) (x3)),					\
> +	     "g" ((USItype) (y3)),					\
> +	     "1" ((USItype) (x2)),					\
> +	     "g" ((USItype) (y2)),					\
> +	     "2" ((USItype) (x1)),					\
> +	     "g" ((USItype) (y1)),					\
> +	     "3" ((USItype) (x0)),					\
> +	     "g" ((USItype) (y0)))
> +#endif
>   

BTW: I have a preprocessed testcase, but the source looks like 
obfuscated-c contest winner. If anybody is interested, I can send it 
privatelly.

Uros.



More information about the Gcc-patches mailing list