Mesa's LLVMpipe Driver Begins Experimenting With AVX-512 Optimizations Ahead Of Zen 4
LLVMpipe is the Mesa software OpenGL implementation used when no GPU hardware or driver is present on the system. LLVMpipe leverages LLVM for making use of modern software instruction set extensions and features for offering much better performance than Softpipe and other software OpenGL implementations.
Mesa contributor Yonggang Luo started working on AVX-512 LLVMpipe support because:
As AVX512 can be a thing with Ryzen 7950x, so I'd like to enable it in llvmpipe
Granted, Intel has been supporting AVX-512 for years. The justification is also a bit off since at least with the recently announced Ryzen 7000 series processors, they also feature integrated RDNA2 graphics. Given the state of LLVMpipe, the integrated RDNA2 graphics are likely to be much more performant than LLVMpipe.
Zen 4 processors bring AVX-512 to the AMD side and is already piquing interest among open-source developers.
It's also not clear how much faster AVX-512 will be for LLVMpipe on AMD Zen 4 processors. For Zen 4, AVX-512 is implemented still using a 256-bit data path rather than 512-bit, but we'll see how well their AVX-512 implementation plays out soon enough.
In this merge request, it makes the basic changes for enabling AVX-512 use within Gallivm where as previously AVX-512 support was disabled there. The change also adds a "GALLIUM_OVERRIDE_CPU_CAPS" environment variable if wishing to override the reported CPU capabilities for Softpipe/LLVMpipe to enable/disable AVX, SSE, and other features. Similarly there is "LP_NATIVE_VECTOR_WIDTH" if wanting to override the vector bits width for AVX/AVX2/AVX-512 usage within LLVMpipe. It will be interesting to see how well this AVX-512 for LLVMpipe works in practice for Intel and AMD.