https://www.phoronix.com/news/Linux-AMD-Old-Chipset-WA 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] We Rely On Your Support: Did you know that the hundreds of articles written on Phoronix each month are mostly authored by one individual working insane hours? Phoronix.com doesn't have a whole news room with unlimited resources and relies upon people reading our content without blocking ads and alternatively by people subscribing to Phoronix Premium for our ad-free service with other extra features. You can also consider a tip via PayPal. A 20 Year Old Chipset Workaround Has Been Hurting Modern AMD Linux Systems Written by Michael Larabel in AMD on 26 September 2022 at 05:26 AM EDT. 30 Comments AMD -- AMD engineer K Prateek Nayak recently uncovered that a ~20 year old chipset workaround in the Linux kernel still being applied to modern AMD systems is responsible in some cases for hurting performance on modern Zen hardware. Fortunately, a fix is on the way for limiting that workaround to old systems and in turn helping with performance for modern systems. Last week was a patch posted for the ACPI processor idle code to avoid an old chipset workaround on modern AMD Zen systems. Since ACPI support was added to the Linux kernel in 2002, there has been a "dummy wait op" to deal with some chipsets where STPCLK# doesn't get asserted in time. The dummy I/O read delays further instruction processing until the CPU is fully stopped. This was a problem with at least some AMD Athlon era systems with a VIA chipset... But not a problem with newer chipsets of roughly the past two decades. [image] A Linux kernel workaround for the past two decades intended for now-ancient chipsets is still being needlessly applied to modern AMD systems, which in turn can hurt performance in select workloads. With this workaround still being applied to even modern AMD systems, K Prateek Nayak discovered: Sampling certain workloads with IBS on AMD Zen3 system shows that a significant amount of time is spent in the dummy op, which incorrectly gets accounted as C-State residency. A large C-State residency value can prime the cpuidle governor to recommend a deeper C-State during the subsequent idle instances, starting a vicious cycle, leading to performance degradation on workloads that rapidly switch between busy and idle phases. One such workload is tbench where a massive performance degradation can be observed during certain runs. At least for Tbench, this long-time, unconditional workaround in the Linux kernel has been hurting AMD Ryzen / Threadripper / EPYC performance in select workloads: [image] This workaround hasn't affected modern Intel systems since those newer Intel platforms use the alternative MWAIT-based intel_idle driver code path instead. The AMD patch evolved into this patch by Intel Linux engineer Dave Hansen. That patch to limit the "dummy wait" workaround to old systems is already queued into TIP's x86/urgent branch. With it going the route of "x86/urgent" and for fixing a overzealous workaround that isn't needed on modern hardware, it's likely this patch will be submitted this week still for the Linux 6.0 kernel rather than needing to wait until the next (v6.1) merge window. Update: The fix has been merged for Linux 6.0! I will be having some benchmarks on Phoronix soon. 30 Comments Tweet [INS::INS] Related News Linux 6.0 Merges The AMD Performance Fix For The Old "Dummy Wait" Workaround AMD Hardware Ray-Tracing Hopes To Be Ready For Blender 3.5 AMD RDNA 3 Being Announced On 3 November More AMD Ryzen Laptops See Suspend-To-Idle Fix AMD Engineers Held Several Interesting Talks At This Week's Linux Conferences AMD Prepares s2idle Fixes For AMD Ryzen 6000 Series Powered ASUS Laptops About The Author Author picture Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com. Popular News This Week A 20 Year Old Chipset Workaround Has Been Hurting Modern AMD Linux Systems Rust-Written Apple DRM Linux Kernel Driver Renders First Cube Microsoft & Canonical Bring systemd To WSL GNOME 43 Released With More Apps Ported To GTK4, Wayland Enhancements Firefox 105 Now Available - Better Linux Performance Under Memory Pressure Phoronix Oktoberfest Special Begins, Premium Now Accept Stripe & Corporate Subscriptions Available Wayland's Weston 11.0 Released With HDR Display & Multi-GPU Preparations Google Engineers Argue For Linux "ASI" To Better Deal With Speculative Execution Attacks Latest Linux News Linux 6.0 Merges The AMD Performance Fix For The Old "Dummy Wait" Workaround openSUSE ALP Prototype "Les Droites" Releasing This Week Experimental Patch Gets The ARM64 Linux Kernel Compiling Under macOS A 20 Year Old Chipset Workaround Has Been Hurting Modern AMD Linux Systems Rusticl Support For AMD RadeonSI Driver Being Worked On Linux 6.0-rc7 Released - Linux 6.0 Will Hopefully Release Next Sunday Btrfs Async Buffered Writes Slated For Linux 6.1 - 2x Throughput Improvement Archinstall 2.5.1 Released With A Number Of Fixes For The Arch Linux Installer OpenJDK Java's Native Wayland Support Progressing Rust-Written Apple DRM Linux Kernel Driver Renders First Cube 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 9 7900X / Ryzen 9 7950X Benchmarks Show Impressive Zen 4 Linux Performance AMD Zen 4 AVX-512 Performance Analysis On The Ryzen 9 7950X AMD Ryzen 9 7900X / 7950X Linux Gaming Performance Solidigm P41 Plus NVMe SSD Blender 3.3 AMD Radeon HIP vs. NVIDIA CUDA/OptiX Performance 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.