[Mesa-dev] [PATCH 08/11] i965/miptree: Call alloc_aux in create_for_bo
Tapani Pälli
tapani.palli at intel.com
Thu Aug 3 06:38:29 UTC 2017
On 08/03/2017 09:33 AM, Tapani Pälli wrote:
>
>
> On 08/03/2017 09:28 AM, Jason Ekstrand wrote:
>> On August 2, 2017 11:21:33 PM Tapani Pälli <tapani.palli at intel.com>
>> wrote:
>>
>>> Hi Jason;
>>>
>>> Unfortunately this patch does not fix the mentioned bug. I've tested
>>> both with Piglit on desktop and on Android and issue persists on both.
>>
>> Can you provide a but now detail? I tried today but wasn't able to
>> reproduce the piglit failure.
>
> Sure, so for me it looks like this:
>
> [tpalli at tpalli-mobl2 piglit]$ mesa_run bin/egl-create-pbuffer-surface
> egl-create-pbuffer-surface: brw_blorp.c:808: do_single_blorp_clear:
> Assertion `irb->mt->aux_usage == ISL_AUX_USAGE_CCS_D' failed.
>
> I tried taking away that assert but that leads to another one and so on.
> I'm running this on Fedora25.
Forgot to say that machine is HSW and backtrace is from glClear like this:
#3 0x00007ffff4e27e12 in __assert_fail () from /lib64/libc.so.6
#4 0x00007ffff15a72cb in do_single_blorp_clear
(brw=brw at entry=0x7ffff7f71040, fb=fb at entry=0x774c00, rb=0x775060,
buf=buf at entry=0, partial_clear=partial_clear at entry=false,
encode_srgb=encode_srgb at entry=true)
at brw_blorp.c:808
#5 0x00007ffff15a8785 in brw_blorp_clear_color
(brw=brw at entry=0x7ffff7f71040, fb=fb at entry=0x774c00, mask=1,
partial_clear=partial_clear at entry=false, encode_srgb=true) at
brw_blorp.c:928
#6 0x00007ffff15ab734 in brw_clear (ctx=<optimized out>,
mask=<optimized out>) at brw_clear.c:285
#7 0x00000000004020ea in draw ()
#8 0x0000000000401e8c in egl_util_run ()
>
>>> On 08/02/2017 11:35 PM, Jason Ekstrand wrote:
>>>> Originally, I had moved it to the caller to make some things easier
>>>> when
>>>> adding the CCS modifier. However, this broke DRI2 because
>>>> intel_process_dri2_buffer calls intel_miptree_create_for_bo but never
>>>> calls intel_miptree_alloc_aux. Also, in hindsight, it should be pretty
>>>> easy to make the CCS modifier stuff work even if create_for_bo
>>>> allocates
>>>> the CCS when DISABLE_AUX is not set.
>>>>
>>>> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101925
>>>> Cc: Tapani Palli <tapani.palli at intel.com>
>>>> Cc: "17.2" <mesa-stable at lists.freedesktop.org>
>>>> ---
>>>> src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 13 +++++++------
>>>> 1 file changed, 7 insertions(+), 6 deletions(-)
>>>>
>>>> diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>>>> b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>>>> index 910bb46..305912c 100644
>>>> --- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>>>> +++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
>>>> @@ -839,9 +839,15 @@ intel_miptree_create_for_bo(struct brw_context
>>>> *brw,
>>>> mt->bo = bo;
>>>> mt->offset = offset;
>>>>
>>>> - if (!(layout_flags & MIPTREE_LAYOUT_DISABLE_AUX))
>>>> + if (!(layout_flags & MIPTREE_LAYOUT_DISABLE_AUX)) {
>>>> intel_miptree_choose_aux_usage(brw, mt);
>>>>
>>>> + if (!intel_miptree_alloc_aux(brw, mt)) {
>>>> + intel_miptree_release(&mt);
>>>> + return NULL;
>>>> + }
>>>> + }
>>>> +
>>>> return mt;
>>>> }
>>>>
>>>> @@ -978,11 +984,6 @@ intel_miptree_create_for_dri_image(struct
>>>> brw_context *brw,
>>>> if (is_winsys_image)
>>>> image->bo->cache_coherent = false;
>>>>
>>>> - if (!intel_miptree_alloc_aux(brw, mt)) {
>>>> - intel_miptree_release(&mt);
>>>> - return NULL;
>>>> - }
>>>> -
>>>> return mt;
>>>> }
>>>>
>>>>
>>
>>
More information about the mesa-dev
mailing list