MPX for amd64
[deliverable/binutils-gdb.git] / gas / sb.c
index f68402fc470f6af031241d32f62d7388e1af6246..7710cbc0c89574354a4ce78354d9e8169a59b942 100644 (file)
--- a/gas/sb.c
+++ b/gas/sb.c
@@ -113,7 +113,7 @@ sb_scrub_and_add_sb (sb *ptr, sb *s)
 {
   sb_to_scrub = s;
   scrub_position = s->ptr;
-  
+
   sb_check (ptr, s->len);
   ptr->len += do_scrub_chars (scrub_from_sb, ptr->ptr + ptr->len, s->len);
 
@@ -137,7 +137,10 @@ sb_check (sb *ptr, size_t len)
       if ((ssize_t) want < 0)
        as_fatal ("string buffer overflow");
 #if GCC_VERSION >= 3004
-      max = (size_t) 1 << (CHAR_BIT * sizeof (want) - __builtin_clzl (want));
+      max = (size_t) 1 << (CHAR_BIT * sizeof (want)
+                          - (sizeof (want) <= sizeof (long)
+                             ? __builtin_clzl ((long) want)
+                             : __builtin_clzll ((long long) want)));
 #else
       max = 128;
       while (want > max)
This page took 0.022978 seconds and 4 git commands to generate.