[PATCH] D63144: [coroutines] Add missing pass dependency.

Ben Clayton via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 11 09:21:36 PDT 2019


ben-clayton created this revision.
ben-clayton added a reviewer: GorNishanov.
Herald added subscribers: llvm-commits, modocache, EricWF.
Herald added a project: LLVM.

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.


Repository:
  rL LLVM

https://reviews.llvm.org/D63144

Files:
  lib/Transforms/Coroutines/CoroSplit.cpp


Index: lib/Transforms/Coroutines/CoroSplit.cpp
===================================================================
--- lib/Transforms/Coroutines/CoroSplit.cpp
+++ lib/Transforms/Coroutines/CoroSplit.cpp
@@ -946,7 +946,12 @@
 
 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)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63144.204084.patch
Type: text/x-patch
Size: 613 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190611/2dbab48e/attachment.bin>


More information about the llvm-commits mailing list