diff options
author | Tapani Pälli <tapani.palli@intel.com> | 2019-03-04 14:22:36 +0200 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2019-03-12 15:10:02 -0700 |
commit | ef8a38e0e689809a88364c574a57893368062931 (patch) | |
tree | 705d4c934e63c18cddcfc1d037f7131139e5fcbe /src/egl | |
parent | 8d43691b269f94f88e469ff5eb15fa9e00be47c6 (diff) | |
download | mesa-ef8a38e0e689809a88364c574a57893368062931.tar.gz mesa-ef8a38e0e689809a88364c574a57893368062931.tar.bz2 mesa-ef8a38e0e689809a88364c574a57893368062931.zip |
anv: destroy descriptor sets when pool gets destroyed
Patch maintains a list of sets in the pool and destroys possible
remaining sets when pool is destroyed.
As stated in Vulkan spec:
"When a pool is destroyed, all descriptor sets allocated from
the pool are implicitly freed and become invalid."
This fixes memory leaks spotted with valgrind:
==19622== 96 bytes in 1 blocks are definitely lost in loss record 2 of 3
==19622== at 0x483880B: malloc (vg_replace_malloc.c:309)
==19622== by 0x495B67E: default_alloc_func (anv_device.c:547)
==19622== by 0x4955E05: vk_alloc (vk_alloc.h:36)
==19622== by 0x4956A8F: anv_multialloc_alloc (anv_private.h:538)
==19622== by 0x4956A8F: anv_CreateDescriptorSetLayout (anv_descriptor_set.c:217)
Fixes: 14f6275c92f1 ("anv/descriptor_set: add reference counting for descriptor set layouts")
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
(cherry picked from commit 105002bd2d6173b24f6955c22340b5bc77e029fa)
Conflicts resolved by Dylan and Jason
Diffstat (limited to 'src/egl')
0 files changed, 0 insertions, 0 deletions