SUPA
SUPA copied to clipboard
SUPA/SVF fails to resolve pointer-to-member function pointer
The issue is most probably from SVF project, but still, I have found it from SUPA, I am reporting it here.
If there is an indirect call to a class member function using pointer-to-member function pointer, the analysis fails to resolve it.
class A {
public:
int f();
int (A::*x)();
};
int A::f() { return 1; }
void ctx() {
A a;
a.x = &A::f;
(a.*(a.x))();
}
The result it shows:
##<> Source Loc:
Ptr 4295 PointsTo: {empty}
with
/llvm-svf-src/Release-build/bin/dvf -cxt -query=funptr -maxcxt=5 -flowbg=10000 -cxtbg=10000 -cpts -print-query-pts sample.bc
It is expected to have _ZN1A1fEv
as points-to.