Hi all,<br><br>I am using llvm to perform some static analysis with a module pass. In getAnalysisUsage(), I specified some required passes by:<br><br>addRequiredTransitive<LoopInfo>();<br clear="all"><br>When I run my pass using opt, it crashes with segmentation fault with callstack:<br>
<br><div style>#0  0x0877aebd in llvm::PMTopLevelManager::findAnalysisUsage (this=0x8c10934, P=0xb15b988) at PassManager.cpp:573</div><div style>#1  0x0877aa9b in llvm::PMTopLevelManager::setLastUser (this=0x8c10934, AnalysisPasses=..., P=0xb121c18) at PassManager.cpp:512</div>
<div style>#2  0x0877ee0f in llvm::MPPassManager::addLowerLevelRequiredPass (this=0x8c102d8, P=0xb121c18, RequiredPass=0xb15b988) at PassManager.cpp:162\</div><div style>5</div><div style>#3  0x0877ca44 in llvm::PMDataManager::add (this=0x8c102e8, P=0xb121c18, ProcessAnalysis=true) at PassManager.cpp:1014</div>
<div style>#4  0x0877f549 in llvm::ModulePass::assignPassManager (this=0xb121c18, PMS=..., PreferredType=llvm::PMT_ModulePassManager) at PassManager.cpp\</div><div style>:1782</div><div style>#5  0x0877b339 in llvm::PMTopLevelManager::schedulePass (this=0x99ce80c, P=0xb121c18) at PassManager.cpp:655</div>
<div style>#6  0x08780ab6 in llvm::PassManagerImpl::add (this=0x99ce738, P=0xb121c18) at PassManager.cpp:387</div><div style>#7  0x0877f0bf in llvm::PassManager::add (this=0xbfffefc8, P=0xb121c18) at PassManager.cpp:1680</div>
<div style>#8  0x082c6ad7 in addPass (PM=..., P=0xb121c18) at opt.cpp:397</div><div style>#9  0x082c79c1 in main (argc=5, argv=0xbffff0f4) at opt.cpp:636</div><br><br>I am using the llvm just checked out from svn. It is configured with Debug and Asserts enabled. I tried to use setPrevervesAll() and the seg fault still exists. I also tried to require other passes such as DominatorTree and it also crashes.<br>
<br>I found a similar bug at <a href="http://llvm.org/bugs/show_bug.cgi?id=9550">http://llvm.org/bugs/show_bug.cgi?id=9550</a>. However since I just checked out from svn, I believe the patch is already there.<br><br>Could any one help on this issue? Any instructions or walk around is greatly appreciated.<br>
<br>Thanks very much.<br><br>-- <br>Best regards<br>JiaQi Zhang<br>