OSDN Git Service

* sh.md (cbranch define_delay) Use cond_delay_slot for
[pf3gnuchains/gcc-fork.git] / gcc / libgcc2.c
index 05cb315..3d021e2 100644 (file)
@@ -63,13 +63,9 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
 DWtype
 __negdi2 (DWtype u)
 {
-  DWunion w;
-  DWunion uu;
-
-  uu.ll = u;
-
-  w.s.low = -uu.s.low;
-  w.s.high = -uu.s.high - ((UWtype) w.s.low > 0);
+  const DWunion uu = {.ll = u};
+  const DWunion w = { {.low = -uu.s.low,
+                      .high = -uu.s.high - ((UWtype) -uu.s.low > 0) } };
 
   return w.ll;
 }
@@ -79,9 +75,7 @@ __negdi2 (DWtype u)
 Wtype
 __addvsi3 (Wtype a, Wtype b)
 {
-  Wtype w;
-
-  w = a + b;
+  const Wtype w = a + b;
 
   if (b >= 0 ? w < a : w > a)
     abort ();
@@ -94,9 +88,7 @@ __addvsi3 (Wtype a, Wtype b)
 DWtype
 __addvdi3 (DWtype a, DWtype b)
 {
-  DWtype w;
-
-  w = a + b;
+  const DWtype w = a + b;
 
   if (b >= 0 ? w < a : w > a)
     abort ();
@@ -109,9 +101,7 @@ __addvdi3 (DWtype a, DWtype b)
 Wtype
 __subvsi3 (Wtype a, Wtype b)
 {
-  DWtype w;
-
-  w = a - b;
+  const DWtype w = a - b;
 
   if (b >= 0 ? w > a : w < a)
     abort ();
@@ -124,9 +114,7 @@ __subvsi3 (Wtype a, Wtype b)
 DWtype
 __subvdi3 (DWtype a, DWtype b)
 {
-  DWtype w;
-
-  w = a - b;
+  const DWtype w = a - b;
 
   if (b >= 0 ? w > a : w < a)
     abort ();
@@ -140,13 +128,9 @@ __subvdi3 (DWtype a, DWtype b)
 Wtype
 __mulvsi3 (Wtype a, Wtype b)
 {
-  DWtype w;
-
-  w = (DWtype) a * (DWtype) b;
+  const DWtype w = (DWtype) a * (DWtype) b;
 
-  if (((a >= 0) == (b >= 0))
-      ? (UDWtype) w > (UDWtype) (((DWtype) 1 << (WORD_SIZE - 1)) - 1)
-      : (UDWtype) w < (UDWtype) ((DWtype) -1 << (WORD_SIZE - 1)))
+  if ((Wtype) (w >> WORD_SIZE) != (Wtype) w >> (WORD_SIZE - 1))
     abort ();
 
   return w;
@@ -157,9 +141,7 @@ __mulvsi3 (Wtype a, Wtype b)
 Wtype
 __negvsi2 (Wtype a)
 {
-  Wtype w;
-
-  w  = -a;
+  const Wtype w = -a;
 
   if (a >= 0 ? w > 0 : w < 0)
     abort ();
@@ -172,9 +154,7 @@ __negvsi2 (Wtype a)
 DWtype
 __negvdi2 (DWtype a)
 {
-  DWtype w;
-
-  w  = -a;
+  const DWtype w = -a;
 
   if (a >= 0 ? w > 0 : w < 0)
     abort ();
@@ -230,10 +210,8 @@ __mulvdi3 (DWtype u, DWtype v)
 {
   /* The unchecked multiplication needs 3 Wtype x Wtype multiplications,
      but the checked multiplication needs only two.  */
-  DWunion uu, vv;
-
-  uu.ll = u;
-  vv.ll = v;
+  const DWunion uu = {.ll = u};
+  const DWunion vv = {.ll = v};
 
   if (__builtin_expect (uu.s.high == uu.s.low >> (WORD_SIZE - 1), 1))
     {
@@ -247,10 +225,11 @@ __mulvdi3 (DWtype u, DWtype v)
       else
        {
          /* Two multiplications.  */
-         DWunion w0, w1;
+         DWunion w0 = {.ll = (UDWtype) (UWtype) uu.s.low
+                       * (UDWtype) (UWtype) vv.s.low};
+         DWunion w1 = {.ll = (UDWtype) (UWtype) uu.s.low
+                       * (UDWtype) (UWtype) vv.s.high};
 
-         w0.ll = (UDWtype) (UWtype) uu.s.low * (UDWtype) (UWtype) vv.s.low;
-         w1.ll = (UDWtype) (UWtype) uu.s.low * (UDWtype) (UWtype) vv.s.high;
          if (vv.s.high < 0)
            w1.s.high -= uu.s.low;
          if (uu.s.low < 0)
@@ -269,10 +248,11 @@ __mulvdi3 (DWtype u, DWtype v)
        {
          /* v fits into a single Wtype.  */
          /* Two multiplications.  */
-         DWunion w0, w1;
+         DWunion w0 = {.ll = (UDWtype) (UWtype) uu.s.low
+                       * (UDWtype) (UWtype) vv.s.low};
+         DWunion w1 = {.ll = (UDWtype) (UWtype) uu.s.high
+                       * (UDWtype) (UWtype) vv.s.low};
 
-         w0.ll = (UDWtype) (UWtype) uu.s.low * (UDWtype) (UWtype) vv.s.low;
-         w1.ll = (UDWtype) (UWtype) uu.s.high * (UDWtype) (UWtype) vv.s.low;
          if (uu.s.high < 0)
            w1.s.high -= vv.s.low;
          if (vv.s.low < 0)
@@ -293,10 +273,8 @@ __mulvdi3 (DWtype u, DWtype v)
                {
                  if (uu.s.high == 0 && vv.s.high == 0)
                    {
-                     DWtype w;
-
-                     w = (UDWtype) (UWtype) uu.s.low
-                         * (UDWtype) (UWtype) vv.s.low;
+                     const DWtype w = (UDWtype) (UWtype) uu.s.low
+                       * (UDWtype) (UWtype) vv.s.low;
                      if (__builtin_expect (w >= 0, 1))
                        return w;
                    }
@@ -305,10 +283,9 @@ __mulvdi3 (DWtype u, DWtype v)
                {
                  if (uu.s.high == 0 && vv.s.high == (Wtype) -1)
                    {
-                     DWunion ww;
+                     DWunion ww = {.ll = (UDWtype) (UWtype) uu.s.low
+                                   * (UDWtype) (UWtype) vv.s.low};
 
-                     ww.ll = (UDWtype) (UWtype) uu.s.low
-                             * (UDWtype) (UWtype) vv.s.low;
                      ww.s.high -= uu.s.low;
                      if (__builtin_expect (ww.s.high < 0, 1))
                        return ww.ll;
@@ -321,10 +298,9 @@ __mulvdi3 (DWtype u, DWtype v)
                {
                  if (uu.s.high == (Wtype) -1 && vv.s.high == 0)
                    {
-                     DWunion ww;
+                     DWunion ww = {.ll = (UDWtype) (UWtype) uu.s.low
+                                   * (UDWtype) (UWtype) vv.s.low};
 
-                     ww.ll = (UDWtype) (UWtype) uu.s.low
-                             * (UDWtype) (UWtype) vv.s.low;
                      ww.s.high -= vv.s.low;
                      if (__builtin_expect (ww.s.high < 0, 1))
                        return ww.ll;
@@ -334,10 +310,9 @@ __mulvdi3 (DWtype u, DWtype v)
                {
                  if (uu.s.high == (Wtype) -1 && vv.s.high == (Wtype) - 1)
                    {
-                     DWunion ww;
+                     DWunion ww = {.ll = (UDWtype) (UWtype) uu.s.low
+                                   * (UDWtype) (UWtype) vv.s.low};
 
-                     ww.ll = (UDWtype) (UWtype) uu.s.low
-                             * (UDWtype) (UWtype) vv.s.low;
                      ww.s.high -= uu.s.low;
                      ww.s.high -= vv.s.low;
                      if (__builtin_expect (ww.s.high >= 0, 1))
@@ -360,16 +335,13 @@ __mulvdi3 (DWtype u, DWtype v)
 DWtype
 __lshrdi3 (DWtype u, word_type b)
 {
-  DWunion w;
-  word_type bm;
-  DWunion uu;
-
   if (b == 0)
     return u;
 
-  uu.ll = u;
+  const DWunion uu = {.ll = u};
+  const word_type bm = (sizeof (Wtype) * BITS_PER_UNIT) - b;
+  DWunion w;
 
-  bm = (sizeof (Wtype) * BITS_PER_UNIT) - b;
   if (bm <= 0)
     {
       w.s.high = 0;
@@ -377,7 +349,7 @@ __lshrdi3 (DWtype u, word_type b)
     }
   else
     {
-      UWtype carries = (UWtype) uu.s.high << bm;
+      const UWtype carries = (UWtype) uu.s.high << bm;
 
       w.s.high = (UWtype) uu.s.high >> b;
       w.s.low = ((UWtype) uu.s.low >> b) | carries;
@@ -391,16 +363,13 @@ __lshrdi3 (DWtype u, word_type b)
 DWtype
 __ashldi3 (DWtype u, word_type b)
 {
-  DWunion w;
-  word_type bm;
-  DWunion uu;
-
   if (b == 0)
     return u;
 
-  uu.ll = u;
+  const DWunion uu = {.ll = u};
+  const word_type bm = (sizeof (Wtype) * BITS_PER_UNIT) - b;
+  DWunion w;
 
-  bm = (sizeof (Wtype) * BITS_PER_UNIT) - b;
   if (bm <= 0)
     {
       w.s.low = 0;
@@ -408,7 +377,7 @@ __ashldi3 (DWtype u, word_type b)
     }
   else
     {
-      UWtype carries = (UWtype) uu.s.low >> bm;
+      const UWtype carries = (UWtype) uu.s.low >> bm;
 
       w.s.low = (UWtype) uu.s.low << b;
       w.s.high = ((UWtype) uu.s.high << b) | carries;
@@ -422,16 +391,13 @@ __ashldi3 (DWtype u, word_type b)
 DWtype
 __ashrdi3 (DWtype u, word_type b)
 {
-  DWunion w;
-  word_type bm;
-  DWunion uu;
-
   if (b == 0)
     return u;
 
-  uu.ll = u;
+  const DWunion uu = {.ll = u};
+  const word_type bm = (sizeof (Wtype) * BITS_PER_UNIT) - b;
+  DWunion w;
 
-  bm = (sizeof (Wtype) * BITS_PER_UNIT) - b;
   if (bm <= 0)
     {
       /* w.s.high = 1..1 or 0..0 */
@@ -440,7 +406,7 @@ __ashrdi3 (DWtype u, word_type b)
     }
   else
     {
-      UWtype carries = (UWtype) uu.s.high << bm;
+      const UWtype carries = (UWtype) uu.s.high << bm;
 
       w.s.high = uu.s.high >> b;
       w.s.low = ((UWtype) uu.s.low >> b) | carries;
@@ -452,7 +418,6 @@ __ashrdi3 (DWtype u, word_type b)
 \f
 #ifdef L_ffssi2
 #undef int
-extern int __ffsSI2 (UWtype u);
 int
 __ffsSI2 (UWtype u)
 {
@@ -468,14 +433,12 @@ __ffsSI2 (UWtype u)
 \f
 #ifdef L_ffsdi2
 #undef int
-extern int __ffsDI2 (DWtype u);
 int
 __ffsDI2 (DWtype u)
 {
-  DWunion uu;
+  const DWunion uu = {.ll = u};
   UWtype word, count, add;
 
-  uu.ll = u;
   if (uu.s.low != 0)
     word = uu.s.low, add = 0;
   else if (uu.s.high != 0)
@@ -492,13 +455,10 @@ __ffsDI2 (DWtype u)
 DWtype
 __muldi3 (DWtype u, DWtype v)
 {
-  DWunion w;
-  DWunion uu, vv;
-
-  uu.ll = u,
-  vv.ll = v;
+  const DWunion uu = {.ll = u};
+  const DWunion vv = {.ll = v};
+  DWunion w = {.ll = __umulsidi3 (uu.s.low, vv.s.low)};
 
-  w.ll = __umulsidi3 (uu.s.low, vv.s.low);
   w.s.high += ((UWtype) uu.s.low * (UWtype) vv.s.high
               + (UWtype) uu.s.high * (UWtype) vv.s.low);
 
@@ -649,7 +609,6 @@ const UQItype __clz_tab[] =
 \f
 #ifdef L_clzsi2
 #undef int
-extern int __clzSI2 (UWtype x);
 int
 __clzSI2 (UWtype x)
 {
@@ -663,15 +622,13 @@ __clzSI2 (UWtype x)
 \f
 #ifdef L_clzdi2
 #undef int
-extern int __clzDI2 (UDWtype x);
 int
 __clzDI2 (UDWtype x)
 {
-  DWunion uu;
+  const DWunion uu = {.ll = x};
   UWtype word;
   Wtype ret, add;
 
-  uu.ll = x;
   if (uu.s.high)
     word = uu.s.high, add = 0;
   else
@@ -684,7 +641,6 @@ __clzDI2 (UDWtype x)
 \f
 #ifdef L_ctzsi2
 #undef int
-extern int __ctzSI2 (UWtype x);
 int
 __ctzSI2 (UWtype x)
 {
@@ -698,15 +654,13 @@ __ctzSI2 (UWtype x)
 \f
 #ifdef L_ctzdi2
 #undef int
-extern int __ctzDI2 (UDWtype x);
 int
 __ctzDI2 (UDWtype x)
 {
-  DWunion uu;
+  const DWunion uu = {.ll = x};
   UWtype word;
   Wtype ret, add;
 
-  uu.ll = x;
   if (uu.s.low)
     word = uu.s.low, add = 0;
   else
@@ -738,7 +692,6 @@ const UQItype __popcount_tab[] =
 \f
 #ifdef L_popcountsi2
 #undef int
-extern int __popcountSI2 (UWtype x);
 int
 __popcountSI2 (UWtype x)
 {
@@ -753,7 +706,6 @@ __popcountSI2 (UWtype x)
 \f
 #ifdef L_popcountdi2
 #undef int
-extern int __popcountDI2 (UDWtype x);
 int
 __popcountDI2 (UDWtype x)
 {
@@ -768,7 +720,6 @@ __popcountDI2 (UDWtype x)
 \f
 #ifdef L_paritysi2
 #undef int
-extern int __paritySI2 (UWtype x);
 int
 __paritySI2 (UWtype x)
 {
@@ -790,15 +741,11 @@ __paritySI2 (UWtype x)
 \f
 #ifdef L_paritydi2
 #undef int
-extern int __parityDI2 (UDWtype x);
 int
 __parityDI2 (UDWtype x)
 {
-  DWunion uu;
-  UWtype nx;
-
-  uu.ll = x;
-  nx = uu.s.low ^ uu.s.high;
+  const DWunion uu = {.ll = x};
+  UWtype nx = uu.s.low ^ uu.s.high;
 
 #if W_TYPE_SIZE > 64
 # error "fill out the table"
@@ -825,16 +772,13 @@ static inline __attribute__ ((__always_inline__))
 UDWtype
 __udivmoddi4 (UDWtype n, UDWtype d, UDWtype *rp)
 {
-  DWunion ww;
-  DWunion nn, dd;
+  const DWunion nn = {.ll = n};
+  const DWunion dd = {.ll = d};
   DWunion rr;
   UWtype d0, d1, n0, n1, n2;
   UWtype q0, q1;
   UWtype b, bm;
 
-  nn.ll = n;
-  dd.ll = d;
-
   d0 = dd.s.low;
   d1 = dd.s.high;
   n0 = nn.s.low;
@@ -1034,8 +978,7 @@ __udivmoddi4 (UDWtype n, UDWtype d, UDWtype *rp)
        }
     }
 
-  ww.s.low = q0;
-  ww.s.high = q1;
+  const DWunion ww = {{.low = q0, .high = q1}};
   return ww.ll;
 }
 #endif
@@ -1045,12 +988,10 @@ DWtype
 __divdi3 (DWtype u, DWtype v)
 {
   word_type c = 0;
-  DWunion uu, vv;
+  DWunion uu = {.ll = u};
+  DWunion vv = {.ll = v};
   DWtype w;
 
-  uu.ll = u;
-  vv.ll = v;
-
   if (uu.s.high < 0)
     c = ~c,
     uu.ll = -uu.ll;
@@ -1071,12 +1012,10 @@ DWtype
 __moddi3 (DWtype u, DWtype v)
 {
   word_type c = 0;
-  DWunion uu, vv;
+  DWunion uu = {.ll = u};
+  DWunion vv = {.ll = v};
   DWtype w;
 
-  uu.ll = u;
-  vv.ll = v;
-
   if (uu.s.high < 0)
     c = ~c,
     uu.ll = -uu.ll;
@@ -1115,9 +1054,8 @@ __udivdi3 (UDWtype n, UDWtype d)
 word_type
 __cmpdi2 (DWtype a, DWtype b)
 {
-  DWunion au, bu;
-
-  au.ll = a, bu.ll = b;
+  const DWunion au = {.ll = a};
+  const DWunion bu = {.ll = b};
 
   if (au.s.high < bu.s.high)
     return 0;
@@ -1135,9 +1073,8 @@ __cmpdi2 (DWtype a, DWtype b)
 word_type
 __ucmpdi2 (DWtype a, DWtype b)
 {
-  DWunion au, bu;
-
-  au.ll = a, bu.ll = b;
+  const DWunion au = {.ll = a};
+  const DWunion bu = {.ll = b};
 
   if ((UWtype) au.s.high < (UWtype) bu.s.high)
     return 0;
@@ -1158,17 +1095,14 @@ __ucmpdi2 (DWtype a, DWtype b)
 DWtype
 __fixunstfDI (TFtype a)
 {
-  TFtype b;
-  UDWtype v;
-
   if (a < 0)
     return 0;
 
   /* Compute high word of result, as a flonum.  */
-  b = (a / HIGH_WORD_COEFF);
+  const TFtype b = (a / HIGH_WORD_COEFF);
   /* Convert that to fixed (but not to DWtype!),
      and shift it into the high word.  */
-  v = (UWtype) b;
+  UDWtype v = (UWtype) b;
   v <<= WORD_SIZE;
   /* Remove high part from the TFtype, leaving the low part as flonum.  */
   a -= (TFtype)v;
@@ -1193,24 +1127,21 @@ __fixtfdi (TFtype a)
 }
 #endif
 
-#if defined(L_fixunsxfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96)
+#if defined(L_fixunsxfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 80)
 #define WORD_SIZE (sizeof (Wtype) * BITS_PER_UNIT)
 #define HIGH_WORD_COEFF (((UDWtype) 1) << WORD_SIZE)
 
 DWtype
 __fixunsxfDI (XFtype a)
 {
-  XFtype b;
-  UDWtype v;
-
   if (a < 0)
     return 0;
 
   /* Compute high word of result, as a flonum.  */
-  b = (a / HIGH_WORD_COEFF);
+  const XFtype b = (a / HIGH_WORD_COEFF);
   /* Convert that to fixed (but not to DWtype!),
      and shift it into the high word.  */
-  v = (UWtype) b;
+  UDWtype v = (UWtype) b;
   v <<= WORD_SIZE;
   /* Remove high part from the XFtype, leaving the low part as flonum.  */
   a -= (XFtype)v;
@@ -1225,7 +1156,7 @@ __fixunsxfDI (XFtype a)
 }
 #endif
 
-#if defined(L_fixxfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96)
+#if defined(L_fixxfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 80)
 DWtype
 __fixxfdi (XFtype a)
 {
@@ -1242,17 +1173,15 @@ __fixxfdi (XFtype a)
 DWtype
 __fixunsdfDI (DFtype a)
 {
-  UWtype hi, lo;
-
   /* Get high part of result.  The division here will just moves the radix
      point and will not cause any rounding.  Then the conversion to integral
      type chops result as desired.  */
-  hi = a / HIGH_WORD_COEFF;
+  const UWtype hi = a / HIGH_WORD_COEFF;
 
   /* Get low part of result.  Convert `hi' to floating type and scale it back,
      then subtract this from the number being converted.  This leaves the low
      part.  Convert that to integral type.  */
-  lo = (a - ((DFtype) hi) * HIGH_WORD_COEFF);
+  const UWtype lo = (a - ((DFtype) hi) * HIGH_WORD_COEFF);
 
   /* Assemble result from the two parts.  */
   return ((UDWtype) hi << WORD_SIZE) | lo;
@@ -1279,18 +1208,17 @@ __fixunssfDI (SFtype original_a)
   /* Convert the SFtype to a DFtype, because that is surely not going
      to lose any bits.  Some day someone else can write a faster version
      that avoids converting to DFtype, and verify it really works right.  */
-  DFtype a = original_a;
-  UWtype hi, lo;
+  const DFtype a = original_a;
 
   /* Get high part of result.  The division here will just moves the radix
      point and will not cause any rounding.  Then the conversion to integral
      type chops result as desired.  */
-  hi = a / HIGH_WORD_COEFF;
+  const UWtype hi = a / HIGH_WORD_COEFF;
 
   /* Get low part of result.  Convert `hi' to floating type and scale it back,
      then subtract this from the number being converted.  This leaves the low
      part.  Convert that to integral type.  */
-  lo = (a - ((DFtype) hi) * HIGH_WORD_COEFF);
+  const UWtype lo = (a - ((DFtype) hi) * HIGH_WORD_COEFF);
 
   /* Assemble result from the two parts.  */
   return ((UDWtype) hi << WORD_SIZE) | lo;
@@ -1307,7 +1235,7 @@ __fixsfdi (SFtype a)
 }
 #endif
 
-#if defined(L_floatdixf) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96)
+#if defined(L_floatdixf) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 80)
 #define WORD_SIZE (sizeof (Wtype) * BITS_PER_UNIT)
 #define HIGH_HALFWORD_COEFF (((UDWtype) 1) << (WORD_SIZE / 2))
 #define HIGH_WORD_COEFF (((UDWtype) 1) << WORD_SIZE)
@@ -1315,9 +1243,7 @@ __fixsfdi (SFtype a)
 XFtype
 __floatdixf (DWtype u)
 {
-  XFtype d;
-
-  d = (Wtype) (u >> WORD_SIZE);
+  XFtype d = (Wtype) (u >> WORD_SIZE);
   d *= HIGH_HALFWORD_COEFF;
   d *= HIGH_HALFWORD_COEFF;
   d += (UWtype) (u & (HIGH_WORD_COEFF - 1));
@@ -1334,9 +1260,7 @@ __floatdixf (DWtype u)
 TFtype
 __floatditf (DWtype u)
 {
-  TFtype d;
-
-  d = (Wtype) (u >> WORD_SIZE);
+  TFtype d = (Wtype) (u >> WORD_SIZE);
   d *= HIGH_HALFWORD_COEFF;
   d *= HIGH_HALFWORD_COEFF;
   d += (UWtype) (u & (HIGH_WORD_COEFF - 1));
@@ -1353,9 +1277,7 @@ __floatditf (DWtype u)
 DFtype
 __floatdidf (DWtype u)
 {
-  DFtype d;
-
-  d = (Wtype) (u >> WORD_SIZE);
+  DFtype d = (Wtype) (u >> WORD_SIZE);
   d *= HIGH_HALFWORD_COEFF;
   d *= HIGH_HALFWORD_COEFF;
   d += (UWtype) (u & (HIGH_WORD_COEFF - 1));
@@ -1376,11 +1298,6 @@ __floatdidf (DWtype u)
 SFtype
 __floatdisf (DWtype u)
 {
-  /* Do the calculation in DFmode
-     so that we don't lose any of the precision of the high word
-     while multiplying it.  */
-  DFtype f;
-
   /* Protect against double-rounding error.
      Represent any low-order bits, that might be truncated in DFmode,
      by a bit that won't be lost.  The bit can go in anywhere below the
@@ -1401,7 +1318,10 @@ __floatdisf (DWtype u)
            }
        }
     }
-  f = (Wtype) (u >> WORD_SIZE);
+  /* Do the calculation in DFmode
+     so that we don't lose any of the precision of the high word
+     while multiplying it.  */
+  DFtype f = (Wtype) (u >> WORD_SIZE);
   f *= HIGH_HALFWORD_COEFF;
   f *= HIGH_HALFWORD_COEFF;
   f += (UWtype) (u & (HIGH_WORD_COEFF - 1));
@@ -1410,7 +1330,7 @@ __floatdisf (DWtype u)
 }
 #endif
 
-#if defined(L_fixunsxfsi) && LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96
+#if defined(L_fixunsxfsi) && LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 80
 /* Reenable the normal types, in case limits.h needs them.  */
 #undef char
 #undef short
@@ -1510,7 +1430,7 @@ __gcc_bcmp (const unsigned char *s1, const unsigned char *s2, size_t size)
 {
   while (size > 0)
     {
-      unsigned char c1 = *s1++, c2 = *s2++;
+      const unsigned char c1 = *s1++, c2 = *s2++;
       if (c1 != c2)
        return c1 - c2;
       size--;
@@ -1557,6 +1477,19 @@ __clear_cache (char *beg __attribute__((__unused__)),
 
 #endif /* L_clear_cache */
 \f
+#ifdef L_enable_execute_stack
+/* Attempt to turn on execute permission for the stack.  */
+
+#ifdef ENABLE_EXECUTE_STACK
+  ENABLE_EXECUTE_STACK
+#else
+void
+__enable_execute_stack (void *addr __attribute__((__unused__)))
+{}
+#endif /* ENABLE_EXECUTE_STACK */
+
+#endif /* L_enable_execute_stack */
+\f
 #ifdef L_trampoline
 
 /* Jump to a trampoline, loading the static chain address.  */
@@ -1690,8 +1623,9 @@ __do_global_ctors (void)
    For systems which support a .init section we use the .init section
    to run __do_global_ctors, so we need not do anything here.  */
 
+extern void SYMBOL__MAIN (void);
 void
-SYMBOL__MAIN ()
+SYMBOL__MAIN (void)
 {
   /* Support recursive calls to `main': run initializers just once.  */
   static int initialized;