This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Save and restore xmm0-xmm7 in _dl_runtime_resolve
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- Cc: OndÅej BÃlka <neleai at seznam dot cz>, "libc-alpha at sourceware dot org" <libc-alpha at sourceware dot org>
- Date: Sun, 12 Jul 2015 14:50:19 -0700
- Subject: Re: [PATCH] Save and restore xmm0-xmm7 in _dl_runtime_resolve
- Authentication-results: sourceware.org; auth=none
- References: <0EFAB2BDD0F67E4FB6CCC8B9F87D75696A921FC8 at IRSMSX101 dot ger dot corp dot intel dot com> <CAMe9rOoUr1fjCHDsd+kbiFZ5KL_HoDB_GG65epxqpX7AcocvZw at mail dot gmail dot com> <0EFAB2BDD0F67E4FB6CCC8B9F87D75696A9220AE at IRSMSX101 dot ger dot corp dot intel dot com> <CAMe9rOo81zoKpt+QmmVYjfjV2=KwLkYiqeADv3kMyeouM+9uug at mail dot gmail dot com> <0EFAB2BDD0F67E4FB6CCC8B9F87D75696A9235F6 at IRSMSX101 dot ger dot corp dot intel dot com> <CAMe9rOoXLPUr_LUexoRKjrCdNhP0J8EMY+1XNAaLnpW1qknb7w at mail dot gmail dot com> <20150709142827 dot GA18030 at domone> <CAMe9rOoXCwiPdQVP7_tV7599f6y9w_n1P+SXsE7urb69f3v7gA at mail dot gmail dot com> <20150711104654 dot GA26570 at domone> <20150711202742 dot GA9074 at gmail dot com> <20150711235002 dot GA7543 at gmail dot com>
On Sat, Jul 11, 2015 at 4:50 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
> On Sat, Jul 11, 2015 at 01:27:42PM -0700, H.J. Lu wrote:
>> On Sat, Jul 11, 2015 at 12:46:54PM +0200, OndÅej BÃlka wrote:
>> > On Thu, Jul 09, 2015 at 09:07:24AM -0700, H.J. Lu wrote:
>> > > On Thu, Jul 9, 2015 at 7:28 AM, OndÅej BÃlka <neleai@seznam.cz> wrote:
>> > > > On Thu, Jul 09, 2015 at 07:12:24AM -0700, H.J. Lu wrote:
>> > > >> On Thu, Jul 9, 2015 at 6:37 AM, Zamyatin, Igor <igor.zamyatin@intel.com> wrote:
>> > > >> >> On Wed, Jul 8, 2015 at 8:56 AM, Zamyatin, Igor <igor.zamyatin@intel.com>
>> > > >> >> wrote:
>> > > >> >> > Fixed in the attached patch
>> > > >> >> >
>> > > >> >>
>> > > >> >> I fixed some typos and updated sysdeps/i386/configure for
>> > > >> >> HAVE_MPX_SUPPORT. Please verify both with HAVE_MPX_SUPPORT and
>> > > >> >> without on i386 and x86-64.
>> > > >> >
>> > > >> > Done, all works fine
>> > > >> >
>> > > >>
>> > > >> I checked it in for you.
>> > > >>
>> > > > These are nice but you could have same problem with lazy tls allocation.
>> > > > I wrote patch to merge trampolines, which now conflicts. Could you write
>> > > > similar patch to solve that? Original purpose was to always save xmm
>> > > > registers so we could use sse2 routines which speeds up lookup time.
>> > >
>> > > So we will preserve only xmm0 to xmm7 in _dl_runtime_resolve? How
>> > > much gain it will give us?
>> > >
>> > I couldn't measure that without patch. Gain now would be big as we now
>> > use byte-by-byte loop to check symbol name which is slow, especially
>> > with c++ name mangling. Would be following benchmark good to measure
>> > speedup or do I need to measure startup time which is bit harder?
>> >
>>
>> Please try this.
>>
>
> We have to use movups instead of movaps due to
>
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58066
>
It won't work since stack may be misaligned when SSE2 functions
are called. Please try glibc hjl/pr18661 branch, where I fixed a few
stack misalignment bugs in x86-64 assembly code and save/restore
xmm0-xmm7, with GCC hjl/pr58066/gcc-5-branch
--
H.J.
- References:
- RE: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- RE: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- RE: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- Re: [PATCH, MPX] MPX-specific changes in dl_runtime routines
- [PATCH] Save and restore xmm0-xmm7 in _dl_runtime_resolve