From: Florian Weimer <fweimer@redhat.com>
To: "H.J. Lu" <hjl.tools@gmail.com>
Cc: GNU C Library <libc-alpha@sourceware.org>,
Jakub Jelinek <jakub@redhat.com>
Subject: Re: [PATCH 0/2] Remove some i386 system call optimizations
Date: Tue, 11 Jan 2022 23:52:39 +0100 [thread overview]
Message-ID: <87bl0hriko.fsf@oldenburg.str.redhat.com> (raw)
In-Reply-To: <CAMe9rOowcGPjbSK5KUXDMJyu7Em=gEyujV4kwhEHnffPVMGkHQ@mail.gmail.com> (H. J. Lu's message of "Tue, 11 Jan 2022 14:20:29 -0800")
* H. J. Lu:
>> > There are
>> >
>> > /* Since GCC 5 and above can properly spill %ebx with PIC when needed,
>> > we can inline syscalls with 6 arguments if GCC 5 or above is used
>> > to compile glibc. Disable GCC 5 optimization when compiling for
>> > profiling or when -fno-omit-frame-pointer is used since asm ("ebp")
>> > can't be used to put the 6th argument in %ebp for syscall. */
>> > #if !defined PROF && CAN_USE_REGISTER_ASM_EBP
>> > # define OPTIMIZE_FOR_GCC_5
>> > #endif
>> >
>> > If we want to support profiling or -fno-omit-frame-pointer,
>> > we need to keep these codes.
>>
>> This is strictly for %ebp, I think, as indicated by the comment. %ebx
>> does not need to be special-cased for profiling.
>>
>> I assume that building glibc (with profiling) is proof enough that this
>> works?
>
> You need to test glibc build with -fno-omit-frame-pointer.
I tried it, it works (with both patches applied).
-fno-omit-frame-pointer is about %ebp, not %ebx.
Thanks,
Florian
next prev parent reply other threads:[~2022-01-11 22:52 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-11 10:05 Florian Weimer
2022-01-11 10:06 ` [PATCH 1/2] i386: Always treat %ebx as an allocatable register Florian Weimer
2022-01-11 10:06 ` [PATCH 2/2] i386: Always use __libc_do_syscall for 6-argument syscalls (bug 27997) Florian Weimer
2022-01-11 14:00 ` [PATCH 0/2] Remove some i386 system call optimizations H.J. Lu
2022-01-11 20:30 ` H.J. Lu
2022-01-11 20:37 ` Florian Weimer
2022-01-11 22:20 ` H.J. Lu
2022-01-11 22:52 ` Florian Weimer [this message]
2022-01-12 18:49 ` H.J. Lu
2022-01-12 19:37 ` Florian Weimer
2022-01-12 19:56 ` H.J. Lu
2022-01-12 20:12 ` Florian Weimer
2022-01-12 21:59 ` H.J. Lu
2022-01-12 22:33 ` Florian Weimer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bl0hriko.fsf@oldenburg.str.redhat.com \
--to=fweimer@redhat.com \
--cc=hjl.tools@gmail.com \
--cc=jakub@redhat.com \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).