]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
powerpc: refactor strrchr IFUNC
authorRajalakshmi Srinivasaraghavan <raji@linux.vnet.ibm.com>
Fri, 23 Jun 2017 05:54:30 +0000 (11:24 +0530)
committerRajalakshmi Srinivasaraghavan <raji@linux.vnet.ibm.com>
Fri, 23 Jun 2017 05:54:30 +0000 (11:24 +0530)
As done in commit 6d15a5c2e9450a1e926d5b4991759e1cfa50fccf
clean up IFUNC implementation for power8 in order to remove
unneeded macro definitions.

ChangeLog
sysdeps/powerpc/powerpc64/multiarch/strrchr-power8.S
sysdeps/powerpc/powerpc64/power8/strrchr.S

index ed0192b51f75e28ebb8817186915a034ed852f9a..e495f4cf5f58f6809faf4cadbf8179b21659c5f6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2017-06-23  Rajalakshmi Srinivasaraghavan  <raji@linux.vnet.ibm.com>
+
+       * sysdeps/powerpc/powerpc64/multiarch/strchr-power8.S(STRRCHR): Define
+       the implementation-specific function name and remove unneeded macros
+       definition.
+       * sysdeps/powerpc/powerpc64/power8/strrchr.S(STRRCHR): Set a default
+       function name if not defined and pass as parameter to macros
+       accordingly.
+
 2017-06-23  Rajalakshmi Srinivasaraghavan  <raji@linux.vnet.ibm.com>
 
        * sysdeps/powerpc/powerpc64/fpu/multiarch/Makefile
index 2b2b1de1488e84a16705ce8543927df25dcf20d0..63080f5ecb40903915391346b28b2ec3729f1f5d 100644 (file)
 
 #include <sysdep.h>
 
-#undef ENTRY_TOCLESS
-#ifndef PROF
-#define ENTRY_TOCLESS(name, ...)                               \
-       ENTRY_3 __strrchr_power8, ## __VA_ARGS__;               \
-       cfi_startproc
-#else
-#define ENTRY_TOCLESS(name, ...)                               \
-       ENTRY_3 __strrchr_power8, ## __VA_ARGS__;               \
-       cfi_startproc;                                          \
-       LOCALENTRY(__strrchr_power8)
-#endif
-
-#undef END
-#define END(name)                                              \
-  cfi_endproc;                                                 \
-  TRACEBACK(__strrchr_power8);                                 \
-  END_2(__strrchr_power8)
+#define STRRCHR __strrchr_power8
 
 #undef libc_hidden_builtin_def
 #define libc_hidden_builtin_def(name)
index 0ba61389a750ef06f71094d324429a5dd9b54b87..090eb96fa629f36c39880ad1aa03406b86788524 100644 (file)
 1: \
        vsumsws v2, v2, v0;
 #endif /* !__LITTLE_ENDIAN__  */
+
+#ifndef STRRCHR
+# define STRRCHR strrchr
+#endif
        .machine  power7
-ENTRY_TOCLESS (strrchr)
+ENTRY_TOCLESS (STRRCHR)
        CALL_MCOUNT 2
        dcbt    0,r3
        clrrdi  r8,r3,3       /* Align the address to doubleword boundary.  */
@@ -459,6 +463,6 @@ L(continue1):
 #endif
        add     r3, r3, r6      /* Compute final length.  */
        blr
-END (strrchr)
+END_GEN_TB (STRRCHR, TB_TOCLESS)
 weak_alias (strrchr, rindex)
 libc_hidden_builtin_def (strrchr)