surpport seeking the recorded video
[vuplus_openembedded] / recipes / glibc / glibc-2.3.2 / libgcc-compat-other.patch
1 --- glibc-2.3.1.old/sysdeps/arm/Dist    2002-08-27 21:06:52.000000000 +0900
2 +++ glibc-2.3.1/sysdeps/arm/Dist        2003-03-01 00:29:42.000000000 +0900
3 @@ -1,2 +1,3 @@
4  ieee754.h
5  bits/link.h
6 +libgcc-compat.c
7 --- glibc-2.3.1.old/sysdeps/arm/Makefile        1970-01-01 09:00:00.000000000 +0900
8 +++ glibc-2.3.1/sysdeps/arm/Makefile    2003-03-01 00:29:42.000000000 +0900
9 @@ -0,0 +1,7 @@
10 +ifeq ($(subdir),csu)
11 +ifeq (yes,$(build-shared))
12 +# Compatibility
13 +sysdep_routines += libgcc-compat
14 +shared-only-routines += libgcc-compat
15 +endif
16 +endif
17 --- glibc-2.3.1.old/sysdeps/arm/Versions        1970-01-01 09:00:00.000000000 +0900
18 +++ glibc-2.3.1/sysdeps/arm/Versions    2003-03-01 18:22:10.000000000 +0900
19 @@ -0,0 +1,16 @@
20 +libc {
21 +  GLIBC_2.0 {
22 +    # Functions from libgcc.
23 +    __ashldi3; __ashrdi3;
24 +    __cmpdi2;
25 +    __divsi3;
26 +    __fixdfdi;
27 +    __floatdidf;
28 +    __floatdisf;
29 +    __modsi3;
30 +    __muldi3;
31 +    __ucmpdi2;
32 +    __udivsi3;
33 +    __umodsi3;
34 +  }
35 +}
36 --- glibc-2.3.1.old/sysdeps/arm/libgcc-compat.c 1970-01-01 09:00:00.000000000 +0900
37 +++ glibc-2.3.1/sysdeps/arm/libgcc-compat.c     2003-03-02 19:40:20.000000000 +0900
38 @@ -0,0 +1,111 @@
39 +/* pre-.hidden libgcc compatibility
40 +   Copyright (C) 2003 Free Software Foundation, Inc.
41 +   This file is part of the GNU C Library.
42 +   Contributed by GOTO Masanori <gotom@debian.org>
43 +
44 +   The GNU C Library is free software; you can redistribute it and/or
45 +   modify it under the terms of the GNU Lesser General Public
46 +   License as published by the Free Software Foundation; either
47 +   version 2.1 of the License, or (at your option) any later version.
48 +
49 +   The GNU C Library is distributed in the hope that it will be useful,
50 +   but WITHOUT ANY WARRANTY; without even the implied warranty of
51 +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
52 +   Lesser General Public License for more details.
53 +
54 +   You should have received a copy of the GNU Lesser General Public
55 +   License along with the GNU C Library; if not, write to the Free
56 +   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
57 +   02111-1307 USA.  */
58 +
59 +
60 +#include <stdint.h>
61 +#include <shlib-compat.h>
62 +
63 +#if SHLIB_COMPAT(libc, GLIBC_2_0, GLIBC_2_2_6)
64 +
65 +extern int64_t __ashldi3 (int64_t, int32_t);
66 +int64_t __ashldi3_internal (int64_t u, int32_t b)
67 +{
68 +  return __ashldi3 (u, b);
69 +}
70 +symbol_version (__ashldi3_internal, __ashldi3, GLIBC_2.0);
71 +
72 +extern int64_t __ashrdi3 (int64_t, int32_t);
73 +int32_t __ashrdi3_internal (int64_t u, int32_t b)
74 +{
75 +  return __ashrdi3 (u, b);
76 +}
77 +symbol_version (__ashrdi3_internal, __ashrdi3, GLIBC_2.0);
78 +
79 +extern int32_t __cmpdi2 (int64_t, int64_t);
80 +int32_t __cmpdi2_internal (int64_t u, int64_t v)
81 +{
82 +  return __cmpdi2 (u, v);
83 +}
84 +symbol_version (__cmpdi2_internal, __cmpdi2, GLIBC_2.0);
85 +
86 +extern int32_t __divsi3 (int32_t, int32_t);
87 +int32_t __divsi3_internal (int32_t u, int32_t v)
88 +{
89 +  return __divsi3 (u, v);
90 +}
91 +symbol_version (__divsi3_internal, __divsi3, GLIBC_2.0);
92 +
93 +extern int64_t __fixdfdi (double);
94 +int64_t __fixdfdi_internal (double d)
95 +{
96 +  return __fixdfdi (d);
97 +}
98 +symbol_version (__fixdfdi_internal, __fixdfdi, GLIBC_2.0);
99 +
100 +extern double __floatdidf (int64_t);
101 +double __floatdidf_internal (int64_t u)
102 +{
103 +  return __floatdidf (u);
104 +}
105 +symbol_version (__floatdidf_internal, __floatdidf, GLIBC_2.0);
106 +
107 +extern float __floatdisf (int64_t);
108 +float __floatdisf_internal (int64_t u)
109 +{
110 +  return __floatdisf (u);
111 +}
112 +symbol_version (__floatdisf_internal, __floatdisf, GLIBC_2.0);
113 +
114 +extern int32_t __modsi3 (int32_t, int32_t);
115 +int32_t __modsi3_internal (int32_t u, int32_t v)
116 +{
117 +  return __modsi3 (u, v);
118 +}
119 +symbol_version (__modsi3_internal, __modsi3, GLIBC_2.0);
120 +
121 +extern int64_t __muldi3 (int64_t, int64_t);
122 +int64_t __muldi3_internal (int64_t u, int64_t v)
123 +{
124 +  return __muldi3 (u, v);
125 +}
126 +symbol_version (__muldi3_internal, __muldi3, GLIBC_2.0);
127 +
128 +extern int32_t __ucmpdi2 (int64_t, int64_t);
129 +int32_t __ucmpdi2_internal (int64_t u, int64_t v)
130 +{
131 +  return __ucmpdi2 (u, v);
132 +}
133 +symbol_version (__ucmpdi2_internal, __ucmpdi2, GLIBC_2.0);
134 +
135 +extern int32_t __udivsi3 (int32_t, int32_t);
136 +int32_t __udivsi3_internal (int32_t u, int32_t v)
137 +{
138 +  return __udivsi3 (u, v);
139 +}
140 +symbol_version (__udivsi3_internal, __udivsi3, GLIBC_2.0);
141 +
142 +extern int32_t __umodsi3 (int32_t, int32_t);
143 +int32_t __umodsi3_internal (int32_t u, int32_t v)
144 +{
145 +  return __umodsi3 (u, v);
146 +}
147 +symbol_version (__umodsi3_internal, __umodsi3, GLIBC_2.0);
148 +
149 +#endif
150 --- glibc-2.3.1.old/sysdeps/ia64/Makefile       2002-05-15 05:46:15.000000000 +0900
151 +++ glibc-2.3.1/sysdeps/ia64/Makefile   2003-03-04 00:51:34.000000000 +0900
152 @@ -12,8 +12,8 @@
153  
154  ifeq (yes,$(build-shared))
155  # Compatibility
156 -sysdep_routines += ia64libgcc
157 -shared-only-routines += ia64libgcc
158 +sysdep_routines += libgcc-compat
159 +shared-only-routines += libgcc-compat
160  endif
161  endif
162  
163 --- glibc-2.3.1.old/sysdeps/ia64/Versions       2002-05-03 16:00:46.000000000 +0900
164 +++ glibc-2.3.1/sysdeps/ia64/Versions   2003-03-04 01:14:39.000000000 +0900
165 @@ -10,5 +10,9 @@
166      # Functions from libgcc.
167      __divtf3; __divdf3; __divsf3; __divdi3; __moddi3; __udivdi3; __umoddi3;
168      __multi3;
169 +    __divsi3;
170 +    __modsi3;
171 +    __udivsi3;
172 +    __umodsi3;
173    }
174  }
175 --- glibc-2.3.1.old/sysdeps/ia64/ia64libgcc.S   2002-05-15 05:46:15.000000000 +0900
176 +++ glibc-2.3.1/sysdeps/ia64/ia64libgcc.S       2003-03-04 00:51:34.000000000 +0900
177 @@ -1,350 +0,0 @@
178 -/* From the Intel IA-64 Optimization Guide, choose the minimum latency
179 -   alternative.  */
180 -
181 -#include <sysdep.h>
182 -#undef ret
183 -
184 -#include <shlib-compat.h>
185 -
186 -#if SHLIB_COMPAT(libc, GLIBC_2_2, GLIBC_2_2_6)
187 -
188 -/* __divtf3
189 -   Compute a 80-bit IEEE double-extended quotient.
190 -   farg0 holds the dividend.  farg1 holds the divisor.  */
191 -
192 -ENTRY(___divtf3)
193 -       cmp.eq p7, p0 = r0, r0
194 -       frcpa.s0 f10, p6 = farg0, farg1
195 -       ;;
196 -(p6)   cmp.ne p7, p0 = r0, r0
197 -       .pred.rel.mutex p6, p7
198 -(p6)   fnma.s1 f11 = farg1, f10, f1
199 -(p6)   fma.s1 f12 = farg0, f10, f0
200 -       ;;
201 -(p6)   fma.s1 f13 = f11, f11, f0
202 -(p6)   fma.s1 f14 = f11, f11, f11
203 -       ;;
204 -(p6)   fma.s1 f11 = f13, f13, f11
205 -(p6)   fma.s1 f13 = f14, f10, f10
206 -       ;;
207 -(p6)   fma.s1 f10 = f13, f11, f10
208 -(p6)   fnma.s1 f11 = farg1, f12, farg0
209 -       ;;
210 -(p6)   fma.s1 f11 = f11, f10, f12
211 -(p6)   fnma.s1 f12 = farg1, f10, f1
212 -       ;;
213 -(p6)   fma.s1 f10 = f12, f10, f10
214 -(p6)   fnma.s1 f12 = farg1, f11, farg0
215 -       ;;
216 -(p6)   fma.s0 fret0 = f12, f10, f11
217 -(p7)   mov fret0 = f10
218 -       br.ret.sptk rp
219 -END(___divtf3)
220 -       .symver ___divtf3, __divtf3@GLIBC_2.2
221 -
222 -/* __divdf3
223 -   Compute a 64-bit IEEE double quotient.
224 -   farg0 holds the dividend.  farg1 holds the divisor.  */
225 -
226 -ENTRY(___divdf3)
227 -       cmp.eq p7, p0 = r0, r0
228 -       frcpa.s0 f10, p6 = farg0, farg1
229 -       ;;
230 -(p6)   cmp.ne p7, p0 = r0, r0
231 -       .pred.rel.mutex p6, p7
232 -(p6)   fmpy.s1 f11 = farg0, f10
233 -(p6)   fnma.s1 f12 = farg1, f10, f1
234 -       ;;
235 -(p6)   fma.s1 f11 = f12, f11, f11
236 -(p6)   fmpy.s1 f13 = f12, f12
237 -       ;;
238 -(p6)   fma.s1 f10 = f12, f10, f10
239 -(p6)   fma.s1 f11 = f13, f11, f11
240 -       ;;
241 -(p6)   fmpy.s1 f12 = f13, f13
242 -(p6)   fma.s1 f10 = f13, f10, f10
243 -       ;;
244 -(p6)   fma.d.s1 f11 = f12, f11, f11
245 -(p6)   fma.s1 f10 = f12, f10, f10
246 -       ;;
247 -(p6)   fnma.d.s1 f8 = farg1, f11, farg0
248 -       ;;
249 -(p6)   fma.d fret0 = f8, f10, f11
250 -(p7)   mov fret0 = f10
251 -       br.ret.sptk rp
252 -       ;;
253 -END(___divdf3)
254 -       .symver ___divdf3, __divdf3@GLIBC_2.2
255 -
256 -/* __divsf3
257 -   Compute a 32-bit IEEE float quotient.
258 -   farg0 holds the dividend.  farg1 holds the divisor.  */
259 -
260 -ENTRY(___divsf3)
261 -       cmp.eq p7, p0 = r0, r0
262 -       frcpa.s0 f10, p6 = farg0, farg1
263 -       ;;
264 -(p6)   cmp.ne p7, p0 = r0, r0
265 -       .pred.rel.mutex p6, p7
266 -(p6)   fmpy.s1 f8 = farg0, f10
267 -(p6)   fnma.s1 f9 = farg1, f10, f1
268 -       ;;
269 -(p6)   fma.s1 f8 = f9, f8, f8
270 -(p6)   fmpy.s1 f9 = f9, f9
271 -       ;;
272 -(p6)   fma.s1 f8 = f9, f8, f8
273 -(p6)   fmpy.s1 f9 = f9, f9
274 -       ;;
275 -(p6)   fma.d.s1 f10 = f9, f8, f8
276 -       ;;
277 -(p6)   fnorm.s.s0 fret0 = f10
278 -(p7)   mov fret0 = f10
279 -       br.ret.sptk rp
280 -       ;;
281 -END(___divsf3)
282 -       .symver ___divsf3, __divsf3@GLIBC_2.2
283 -
284 -/* __divdi3
285 -   Compute a 64-bit integer quotient.
286 -   in0 holds the dividend.  in1 holds the divisor.  */
287 -
288 -ENTRY(___divdi3)
289 -       .regstk 2,0,0,0
290 -       /* Transfer inputs to FP registers.  */
291 -       setf.sig f8 = in0
292 -       setf.sig f9 = in1
293 -       ;;
294 -       /* Convert the inputs to FP, so that they won't be treated as
295 -          unsigned.  */
296 -       fcvt.xf f8 = f8
297 -       fcvt.xf f9 = f9
298 -       ;;
299 -       /* Compute the reciprocal approximation.  */
300 -       frcpa.s1 f10, p6 = f8, f9
301 -       ;;
302 -       /* 3 Newton-Raphson iterations.  */
303 -(p6)   fnma.s1 f11 = f9, f10, f1
304 -(p6)   fmpy.s1 f12 = f8, f10
305 -       ;;
306 -(p6)   fmpy.s1 f13 = f11, f11
307 -(p6)   fma.s1 f12 = f11, f12, f12
308 -       ;;
309 -(p6)   fma.s1 f10 = f11, f10, f10
310 -(p6)   fma.s1 f11 = f13, f12, f12
311 -       ;;
312 -(p6)   fma.s1 f10 = f13, f10, f10
313 -(p6)   fnma.s1 f12 = f9, f11, f8
314 -       ;;
315 -(p6)   fma.s1 f10 = f12, f10, f11
316 -       ;;
317 -       /* Round quotient to an integer.  */
318 -       fcvt.fx.trunc.s1 f10 = f10
319 -       ;;
320 -       /* Transfer result to GP registers.  */
321 -       getf.sig ret0 = f10
322 -       br.ret.sptk rp
323 -       ;;
324 -END(___divdi3)
325 -       .symver ___divdi3, __divdi3@GLIBC_2.2
326 -
327 -/* __moddi3
328 -   Compute a 64-bit integer modulus.
329 -   in0 holds the dividend (a).  in1 holds the divisor (b).  */
330 -
331 -ENTRY(___moddi3)
332 -       .regstk 2,0,0,0
333 -       /* Transfer inputs to FP registers.  */
334 -       setf.sig f14 = in0
335 -       setf.sig f9 = in1
336 -       ;;
337 -       /* Convert the inputs to FP, so that they won't be treated as
338 -          unsigned.  */
339 -       fcvt.xf f8 = f14
340 -       fcvt.xf f9 = f9
341 -       ;;
342 -       /* Compute the reciprocal approximation.  */
343 -       frcpa.s1 f10, p6 = f8, f9
344 -       ;;
345 -       /* 3 Newton-Raphson iterations.  */
346 -(p6)   fmpy.s1 f12 = f8, f10
347 -(p6)   fnma.s1 f11 = f9, f10, f1
348 -       ;;
349 -(p6)   fma.s1 f12 = f11, f12, f12
350 -(p6)   fmpy.s1 f13 = f11, f11
351 -       ;;
352 -(p6)   fma.s1 f10 = f11, f10, f10
353 -(p6)   fma.s1 f11 = f13, f12, f12
354 -       ;;
355 -       sub in1 = r0, in1
356 -(p6)   fma.s1 f10 = f13, f10, f10
357 -(p6)   fnma.s1 f12 = f9, f11, f8
358 -       ;;
359 -       setf.sig f9 = in1
360 -(p6)   fma.s1 f10 = f12, f10, f11
361 -       ;;
362 -       fcvt.fx.trunc.s1 f10 = f10
363 -       ;;
364 -       /* r = q * (-b) + a  */
365 -       xma.l f10 = f10, f9, f14
366 -       ;;
367 -       /* Transfer result to GP registers.  */
368 -       getf.sig ret0 = f10
369 -       br.ret.sptk rp
370 -       ;;
371 -END(___moddi3)
372 -       .symver ___moddi3, __moddi3@GLIBC_2.2
373 -
374 -/* __udivdi3
375 -   Compute a 64-bit unsigned integer quotient.
376 -   in0 holds the dividend.  in1 holds the divisor.  */
377 -
378 -ENTRY(___udivdi3)
379 -       .regstk 2,0,0,0
380 -       /* Transfer inputs to FP registers.  */
381 -       setf.sig f8 = in0
382 -       setf.sig f9 = in1
383 -       ;;
384 -       /* Convert the inputs to FP, to avoid FP software-assist faults.  */
385 -       fcvt.xuf.s1 f8 = f8
386 -       fcvt.xuf.s1 f9 = f9
387 -       ;;
388 -       /* Compute the reciprocal approximation.  */
389 -       frcpa.s1 f10, p6 = f8, f9
390 -       ;;
391 -       /* 3 Newton-Raphson iterations.  */
392 -(p6)   fnma.s1 f11 = f9, f10, f1
393 -(p6)   fmpy.s1 f12 = f8, f10
394 -       ;;
395 -(p6)   fmpy.s1 f13 = f11, f11
396 -(p6)   fma.s1 f12 = f11, f12, f12
397 -       ;;
398 -(p6)   fma.s1 f10 = f11, f10, f10
399 -(p6)   fma.s1 f11 = f13, f12, f12
400 -       ;;
401 -(p6)   fma.s1 f10 = f13, f10, f10
402 -(p6)   fnma.s1 f12 = f9, f11, f8
403 -       ;;
404 -(p6)   fma.s1 f10 = f12, f10, f11
405 -       ;;
406 -       /* Round quotient to an unsigned integer.  */
407 -       fcvt.fxu.trunc.s1 f10 = f10
408 -       ;;
409 -       /* Transfer result to GP registers.  */
410 -       getf.sig ret0 = f10
411 -       br.ret.sptk rp
412 -       ;;
413 -END(___udivdi3)
414 -       .symver ___udivdi3, __udivdi3@GLIBC_2.2
415 -
416 -/* __umoddi3
417 -   Compute a 64-bit unsigned integer modulus.
418 -   in0 holds the dividend (a).  in1 holds the divisor (b).  */
419 -
420 -ENTRY(___umoddi3)
421 -       .regstk 2,0,0,0
422 -       /* Transfer inputs to FP registers.  */
423 -       setf.sig f14 = in0
424 -       setf.sig f9 = in1
425 -       ;;
426 -       /* Convert the inputs to FP, to avoid FP software assist faults.  */
427 -       fcvt.xuf.s1 f8 = f14
428 -       fcvt.xuf.s1 f9 = f9
429 -       ;;
430 -       /* Compute the reciprocal approximation.  */
431 -       frcpa.s1 f10, p6 = f8, f9
432 -       ;;
433 -       /* 3 Newton-Raphson iterations.  */
434 -(p6)   fmpy.s1 f12 = f8, f10
435 -(p6)   fnma.s1 f11 = f9, f10, f1
436 -       ;;
437 -(p6)   fma.s1 f12 = f11, f12, f12
438 -(p6)   fmpy.s1 f13 = f11, f11
439 -       ;;
440 -(p6)   fma.s1 f10 = f11, f10, f10
441 -(p6)   fma.s1 f11 = f13, f12, f12
442 -       ;;
443 -       sub in1 = r0, in1
444 -(p6)   fma.s1 f10 = f13, f10, f10
445 -(p6)   fnma.s1 f12 = f9, f11, f8
446 -       ;;
447 -       setf.sig f9 = in1
448 -(p6)   fma.s1 f10 = f12, f10, f11
449 -       ;;
450 -       /* Round quotient to an unsigned integer.  */
451 -       fcvt.fxu.trunc.s1 f10 = f10
452 -       ;;
453 -       /* r = q * (-b) + a  */
454 -       xma.l f10 = f10, f9, f14
455 -       ;;
456 -       /* Transfer result to GP registers.  */
457 -       getf.sig ret0 = f10
458 -       br.ret.sptk rp
459 -       ;;
460 -END(___umoddi3)
461 -       .symver ___umoddi3, __umoddi3@GLIBC_2.2
462 -
463 -/* __multi3
464 -   Compute a 128-bit multiply of 128-bit multiplicands.
465 -   in0/in1 holds one multiplicand (a), in2/in3 holds the other one (b).  */
466 -
467 -ENTRY(___multi3)
468 -       .regstk 4,0,0,0
469 -       setf.sig f6 = in1
470 -       movl r19 = 0xffffffff
471 -       setf.sig f7 = in2
472 -       ;;
473 -       and r14 = r19, in0
474 -       ;;
475 -       setf.sig f10 = r14
476 -       and r14 = r19, in2
477 -       xmpy.l f9 = f6, f7
478 -       ;;
479 -       setf.sig f6 = r14
480 -       shr.u r14 = in0, 32
481 -       ;;
482 -       setf.sig f7 = r14
483 -       shr.u r14 = in2, 32
484 -       ;;
485 -       setf.sig f8 = r14
486 -       xmpy.l f11 = f10, f6
487 -       xmpy.l f6 = f7, f6
488 -       ;;
489 -       getf.sig r16 = f11
490 -       xmpy.l f7 = f7, f8
491 -       ;;
492 -       shr.u r14 = r16, 32
493 -       and r16 = r19, r16
494 -       getf.sig r17 = f6
495 -       setf.sig f6 = in0
496 -       ;;
497 -       setf.sig f11 = r14
498 -       getf.sig r21 = f7
499 -       setf.sig f7 = in3
500 -       ;;
501 -       xma.l f11 = f10, f8, f11
502 -       xma.l f6 = f6, f7, f9
503 -       ;;
504 -       getf.sig r18 = f11
505 -       ;;
506 -       add r18 = r18, r17
507 -       ;;
508 -       and r15 = r19, r18
509 -       cmp.ltu p7, p6 = r18, r17
510 -       ;;
511 -       getf.sig r22 = f6
512 -(p7)   adds r14 = 1, r19
513 -       ;;
514 -(p7)   add r21 = r21, r14
515 -       shr.u r14 = r18, 32
516 -       shl r15 = r15, 32
517 -       ;;
518 -       add r20 = r21, r14
519 -       ;;
520 -       add ret0 = r15, r16
521 -       add ret1 = r22, r20
522 -       br.ret.sptk rp
523 -       ;;
524 -END(___multi3)
525 -       .symver ___multi3, __multi3@GLIBC_2.2
526 -
527 -#endif
528 --- glibc-2.3.1.old/sysdeps/ia64/libgcc-compat.c        1970-01-01 09:00:00.000000000 +0900
529 +++ glibc-2.3.1/sysdeps/ia64/libgcc-compat.c    2003-03-04 02:24:15.000000000 +0900
530 @@ -0,0 +1,112 @@
531 +/* pre-.hidden libgcc compatibility
532 +   Copyright (C) 2002 Free Software Foundation, Inc.
533 +   This file is part of the GNU C Library.
534 +
535 +   The GNU C Library is free software; you can redistribute it and/or
536 +   modify it under the terms of the GNU Lesser General Public
537 +   License as published by the Free Software Foundation; either
538 +   version 2.1 of the License, or (at your option) any later version.
539 +
540 +   The GNU C Library is distributed in the hope that it will be useful,
541 +   but WITHOUT ANY WARRANTY; without even the implied warranty of
542 +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
543 +   Lesser General Public License for more details.
544 +
545 +   You should have received a copy of the GNU Lesser General Public
546 +   License along with the GNU C Library; if not, write to the Free
547 +   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
548 +   02111-1307 USA.  */
549 +
550 +
551 +#include <stdint.h>
552 +#include <shlib-compat.h>
553 +
554 +#if SHLIB_COMPAT(libc, GLIBC_2_2, GLIBC_2_2_6)
555 +
556 +typedef int int128_t __attribute__((__mode__(TI)));
557 +
558 +extern long double __divtf3 (long double, long double) attribute_hidden;
559 +long double INTUSE (__divtf3) (long double x, long double y)
560 +{
561 +  return __divtf3 (x, y);
562 +}
563 +symbol_version (INTUSE (__divtf3), __divtf3, GLIBC_2.2);
564 +
565 +extern double __divdf3 (double, double) attribute_hidden;
566 +double INTUSE (__divdf3) (double x, double y)
567 +{
568 +  return __divdf3 (x, y);
569 +}
570 +symbol_version (INTUSE (__divdf3), __divdf3, GLIBC_2.2);
571 +
572 +extern float __divsf3 (float, float) attribute_hidden;
573 +float INTUSE (__divsf3) (float x, float y)
574 +{
575 +  return __divsf3 (x, y);
576 +}
577 +symbol_version (INTUSE (__divsf3), __divsf3, GLIBC_2.2);
578 +
579 +extern int64_t __divdi3 (int64_t, int64_t) attribute_hidden;
580 +int64_t INTUSE (__divdi3) (int64_t x, int64_t y)
581 +{
582 +  return __divdi3 (x, y);
583 +}
584 +symbol_version (INTUSE (__divdi3), __divdi3, GLIBC_2.2);
585 +
586 +extern int64_t __moddi3 (int64_t, int64_t) attribute_hidden;
587 +int64_t INTUSE (__moddi3) (int64_t x, int64_t y)
588 +{
589 +  return __moddi3 (x, y);
590 +}
591 +symbol_version (INTUSE (__moddi3), __moddi3, GLIBC_2.2);
592 +
593 +extern uint64_t __udivdi3 (uint64_t, uint64_t) attribute_hidden;
594 +uint64_t INTUSE (__udivdi3) (uint64_t x, uint64_t y)
595 +{
596 +  return __udivdi3 (x, y);
597 +}
598 +symbol_version (INTUSE (__udivdi3), __udivdi3, GLIBC_2.2);
599 +
600 +extern uint64_t __umoddi3 (uint64_t, uint64_t) attribute_hidden;
601 +uint64_t INTUSE (__umoddi3) (uint64_t x, uint64_t y)
602 +{
603 +  return __umoddi3 (x, y);
604 +}
605 +symbol_version (INTUSE (__umoddi3), __umoddi3, GLIBC_2.2);
606 +
607 +extern int128_t __multi3 (int128_t, int128_t) attribute_hidden;
608 +int128_t INTUSE (__multi3) (int128_t x, int128_t y)
609 +{
610 +  return __multi3 (x, y);
611 +}
612 +symbol_version (INTUSE (__multi3), __multi3, GLIBC_2.2);
613 +
614 +extern int64_t __divsi3 (int64_t, int64_t) attribute_hidden;
615 +int64_t INTUSE (__divsi3) (int64_t x, int64_t y)
616 +{
617 +  return __divsi3 (x, y);
618 +}
619 +symbol_version (INTUSE (__divsi3), __divsi3, GLIBC_2.2);
620 +
621 +extern int64_t __modsi3 (int64_t, int64_t) attribute_hidden;
622 +int64_t INTUSE (__modsi3) (int64_t x, int64_t y)
623 +{
624 +  return __modsi3 (x, y);
625 +}
626 +symbol_version (INTUSE (__modsi3), __modsi3, GLIBC_2.2);
627 +
628 +extern uint64_t __udivsi3 (uint64_t, uint64_t) attribute_hidden;
629 +uint64_t INTUSE (__udivsi3) (uint64_t x, uint64_t y)
630 +{
631 +  return __udivsi3 (x, y);
632 +}
633 +symbol_version (INTUSE (__udivsi3), __udivsi3, GLIBC_2.2);
634 +
635 +extern uint64_t __umodsi3 (uint64_t, uint64_t) attribute_hidden;
636 +uint64_t INTUSE (__umodsi3) (uint64_t x, uint64_t y)
637 +{
638 +  return __umodsi3 (x, y);
639 +}
640 +symbol_version (INTUSE (__umodsi3), __umodsi3, GLIBC_2.2);
641 +
642 +#endif
643 --- glibc-2.3.1.old/sysdeps/m68k/Deps   1970-01-01 09:00:00.000000000 +0900
644 +++ glibc-2.3.1/sysdeps/m68k/Deps       2003-03-01 00:29:42.000000000 +0900
645 @@ -0,0 +1 @@
646 +libgcc-compat.c
647 --- glibc-2.3.1.old/sysdeps/m68k/Makefile       2003-02-27 19:29:49.000000000 +0900
648 +++ glibc-2.3.1/sysdeps/m68k/Makefile   2003-03-01 00:29:42.000000000 +0900
649 @@ -45,3 +45,11 @@
650  # Build objects in libc_nonshared.a with -fPIC (instead of -fpic) to avoid
651  # possible linkage problems.
652  CFLAGS-.oS += -fPIC
653 +
654 +ifeq ($(subdir),csu)
655 +ifeq (yes,$(build-shared))
656 +# Compatibility
657 +sysdep_routines += libgcc-compat
658 +shared-only-routines += libgcc-compat
659 +endif
660 +endif
661 --- glibc-2.3.1.old/sysdeps/m68k/Versions       2000-06-15 15:54:28.000000000 +0900
662 +++ glibc-2.3.1/sysdeps/m68k/Versions   2003-03-02 01:12:58.000000000 +0900
663 @@ -2,5 +2,13 @@
664    GLIBC_2.0 {
665      # Functions from libgcc.
666      __divdi3; __moddi3; __udivdi3; __umoddi3;
667 +    __ashldi3;
668 +    __ashrdi3;
669 +    __fixdfdi;
670 +    __fixsfdi;
671 +    __fixunsdfdi;
672 +    __fixunssfdi;
673 +    __floatdidf;
674 +    __floatdisf;
675    }
676  }
677 --- glibc-2.3.1.old/sysdeps/m68k/libgcc-compat.c        1970-01-01 09:00:00.000000000 +0900
678 +++ glibc-2.3.1/sysdeps/m68k/libgcc-compat.c    2003-03-02 13:26:49.000000000 +0900
679 @@ -0,0 +1,83 @@
680 +/* pre-.hidden libgcc compatibility
681 +   Copyright (C) 2003 Free Software Foundation, Inc.
682 +   This file is part of the GNU C Library.
683 +   Contributed by GOTO Masanori <gotom@debian.org>
684 +
685 +   The GNU C Library is free software; you can redistribute it and/or
686 +   modify it under the terms of the GNU Lesser General Public
687 +   License as published by the Free Software Foundation; either
688 +   version 2.1 of the License, or (at your option) any later version.
689 +
690 +   The GNU C Library is distributed in the hope that it will be useful,
691 +   but WITHOUT ANY WARRANTY; without even the implied warranty of
692 +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
693 +   Lesser General Public License for more details.
694 +
695 +   You should have received a copy of the GNU Lesser General Public
696 +   License along with the GNU C Library; if not, write to the Free
697 +   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
698 +   02111-1307 USA.  */
699 +
700 +
701 +#include <stdint.h>
702 +#include <shlib-compat.h>
703 +
704 +#if SHLIB_COMPAT(libc, GLIBC_2_0, GLIBC_2_2_6)
705 +
706 +extern int64_t __ashldi3 (int64_t, int32_t);
707 +int64_t __ashldi3_internal (int64_t u, int32_t b)
708 +{
709 +  return __ashldi3 (u, b);
710 +}
711 +symbol_version (__ashldi3_internal, __ashldi3, GLIBC_2.0);
712 +
713 +extern int64_t __ashrdi3 (int64_t, int32_t);
714 +int64_t __ashrdi3_internal (int64_t u, int32_t b)
715 +{
716 +  return __ashrdi3 (u, b);
717 +}
718 +symbol_version (__ashrdi3_internal, __ashrdi3, GLIBC_2.0);
719 +
720 +extern int64_t __fixdfdi (double);
721 +int64_t __fixdfdi_internal (double d)
722 +{
723 +  return __fixdfdi (d);
724 +}
725 +symbol_version (__fixdfdi_internal, __fixdfdi, GLIBC_2.0);
726 +
727 +extern int64_t __fixsfdi (float);
728 +int64_t __fixsfdi_internal (float d)
729 +{
730 +  return __fixsfdi (d);
731 +}
732 +symbol_version (__fixsfdi_internal, __fixsfdi, GLIBC_2.0);
733 +
734 +extern int64_t __fixunsdfdi (double);
735 +int64_t __fixunsdfdi_internal (double d)
736 +{
737 +  return __fixunsdfdi (d);
738 +}
739 +symbol_version (__fixunsdfdi_internal, __fixunsdfdi, GLIBC_2.0);
740 +
741 +extern int64_t __fixunssfdi (float);
742 +int64_t __fixunssfdi_internal (float d)
743 +{
744 +  return __fixunssfdi (d);
745 +}
746 +symbol_version (__fixunssfdi_internal, __fixunssfdi, GLIBC_2.0);
747 +
748 +extern double __floatdidf (int64_t);
749 +double __floatdidf_internal (int64_t u)
750 +{
751 +  return __floatdidf (u);
752 +}
753 +symbol_version (__floatdidf_internal, __floatdidf, GLIBC_2.0);
754 +
755 +extern float __floatdisf (int64_t);
756 +float __floatdisf_internal (int64_t u)
757 +{
758 +  return __floatdisf (u);
759 +}
760 +symbol_version (__floatdisf_internal, __floatdisf, GLIBC_2.0);
761 +
762 +#endif
763 --- glibc-2.3.1.old/sysdeps/s390/s390-32/Dist   2001-03-27 14:14:38.000000000 +0900
764 +++ glibc-2.3.1/sysdeps/s390/s390-32/Dist       2003-03-02 11:09:37.000000000 +0900
765 @@ -1 +1,2 @@
766  s390-mcount.S
767 +libgcc-compat.c
768 --- glibc-2.3.1.old/sysdeps/s390/s390-32/Makefile       2002-09-19 15:42:09.000000000 +0900
769 +++ glibc-2.3.1/sysdeps/s390/s390-32/Makefile   2003-03-02 11:09:11.000000000 +0900
770 @@ -9,3 +9,11 @@
771  CFLAGS-dl-load.c += -Wno-unused
772  CFLAGS-dl-reloc.c += -Wno-unused
773  endif
774 +
775 +ifeq ($(subdir),csu)
776 +ifeq (yes,$(build-shared))
777 +# Compatibility
778 +sysdep_routines += libgcc-compat
779 +shared-only-routines += libgcc-compat
780 +endif
781 +endif
782 --- glibc-2.3.1.old/sysdeps/s390/s390-32/Versions       2001-03-16 17:15:07.000000000 +0900
783 +++ glibc-2.3.1/sysdeps/s390/s390-32/Versions   2003-03-02 11:08:03.000000000 +0900
784 @@ -2,5 +2,13 @@
785    GLIBC_2.0 {
786      # Functions from libgcc.
787      __divdi3; __moddi3; __udivdi3; __umoddi3;
788 +    __cmpdi2;
789 +    __fixdfdi;
790 +    __fixsfdi;
791 +    __fixunsdfdi;
792 +    __fixunssfdi;
793 +    __floatdidf;
794 +    __floatdisf;
795 +    __ucmpdi2;
796    }
797  }
798 --- glibc-2.3.1.old/sysdeps/s390/s390-32/libgcc-compat.c        1970-01-01 09:00:00.000000000 +0900
799 +++ glibc-2.3.1/sysdeps/s390/s390-32/libgcc-compat.c    2003-03-02 19:42:19.000000000 +0900
800 @@ -0,0 +1,83 @@
801 +/* pre-.hidden libgcc compatibility
802 +   Copyright (C) 2003 Free Software Foundation, Inc.
803 +   This file is part of the GNU C Library.
804 +   Contributed by GOTO Masanori <gotom@debian.org>
805 +
806 +   The GNU C Library is free software; you can redistribute it and/or
807 +   modify it under the terms of the GNU Lesser General Public
808 +   License as published by the Free Software Foundation; either
809 +   version 2.1 of the License, or (at your option) any later version.
810 +
811 +   The GNU C Library is distributed in the hope that it will be useful,
812 +   but WITHOUT ANY WARRANTY; without even the implied warranty of
813 +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
814 +   Lesser General Public License for more details.
815 +
816 +   You should have received a copy of the GNU Lesser General Public
817 +   License along with the GNU C Library; if not, write to the Free
818 +   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
819 +   02111-1307 USA.  */
820 +
821 +
822 +#include <stdint.h>
823 +#include <shlib-compat.h>
824 +
825 +#if SHLIB_COMPAT(libc, GLIBC_2_0, GLIBC_2_2_6)
826 +
827 +extern int32_t __cmpdi2 (int64_t, int64_t);
828 +int32_t __cmpdi2_internal (int64_t u, int64_t v)
829 +{
830 +  return __cmpdi2 (u, v);
831 +}
832 +symbol_version (__cmpdi2_internal, __cmpdi2, GLIBC_2.0);
833 +
834 +extern int64_t __fixdfdi (double);
835 +int64_t __fixdfdi_internal (double d)
836 +{
837 +  return __fixdfdi (d);
838 +}
839 +symbol_version (__fixdfdi_internal, __fixdfdi, GLIBC_2.0);
840 +
841 +extern int64_t __fixsfdi (float);
842 +int64_t __fixsfdi_internal (float d)
843 +{
844 +  return __fixsfdi (d);
845 +}
846 +symbol_version (__fixsfdi_internal, __fixsfdi, GLIBC_2.0);
847 +
848 +extern int64_t __fixunsdfdi (double);
849 +int64_t __fixunsdfdi_internal (double d)
850 +{
851 +  return __fixunsdfdi (d);
852 +}
853 +symbol_version (__fixunsdfdi_internal, __fixunsdfdi, GLIBC_2.0);
854 +
855 +extern int64_t __fixunssfdi (float);
856 +int64_t __fixunssfdi_internal (float d)
857 +{
858 +  return __fixunssfdi (d);
859 +}
860 +symbol_version (__fixunssfdi_internal, __fixunssfdi, GLIBC_2.0);
861 +
862 +extern double __floatdidf (int64_t);
863 +double __floatdidf_internal (int64_t u)
864 +{
865 +  return __floatdidf (u);
866 +}
867 +symbol_version (__floatdidf_internal, __floatdidf, GLIBC_2.0);
868 +
869 +extern float __floatdisf (int64_t);
870 +float __floatdisf_internal (int64_t u)
871 +{
872 +  return __floatdisf (u);
873 +}
874 +symbol_version (__floatdisf_internal, __floatdisf, GLIBC_2.0);
875 +
876 +extern int32_t __ucmpdi2 (int64_t, int64_t);
877 +int32_t __ucmpdi2_internal (int64_t u, int64_t v)
878 +{
879 +  return __ucmpdi2 (u, v);
880 +}
881 +symbol_version (__ucmpdi2_internal, __ucmpdi2, GLIBC_2.0);
882 +
883 +#endif