about summary refs log tree commit diff
path: root/ChangeLog
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2017-07-01 07:29:19 -0700
committerH.J. Lu <hjl.tools@gmail.com>2017-07-01 07:29:32 -0700
commit8dc6133eff1c09382bc8f6f98c49fb807900eecd (patch)
tree3ca0c6660b09b6fdd51e2a45af626d8bd49019ee /ChangeLog
parent47ea614b9afcdaef80e09d58afcdad4f96ba3f15 (diff)
downloadglibc-8dc6133eff1c09382bc8f6f98c49fb807900eecd.tar.gz
glibc-8dc6133eff1c09382bc8f6f98c49fb807900eecd.tar.xz
glibc-8dc6133eff1c09382bc8f6f98c49fb807900eecd.zip
Use __builtin_popcount in __sched_cpucount [BZ #21696]
posix/sched_cpucount.c assumes that size of __cpu_mask == size of long,
which is incorrect for x32.  This patch uses __builtin_popcount, which
is availabe in GCC 4.9, in posix/sched_cpucount.c.

Tested on i686, x86-64 and x32 with multi-arch disabled.

	[BZ #21696]
	* posix/sched_cpucount.c: Don't include <limits.h>.
	(__sched_cpucount): Use __builtin_popcount.
Diffstat (limited to 'ChangeLog')
-rw-r--r--ChangeLog7
1 files changed, 7 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 58ce87749e..4cd5d31770 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2017-07-01  Florian Weimer  <fweimer@redhat.com>
+	    H.J. Lu  <hongjiu.lu@intel.com>
+
+	[BZ #21696]
+	* posix/sched_cpucount.c: Don't include <limits.h>.
+	(__sched_cpucount): Use __builtin_popcount.
+
 2017-07-01  Ramana Radhakrishnan  <ramana.gcc@googlemail.com>
 
 	* sysdeps/unix/sysv/aarch64/cpu-features.c (init_cpu_features):