aboutsummaryrefslogtreecommitdiffstats
path: root/src/mapi
Commit message (Collapse)AuthorAgeFilesLines
* glthread: fall back if a param size is non-zero and a pointer param is NULLMarek Olšák2020-03-061-0/+1
| | | | | | | | So that we don't crash. This is a GL error anyway. Reviewed-by: Timothy Arceri <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add custom marshalling for glNamedBuffer(Sub)DataEXTMarek Olšák2020-03-061-2/+2
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: replace custom glBindBuffer marshalling with generated oneMarek Olšák2020-03-061-1/+2
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: sync instead of disabling glthread for non-VBO pointersMarek Olšák2020-03-069-22/+34
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: track for each VAO whether the user has set a user pointerMarek Olšák2020-03-069-29/+38
| | | | | | | | | | | | This commit mainly adds basic infrastructure for tracking vertex array state. If glthread gets a non-VBO pointer, this commit delays disabling glthread until glDraw is called. The next will change that to "sync" instead of "disable". Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add marshal_call_after and remove custom glFlush and glEnable codeMarek Olšák2020-03-064-11/+15
| | | | | | | | Instead of implementing marshalling manually, this XML property allows us to insert additional code into code-generated functions. Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: don't insert an empty line after (void) cmd;Marek Olšák2020-03-061-1/+1
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add support for glMemoryObjectParameteriv, glSemaphoreParameterui64vMarek Olšák2020-03-061-2/+2
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add support for glCallLists, glPatchParameterfvMarek Olšák2020-03-062-2/+3
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add support for glClearNamedFramebuffer, glMaterial, glPointParameterMarek Olšák2020-03-063-9/+15
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add support for glFog, glLight, glLightModel, glTexEnv, glTexGenMarek Olšák2020-03-064-21/+37
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add support for TexParameteri and SamplerParameteri functionsMarek Olšák2020-03-0611-33/+42
| | | | | | | | | | It's straightfoward except that I had to hack the python scripts to add "marshal_count", which behaves just like "count" except that "variable_param" is ignored. ("variable_param" changes the behavior of "count", which I don't want) Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: replace custom ClearBuffer marshalling with generated oneMarek Olšák2020-03-061-7/+7
| | | | | | | If the count attribute contains "enum", the count is evaluated only once. Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: check the size of all variable params and clean up the codeMarek Olšák2020-03-061-25/+16
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: handle complex pointer parameters and support GL functions with ↵Marek Olšák2020-03-065-18/+17
| | | | | | | | | | strings The python changes add a local variable that computes the parameter size only once. Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add/update count and marshal fields for many GL functionsMarek Olšák2020-03-0624-132/+141
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: add GL_DRAW_INDIRECT_BUFFER tracking and generator supportMarek Olšák2020-03-061-1/+3
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: don't increment variable_data if it's the last variable-size paramMarek Olšák2020-03-061-8/+15
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: don't insert _mesa_post_marshal_hook into every functionMarek Olšák2020-03-061-1/+3
| | | | | | | Let the developer decide that in the python script. Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: simplify repeated function sequences in marshal_generated.cMarek Olšák2020-03-061-6/+3
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: use int instead of size_t where it's OKMarek Olšák2020-03-061-1/+1
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: inline _mesa_unmarshal_dispatch_cmd and convert the switch to a tableMarek Olšák2020-03-062-21/+4
| | | | | Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: don't prefix variable_data with constMarek Olšák2020-03-061-2/+2
| | | | | | | | Not all variable data that is constant is declared with const, such as glDeletePerfMonitorsAMD. Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glthread: don't generate the sync fallback if the call size is not variableMarek Olšák2020-03-061-11/+15
| | | | | | | marshal_generated.c is 12% smaller. Reviewed-by: Timothy Arceri <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3948>
* glapi/copyimage: Implement CopyImageSubDataNVIndrajit Kumar Das2020-02-244-0/+31
| | | | | | | | | | | Implement CopyImageSubDataNV from NV_copy_image spec. This is derived out of the existing implementation of CopyImageSubData. It differs from CopyImageSubData in accordance with the differences laid down in the ARB_copy_image spec. Reviewed-by: Marek Olšák <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3649> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3649>
* glapi / teximage: implement EGLImageTargetTexStorageEXTGurchetan Singh2020-01-133-0/+25
| | | | | | | Check various parts of the EXT_EGL_image_storage spec, and add a new vfunc for drivers implementing it. Reviewed-by: Tapani Pälli <[email protected]>
* mapi: add GetInteger64vEXT with EXT_disjoint_timer_queryTapani Pälli2019-11-262-0/+13
| | | | | | | | | | | | | From EXT_disjoint_timer_query spec: "Interaction: This extension adds GetInteger64vEXT if OpenGL ES 3.0 is not supported" See https://github.com/KhronosGroup/OpenGL-Registry/issues/326. Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/2090 Signed-off-by: Tapani Pälli <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* mesa/glthread: Implement ARB_multi_bind.Markus Wick2019-11-221-10/+10
| | | | | Signed-off-by: Markus Wick <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* mapi/glapi: Generate sizeof() helpers instead of fixed sizes.Markus Wick2019-11-211-4/+11
| | | | | | | | | Generating a source code with a fixed size leads to issues with plattform dependent types. We either hard code 4 or 8 bytes there, and both are wrong on the other plattform. So this patch solves this issue by generating eg sizeof(GLsizeiptr), which is valid both on 32 and on 64 bit plattforms. Signed-off-by: Marek Olšák <[email protected]>
* mesa: add ARB_shading_language_include stubsTimothy Arceri2019-11-203-1/+50
| | | | | Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]> Reviewed-by: Witold Baryluk <[email protected]>
* mesa: add ARB_sparse_buffer NamedBufferPageCommitmentEXT functionPierre-Eric Pelloux-Prayer2019-11-192-3/+10
| | | | | | | The spec is unclear on how to handle the buffer argument so we reuse the logic from the EXT_direct_state_access spec. Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_vertex_attrib_binding glVertexArray* functionsPierre-Eric Pelloux-Prayer2019-11-192-0/+51
| | | | | | | We can't simply alias ARB_direct_state_access functions because those fail if the vao has never been bound before. Reviewed-by: Marek Olšák <[email protected]>
* mesa: implement ARB_texture_storage_multisample + EXT_dsa functionsPierre-Eric Pelloux-Prayer2019-11-192-0/+23
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_texture_buffer_range glTextureBufferRangeEXT functionPierre-Eric Pelloux-Prayer2019-11-192-0/+10
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_instanced_arrays EXT_dsa functionPierre-Eric Pelloux-Prayer2019-11-192-0/+7
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_gpu_shader_fp64 selector-less functionsPierre-Eric Pelloux-Prayer2019-11-191-0/+131
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_clear_buffer_object named functionsPierre-Eric Pelloux-Prayer2019-11-192-6/+7
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_vertex_attrib_64bit VertexArrayVertexAttribLOffsetEXTPierre-Eric Pelloux-Prayer2019-11-192-0/+11
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add ARB_framebuffer_no_attachments named functionsPierre-Eric Pelloux-Prayer2019-11-192-1/+15
| | | | | | | | | | | The wording in ARB_framebuffer_no_attachments and EXT_direct_state_access is different. In the former framebuffer names must have been generated using glGenFramebuffers before using the named functions. In the latter framebuffer names have no such constraints, so we can't use the _mesa_lookup_framebuffer_dsa function. Reviewed-by: Marek Olšák <[email protected]>
* meson: move the generic symbols check arguments to a common variableEric Engestrom2019-11-053-3/+3
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviwed-by: Dylan Baker <dylan@pnwbakers>
* meson: add variable to control the symbols checksEric Engestrom2019-11-053-3/+3
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviwed-by: Dylan Baker <dylan@pnwbakers>
* util: rename PIPE_ARCH_*_ENDIAN to UTIL_ARCH_*_ENDIANDylan Baker2019-11-051-1/+1
| | | | | | | | | | | As requested by Tim. This was generated with: grep 'PIPE_ARCH_.*_ENDIAN' -rIl | xargs sed -ie 's@PIPE_ARCH_\(.*\)_ENDIAN@UTIL_ARCH_\1_ENDIAN@'g v2: - add this patch Reviewed-by: Eric Engestrom <[email protected]>
* util/u_endian: set PIPE_ARCH_*_ENDIAN to 1Dylan Baker2019-11-051-1/+1
| | | | | | | | | | | | This will allow it to be used as a drop in replacement for _mesa_little_endian in a number of cases. v2: - Always define PIPE_ARCH_LITTLE_ENDIAN and PIPE_ARCH_BIG_ENDIAN, define the one that reflects the host system to 1 and the other to 0 - replace all uses of #ifdef, #ifndef, and #if defined() with #if and #if ! with PIPE_ARCH_*_ENDIAN Reviewed-by: Eric Engestrom <[email protected]>
* mesa: add EXT_dsa glGetVertexArray* 4 functionsPierre-Eric Pelloux-Prayer2019-11-052-0/+30
| | | | | | | | | | | | The implementation doesn't share much with get.c because: * the refactoring needed for get.c to not depend on ctx->Array.VAO would be quite large * glGetVertexArray* would still need to filter pname to only accept the one specified by the spec * these functions are getter, the implementation is trivial (the complexity is in the correct filtering of pname input) Reviewed-by: Marek Olšák <[email protected]>
* mesa: add EXT_dsa EnableVertexArrayAttribEXT / DisableVertexArrayAttribEXTPierre-Eric Pelloux-Prayer2019-11-052-0/+12
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add EXT_dsa glEnableVertexArrayEXT / glDisableVertexArrayEXTPierre-Eric Pelloux-Prayer2019-11-052-0/+12
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: add EXT_dsa glVertexArray* functions declarationsPierre-Eric Pelloux-Prayer2019-11-052-0/+109
| | | | Reviewed-by: Marek Olšák <[email protected]>
* mesa: enable ARB_gpu_shader_int64 in compat profileTapani Pälli2019-10-301-38/+37
| | | | | | Signed-off-by: Tapani Pälli <[email protected]> Acked-by: Marek Olšák <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* mapi: Improve the x86 tsd stubs performance.Lepton Wu2019-10-291-5/+6
| | | | | | | | This skips touching %ebx most times and it shows that glGetString performance increased from 114M/s to 120M/s on my desktop. Reviewed-by: Matt Turner <[email protected]> Signed-off-by: Lepton Wu <[email protected]>
* mapi: Inline call x86_current_tls.Lepton Wu2019-10-291-4/+8
| | | | | | | | | | This saves one return and a simple benchmark which calls glGetString repeatedly on my desktop shows it improves calls per second from 123M to 141M. Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/1997 Reviewed-by: Matt Turner <[email protected]> Signed-off-by: Lepton Wu <[email protected]>