tu, freedreno: Fix a few issues with LRZ and unify calculations between Turnip and Freedreno
What does this MR do and why?
- In Turnip wrong re-calculation of blend LRZ state when it was already calculated with static info - resulted in LRZ not being used when it may be in VK titles.
- In Turnip we didn't account for arrayed depth in LRZ calculations.
- After addition of 8x MSAA, LRZ calculation was not updated.
- We disabled LRZ for the whole RP if LRZ was disabled anywhere in the RP. That's not realistic to expect the whole pass to support LRZ, it's probably came from misunderstanding of how GPU lrz dir tracking bit works. Now, after testing it again, if LRZ is disabled via dir tracking bit during binning pass - it would be disabled for the whole tiling pass. So now we track whether LRZ valid in driver as long as we can (secondary cmdbufs and RP suspend/resume may force us to flush it) and introduce driconf option to specify how early LRZ has to become invalid to disable LRZ for the whole renderpass.
And finally unify LRZ layout calculations between Turnip and Freedreno. There is no point in duplication.
Edited by Danylo Piliaiev