Skip to content

freedreno disasm: unit test and new cat2 float immediate disasm.

Emma Anholt requested to merge anholt/mesa:fd-disasm-test into master

In working on LDC for GL, I wanted to be able to verify the instructions I generated would generate sensible disasm. Refactoring disasm always feels dangerous since it's easy to break without noticing until the next shader you debug, so it's good to have a unit test verifying that you don't break decode of old instructions.

So, I rigged up a test to verify our disasm, and captured a bunch of qcom-generated instructions from various traces I have that tickle various parts of disasm, and compared their disasm to qcom's. For those where we matched (or were very close), I've included them in a new unit test. And, while I was digging, I found that cat2 float immediates have a bunch of useful values that we might want to use.

Merge request reports

Loading