[PATCH] D83372: Fix for memory leak reported by Valgrind
Antonio Maiorano via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 1 07:47:47 PST 2021
amaiorano added a comment.
Coming back to this, in SwiftShader, I've landed this patch plus the removal of the lock on getManagedStaticMutex from within llvm::llvm_shutdown. I think this is the best approach: document that llvm_shutdown is to be called from a single thread, along with this patch (the last version, with `static std::recursive_mutex m;` in getManagedStaticMutex. This allows for code that uses llvm::llvm_shutdown_obj to work properly, without worrying about order of destruction, and it plugs the memory leak.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D83372/new/
https://reviews.llvm.org/D83372
More information about the llvm-commits
mailing list