This is the mail archive of the libc-hacker@sourceware.org mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Fix x86_64 copysign{,f}


Hi!

These two functions were emitted into .rodata section rather than .text,
furthermore signmask didn't have .size and othermask .type.

2006-11-16  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/x86_64/fpu/s_copysignf.S (__copysignf): Switch to .text.
	* sysdeps/x86_64/fpu/s_copysign.S (__copysign): Likewise.
	(signmask): Add .size directive.
	(othermask): Add .type directive.

--- libc/sysdeps/x86_64/fpu/s_copysignf.S.jj	2004-02-09 21:46:36.000000000 +0100
+++ libc/sysdeps/x86_64/fpu/s_copysignf.S	2006-11-16 18:27:17.000000000 +0100
@@ -1,5 +1,5 @@
 /* copy sign, double version.
-   Copyright (C) 2002 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2006 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Andreas Jaeger <aj@suse.de>, 2002.
 
@@ -38,6 +38,7 @@ mask:
 #define MO(op) op
 #endif
 
+	.text
 ENTRY(__copysignf)
 	movss	MO(mask),%xmm3
 	andps	%xmm3,%xmm0
--- libc/sysdeps/x86_64/fpu/s_copysign.S.jj	2006-11-16 18:11:16.000000000 +0100
+++ libc/sysdeps/x86_64/fpu/s_copysign.S	2006-11-16 18:27:49.000000000 +0100
@@ -1,5 +1,5 @@
 /* copy sign, double version.
-   Copyright (C) 2002 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2006 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Andreas Jaeger <aj@suse.de>, 2002.
 
@@ -31,6 +31,8 @@
 signmask:
 	.byte 0, 0, 0, 0, 0, 0, 0, 0x80
 	.byte 0, 0, 0, 0, 0, 0, 0, 0
+	ASM_SIZE_DIRECTIVE(signmask)
+	ASM_TYPE_DIRECTIVE(othermask,@object)
 othermask:
 	.byte 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f
 	.byte 0, 0, 0, 0, 0, 0, 0, 0
@@ -42,6 +44,7 @@ othermask:
 #define MO(op) op
 #endif
 
+	.text
 ENTRY(__copysign)
 	andpd MO(othermask),%xmm0
 	andpd MO(signmask),%xmm1

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]