Open ZH-Lee opened 3 years ago
Are you refactoring MTA code? May I know which option you are using and where is the repo?
Are you refactoring MTA code? May I know which option you are using and where is the repo?
Yes, i am refactoring MTA. Most of part have done. What i really want is lock analysis, so i am refactoring only MTA.cpp, MHP.cpp, TCT.cpp and LockAnalysis.cpp . For other part, i will refactor it in the futher.
For now, i get some unexpected result for lock analysis, such as considering multiple module, its lock infomation flow seems to be incomplete. I am tring to fix it. Can i resolve it by adding others file such as FSMPTA.cpp/~.h ?
Besides, when i analyze a project composed of two cpp file, i got an assert failed in addObjNode function, the reason is that llvm will create a intrinsic global variable for std::ios or else. For these two cpp file, there exit two same node except that the name of module. And in SVF, it will create a glbRep for these two node. For the first one ObjNode, it will create a MemObj successfully, but for the second node, it trigger an assert fail due to there exits a same node in PAG.h (line 804).
And i fix it by replacing a if statement with the assert. @ yuleisui
I am unsure why you would like to add other files? Where is your refactored codebase?
I am unsure why you would like to add other files? Where is your refactored codebase?
because i delete some unnecessary file in MTA. In main repo, there are 9 files, but for me, I don't need such more files. The code has not been refactored yet, so i have not upload the code. Can i contact you in other way?
Dear developers:
I got an error when running, but build correctly.
mta: /home/lee/SVF-master/llvm-12.0.0.obj/include/llvm/PassAnalysisSupport.h:221: AnalysisType& llvm::Pass::getAnalysis() const [with AnalysisType = llvm::ScalarEvolutionWrapperPass]: Assertion
Resolver && "Pass has not been inserted into a PassManager object!"' failed.Program received signal SIGABRT, Aborted. __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51 51 ../sysdeps/unix/sysv/linux/raise.c: No such file or directory. (gdb) bt
0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
1 0x00007ffff6c9a921 in __GI_abort () at abort.c:79
2 0x00007ffff6c8a48a in __assert_fail_base (fmt=0x7ffff6e11750 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n",
3 0x00007ffff6c8a502 in __GI___assert_fail (assertion=0x555555d37730 "Resolver && \"Pass has not been inserted into a PassManager object!\"",
4 0x00005555555ee014 in llvm::Pass::getAnalysis (this=0x555556243ad0)
5 0x00005555555ec052 in SVF::MTA::getSE (F=0x55555623abc8) at /home/lee/SVF-master/include/MTA/MTA.h:83
6 0x0000555555765af4 in SVF::ForkJoinAnalysis::collectSCEVInfo (this=0x55555627b210) at /home/lee/SVF-master/lib/MTA/MHP.cpp:736
7 0x000055555576a167 in SVF::ForkJoinAnalysis::ForkJoinAnalysis (this=0x55555627b210, t=0x5555562793a0) at /home/lee/SVF-master/include/MTA/MHP.h:283
8 0x0000555555762292 in SVF::MHP::MHP (this=0x55555627b0a0, t=0x5555562793a0) at /home/lee/SVF-master/lib/MTA/MHP.cpp:82
9 0x00005555555ce8a6 in SVF::MTA::computeMHP (this=0x555556243ad0, module=0x5555562322d0) at /home/lee/SVF-master/lib/MTA/MTA.cpp:132
10 0x00005555555ce7a8 in SVF::MTA::runOnModule (this=0x555556243ad0, module=0x5555562322d0) at /home/lee/SVF-master/lib/MTA/MTA.cpp:63
11 0x00005555555cc153 in main (argc=3, argv=0x7fffffffe218) at /home/lee/SVF-master/tools/MTA/mta.cpp:25 `
I tried to comment the code which associated with SCEV pass, and it works well. However, the result of thread interleaving is incorrect.
Could you help with this?
regards