[Mesa-dev] [PATCH 14/16] i965/icl: Disable HiZ surface sampling

Anuj Phogat anuj.phogat at gmail.com
Wed Feb 14 22:22:49 UTC 2018


On Tue, Feb 13, 2018 at 4:25 PM, Kenneth Graunke <kenneth at whitecape.org> wrote:
> On Tuesday, February 13, 2018 11:15:14 AM PST Anuj Phogat wrote:
>> On gen11+ AUX_HIZ is not a supported value for surfaces being
>> sampled by the 3D sampler.
>>
>> Signed-off-by: Anuj Phogat <anuj.phogat at gmail.com>
>> ---
>>  src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 5 +++--
>>  1 file changed, 3 insertions(+), 2 deletions(-)
>>
>> diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>> index f27d559149..9c6f166677 100644
>> --- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>> +++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>> @@ -1912,9 +1912,10 @@ intel_miptree_sample_with_hiz(struct brw_context *brw,
>>     const struct gen_device_info *devinfo = &brw->screen->devinfo;
>>
>>     /* It's unclear how well supported sampling from the hiz buffer is on GEN8,
>> -    * so keep things conservative for now and never enable it unless we're SKL+.
>> +    * so keep things conservative for now and never enable it unless we're GEN9+.
>> +    * Also, disable the sampling from the hiz buffer for GEN11+.
>>      */
>> -   if (devinfo->gen < 9) {
>> +   if (devinfo->gen < 9 || devinfo->gen > 10) {
>>        return false;
>>     }
>
> Sad to see this go :(
>
> I think we should add a devinfo->has_aux_hiz boolean, set it on Gen9-10,
> leave it false on Gen8 with this "it's unclear how well supported..."
> comment, then change this code to use the flag.
>
> That will disable it for Gen11 but gives us a bit more flexibility.

Sounds good. I think 'has_sample_with_hiz' a better name for the flag?
has_aux_hiz can be easily misinterpreted as a flag to check if
mt->hiz_buf is valid or not.


More information about the mesa-dev mailing list