Re: [PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-13 Thread Thomas Gleixner
On Sat, 13 Jan 2018, Tom Lendacky wrote: > On 1/13/2018 8:07 AM, Van De Ven, Arjan wrote: > >>> The RSB filling macro is applicable to AMD, and, if software is unable to > >>> verify that lfence is serializing on AMD (possible when running under a > >>> hypervisor), the generic retpoline support w

Re: [PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-13 Thread Tom Lendacky
On 1/13/2018 8:07 AM, Van De Ven, Arjan wrote: >>> The RSB filling macro is applicable to AMD, and, if software is unable to >>> verify that lfence is serializing on AMD (possible when running under a >>> hypervisor), the generic retpoline support will be used and, so, is also >>> applicable to AMD

RE: [PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-13 Thread Van De Ven, Arjan
> > The RSB filling macro is applicable to AMD, and, if software is unable to > > verify that lfence is serializing on AMD (possible when running under a > > hypervisor), the generic retpoline support will be used and, so, is also > > applicable to AMD.  Change the use of pause to lfence. > > > > S

Re: [PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-13 Thread Woodhouse, David
On Fri, 2018-01-12 at 19:07 -0600, Tom Lendacky wrote: > The pause instruction is currently used in the retpoline and RSB filling > macros as a speculation trap.  The use of pause was originally suggested > because it showed a very, very small difference in the amount of > cycles/time used to execu

Re: [PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-12 Thread Tom Lendacky
On 1/12/2018 7:53 PM, Dan Williams wrote: > On Fri, Jan 12, 2018 at 5:07 PM, Tom Lendacky wrote: >> The pause instruction is currently used in the retpoline and RSB filling >> macros as a speculation trap. The use of pause was originally suggested >> because it showed a very, very small differenc

Re: [PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-12 Thread Dan Williams
On Fri, Jan 12, 2018 at 5:07 PM, Tom Lendacky wrote: > The pause instruction is currently used in the retpoline and RSB filling > macros as a speculation trap. The use of pause was originally suggested > because it showed a very, very small difference in the amount of > cycles/time used to execut

[PATCH v1] x86/retpoline: Use lfence in the retpoline/RSB filling RSB macros

2018-01-12 Thread Tom Lendacky
The pause instruction is currently used in the retpoline and RSB filling macros as a speculation trap. The use of pause was originally suggested because it showed a very, very small difference in the amount of cycles/time used to execute the retpoline as compared to lfence. On AMD, the pause inst