summaryrefslogtreecommitdiff
path: root/sysdeps/i386/i586/strcpy.S
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/i386/i586/strcpy.S')
-rw-r--r--sysdeps/i386/i586/strcpy.S22
1 files changed, 7 insertions, 15 deletions
diff --git a/sysdeps/i386/i586/strcpy.S b/sysdeps/i386/i586/strcpy.S
index 50fc521dd2..b061491532 100644
--- a/sysdeps/i386/i586/strcpy.S
+++ b/sysdeps/i386/i586/strcpy.S
@@ -1,5 +1,5 @@
/* strcpy/stpcpy implementation for i586.
- Copyright (C) 1997, 2000, 2003, 2005 Free Software Foundation, Inc.
+ Copyright (C) 1997-2014 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
@@ -19,13 +19,11 @@
#include <sysdep.h>
#include "asm-syntax.h"
-#include "bp-sym.h"
-#include "bp-asm.h"
-#define PARMS LINKAGE+12 /* space for 3 saved regs */
+#define PARMS 4+12 /* space for 3 saved regs */
#define RTN PARMS
-#define DEST RTN+RTN_SIZE
-#define SRC DEST+PTR_SIZE
+#define DEST RTN
+#define SRC DEST+4
#ifndef USE_AS_STPCPY
# define STRCPY strcpy
@@ -34,8 +32,7 @@
#define magic 0xfefefeff
.text
-ENTRY (BP_SYM (STRCPY))
- ENTER
+ENTRY (STRCPY)
pushl %edi
cfi_adjust_cfa_offset (4)
@@ -48,8 +45,6 @@ ENTRY (BP_SYM (STRCPY))
cfi_rel_offset (edi, 8)
movl SRC(%esp), %esi
cfi_rel_offset (esi, 4)
- CHECK_BOUNDS_LOW (%edi, DEST(%esp))
- CHECK_BOUNDS_LOW (%esi, SRC(%esp))
xorl %eax, %eax
leal -1(%esi), %ecx
@@ -152,13 +147,11 @@ L(4): movb %dl, (%edi)
L(end): movb %ah, (%edi)
L(end2):
- /* GKM FIXME: check high bounds */
#ifdef USE_AS_STPCPY
movl %edi, %eax
#else
movl DEST(%esp), %eax
#endif
- RETURN_BOUNDED_POINTER (DEST(%esp))
popl %ebx
cfi_adjust_cfa_offset (-4)
cfi_restore (ebx)
@@ -169,9 +162,8 @@ L(end2):
cfi_adjust_cfa_offset (-4)
cfi_restore (edi)
- LEAVE
- RET_PTR
-END (BP_SYM (STRCPY))
+ ret
+END (STRCPY)
#ifndef USE_AS_STPCPY
libc_hidden_builtin_def (strcpy)
#endif