commit | f75609e015cdb9eb1014b4d2e9cf9fd942bb7b20 | [log] [tgz] |
---|---|---|
author | Peter Collingbourne <peter@pcc.me.uk> | Thu Sep 29 03:29:28 2016 +0000 |
committer | Peter Collingbourne <peter@pcc.me.uk> | Thu Sep 29 03:29:28 2016 +0000 |
tree | 527aba1a44e470ae53a563b9f45ee1f33cec93b7 | |
parent | 20ac943748aec8f98694b7b024b206e8bd86b932 [diff] [blame] |
Add explanatory comment. llvm-svn: 282678
diff --git a/llvm/lib/LTO/LTOBackend.cpp b/llvm/lib/LTO/LTOBackend.cpp index 86ab8aa..c2fff4a 100644 --- a/llvm/lib/LTO/LTOBackend.cpp +++ b/llvm/lib/LTO/LTOBackend.cpp
@@ -253,6 +253,10 @@ std::move(BC), ThreadCount++); }, false); + + // Because the inner lambda (which runs in a worker thread) captures our local + // variables, we need to wait for the worker threads to terminate before we + // can leave the function scope. CodegenThreadPool.wait(); }