[Mesa-dev] [PATCH] i965: Drop assertion about buffer offset at draw time.
Kenneth Graunke
kenneth at whitecape.org
Tue Aug 16 05:52:07 UTC 2016
On Monday, August 15, 2016 9:01:06 AM PDT Eric Anholt wrote:
> Given robust access, we should just be returning zeroes if the user gives
> us a base pointer that's too big, which is what was happens on a release
> build. This was caught by a webgl conformance test for out-of-bounds
> draws on servo.
> ---
> src/mesa/drivers/dri/i965/brw_draw_upload.c | 11 -----------
> 1 file changed, 11 deletions(-)
>
> diff --git a/src/mesa/drivers/dri/i965/brw_draw_upload.c b/src/mesa/drivers/dri/i965/brw_draw_upload.c
> index fdb1b35f4c35..a44e04be6be6 100644
> --- a/src/mesa/drivers/dri/i965/brw_draw_upload.c
> +++ b/src/mesa/drivers/dri/i965/brw_draw_upload.c
> @@ -552,17 +552,6 @@ brw_prepare_vertices(struct brw_context *brw)
> input->buffer = j++;
> input->offset = 0;
> }
> -
> - /* This is a common place to reach if the user mistakenly supplies
> - * a pointer in place of a VBO offset. If we just let it go through,
> - * we may end up dereferencing a pointer beyond the bounds of the
> - * GTT.
> - *
> - * The VBO spec allows application termination in this case, and it's
> - * probably a service to the poor programmer to do so rather than
> - * trying to just not render.
> - */
> - assert(input->offset < intel_buffer->Base.Size);
> } else {
> /* Queue the buffer object up to be uploaded in the next pass,
> * when we've decided if we're doing interleaved or not.
>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160815/e303f043/attachment.sig>
More information about the mesa-dev
mailing list