Open anszom opened 7 months ago
Hello, please note that I haven't checked yet as objC is entirely foreign to me, but could this be related to #7393 and #6528 ?
My experience with osx is quite limited, but I think these issues are not directly related.
Version/Branch of Dear ImGui:
git commit 9a5da23, but the code is the same on master
Back-ends:
imgui_impl_metal.cpp + custom platform backend
Compiler, OS:
macOS + Clang 14
Full config/build information:
No response
Details:
My Issue/Question:
I'm using multiple ImGui contexts within a single application, with a thread_local GImGui pointer, as described in imgui.cpp:
I'm observing a significant memory leak with the Metal backend. I've traced it down to the buffers allocated in
dequeueReusableBufferOfLength:device:
. The asynchronous callback responsible for releasing the buffers is running on a thread without any ImGui context active, therefore the buffers are never released.I suggest the following changes to fix the problem.
Screenshots/Video:
No response
Minimal, Complete and Verifiable Example code:
No response