[llvm] r363727 - [coroutines] Add missing pass dependency.

Gor Nishanov via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 18 12:49:48 PDT 2019


Author: gornishanov
Date: Tue Jun 18 12:49:48 2019
New Revision: 363727

URL: http://llvm.org/viewvc/llvm-project?rev=363727&view=rev
Log:
[coroutines] Add missing pass dependency.

Summary:
CoroSplit depends on CallGraphWrapperPass, but it was not explicitly adding it as a pass dependency.

This missing dependency can trigger errors / assertions / crashes in PMTopLevelManager::schedulePass() under certain configurations.

Author: ben-clayton

Reviewers: GorNishanov

Reviewed By: GorNishanov

Subscribers: capn, EricWF, modocache, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D63144

Modified:
    llvm/trunk/lib/Transforms/Coroutines/CoroSplit.cpp

Modified: llvm/trunk/lib/Transforms/Coroutines/CoroSplit.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Coroutines/CoroSplit.cpp?rev=363727&r1=363726&r2=363727&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Coroutines/CoroSplit.cpp (original)
+++ llvm/trunk/lib/Transforms/Coroutines/CoroSplit.cpp Tue Jun 18 12:49:48 2019
@@ -946,7 +946,12 @@ struct CoroSplit : public CallGraphSCCPa
 
 char CoroSplit::ID = 0;
 
-INITIALIZE_PASS(
+INITIALIZE_PASS_BEGIN(
+    CoroSplit, "coro-split",
+    "Split coroutine into a set of functions driving its state machine", false,
+    false)
+INITIALIZE_PASS_DEPENDENCY(CallGraphWrapperPass)
+INITIALIZE_PASS_END(
     CoroSplit, "coro-split",
     "Split coroutine into a set of functions driving its state machine", false,
     false)




More information about the llvm-commits mailing list