Skip to content
Snippets Groups Projects
Forked from Mesa / mesa
91394 commits behind, 153 commits ahead of the upstream repository.
user avatar
Sergii Romantsov authored
In case of any enabled VS members from: uses_firstvertex,
uses_baseinstance, uses_drawid, uses_is_indexed_draw
leaks may happens.
Call gen6_upload_push_constants allocates
stage_stat->push_const_bo. It than takes pointer from
push_const_bo to draw_params_bo (in the call
brw_prepare_shader_draw_parameters by brw_upload_data)
and do reference which finally haven't got unreferenced.

Fixes leak:
 136 bytes in 1 blocks are definitely lost in loss record 6 of 13
    at 0x4C31B25: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
    by 0xC2B64B7: bo_alloc_internal (brw_bufmgr.c:596)
    by 0xC2B6748: brw_bo_alloc (brw_bufmgr.c:672)
    by 0xC314BB3: brw_upload_space (intel_upload.c:88)
    by 0xC2EBBC5: gen6_upload_push_constants (gen6_constant_state.c:155)
    by 0xC9E4FA6: gen9_upload_vs_push_constants (genX_state_upload.c:3300)
    by 0xC2E0EDA: check_and_emit_atom (brw_state_upload.c:540)
    by 0xC2E0EDA: brw_upload_pipeline_state (brw_state_upload.c:659)
    by 0xC2E0FF1: brw_upload_render_state (brw_state_upload.c:681)
    by 0xC2C5D2D: brw_draw_single_prim (brw_draw.c:1052)
    by 0xC2C62CB: brw_draw_prims (brw_draw.c:1175)
    by 0xC488AD1: vbo_exec_vtx_flush (vbo_exec_draw.c:386)
    by 0xC485270: vbo_exec_FlushVertices_internal (vbo_exec_api.c:652)

Reviewed-by: default avatarLionel Landwerlin <lionel.g.landwerlin@intel.com>
Reported-by: default avatarYevhenii Kolesnikov <yevhenii.kolesnikov@globallogic.com>
Signed-off-by: default avatarSergii Romantsov <sergii.romantsov@globallogic.com>
(cherry picked from commit 1931c97a)
3e1c46f2
History

Mesa - The 3D Graphics Library

Source

This repository lives at https://gitlab.freedesktop.org/mesa/mesa. Other repositories are likely forks, and code found there is not supported.

Build & install

You can find more information in our documentation (docs/install.html), but the recommended way is to use Meson (docs/meson.html):

$ mkdir build
$ cd build
$ meson ..
$ sudo ninja install

Support

Many Mesa devs hang on IRC; if you're not sure which channel is appropriate, you should ask your question on Freenode's #dri-devel, someone will redirect you if necessary. Remember that not everyone is in the same timezone as you, so it might take a while before someone qualified sees your question. To figure out who you're talking to, or which nick to ping for your question, check out Who's Who on IRC.

The next best option is to ask your question in an email to the mailing lists: mesa-dev@lists.freedesktop.org

Bug reports

If you think something isn't working properly, please file a bug report (docs/bugs.html).

Contributing

Contributions are welcome, and step-by-step instructions can be found in our documentation (docs/submittingpatches.html).

Note that Mesa uses email mailing-lists for patches submission, review and discussions.