forked from OSchip/llvm-project
8831eb7db4
After we moved isl_ctx into Scop, we need to free the isl_ctx after freeing all isl objects, which requires the ScopInfo pass to be freed at last. But this is not guaranteed by the PassManager, and we need extra code to free the isl_ctx at the right time. We introduced a shared pointer to manage the isl_ctx, and distribute it to all analyses that create isl objects. As such, whenever we free an analyses with the shared_ptr (and also free the isl objects which are created by the analyses), we decrease the (shared) reference counter of the shared_ptr by 1. Whenever the reference counter reach 0 in the releaseMemory function of an analysis, that analysis will be the last one that hold any isl objects, and we can safely free the isl_ctx with that analysis. Differential Revision: http://reviews.llvm.org/D17241 llvm-svn: 261100 |
||
---|---|---|
.. | ||
BlockGenerators.cpp | ||
CodeGeneration.cpp | ||
CodegenCleanup.cpp | ||
IRBuilder.cpp | ||
IslAst.cpp | ||
IslExprBuilder.cpp | ||
IslNodeBuilder.cpp | ||
LoopGenerators.cpp | ||
RuntimeDebugBuilder.cpp | ||
Utils.cpp |