SVF
SVF copied to clipboard
Unable to construct SVFG
I'm getting an assertion fail when constructing a VFG, with the message: wpa: /home/martin/SVF/include/Graphs/VFG.h:407: SVF::NodeID SVF::VFG::getDef(const SVF::PAGNode*) const: Assertion `it!=PAGNodeToDefMap.end() && "PAG node does not have a definition??"' failed.
I there anything I'm doing wrong?
Can you also send us your bc code that triggered the assertion?
Thank you for the prompt response. Here I attach the zipped mpktest-bfec73d5f75514f6..zip files: I ran them with the -fspta option. One file doesn't construct the SVFG at all, the other gives the aforementioned error. It's also possible I am giving the wrong args?
mpktest-bfec73d5f75514f6.2y7dp8eo2oaxkxr7.rcgu.bc
works fine at myside for -fspta
no assertion.
mpktest-bfec73d5f75514f6.1dnfl7w3u9olhqeo.rcgu.bc
triggered an assertion but not yours.
* frame #0: 0x000000010066e707 wpa`(anonymous namespace)::TypePrinting::print(llvm::Type*, llvm::raw_ostream&) + 23
frame #1: 0x000000010066e5f9 wpa`llvm::Type::print(llvm::raw_ostream&, bool, bool) const + 121
frame #2: 0x0000000100691e00 wpa`llvm::Attribute::getAsString(bool) const + 3408
frame #3: 0x00000001007fd091 wpa`(anonymous namespace)::Verifier::verifyAttributeTypes(llvm::AttributeSet, bool, llvm::Value const*) + 241
frame #4: 0x00000001007f839b wpa`(anonymous namespace)::Verifier::verifyFunctionAttrs(llvm::FunctionType*, llvm::AttributeList, llvm::Value const*, bool) + 1787
frame #5: 0x00000001007f67ff wpa`(anonymous namespace)::Verifier::visitFunction(llvm::Function const&) + 703
frame #6: 0x00000001007f0ac0 wpa`(anonymous namespace)::Verifier::verify(llvm::Function const&) + 160
frame #7: 0x00000001007f2623 wpa`llvm::verifyModule(llvm::Module const&, llvm::raw_ostream*, bool*) + 115
frame #8: 0x00000001006b1c80 wpa`llvm::UpgradeDebugInfo(llvm::Module&) + 48
frame #9: 0x0000000100bdb801 wpa`(anonymous namespace)::BitcodeReader::materializeModule() + 1233
The above seems that you did not generate the bc correctly. It is not an error in SVF.