Skip to content

Draft: gallium/meson: Deconflate swrast/softpipe/llvmpipe

Adam Jackson requested to merge ajax/mesa:softerpipe into main

softpipe is fine I guess. But it's required even if you just want to build llvmpipe. I would prefer to build at least my enterprise OS without softpipe because I don't want to support it, given that I'm already compelled to support llvmpipe, and that's challenge enough, and llvmpipe really ought to be preferable in almost every circumstance. I think it's especially goofy to include a copy of softpipe inside lavapipe, though at least there I am pretty sure lavapipe will fail to initialize.

Detangling this is pretty awful and this patch definitely needs some work, but the strategy is to add llvmpipe and softpipe as names to gallium-drivers, and treat swrast as a shorthand for both. We build src/gallium/drivers/llvmpipe if it is named as a gallium driver or if lavapipe was explicitly requested. The lavapipe target always links only llvmpipe, and the other targets link either or both as requested. Other than the lavapipe thing, which I sincerely hope is NFC, this stops short of any CI/policy/default changes and simply makes -Dgallium-drivers=llvmpipe do what you wanted.

Building out softpipe saves about 133k of text on aarch64, which is about 1/60th of the size of the lavapipe binary, which ain't too shabby.

Merge request reports