This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] powerpc: Fix PPC64/POWER7 conform tests
- From: Steven Munroe <munroesj at linux dot vnet dot ibm dot com>
- To: Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- Cc: GNU C Library <libc-alpha at sourceware dot org>, Tulio Magno Quites Machado Filho <tuliom at linux dot vnet dot ibm dot com>
- Date: Wed, 05 Aug 2015 13:19:04 -0500
- Subject: Re: [PATCH] powerpc: Fix PPC64/POWER7 conform tests
- Authentication-results: sourceware.org; auth=none
- References: <55BB88D6 dot 4080601 at linaro dot org>
- Reply-to: munroesj at linux dot vnet dot ibm dot com
On Fri, 2015-07-31 at 11:40 -0300, Adhemerval Zanella wrote:
> When building with --disable-multi-arch the memmove and strstr POWER7
> optimization create and uses symbols that conflict with expect conform
> tests.
>
> Checked on powerpc64.
>
> --
>
> * sysdeps/powerpc/powerpc64/power7/memmove.S (bcopy): Changing to
> __bcopy and add a weak_alias to bcopy.
> * sysdeps/powerpc/powerpc64/power7/strstr.S (strstr): Use __strnlen
> for static build.
>
> --
>
> diff --git a/sysdeps/powerpc/powerpc64/power7/memmove.S b/sysdeps/powerpc/powerpc64/power7/memmove.S
> index 3bd4b4b..43f0a48 100644
> --- a/sysdeps/powerpc/powerpc64/power7/memmove.S
> +++ b/sysdeps/powerpc/powerpc64/power7/memmove.S
> @@ -823,9 +823,10 @@ libc_hidden_builtin_def (memmove)
> /* void bcopy(const void *src [r3], void *dest [r4], size_t n [r5])
> Implemented in this file to avoid linker create a stub function call
> in the branch to '_memmove'. */
> -ENTRY (bcopy)
> +ENTRY (__bcopy)
> mr r6,r3
> mr r3,r4
> mr r4,r6
> b L(_memmove)
> -END (bcopy)
> +END (__bcopy)
> +weak_alias (__bcopy, bcopy)
> diff --git a/sysdeps/powerpc/powerpc64/power7/strstr.S b/sysdeps/powerpc/powerpc64/power7/strstr.S
> index 8dca31c..bfb0c49 100644
> --- a/sysdeps/powerpc/powerpc64/power7/strstr.S
> +++ b/sysdeps/powerpc/powerpc64/power7/strstr.S
> @@ -39,7 +39,7 @@
> # ifdef SHARED
> # define STRNLEN __GI_strnlen
> # else
> -# define STRNLEN strnlen
> +# define STRNLEN __strnlen
> # endif
> #endif
>
Ok