asahi: Add mipmapping state to the XML
authorAlyssa Rosenzweig <alyssa@rosenzweig.io>
Tue, 1 Jun 2021 00:08:37 +0000 (20:08 -0400)
committerMarge Bot <eric+marge@anholt.net>
Tue, 1 Jun 2021 01:31:02 +0000 (01:31 +0000)
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11086>

src/asahi/lib/cmdbuf.xml

index 38fc74a..c28f343 100644 (file)
     <field name="Swizzle A" size="3" start="25" type="Channel" default="A"/>
     <field name="Width" size="14" start="28" type="uint" modifier="minus(1)"/>
     <field name="Height" size="14" start="42" type="uint" modifier="minus(1)"/>
+    <field name="Levels" size="6" start="60" type="uint" modifier="minus(1)"/>
     <field name="Unk 1" size="36" start="66" type="hex" modifier="shr(4)"/>
+    <!-- Unknown bit set by Metal when mipmapping. Might relate to a mechanism
+    to switch tile size (or disable tiling altogether?) at small mip levels to
+    reduce wasted memory due to padding. Causing test flakiness when set. -->
+    <field name="Unk mipmapped" size="1" start="102" type="bool"/>
     <field name="Compression" size="2" start="106" type="hex"/> <!-- 0 for 64x64 tiling -->
     <field name="sRGB" size="1" start="108" type="bool"/>
     <field name="Unk 2" size="1" start="109" type="bool"/>