Skip to content

Commit

Permalink
Fix parse error in bits/mathinline.h with --std=c99
Browse files Browse the repository at this point in the history
  • Loading branch information
Andreas Schwab committed Sep 26, 2011
1 parent e057a1b commit bf972c9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 8 deletions.
4 changes: 4 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
2011-09-26 Andreas Schwab <schwab@redhat.com>

* sysdeps/x86_64/fpu/bits/mathinline.h: Use __asm instead of asm.

2011-09-21 Chung-Lin Tang <cltang@codesourcery.com>
Maxim Kuvyrkov <maxim@codesourcery.com>
Joseph Myers <joseph@codesourcery.com>
Expand Down
16 changes: 8 additions & 8 deletions sysdeps/x86_64/fpu/bits/mathinline.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ __MATH_INLINE long int
__NTH (lrintf (float __x))
{
long int __res;
asm ("cvtss2si %1, %0" : "=r" (__res) : "xm" (__x));
__asm ("cvtss2si %1, %0" : "=r" (__res) : "xm" (__x));
return __res;
}
# endif
Expand All @@ -82,7 +82,7 @@ __MATH_INLINE long int
__NTH (lrint (double __x))
{
long int __res;
asm ("cvtsd2si %1, %0" : "=r" (__res) : "xm" (__x));
__asm ("cvtsd2si %1, %0" : "=r" (__res) : "xm" (__x));
return __res;
}
# endif
Expand All @@ -91,14 +91,14 @@ __MATH_INLINE long long int
__NTH (llrintf (float __x))
{
long long int __res;
asm ("cvtss2si %1, %0" : "=r" (__res) : "xm" (__x));
__asm ("cvtss2si %1, %0" : "=r" (__res) : "xm" (__x));
return __res;
}
__MATH_INLINE long long int
__NTH (llrint (double __x))
{
long long int __res;
asm ("cvtsd2si %1, %0" : "=r" (__res) : "xm" (__x));
__asm ("cvtsd2si %1, %0" : "=r" (__res) : "xm" (__x));
return __res;
}
# endif
Expand All @@ -108,27 +108,27 @@ __NTH (llrint (double __x))
__MATH_INLINE float
__NTH (fmaxf (float __x, float __y))
{
asm ("maxss %1, %0" : "+x" (__x) : "xm" (__y));
__asm ("maxss %1, %0" : "+x" (__x) : "xm" (__y));
return __x;
}
__MATH_INLINE double
__NTH (fmax (double __x, double __y))
{
asm ("maxsd %1, %0" : "+x" (__x) : "xm" (__y));
__asm ("maxsd %1, %0" : "+x" (__x) : "xm" (__y));
return __x;
}

/* Determine minimum of two values. */
__MATH_INLINE float
__NTH (fminf (float __x, float __y))
{
asm ("minss %1, %0" : "+x" (__x) : "xm" (__y));
__asm ("minss %1, %0" : "+x" (__x) : "xm" (__y));
return __x;
}
__MATH_INLINE double
__NTH (fmin (double __x, double __y))
{
asm ("minsd %1, %0" : "+x" (__x) : "xm" (__y));
__asm ("minsd %1, %0" : "+x" (__x) : "xm" (__y));
return __x;
}
# endif
Expand Down

0 comments on commit bf972c9

Please sign in to comment.