* virglrenderer regression in commit ad4f0f1941677c
@ 2016-07-29 19:57 Rob Herring
2016-07-29 20:23 ` Marc-André Lureau
2016-07-30 13:40 ` Rob Clark
0 siblings, 2 replies; 5+ messages in thread
From: Rob Herring @ 2016-07-29 19:57 UTC (permalink / raw)
To: Marc-André Lureau, Dave Airlie; +Cc: dri-devel
Hi,
This commit in virglrenderer causes a regression in Android for me.
The parameters that get passed in are last_level = 8, width = 1. I'm
not really sure if this is valid (I'm guessing there should be some
min width?), or where I should be looking to fix this. Any ideas?
commit ad4f0f1941677c6cd78bcd14348cd99ae7dd7527
Author: Marc-André Lureau <marcandre.lureau@redhat.com>
Date: Tue Jan 19 14:37:50 2016 +0100
renderer: reject large LOD values
Or we could sit for a very long time in some further loops.
Fix found thanks to american fuzzy lop.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Thanks,
Rob
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: virglrenderer regression in commit ad4f0f1941677c
2016-07-29 19:57 virglrenderer regression in commit ad4f0f1941677c Rob Herring
@ 2016-07-29 20:23 ` Marc-André Lureau
2016-07-30 13:40 ` Rob Clark
1 sibling, 0 replies; 5+ messages in thread
From: Marc-André Lureau @ 2016-07-29 20:23 UTC (permalink / raw)
To: Rob Herring; +Cc: Marc-André Lureau, dri-devel
Hi
----- Original Message -----
> Hi,
>
> This commit in virglrenderer causes a regression in Android for me.
> The parameters that get passed in are last_level = 8, width = 1. I'm
> not really sure if this is valid (I'm guessing there should be some
> min width?), or where I should be looking to fix this. Any ideas?
>
> commit ad4f0f1941677c6cd78bcd14348cd99ae7dd7527
> Author: Marc-André Lureau <marcandre.lureau@redhat.com>
> Date: Tue Jan 19 14:37:50 2016 +0100
>
> renderer: reject large LOD values
>
> Or we could sit for a very long time in some further loops.
>
> Fix found thanks to american fuzzy lop.
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
I don't know whether a texture of 1x1 with a LOD of 8 is valid. I remember that fix was related to invalid virgl command stream found by afl, that would be able to loop millions of iterations in some code, such as vrend_renderer_resource_create(). I wonder if you could trace it back to some client code. Also worth if there is a valid opengl reproducer, that could be a new piglit test.
Btw, there is a virglrenderer mailing list: virglrenderer-devel@lists.freedesktop.org
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: virglrenderer regression in commit ad4f0f1941677c
2016-07-29 19:57 virglrenderer regression in commit ad4f0f1941677c Rob Herring
2016-07-29 20:23 ` Marc-André Lureau
@ 2016-07-30 13:40 ` Rob Clark
2016-08-01 5:30 ` Marc-André Lureau
1 sibling, 1 reply; 5+ messages in thread
From: Rob Clark @ 2016-07-30 13:40 UTC (permalink / raw)
To: Rob Herring; +Cc: Marc-André Lureau, dri-devel, mesa-dev
On Fri, Jul 29, 2016 at 3:57 PM, Rob Herring <robh@kernel.org> wrote:
> Hi,
>
> This commit in virglrenderer causes a regression in Android for me.
> The parameters that get passed in are last_level = 8, width = 1. I'm
> not really sure if this is valid (I'm guessing there should be some
> min width?), or where I should be looking to fix this. Any ideas?
what is the height? last mip-map level is basically the number of
times you could half the width+height (round up to 1) until it is 1x1.
So something like 1x512 would have last_level=8. (I might be off by
one right-shift..)
Try this:
- if (args->last_level > (floor(log2(MAX2(args->width, args->width))) + 1))
+ if (args->last_level > (floor(log2(MAX2(args->width, args->height))) + 1))
BR,
-R
> commit ad4f0f1941677c6cd78bcd14348cd99ae7dd7527
> Author: Marc-André Lureau <marcandre.lureau@redhat.com>
> Date: Tue Jan 19 14:37:50 2016 +0100
>
> renderer: reject large LOD values
>
> Or we could sit for a very long time in some further loops.
>
> Fix found thanks to american fuzzy lop.
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
>
> Thanks,
> Rob
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: virglrenderer regression in commit ad4f0f1941677c
2016-07-30 13:40 ` Rob Clark
@ 2016-08-01 5:30 ` Marc-André Lureau
2016-08-01 10:28 ` Rob Clark
0 siblings, 1 reply; 5+ messages in thread
From: Marc-André Lureau @ 2016-08-01 5:30 UTC (permalink / raw)
To: Rob Clark; +Cc: mesa-dev, dri-devel, Marc-André Lureau
Hi
----- Original Message -----
> On Fri, Jul 29, 2016 at 3:57 PM, Rob Herring <robh@kernel.org> wrote:
> > Hi,
> >
> > This commit in virglrenderer causes a regression in Android for me.
> > The parameters that get passed in are last_level = 8, width = 1. I'm
> > not really sure if this is valid (I'm guessing there should be some
> > min width?), or where I should be looking to fix this. Any ideas?
>
> what is the height? last mip-map level is basically the number of
> times you could half the width+height (round up to 1) until it is 1x1.
> So something like 1x512 would have last_level=8. (I might be off by
> one right-shift..)
>
> Try this:
>
> - if (args->last_level > (floor(log2(MAX2(args->width, args->width))) + 1))
> + if (args->last_level > (floor(log2(MAX2(args->width, args->height))) + 1))
Oh, looks like what I wanted but I wouldn't see the typo even after re-reading...
please send a patch on the virgl mailing list.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: virglrenderer regression in commit ad4f0f1941677c
2016-08-01 5:30 ` Marc-André Lureau
@ 2016-08-01 10:28 ` Rob Clark
0 siblings, 0 replies; 5+ messages in thread
From: Rob Clark @ 2016-08-01 10:28 UTC (permalink / raw)
To: Marc-André Lureau; +Cc: mesa-dev, dri-devel, Marc-André Lureau
On Mon, Aug 1, 2016 at 1:30 AM, Marc-André Lureau <mlureau@redhat.com> wrote:
>
> Hi
>
> ----- Original Message -----
>> On Fri, Jul 29, 2016 at 3:57 PM, Rob Herring <robh@kernel.org> wrote:
>> > Hi,
>> >
>> > This commit in virglrenderer causes a regression in Android for me.
>> > The parameters that get passed in are last_level = 8, width = 1. I'm
>> > not really sure if this is valid (I'm guessing there should be some
>> > min width?), or where I should be looking to fix this. Any ideas?
>>
>> what is the height? last mip-map level is basically the number of
>> times you could half the width+height (round up to 1) until it is 1x1.
>> So something like 1x512 would have last_level=8. (I might be off by
>> one right-shift..)
>>
>> Try this:
>>
>> - if (args->last_level > (floor(log2(MAX2(args->width, args->width))) + 1))
>> + if (args->last_level > (floor(log2(MAX2(args->width, args->height))) + 1))
>
> Oh, looks like what I wanted but I wouldn't see the typo even after re-reading...
>
> please send a patch on the virgl mailing list.
tbh, I don't even have a virgl setup (psuedo-patch was just from
looking at cgit).. so I'd be more than happy if someone else could
actually test that change and send a patch.
BR,
-R
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2016-08-01 10:28 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-29 19:57 virglrenderer regression in commit ad4f0f1941677c Rob Herring
2016-07-29 20:23 ` Marc-André Lureau
2016-07-30 13:40 ` Rob Clark
2016-08-01 5:30 ` Marc-André Lureau
2016-08-01 10:28 ` Rob Clark
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.