diff options
author | Lang Hames <lhames@gmail.com> | 2017-08-31 01:09:56 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2017-08-31 01:09:56 +0000 |
commit | 1aad27e17bc40273849802240439f6e7d49ac81d (patch) | |
tree | 54e8993d588f531988dbd445acec4ee5d216565c /llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h | |
parent | 415f15c5e206127c57fe7996014569dae0f1419f (diff) | |
download | bcm5719-llvm-1aad27e17bc40273849802240439f6e7d49ac81d.tar.gz bcm5719-llvm-1aad27e17bc40273849802240439f6e7d49ac81d.zip |
[Orc] Add a comment about member variable dependencies to OrcMCJITReplacement.
The comment explains the reason behind the change in member variable order in
r312086.
Thanks to Philip Reames for the suggestion.
llvm-svn: 312205
Diffstat (limited to 'llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h')
-rw-r--r-- | llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h b/llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h index 743d5e2307c..cb48d6cb230 100644 --- a/llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h +++ b/llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h @@ -381,6 +381,9 @@ private: std::shared_ptr<JITSymbolResolver> ClientResolver; Mangler Mang; + // IMPORTANT: ShouldDelete *must* come before LocalModules: The shared_ptr + // delete blocks in LocalModules refer to the ShouldDelete map, so + // LocalModules needs to be destructed before ShouldDelete. std::map<Module*, bool> ShouldDelete; std::vector<std::shared_ptr<Module>> LocalModules; |