about summary refs log tree commit diff
path: root/sysdeps/ia64/memccpy.S
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-12-22 20:10:10 +0000
committerUlrich Drepper <drepper@redhat.com>2004-12-22 20:10:10 +0000
commita334319f6530564d22e775935d9c91663623a1b4 (patch)
treeb5877475619e4c938e98757d518bb1e9cbead751 /sysdeps/ia64/memccpy.S
parent0ecb606cb6cf65de1d9fc8a919bceb4be476c602 (diff)
downloadglibc-a334319f6530564d22e775935d9c91663623a1b4.tar.gz
glibc-a334319f6530564d22e775935d9c91663623a1b4.tar.xz
glibc-a334319f6530564d22e775935d9c91663623a1b4.zip
(CFLAGS-tst-align.c): Add -mpreferred-stack-boundary=4.
Diffstat (limited to 'sysdeps/ia64/memccpy.S')
-rw-r--r--sysdeps/ia64/memccpy.S55
1 files changed, 9 insertions, 46 deletions
diff --git a/sysdeps/ia64/memccpy.S b/sysdeps/ia64/memccpy.S
index dd638d43c8..53c43c512b 100644
--- a/sysdeps/ia64/memccpy.S
+++ b/sysdeps/ia64/memccpy.S
@@ -1,6 +1,6 @@
 /* Optimized version of the memccpy() function.
    This file is part of the GNU C Library.
-   Copyright (C) 2000,2001,2003,2006 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2001, 2003 Free Software Foundation, Inc.
    Contributed by Dan Pop <Dan.Pop@cern.ch>.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -183,64 +183,27 @@ ENTRY(memccpy)
 	br.ret.sptk.many b0
 
 .recovery1:
-#if MEMLAT != 6
-# error "MEMLAT must be 6!"
-#endif
-	adds	src = -8, asrc
+	adds	src = -(MEMLAT + 6 + 1) * 8, asrc
 	mov	loopcnt = ar.lc
-	mov	tmp = ar.ec
-	;;
-(p[0])	adds	src = -8, src
-	;;
-(p[1])	adds	src = -8, src
+	mov	tmp = ar.ec ;;
 	sub	sh1 = (MEMLAT + 6 + 1), tmp
-	;;
-(p[2])	adds	src = -8, src
-	;;
-(p[3])	adds	src = -8, src
+	shr.u	sh2 = sh2, 3
+	;; 
 	shl	loopcnt = loopcnt, 3
-	;;
-(p[4])	adds	src = -8, src
-	;;
-(p[5])	adds	src = -8, src
+	sub	src = src, sh2
 	shl	sh1 = sh1, 3
-	;;
-(p[6])	adds	src = -8, src
-	;;
-(p[7])	adds	src = -8, src
 	shl	tmp = tmp, 3
 	;;
-(p[8])	adds	src = -8, src
-	;;
-(p[9])	adds	src = -8, src
-	shr.u	sh2 = sh2, 3
-	;;
-(p[10])	adds	src = -8, src
-	;;
-(p[11])	adds	src = -8, src
 	add	len = len, loopcnt
-	;;
-	sub	src = src, sh2
-	;;
+	add	src = sh1, src ;;
 	add	len = tmp, len
-	add	src = sh1, src
+.back1:
 	br.cond.sptk .cpyfew
 
 .recovery2:
-#if MEMLAT != 6
-# error "MEMLAT must be 6!"
-#endif
-	add	tmp = -8, src
+	add	tmp = -(MEMLAT + 3) * 8, src
 (p7)	br.cond.spnt .gotit
 	;;
-(p[0])	add	tmp = -8, tmp ;;
-(p[1])	add	tmp = -8, tmp ;;
-(p[2])	add	tmp = -8, tmp ;;
-(p[3])	add	tmp = -8, tmp ;;
-(p[4])	add	tmp = -8, tmp ;;
-(p[5])	add	tmp = -8, tmp ;;
-(p[6])	add	tmp = -8, tmp ;;
-(p[7])	add	tmp = -8, tmp ;;
 	ld8	r[MEMLAT+2] = [tmp] ;;
 	xor	pos0[1] = r[MEMLAT+2], charx8 ;;
 	czx1.r	pos0[1] = pos0[1] ;;