From dac8d371e14e687da36ef7d7be62a9988fd038a3 Mon Sep 17 00:00:00 2001 From: Danylo Piliaiev Date: Thu, 20 Apr 2023 17:06:21 +0200 Subject: [PATCH] freedreno/regs: Define usage for all a6xx/a7xx regs Could be used for knowing which regs to stomp and to verify that only appropriate regs are emitted. Each register that is actually being used by driver should have "usage" defined, currently there are following usages: - "cmd" - the register is used outside of renderpass and blits, roughly corresponds to registers used in ib1 for Freedreno - "rp_blit" - the register is used inside renderpass or blits (ib2 for Freedreno) It is expected that register with "cmd" usage may be written into only at the start of the command buffer (ib1), while "rp_blit" usage indicates that register is either overwritten by renderpass/blit (ib2) or not used if not overwritten by a particular renderpass/blit. Signed-off-by: Danylo Piliaiev Part-of: --- src/freedreno/registers/adreno/a6xx.xml | 1012 ++++++++++++----------- 1 file changed, 517 insertions(+), 495 deletions(-) diff --git a/src/freedreno/registers/adreno/a6xx.xml b/src/freedreno/registers/adreno/a6xx.xml index d7fb7e0c3e0..22b734263c4 100644 --- a/src/freedreno/registers/adreno/a6xx.xml +++ b/src/freedreno/registers/adreno/a6xx.xml @@ -6,6 +6,20 @@ xsi:schemaLocation="http://nouveau.freedesktop.org/ rules-ng.xsd"> + + @@ -1556,9 +1570,9 @@ to upconvert to 32b float internally? - + - + @@ -1632,16 +1646,16 @@ to upconvert to 32b float internally? - + - - + + - + Configures the mapping between VSC_PIPE buffer and @@ -1667,14 +1681,14 @@ to upconvert to 32b float internally? LIMIT is set to PITCH - 64, to make room for a bit of overflow --> - - - - - - + + + + + + - + Seems to be a bitmap of which tiles mapped to the VSC pipe contain geometry. @@ -1685,7 +1699,7 @@ to upconvert to 32b float internally? - + Has the size of data written to corresponding VSC_PRIM_STRM buffer. @@ -1693,7 +1707,7 @@ to upconvert to 32b float internally? - + Has the size of data written to corresponding VSC pipe, ie. same thing that is written out to VSC_DRAW_STRM_SIZE_ADDRESS_LO/HI @@ -1701,10 +1715,10 @@ to upconvert to 32b float internally? - - + + - + @@ -1712,7 +1726,7 @@ to upconvert to 32b float internally? - + @@ -1730,12 +1744,12 @@ to upconvert to 32b float internally? - - - - + + + + - + @@ -1747,25 +1761,25 @@ to upconvert to 32b float internally? - + - + - + - - - - + + + + - + @@ -1773,12 +1787,12 @@ to upconvert to 32b float internally? - + - + @@ -1802,25 +1816,25 @@ to upconvert to 32b float internally? - + - + - + - - - + + + - + - + @@ -1835,9 +1849,9 @@ to upconvert to 32b float internally? - - - + + + @@ -1886,7 +1900,7 @@ to upconvert to 32b float internally? - + @@ -1908,7 +1922,7 @@ to upconvert to 32b float internally? - + @@ -1918,12 +1932,12 @@ to upconvert to 32b float internally? - + - + @@ -1944,30 +1958,30 @@ to upconvert to 32b float internally? - - - + + + - + - + - + - + - - + + @@ -1983,7 +1997,7 @@ to upconvert to 32b float internally? - + LRZ write also disabled for blend/etc. @@ -2017,16 +2031,16 @@ to upconvert to 32b float internally? - + - + - - + + @@ -2062,9 +2076,9 @@ to upconvert to 32b float internally? increases beyond 1 page. Not sure if that is an actual limit or not. --> - + - + - + - + - + - + @@ -2124,26 +2138,26 @@ to upconvert to 32b float internally? - + - - - - - - + + + + + + - - + + - + @@ -2158,7 +2172,7 @@ to upconvert to 32b float internally? --> - + @@ -2167,7 +2181,7 @@ to upconvert to 32b float internally? - + @@ -2175,7 +2189,7 @@ to upconvert to 32b float internally? - + @@ -2190,7 +2204,7 @@ to upconvert to 32b float internally? - + @@ -2200,25 +2214,25 @@ to upconvert to 32b float internally? - + - + - - - + + + - + @@ -2229,7 +2243,7 @@ to upconvert to 32b float internally? - + @@ -2241,16 +2255,16 @@ to upconvert to 32b float internally? - + - + - + @@ -2260,7 +2274,7 @@ to upconvert to 32b float internally? - + @@ -2270,7 +2284,7 @@ to upconvert to 32b float internally? - + @@ -2282,23 +2296,23 @@ to upconvert to 32b float internally? - + - - + + - + - - - - - - + + + + + + - + @@ -2345,16 +2359,16 @@ to upconvert to 32b float internally? - - - - - + + + + + - + @@ -2364,11 +2378,11 @@ to upconvert to 32b float internally? - + - + @@ -2381,27 +2395,27 @@ to upconvert to 32b float internally? - + - + - - - - + + + + - - + + - + - - + + - + - + - - + + - + - - + + - + - - + + - + - + @@ -2486,23 +2500,23 @@ to upconvert to 32b float internally? - - + + - - - + + + - - - - + + + + - + @@ -2530,10 +2544,10 @@ to upconvert to 32b float internally? - + - + @@ -2544,14 +2558,14 @@ to upconvert to 32b float internally? - - + + - + @@ -2559,7 +2573,7 @@ to upconvert to 32b float internally? - + @@ -2568,13 +2582,13 @@ to upconvert to 32b float internally? These show up in a6xx gen3+ but so far haven't found an example of blob writing non-zero: --> - - - - + + + + - - + + @@ -2597,38 +2611,38 @@ to upconvert to 32b float internally? - - - + + + - - - + + + - - + + - - + + - - - - + + + + - + - + - + - + @@ -2654,7 +2668,7 @@ to upconvert to 32b float internally? - + @@ -2673,13 +2687,13 @@ to upconvert to 32b float internally? - + - + @@ -2692,9 +2706,9 @@ to upconvert to 32b float internally? - - - + + + @@ -2702,16 +2716,16 @@ to upconvert to 32b float internally? - - - + + + - + - + @@ -2754,29 +2768,29 @@ to upconvert to 32b float internally? - - - - + + + + - + - + - - + + - + - + - + @@ -2814,9 +2828,9 @@ to upconvert to 32b float internally? - + - + @@ -2824,12 +2838,12 @@ to upconvert to 32b float internally? - + - + @@ -2848,11 +2862,11 @@ to upconvert to 32b float internally? - - - + + + - + @@ -2871,7 +2885,7 @@ to upconvert to 32b float internally? - + @@ -2881,19 +2895,19 @@ to upconvert to 32b float internally? - + - + - - - + + + @@ -2901,29 +2915,29 @@ to upconvert to 32b float internally? - + - + - + - - + + - + - + - + @@ -2956,21 +2970,21 @@ to upconvert to 32b float internally? - + - + - + - + @@ -2979,7 +2993,7 @@ to upconvert to 32b float internally? - + @@ -2997,24 +3011,24 @@ to upconvert to 32b float internally? - - + + - - + + - + - + size in vec4s of per-primitive storage for gs. TODO: not actually in VPC - + - + @@ -3028,8 +3042,8 @@ to upconvert to 32b float internally? - - + + @@ -3054,26 +3068,26 @@ to upconvert to 32b float internally? - + - + - + - + - + This is the ID of the current patch within the @@ -3086,20 +3100,20 @@ to upconvert to 32b float internally? - + - + - + - + - - - + + + - + @@ -3140,16 +3154,16 @@ to upconvert to 32b float internally? - + - + - + @@ -3216,7 +3230,7 @@ to upconvert to 32b float internally? - + - - + + @@ -3259,7 +3273,7 @@ to upconvert to 32b float internally? an extra varying after, but with a lower OUTLOC position. If present, psize is last, preceded by position. --> - + @@ -3339,19 +3353,19 @@ to upconvert to 32b float internally? - - - - - - - - - + + + + + + + + + - + - + @@ -3361,29 +3375,29 @@ to upconvert to 32b float internally? the maximum size of local storage should be: 64 (wavesize) * 64 (SP_HS_WAVE_INPUT_SIZE) * 4 = 16k --> - - + + - - - - - - - - - + + + + + + + + + - + - - + + @@ -3391,7 +3405,7 @@ to upconvert to 32b float internally? - + @@ -3401,21 +3415,21 @@ to upconvert to 32b float internally? - - - - - - - - - + + + + + + + + + - + - + Normally the size of the output of the last stage in dwords. It should be programmed as follows: @@ -3429,11 +3443,11 @@ to upconvert to 32b float internally? doesn't matter in practice. - + - - + + @@ -3442,7 +3456,7 @@ to upconvert to 32b float internally? - + @@ -3452,28 +3466,28 @@ to upconvert to 32b float internally? - - - - - - - - - + + + + + + + + + - - - - - - - - + + + + + + + + - + @@ -3487,20 +3501,20 @@ to upconvert to 32b float internally? - - - - - + + + + + - + - + @@ -3511,7 +3525,7 @@ to upconvert to 32b float internally? - + @@ -3521,17 +3535,17 @@ to upconvert to 32b float internally? - + - + - + per MRT @@ -3539,7 +3553,7 @@ to upconvert to 32b float internally? - + @@ -3548,7 +3562,7 @@ to upconvert to 32b float internally? - + @@ -3572,7 +3586,7 @@ to upconvert to 32b float internally? - + @@ -3586,7 +3600,7 @@ to upconvert to 32b float internally? - + @@ -3598,22 +3612,22 @@ to upconvert to 32b float internally? - + - - - + + + - + @@ -3624,7 +3638,7 @@ to upconvert to 32b float internally? - + If 0 - all 32k of shared storage is enabled, otherwise @@ -3639,27 +3653,27 @@ to upconvert to 32b float internally? - - - - - - - - - - - + + + + + + + + + + + - + - + - - - - + + + + @@ -3692,13 +3706,13 @@ to upconvert to 32b float internally? - + - + @@ -3711,7 +3725,7 @@ to upconvert to 32b float internally? - + - - + + - - + + - + - + @@ -3761,10 +3775,10 @@ to upconvert to 32b float internally? Combined IBO state for 3d pipe, used for Image and SSBO write/atomic instructions VS/HS/DS/GS/FS. See SP_CS_IBO_* for compute shaders. --> - - + + - + @@ -3779,25 +3793,25 @@ to upconvert to 32b float internally? - - + + - + - - + + - - - - + + + + - + @@ -3810,11 +3824,11 @@ to upconvert to 32b float internally? - - - + + + - + @@ -3825,59 +3839,59 @@ to upconvert to 32b float internally? "a6xx_sp_ps_tp_cluster" but this actually specifies the border color base for compute shaders. --> - - - + + + - + - + - - - - - - + + + + + + - + - - + + - - + + - - + + - - + + @@ -3891,30 +3905,30 @@ to upconvert to 32b float internally? - - + + - - + + - + - - - - - - - + + + + + + + - + - + @@ -3922,12 +3936,20 @@ to upconvert to 32b float internally? - - - - - - + + + + + + + + + + + + + + @@ -3938,17 +3960,17 @@ to upconvert to 32b float internally? - - - - + + + + - - - - + + + + - + @@ -3993,69 +4015,69 @@ to upconvert to 32b float internally? - + - + - + - - - - + + + + - + - - + + - + - - - - + + + + - + - + - + - + - + - + - + - + - - - + + + - + - + - + - + - + - + - + - - - + + + - + @@ -4121,7 +4143,7 @@ to upconvert to 32b float internally? - + @@ -4133,7 +4155,7 @@ to upconvert to 32b float internally? - + @@ -4141,7 +4163,7 @@ to upconvert to 32b float internally? - + @@ -4162,7 +4184,7 @@ to upconvert to 32b float internally? - + This register clears pending loads queued up by CP_LOAD_STATE6. Each bit resets a particular kind(s) of @@ -4189,7 +4211,7 @@ to upconvert to 32b float internally? - + This register clears pending loads queued up by CP_LOAD_STATE6. Each bit resets a particular kind(s) of @@ -4212,12 +4234,12 @@ to upconvert to 32b float internally? - - + + - + Shared constants are intended to be used for Vulkan push constants. When enabled, 8 vec4's are reserved in the FS @@ -4240,7 +4262,7 @@ to upconvert to 32b float internally? - + @@ -4252,9 +4274,9 @@ to upconvert to 32b float internally? - - - + + + @@ -4265,9 +4287,9 @@ to upconvert to 32b float internally? - - - + + +