This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 3/3] sparc: M7 optimized memcpy/mempcpy/memmove/memset/bzero.
- From: Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- To: Joseph Myers <joseph at codesourcery dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Wed, 4 Oct 2017 16:53:20 -0300
- Subject: Re: [PATCH 3/3] sparc: M7 optimized memcpy/mempcpy/memmove/memset/bzero.
- Authentication-results: sourceware.org; auth=none
- References: <1506542999-97895-1-git-send-email-patrick.mcgehearty@oracle.com> <1506542999-97895-2-git-send-email-patrick.mcgehearty@oracle.com> <1506542999-97895-3-git-send-email-patrick.mcgehearty@oracle.com> <1506542999-97895-4-git-send-email-patrick.mcgehearty@oracle.com> <125b565d-1c04-c532-e7f7-8a95ba97702c@linaro.org> <4f2d87d6-05ca-bef5-3f01-7a97ce19ea16@oracle.com> <f697dbbb-18bb-8d9b-ace4-e733218ea70e@linaro.org> <alpine.DEB.2.20.1710032048430.8372@digraph.polyomino.org.uk>
On 03/10/2017 17:49, Joseph Myers wrote:
> On Tue, 3 Oct 2017, Adhemerval Zanella wrote:
>
>> SPARC is the only one still using ifunc resolvers coded in assembly and
>> currently there is no gain in continuing doing so. You can rebase your next
>
> ARM resolvers are in assembly, and changing them to C would break the
> build with GCC mainline as the ifunc attribute is not enabled by default
> there for ARM.
>
It is possible to implement the ARM resolvers in C and built it with GCC
mainline with two adjustments along with default _ifunc macro:
1. Add the assembly directives for libc_hidden_builtin_def (memcpy)
using asm as:
asm (".globl __GI_memcpy;"
".hidden __GI_memcpy;"
"__GI_memcpy = memcpy");
2. Circle around which I think it is a GCC bug which it is placing the
very asm statements from 1. before memcpy resolvers definition
and thus conflicting with the symbol-hacks.h. I had to disable
the asm alias from symbol-hacks.h with an extra preprocessor.
I am checking on both arm-linux-gnueabihf and arm-linux-gnueabi and I
will prepare a patch.