[Mesa-dev] [PATCH] i965: Allow mapped VBOs during drawing in non-debug contexts.

Eric Anholt eric at anholt.net
Wed Oct 11 17:07:43 UTC 2017

Kenneth Graunke <kenneth at whitecape.org> writes:

> Section 6.3.2 of the GL 4.5 spec says:
>    "Any GL command which attempts to read from, write to, or change
>     the state of a buffer object may generate an INVALID_OPERATION error
>     if all or part of the buffer object is mapped ... However, only
>     commands which explicitly describe this error are required to do so.
>     If an error is not generated, such commands will have undefined
>     results and may result in GL interruption or termination."
> Setting this flag allows us to skip walking over the buffer bindings
> for every enabled vertex attribute (_mesa_all_buffers_are_unmapped).
> Improves performance in GFXBench4's gl_driver2_off microbenchmark by
> 3.05797% +/- 0.709031% (n=33) on Apollolake.
> This breaks KHR-*.draw_elements_base_vertex_tests.invalid_mapped_bos,
> but that test is invalid and has been removed from the upstream CTS.

Given the spec text, we should probably just remove the flag entirely
and do this for everyone.  However, for i965:

Reviewed-by: Eric Anholt <eric at anholt.net>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20171011/4d3af5cf/attachment.sig>

More information about the mesa-dev mailing list