More AMD Zen Microarchitecture Tuning For Mesa Is Likely Ahead
Published back in September was some Mesa RadeonSI tuning for AMD Zen CPUs. That tuning to pin the application thread and driver execution thread to the same L3 cache benefits the Zen micro-architecture with its multiple core complexes (CCX). That code was merged a short time later unconditionally but it looks like that behavior needs to be refined for delivering maximum performance.
At the end of October, AMD developer Marek Olšák who wrote the initial RadeonSI Zen tuning patch introduced a new DriConf configuration option to allow disabling the L3 thread pinning on a per-application basis. The motivation for that patch was since the Blender 3D modeling software performs better when all of its threads aren't forced onto the same CCX.
A user is now reporting of performance gains in other scenarios when disabling this L3 thread pinning. With a Ryzen 5 2600 there has been some tests of this L3 thread pinning behavior and in games like Hitman, there is a performance loss of about two frames per second on average. The belief is that for applications/games that can make use of many cores, the L3 thread pinning might negate the performance benefit otherwise.
Marek has commented that he will reconsider based upon his testing and potentially just pin the Mesa threads while keeping the app thread intact. Anyhow, we'll see what comes about for Mesa 19.0 and certainly post (and benchmark) any interesting changes.