This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch master updated. glibc-2.20-385-gc9c1a2d


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  c9c1a2d02cf344697c08075a44c170f771ebc6b2 (commit)
      from  e54db0ea6a49affac43fa305fd134f3020c41382 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=c9c1a2d02cf344697c08075a44c170f771ebc6b2

commit c9c1a2d02cf344697c08075a44c170f771ebc6b2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Dec 19 05:28:06 2014 -0800

    Replace 1L with (mp_limb_t) 1
    
    X86-64 and x32 use sysdeps/i386/ldbl2mpn.c.  res_ptr is a pointer
    to mp_limb_t, which is long for i386 and x86-64 and long long for
    x32.  On x32, I got
    
    ../sysdeps/x86_64/../i386/ldbl2mpn.c: In function â??__mpn_extract_long_doubleâ??:
    ../sysdeps/x86_64/../i386/ldbl2mpn.c:72:4: error: left shift count >= width of type [-Werror]
        res_ptr[N - 1] &= ~(1L << ((LDBL_MANT_DIG - 1) % BITS_PER_MP_LIMB));
        ^
    cc1: all warnings being treated as errors
    
    This patch replaces 1L with (mp_limb_t) 1.  Verified on x32, i686 and
    x86-64 with GCC 4.8.3.

diff --git a/ChangeLog b/ChangeLog
index 799b21a..eda51f8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2014-12-19  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* sysdeps/i386/ldbl2mpn.c (__mpn_extract_long_double): Replace
+	1L with (mp_limb_t) 1.
+
 2014-12-17  Roland McGrath  <roland@hack.frob.com>
 
 	* sysdeps/nptl/fork.c (__fork_generation_pointer): Variable moved ...
diff --git a/sysdeps/i386/ldbl2mpn.c b/sysdeps/i386/ldbl2mpn.c
index 09e3096..6f92833 100644
--- a/sysdeps/i386/ldbl2mpn.c
+++ b/sysdeps/i386/ldbl2mpn.c
@@ -69,7 +69,7 @@ __mpn_extract_long_double (mp_ptr res_ptr, mp_size_t size,
 	     for denormalized number.  If it is one, the number is according
 	     to Intel's specification an invalid number.  We make the
 	     representation unique by explicitly clearing this bit.  */
-	  res_ptr[N - 1] &= ~(1L << ((LDBL_MANT_DIG - 1) % BITS_PER_MP_LIMB));
+	  res_ptr[N - 1] &= ~((mp_limb_t) 1 << ((LDBL_MANT_DIG - 1) % BITS_PER_MP_LIMB));
 
 	  if (res_ptr[N - 1] != 0)
 	    {

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog               |    5 +++++
 sysdeps/i386/ldbl2mpn.c |    2 +-
 2 files changed, 6 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]