Skip to content

panfrost: Use GenXML for the GPU data structures

Alyssa Rosenzweig requested to merge alyssa/mesa:clean8 into master

The eventual goal is to remove the mess of enums, packed bitfields, defines, and macros in panfrost-job.h and the accompanied handwritten encode/decode routines. replacing it by a streamlined XML machine description with a GenXML-like schema. We can generate pack, unpacks, and prints automatically at build-time from the XML for improved ergonomics. Additionally, by moving away from implicit packs (bit fields) to explicit packs (via XML), we avoid accidentally reading from write-combine memory while preparing structures which incurs a significant performance penalty.

The first half of the series is just reorganizing our build units to enable GenXML integration and allow building panloader against a modern mesa; those will be landed as !6196 (merged) (please review there). The latter half actually introduces GenXML into our infrastructure and incrementally refactors the driver to use the new patterns.

WIP because only a small number of structures are ported over at the moment and project requirements may continue to evolve. Enough is ported that I think I'd rather land sooner than later.

Cc @tomeu @bbrezillon @icecream95

Edited by Alyssa Rosenzweig

Merge request reports