lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d1c78779-b885-8e3e-a87a-a586b18423fc@redhat.com>
Date:	Wed, 17 Aug 2016 21:26:54 +0200
From:	Denys Vlasenko <dvlasenk@...hat.com>
To:	Andy Lutomirski <luto@...capital.net>,
	Linus Torvalds <torvalds@...ux-foundation.org>
Cc:	Sara Sharon <sara.sharon@...el.com>,
	Dan Williams <dan.j.williams@...el.com>,
	Christian König <christian.koenig@....com>,
	Vinod Koul <vinod.koul@...el.com>,
	Alex Deucher <alexander.deucher@....com>,
	Johannes Berg <johannes.berg@...el.com>,
	"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
	Andy Lutomirski <luto@...nel.org>,
	the arch/x86 maintainers <x86@...nel.org>,
	Ingo Molnar <mingo@...nel.org>,
	LKML <linux-kernel@...r.kernel.org>,
	Adrian Hunter <adrian.hunter@...el.com>
Subject: Re: RFC: Petition Intel/AMD to add POPF_IF insn

On 08/17/2016 09:13 PM, Andy Lutomirski wrote:
> On Wed, Aug 17, 2016 at 12:01 PM, Linus Torvalds
> <torvalds@...ux-foundation.org> wrote:
>> On Aug 17, 2016 11:41 AM, "Denys Vlasenko" <dvlasenk@...hat.com> wrote:
>>>
>>> OTOH 5 years will inevitably pass.
>>
>> Yes. But in five years, maybe we'll have a popf that is faster anyway.
>>
>> I'd actually prefer that in the end. The problem with popf right now seems
>> to be mainly that it's effectively serializing and does stupid things in
>> microcode. It doesn't have to be that way. It could actually do much better,
>> but it hasn't been a high enough priority for Intel.
>>
>
> It wouldn't surprise me if that were easier said than done.  popf
> potentially changes AC, and AC affects address translation.  popf also
> potentially changes IOPL, and I don't know whether Intel chips track
> IOPL in a way that lets them find all the dependent instructions
> without serializing.  But maybe their pipeline is fancy enough.

Exactly. And more:

POPF potentially changes TF (and it works even in CPL3).
POPD changes DF - must serialize versus string insns.
POPF changes NT - must serialize versus IRET insns.
POPF changes VIF, from a different bit in a popped value,
and under a rather complex conditions.

Intel's documentation has a pseudo-code for the instructions.
For POPF, that pseudo-code is two pages long...

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ