summaryrefslogtreecommitdiffstats
path: root/meta/packages/glibc/glibc-cvs/arm-longlong.patch
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2006-07-21 10:10:31 +0000
committerRichard Purdie <richard@openedhand.com>2006-07-21 10:10:31 +0000
commitb2f192faabe412adce79534e22efe9fb69ee40e2 (patch)
tree7076c49d4286f8a1733650bd8fbc7161af200d57 /meta/packages/glibc/glibc-cvs/arm-longlong.patch
parent2cf0eadf9f730027833af802d7e6c90b44248f80 (diff)
downloadpoky-b2f192faabe412adce79534e22efe9fb69ee40e2.tar.gz
Rename /openembedded/ -> /meta/
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@530 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/packages/glibc/glibc-cvs/arm-longlong.patch')
-rw-r--r--meta/packages/glibc/glibc-cvs/arm-longlong.patch59
1 files changed, 59 insertions, 0 deletions
diff --git a/meta/packages/glibc/glibc-cvs/arm-longlong.patch b/meta/packages/glibc/glibc-cvs/arm-longlong.patch
new file mode 100644
index 0000000000..dfb9309b7b
--- /dev/null
+++ b/meta/packages/glibc/glibc-cvs/arm-longlong.patch
@@ -0,0 +1,59 @@
1--- stdlib/longlong.h~ 2002-09-29 18:45:58.000000000 +0100
2+++ stdlib/longlong.h 2004-03-20 19:16:44.000000000 +0000
3@@ -210,6 +210,14 @@
4 "rI" ((USItype) (bh)), \
5 "r" ((USItype) (al)), \
6 "rI" ((USItype) (bl)))
7+/* v3m and all higher arches have long multiply support. */
8+#if !defined(__ARM_ARCH_2__) && !defined(__ARM_ARCH_3__)
9+#define umul_ppmm(xh, xl, a, b) \
10+ __asm__ ("umull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b))
11+#define UMUL_TIME 5
12+#define smul_ppmm(xh, xl, a, b) \
13+ __asm__ ("smull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b))
14+#else
15 #define umul_ppmm(xh, xl, a, b) \
16 {register USItype __t0, __t1, __t2; \
17 __asm__ ("%@ Inlined umul_ppmm\n" \
18@@ -231,7 +239,14 @@
19 : "r" ((USItype) (a)), \
20 "r" ((USItype) (b)));}
21 #define UMUL_TIME 20
22+#endif
23 #define UDIV_TIME 100
24+
25+#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__)
26+#define count_leading_zeros(COUNT,X) ((COUNT) = __builtin_clz (X))
27+#define COUNT_LEADING_ZEROS_0 32
28+#endif
29+
30 #endif /* __arm__ */
31
32 #if defined (__hppa) && W_TYPE_SIZE == 32
33--- /dev/null 2004-02-02 20:32:13.000000000 +0000
34+++ sysdeps/arm/mp_clz_tab.c 2004-03-20 19:24:26.000000000 +0000
35@@ -0,0 +1,24 @@
36+/* __clz_tab -- support for longlong.h
37+ Copyright (C) 2004 Free Software Foundation, Inc.
38+ This file is part of the GNU C Library.
39+
40+ The GNU C Library is free software; you can redistribute it and/or
41+ modify it under the terms of the GNU Lesser General Public
42+ License as published by the Free Software Foundation; either
43+ version 2.1 of the License, or (at your option) any later version.
44+
45+ The GNU C Library is distributed in the hope that it will be useful,
46+ but WITHOUT ANY WARRANTY; without even the implied warranty of
47+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
48+ Lesser General Public License for more details.
49+
50+ You should have received a copy of the GNU Lesser General Public
51+ License along with the GNU C Library; if not, write to the Free
52+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
53+ 02111-1307 USA. */
54+
55+#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__)
56+/* Nothing required. */
57+#else
58+#include <sysdeps/generic/mp_clz_tab.c>
59+#endif