https://www.phoronix.com/review/amd-zen4-spectrev2 Phoronix * Articles & Reviews * News Archive * Forums * Premium * Categories * Computers * Display Drivers * Graphics Cards * Linux Gaming * Memory * Motherboards * Processors * Software * Storage * Operating Systems * Peripherals * Close * * Articles & Reviews * News Archive * Forums * Premium * Contact * Categories Computers Display Drivers Graphics Cards Linux Gaming Memory Motherboards Processors Software Storage Operating Systems Peripherals * [ ] [Search] Disabling Spectre V2 Mitigations Is What Can Impair AMD Ryzen 7000 Series Performance Written by Michael Larabel in Software on 3 October 2022. Page 1 of 4 . 44 Comments Last week I shared some initial numbers how surprisingly when disabling Zen 4 CPU security mitigations can actually *hurt* the Ryzen 7000 series CPU performance. While conventional wisdom and with past Intel/AMD processors yield better performance when disabling the CPU security mitigations, with the Ryzen 9 7950X it was found to be basically the opposite. I have since conducted more tests and using an AMD Ryzen 5 7600X to confirm the earlier results and dig deeper into the data. [image] The data shared last week showed that for most tests, it was actually faster keeping the AMD Ryzen 9 7950X in its default and secure mitigated state with still having some software controls pertaining to Spectre V1/V2/V4. That's the out-of-the-box Linux state for the Ryzen 7000 "Zen 4" processors where booting the kernel with "mitigations=off" was actually leading to worse performance - the opposite compared to what we've seen out of earlier x86_64 processors. [image] Using an AMD Ryzen 5 7600X along with some other slight hardware/ software differences and mostly the same benchmarks, I repeated the testing just to confirm last week's finding. And sure, enough, the Ryzen 5 7600X was clearly performing better with the default mitigations than in the mitigations=off state. Here is the side-by-side on the Ryzen 5 7600X with the defaults versus mitigations=off on Linux 6.0: For the vast majority of the benchmarks, keeping to the default state was faster than mitigations=off. Disabling the mitigations did help in a small subset of tests, mostly the various synthetic kernel benchmarks. OpenJDK Java workloads, database workloads, web browser tests, and many other workloads normally negatively impacted by the Spectre mitigations were actually running better on this Ryzen 5 7600X system than when disabling the mitigations. As a reminder, Zen 4 is not affected by most of the known CPU security vulnerabilities. What is still relevant from a software perspective based on the CPU MSRs and applied with Linux 6.0 is Speculative Store Bypass disabled via prctl for the SSBD / Spectre V4 mitigation and Spectre V1 mitigations of usercopy/SWAPGS barriers and __user pointer sanitization. Then for Spectre V2 there are Retpolines, conditional Indirect Branch Predictor Barriers (IBPB), IBRS firmware, always-on Single Threaded Indirect Branch Predictors (STIBP), and Return Stack Buffer (RSB) filling. So to dig deeper and being curious, I was trying out some of the more targeting kernel options for these mitigations to see what in particular is causing Zen 4 to run slower when disabled. 44 Comments - Next Page Tweet [Page 1 - Introduction ] Page: 1 2 3 4 Next Page Related Articles AMD Rembrandt CPUFreq vs. AMD P-State Linux Testing Blender 3.3 AMD Radeon HIP vs. NVIDIA CUDA/OptiX Performance Following Retbleed, The Combined CPU Security Mitigation Impact For AMD Zen 2 / Ryzen 9 3950X GCC vs. LLVM Clang Compilers For The Apple M2 On Linux Linux 6.0 Supporting New Intel/AMD Hardware, Performance Improvements & Much More AMD Ryzen 7 PRO 6850U: ACPI Platform Profile Low-Power vs. Balanced vs. Performance Latest Linux News KDE Plasma 5.27 Planning To Be The Last Plasma 5 Feature Release WineConf 2022 Talked Up Vulkan, PE Conversion Progress, Wine 8.0 Early Next Year Linux 6.1 To Better Handle "Cheap Clone" Nintendo Controller Knockoffs Open-Source VIA Linux Driver Still Wants To Be Merged, But Pursuing Acceleration First KDE Welcomes Ghostwriter To Its Collection Of Apps systemd 252-rc1 Introduces New systemd-measure Tool, Other New Features Fwupd 1.8.6 Released With Smaller Package Size, New Hardware Support Intel Preps The Linux Kernel For LKGS - Part Of FRED Rusticl Can Run Atop Zink Gallium3D Atop Intel's ANV Vulkan Driver Linux 6.1 Will Likely Be This Year's LTS Kernel Release Show Your Support, Go Premium Phoronix Premium allows ad-free access to the site, multi-page articles on a single page, and other features while supporting this site's continued operations. Latest Featured Articles AMD Ryzen 5 7600X Linux Performance AMD Cloud Platform Makes It Easy To Try Out AMD's Latest CPUs, Accelerators & ROCm Software Intel Arc Graphics A750 + A770 Linux Gaming Performance Disabling Spectre V2 Mitigations Is What Can Impair AMD Ryzen 7000 Series Performance AMD Rembrandt CPUFreq vs. AMD P-State Linux Testing Support Phoronix The mission at Phoronix since 2004 has centered around enriching the Linux hardware experience. In addition to supporting our site through advertisements, you can help by subscribing to Phoronix Premium. You can also contribute to Phoronix through a PayPal tip or tip via Stripe. Phoronix Media --------------------------------------------------------------------- * Contact * Michael Larabel * OpenBenchmarking.org Phoronix Premium --------------------------------------------------------------------- * Support Phoronix * While Having Ad-Free Browsing, * Single-Page Article Viewing Share --------------------------------------------------------------------- * Facebook * Twitter * Legal Disclaimer, Privacy Policy, Cookies | Contact * Copyright (c) 2004 - 2022 by Phoronix Media. * All trademarks used are properties of their respective owners. All rights reserved.