This is the mail archive of the mailing list for the glibc project.

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

RE: [Patch, MIPS] Modify memset.S for mips32r6/mips64r6

On Sat, 2014-12-20 at 00:23 +0000, Joseph Myers wrote:

> Please put this in a central place (a single header that defines 
> __mips_isa_rev to 0 if not already defined, for example) rather than 
> duplicating "defined" tests in different places ("defined" tests are 
> typo-prone and so discouraged in glibc).

Would sysdeps/unix/mips/sysdep.h be an appropriate place to define
__mips_isa_rev?  That header is already used by memcpy and memset.
I thought about using asm.h but that header is visible to users and
defining it there would be a visible change that could affect user
programs.  sysdep.h is internal to glibc and so does not have that

If we add it here there would be no changes needed to memcpy.S or
memset.S, though Ondrej had some useful performance comments I would
like to look at later (once we have the basic functionality checked in).

Steve Ellcey

2014-12-22  Steve Ellcey  <>

	* sysdeps/unix/mips/sysdep.h (__mips_isa_rev): Set
	to zero if not already defined.

diff --git a/sysdeps/unix/mips/sysdep.h b/sysdeps/unix/mips/sysdep.h
index d59fac0..dc70c0f 100644
--- a/sysdeps/unix/mips/sysdep.h
+++ b/sysdeps/unix/mips/sysdep.h
@@ -78,4 +78,8 @@
 # define L(label) .L ## label
+#ifndef __mips_isa_rev
+# define __mips_isa_rev 0

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