Originally posted by hotaru
View Post
Announcement
Collapse
No announcement yet.
Disabling Spectre V2 Mitigations Is What Can Impair AMD Ryzen 7000 Series Performance
Collapse
X
-
-
Originally posted by F.Ultra View PostThe big question is that Windows really uses, they seem to have been used both retpolines and IBRS, but if they used IBRS already in 2018 then they must have taken a huge performance hit on the CPU:s without eIBRS, did no one cry over that or was/is it not enabled by default on all systems?
edit: ok so to make things more complex it looks like Microsoft went the same route as Linux in 2019 in that they replaced IBRS with retpolines in build 1809 of Windows 10. So I wonder if anyone have actually tried to run retbleed on Windows or if it's only assumed that it isn't vulnerable (on CPU:s without eIBRS).
Originally posted by MicrosoftSince Retpoline is a performance optimization for Spectre Variant 2, it requires that hardware and OS support for branch target injection to be present and enabled. Skylake and later generations of Intel processors are not compatible with Retpoline, so only Import Optimization will be enabled on these processors.Originally posted by MicrosoftRetpoline is not applicable to Skylake and later processors from Intel.
Leave a comment:
-
Originally posted by ll1025 View PostLinus rejected it, in part for performance reasons
Although I also think that this shouldn't be of concern for the kernel devs. Just supply the most secure code possible and give people the chance to opt out.
Leave a comment:
-
Originally posted by ll1025 View Post
But the mitigation that defeats it-- IBRS-- was recommended by Intel in 2018 to both Microsoft and Linux, and patchsets were proposed. Torvalds rejected them partly because of performance. Microsoft implemented them, which is why Retbleed did not affect Windows (noted by Intel, among others).
I've provided links elsewhere in this thread, but googling the following should get you some sources:- Windows IBRS retbleed
- Linux IBRS 2018 Torvalds
The big question is that Windows really uses, they seem to have been used both retpolines and IBRS, but if they used IBRS already in 2018 then they must have taken a huge performance hit on the CPU:s without eIBRS, did no one cry over that or was/is it not enabled by default on all systems?
edit: ok so to make things more complex it looks like Microsoft went the same route as Linux in 2019 in that they replaced IBRS with retpolines in build 1809 of Windows 10. So I wonder if anyone have actually tried to run retbleed on Windows or if it's only assumed that it isn't vulnerable (on CPU:s without eIBRS).Last edited by F.Ultra; 07 October 2022, 05:14 PM.
- Likes 2
Leave a comment:
-
My response with sources is en-route but requires approval because it has all of the sources.
I literally got them by googling the above phrases, checking the bleepingcomputer article and its link to the intel advisory, the lkml response by Torvalds, and Microsoft's own write-up on Spectre v2 Mitigations.
But since you want me to deliver them, you get to wait until my post is approved.
Last edited by ll1025; 07 October 2022, 09:32 AM.
- Likes 1
Leave a comment:
-
Oh good grief, talk about lazy.
Originally posted by Anux View PostYou said that multiple times but faild to prove it anywhere.
...
The only thing I found so far is Linus ranting about intel not fixing their CPU's and let the kernel dev's fix intels errors.
But since we already know that the IBRS overhead is <i>huge</i> on
existing hardware, all those hardware capability bits are just
complete and utter garbage. Nobody sane will use them, since the cost
is too damn high.
Originally posted by LITERALLY MICROSOFTOur original mitigations for Spectre variant 2 made use of new capabilities exposed by CPU microcode updates to restrict indirect branch speculation when executing within kernel mode (IBRS and IBPB).
Originally posted by LITERALLY INTELWindows operating system uses IBRS by default, so no update is required.Last edited by ll1025; 07 October 2022, 12:13 PM.
Leave a comment:
-
Originally posted by ll1025 View PostTorvalds rejected them partly because of performance.
I've provided links elsewhere in this thread
- Windows IBRS retbleed
- Linux IBRS 2018 Torvalds
And I'm totaly with this argument.
- Likes 2
Leave a comment:
-
Originally posted by Developer12 View Post
Do you know and understand the ways spectre v2 is mitigated? I said *IBPB* which is distinct from both IBRS and retpoline. AMD chips don't even possess IBRS.
Leave a comment:
-
Originally posted by F.Ultra View Post
Retbleed was first announced in 2022, did you mean some other patches? The only ones I can recall having criticism from Linus was the one from Amazon for the snoop vulnerability and that was criticism, he didn't reject it.
I've provided links elsewhere in this thread, but googling the following should get you some sources:- Windows IBRS retbleed
- Linux IBRS 2018 Torvalds
Leave a comment:
-
Originally posted by Developer12 View Post
Do you know and understand the ways spectre v2 is mitigated? I said *IBPB* which is distinct from both IBRS and retpoline. AMD chips don't even possess IBRS.
*IBPB* is issued during context switches to prevent past branches from affecting future predictions. That's it's entire purpose. [1]
In this test IBPB was enabled during the "mitigations enabled" scenario, though selectively applied, and completely disabled during the no-mitigations run.
[1] This is particularly important on windows, because they can't just recompile the world to use repolines on AMD hardware. People always use old versions of software and issuing IBPB on every context switch protects *all* applications regardless of whether they've been recompiled.
IBPB is used to protect from the scheduling issue as you write, but are there enough such cases in benchmarks of single processes at a time to create this type of overhead? Unsure if IBPB can be disabled while keeping the repolines/IBRS but if that is the case then it would be interesting to see a run of that to figure this out, because if AMD doesn't do a real barrier with IBPB then things can get real ugly here and it would be a strange path of them to take.
edit: I also fail to see how this would benefit them in mitigations=on vs off since this is benchmark runs, aka the entire machine only runs a single application so there would be no benefit from "oh this is a new application so lets do retraining" since it's the same application and also retraining from scratch is what every cpu have to do after IBPB anyway so I still fail to see how this could explain it.Last edited by F.Ultra; 05 October 2022, 08:44 PM.
- Likes 3
Leave a comment:
Leave a comment: