From: "H. Peter Anvin" <hpa@zytor.com>
To: Andy Lutomirski <luto@amacapital.net>, Andi Kleen <andi@firstfloor.org>
Cc: X86 ML <x86@kernel.org>,
Linux Kernel <linux-kernel@vger.kernel.org>,
Borislav Petkov <bp@alien8.de>
Subject: Re: [PATCH] x86_64,entry: Fix RCX for traced syscalls
Date: Thu, 26 Jun 2014 13:12:35 -0700 [thread overview]
Message-ID: <7919ae8b-958b-4b12-a5f4-8be2c3df3824@email.android.com> (raw)
In-Reply-To: <CALCETrWJD4kvoCxxb9y19uMakChmxamveKDceDOhyjYzFkJoUA@mail.gmail.com>
The real question is if we care that sysret and iter don't match. On 32 bits the situation is even more complex.
On June 26, 2014 1:00:22 PM PDT, Andy Lutomirski <luto@amacapital.net> wrote:
>On Thu, Jun 26, 2014 at 12:59 PM, Andy Lutomirski <luto@amacapital.net>
>wrote:
>> On Thu, Jun 26, 2014 at 12:56 PM, Andi Kleen <andi@firstfloor.org>
>wrote:
>>>> show RCX == RIP even under strace.
>>>
>>> If you think it's really worth the extra instruction?
>>
>> Hard to say. That extra instruction only happens on slow paths, so I
>> suspect the slowdown is negligible. On the other hand, having
>syscall
>> show a blatant difference in behavior between traced and untraced
>> processes seems unfortunate.
>>
>>>
>>> It's not wrong, but it's not clear if it's useful.
>
>Also, if anyone ever wants to add some code to switch back from iret
>to sysret when sysret will work, this is a prerequisite. Otherwise
>sysret will never match iret. (I'm not immediately planning on doing
>this, but I can imagine workloads (e.g. UML) for which it would be a
>big improvement.)
>
>--Andy
--
Sent from my mobile phone. Please pardon brevity and lack of formatting.
next prev parent reply other threads:[~2014-06-26 20:13 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-26 19:08 Andy Lutomirski
2014-06-26 19:56 ` Andi Kleen
2014-06-26 19:59 ` Andy Lutomirski
2014-06-26 20:00 ` Andy Lutomirski
2014-06-26 20:12 ` H. Peter Anvin [this message]
2014-06-26 20:47 ` Andy Lutomirski
2014-06-28 17:07 ` Pavel Machek
2014-06-30 15:12 ` Andy Lutomirski
2014-11-04 23:43 ` Andy Lutomirski
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=7919ae8b-958b-4b12-a5f4-8be2c3df3824@email.android.com \
--to=hpa@zytor.com \
--cc=andi@firstfloor.org \
--cc=bp@alien8.de \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@amacapital.net \
--cc=x86@kernel.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
all inboxes | Powered by JetHome®