From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Ingo Molnar <mingo@kernel.org>
Cc: "H. Peter Anvin" <hpa@zytor.com>,
Peter Zijlstra <peterz@infradead.org>,
Rik van Riel <riel@surriel.com>,
Linus Torvalds <torvalds@linux-foundation.org>,
Andy Lutomirski <luto@kernel.org>,
Brian Gerst <brgerst@gmail.com>, Juergen Gross <jgross@suse.com>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
x86@kernel.org, linux-tip-commits@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [tip: x86/mm] x86/idle: Remove mb() barriers for X86_BUG_CLFLUSH_MONITOR in mwait_idle_with_hints()
Date: Wed, 2 Apr 2025 11:17:42 +0100 [thread overview]
Message-ID: <8f2a6d7a-cdd4-4742-9977-0bc1c1e872e6@citrix.com> (raw)
In-Reply-To: <174358864842.14745.908324129810950623.tip-bot2@tip-bot2>
On 02/04/2025 11:10 am, tip-bot2 for Andrew Cooper wrote:
> The following commit has been merged into the x86/mm branch of tip:
>
> Commit-ID: 90a22a5f841490790ecb17166633582681d44945
> Gitweb: https://git.kernel.org/tip/90a22a5f841490790ecb17166633582681d44945
> Author: Andrew Cooper <andrew.cooper3@citrix.com>
> AuthorDate: Wed, 02 Apr 2025 10:10:17 +01:00
> Committer: Ingo Molnar <mingo@kernel.org>
> CommitterDate: Wed, 02 Apr 2025 11:54:51 +02:00
>
> x86/idle: Remove mb() barriers for X86_BUG_CLFLUSH_MONITOR in mwait_idle_with_hints()
>
> The following commit, 12 years ago:
>
> 7e98b7192046 ("x86, idle: Use static_cpu_has() for CLFLUSH workaround, add barriers")
>
> added barriers around the CLFLUSH in mwait_idle_with_hints(), justified with:
>
> ... and add memory barriers around it since the documentation is explicit
> that CLFLUSH is only ordered with respect to MFENCE.
>
> The SDM currently states:
>
> Executions of the CLFLUSH instruction are ordered with respect to each
> other and with respect to writes, locked read-modify-write instructions,
> and fence instructions.
>
> https://web.archive.org/web/20090219054841/http://download.intel.com/design/xeon/specupdt/32033601.pdf
This link isn't the SDM. Its ...
>
> With footnote 1 reading:
>
> Earlier versions of this manual specified that executions of the CLFLUSH
> instruction were ordered only by the MFENCE instruction. All processors
> implementing the CLFLUSH instruction also order it relative to the other
> operations enumerated above.
>
> I.e. The SDM was incorrect at the time, and barriers should not have been
> inserted. Double checking the original AAI65 errata (not available from
> intel.com any more) shows no mention of barriers either.
... this errata link, no longer hosted on intel.com.
~Andrew
next prev parent reply other threads:[~2025-04-02 10:17 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-02 9:10 x86/idle: Remove barriers for X86_BUG_CLFLUSH_MONITOR Andrew Cooper
2025-04-02 9:53 ` Borislav Petkov
2025-04-02 10:10 ` [tip: x86/mm] x86/idle: Remove mb() barriers for X86_BUG_CLFLUSH_MONITOR in mwait_idle_with_hints() tip-bot2 for Andrew Cooper
2025-04-02 10:17 ` Andrew Cooper [this message]
2025-04-02 14:01 ` x86/idle: Remove barriers for X86_BUG_CLFLUSH_MONITOR Dave Hansen
2025-04-02 14:04 ` Andrew Cooper
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=8f2a6d7a-cdd4-4742-9977-0bc1c1e872e6@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=brgerst@gmail.com \
--cc=hpa@zytor.com \
--cc=jgross@suse.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=luto@kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=rafael.j.wysocki@intel.com \
--cc=riel@surriel.com \
--cc=torvalds@linux-foundation.org \
--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®