[cfe-dev] Question on LiveVariables analysis

Georg Altmann george at george-net.de
Tue Feb 17 02:59:36 PST 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 11.10.2011 05:56, Anna Zaks wrote:
> Most likely there is some issue with the way you build the analysis
> in your code; you should probably look at other uses of 
> UninitializedVariables to see what you are missing. Also, try to
> find out at which step the first symptoms of the problem occur -
> for example, do you get a CFG different from what you see when
> dumping the CFG with a debug checker? (See the command from Ted's
> reply below.)
> 
> I noticed that you do not pass CFGBuildOptions when constructing 
> the AnalysisContext. Here is some code from
> AnalysisBasedWarnings.cpp, which implies that you might need to
> request linearized CFG. // Unreachable code analysis requires a
> linearized CFG. AC.getCFGBuildOptions().setAllAlwaysAdd();

Thank you! That just made my day!

Can anybody elaborate or give a pointer on what is meant by
a linearized CFG in this case?
I found this paper [1] which contains some info on CFG linearization.

Which algorithm is implemented for LiveVariables and CFG linearization
in clang static analyzer? Any pointers?

Regards,
Georg


[1]
paper: http://compilers.cs.uni-saarland.de/papers/karrenberg_opencl.pdf
DOI paper: http://dx.doi.org/10.1007/978-3-642-28652-0_1
slides: http://llvm.org/devmtg/2012-04-12/Slides/Ralf_Karrenberg.pdf

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJU4x8RAAoJELvxnEIeMg5lV8IH/1jbAMQGWDdMbqLe9tIpU4/A
2dqQu0Qxs0gKEZOvkQoMGHJNmzcjWKjkF35Yuc6ufbUqjbmmBTJUUybHsI7cxfu2
t471vOFtIcxTD+r4IKG5S7M8j63SbIAKwnPWSDI6T98UUGACEAli602hYziLy3+u
M525f8/nE2KR86G8Kp5vELL9Or6kXNfK023+zymdmL7X/BbanwRfvDPZ6N+c972i
tlay5h0ywZTL9t6liuivMuDfwQiwSpOojSrjpejHXdn/M7wA6CcM757IP4tya7yx
Fykf41SkJrFn2uFho0858gczLQWF4Pksa9Rmkd4l33m+wOtlsgmEkS12UAAN1HY=
=8/Yr
-----END PGP SIGNATURE-----




More information about the cfe-dev mailing list