This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch, master, updated. glibc-2.14-159-g8e999d2
- From: drepper at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 11 Aug 2011 18:09:23 -0000
- Subject: GNU C Library master sources branch, master, updated. glibc-2.14-159-g8e999d2
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 8e999d29628b0d1fec3046722554e792c351450b (commit)
via 89edf2e9119b57fc404891670d2bc47bdfdb61ef (commit)
from 2df1f7be58b2dfc80d29e7d53415df48949340ce (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://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=8e999d29628b0d1fec3046722554e792c351450b
commit 8e999d29628b0d1fec3046722554e792c351450b
Author: Ulrich Drepper <drepper@gmail.com>
Date: Thu Aug 11 14:07:04 2011 -0400
Minor optimization of popcount in l10nflist
diff --git a/ChangeLog b/ChangeLog
index 88ed726..83bee3f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2011-08-11 Ulrich Drepper <drepper@gmail.com>
+ * intl/l10nflist.c: Allow architecture-specific pop function.
+ * sysdeps/x86_64/l10nflist.c: New file.
+
* intl/l10nflist.c (_nl_make_l10nflist): Use locale-independent
classification.
diff --git a/intl/l10nflist.c b/intl/l10nflist.c
index a38e0ef..82af263 100644
--- a/intl/l10nflist.c
+++ b/intl/l10nflist.c
@@ -150,6 +150,7 @@ argz_next__ (argz, argz_len, entry)
/* Return number of bits set in X. */
+#ifndef ARCH_POP
static int pop PARAMS ((int x));
static inline int
@@ -164,6 +165,7 @@ pop (x)
return x;
}
+#endif
struct loaded_l10nfile *
diff --git a/sysdeps/x86_64/l10nflist.c b/sysdeps/x86_64/l10nflist.c
new file mode 100644
index 0000000..2e08372
--- /dev/null
+++ b/sysdeps/x86_64/l10nflist.c
@@ -0,0 +1,13 @@
+#ifdef __POPCNT__
+# include <popcntintrin.h>
+
+static inline unsigned int
+pop (unsigned int x)
+{
+ return _mm_popcnt_u32 (x);
+}
+# define ARCH_POP 1
+
+#endif
+
+#include <intl/l10nflist.c>
http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=89edf2e9119b57fc404891670d2bc47bdfdb61ef
commit 89edf2e9119b57fc404891670d2bc47bdfdb61ef
Author: Ulrich Drepper <drepper@gmail.com>
Date: Thu Aug 11 14:04:08 2011 -0400
Locale-independent parsing in libintl
diff --git a/ChangeLog b/ChangeLog
index c8bb204..88ed726 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-08-11 Ulrich Drepper <drepper@gmail.com>
+
+ * intl/l10nflist.c (_nl_make_l10nflist): Use locale-independent
+ classification.
+
2011-08-10 Andreas Schwab <schwab@redhat.com>
* include/dirent.h: Add libc_hidden_proto for scandirat and
diff --git a/intl/l10nflist.c b/intl/l10nflist.c
index 2c06a91..a38e0ef 100644
--- a/intl/l10nflist.c
+++ b/intl/l10nflist.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-2002, 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 1995-2002, 2004, 2005, 2011 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
@@ -134,7 +134,7 @@ argz_next__ (argz, argz_len, entry)
if (entry)
{
if (entry < argz + argz_len)
- entry = strchr (entry, '\0') + 1;
+ entry = strchr (entry, '\0') + 1;
return entry >= argz + argz_len ? NULL : (char *) entry;
}
@@ -334,11 +334,11 @@ _nl_normalize_codeset (codeset, name_len)
size_t cnt;
for (cnt = 0; cnt < name_len; ++cnt)
- if (isalnum ((unsigned char) codeset[cnt]))
+ if (__isalnum_l ((unsigned char) codeset[cnt], _nl_C_locobj_ptr))
{
++len;
- if (isalpha ((unsigned char) codeset[cnt]))
+ if (__isalpha_l ((unsigned char) codeset[cnt], _nl_C_locobj_ptr))
only_digit = 0;
}
@@ -352,9 +352,9 @@ _nl_normalize_codeset (codeset, name_len)
wp = retval;
for (cnt = 0; cnt < name_len; ++cnt)
- if (isalpha ((unsigned char) codeset[cnt]))
+ if (__isalpha_l ((unsigned char) codeset[cnt], _nl_C_locobj_ptr))
*wp++ = tolower ((unsigned char) codeset[cnt]);
- else if (isdigit ((unsigned char) codeset[cnt]))
+ else if (__isdigit_l ((unsigned char) codeset[cnt], _nl_C_locobj_ptr))
*wp++ = codeset[cnt];
*wp = '\0';
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 8 ++++++++
intl/l10nflist.c | 14 ++++++++------
sysdeps/x86_64/l10nflist.c | 13 +++++++++++++
3 files changed, 29 insertions(+), 6 deletions(-)
create mode 100644 sysdeps/x86_64/l10nflist.c
hooks/post-receive
--
GNU C Library master sources