[fortran, patch] IEEE intrinsic modules

Uros Bizjak ubizjak@gmail.com
Thu Jun 5 07:02:00 GMT 2014


Hello!

> +int
>  get_fpu_except_flags (void)
>  {
>    unsigned short cw;
>    int excepts;
>    int result = 0;
>
> -  __asm__ __volatile__ ("fnstsw\t%0" : "=a" (cw));
> +  __asm__ __volatile__ ("fnstsw\t%0" : "=m" (cw));
>    excepts = cw;
>
>    if (has_sse())

You can use "=am" constraint here, and the compiler will be free to
choose the most appropriate form.

Also, you should use __asm__ __volatile__ consistently in the headers.

Uros.



More information about the Gcc-patches mailing list