patches/glibc/2.3.6/160-sh-memset.patch
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Mon Aug 04 17:45:27 2008 +0000 (2008-08-04)
changeset 759 6b3374c4aef5
parent 402 197e1b49586e
permissions -rw-r--r--
All ARM sample now build with gcc-4.3.1! :-)
Unfortunately (fortunately?), this implies using a uClibc snapshot.

/trunk/samples/armeb-unknown-linux-uclibc/uClibc-20080801.config | 243 243 0 0 ++++++++++
/trunk/samples/armeb-unknown-linux-uclibc/crosstool.config | 29 17 12 0 +
/trunk/samples/arm-unknown-linux-gnueabi/crosstool.config | 13 8 5 0 +
/trunk/samples/arm-unknown-linux-uclibcgnueabi/uClibc-20080801.config | 243 243 0 0 ++++++++++
/trunk/samples/arm-unknown-linux-uclibcgnueabi/crosstool.config | 29 17 12 0 +
/trunk/samples/armeb-unknown-linux-gnu/crosstool.config | 13 8 5 0 +
/trunk/samples/arm-unknown-linux-uclibc/uClibc-20080801.config | 243 243 0 0 ++++++++++
/trunk/samples/arm-unknown-linux-uclibc/crosstool.config | 29 17 12 0 +
/trunk/samples/armeb-unknown-linux-uclibcgnueabi/uClibc-20080801.config | 243 243 0 0 ++++++++++
/trunk/samples/armeb-unknown-linux-uclibcgnueabi/crosstool.config | 29 17 12 0 +
10 files changed, 1056 insertions(+), 58 deletions(-)
     1 From:
     2 	http://sources.redhat.com/ml/libc-alpha/2005-07/msg00051.html
     3 	http://sources.redhat.com/ml/crossgcc/2005-10/msg00035.html
     4 
     5 Message-ID: <434576E1.6020305@sscd.de>
     6 Date: Thu, 06 Oct 2005 21:11:29 +0200
     7 From: Alexander Sieb <sieb at sscd dot de>
     8 To: crossgcc at sourceware dot org
     9 Subject: Crosstool sh4-linux-gcc-4.0.2-glibc-2.3.5 patches
    10 
    11 On sh[34]-linux, memset function does not work if 2nd argument is negative
    12 and 3rd argument is greater than 12.
    13 for example, memset(ptr, "\xda", 20) sets 0xff instead of 0xda.
    14  
    15 Attached patch fixes this problem.
    16  
    17 	* sysdeps/sh/memset.S (memset): Correct 2nd argument handling.
    18  
    19 --- glibc-2.3.5.old/sysdeps/sh/memset.S	29 Apr 2003 22:47:18 -0000	1.4
    20 +++ glibc-2.3.5/sysdeps/sh/memset.S	23 Jul 2005 08:37:21 -0000
    21 @@ -28,6 +28,7 @@ ENTRY(memset)
    22  	bt.s	L_byte_loop_init
    23  	mov	r4,r7
    24  
    25 +	extu.b	r5,r5
    26  	swap.b	r5,r1
    27  	or	r1,r5
    28 	swap.w	r5,r1
    29 
    30 Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>