Ptanal polishing #13

Open
wants to merge 2 commits into
from

Conversation

Projects
None yet
2 participants

cspiel commented Jul 5, 2014

@kerneis: as promised - documentation updates

cspiel added some commits Jul 5, 2014

Fix incomplete documentation with respect to Ptranal.
To use the Points-to-analysis module (Ptranal) it is not only
necessary to call Ptranal.analyze_file as stated in the documentation,
but to run Ptranal.compute_results afterwards and in particular before
any call to the "database query" functions of the module.

This fixes the initial problem as reported in issue #141 ("Bug in
pointer analysis or documentation")
    http://sourceforge.net/p/cil/bugs/141/
Contributor

kerneis commented Jul 5, 2014

Thanks @cspiel. This is a good starting point. I'll tweak your patches and merge them. Comments:

(There is currently no facility for clearing internal state, so \t{Ptranal.analyze_file} should only be called once.)

As a matter of fact, the ptanal-fixes branches has added such a functionality. I will amend the doc accordingly.

Ptranal.olf_backend

This option should not be documented (and it is, in fact, not exposed), because it does not switch the backend. More precisely, for ugly technical reasons related to typing, the choice of backend must be done when the module is loaded: the only available information at that point is the command-line, which is parsed, setting this reference, and then making tricks with first class modules to load the right one. Changing the reference later does not affect which module is used.

cspiel commented Jul 5, 2014

@kerneis, I did not know that the "multi-entry" feature of Ptranal
was ready for prime time. Nice to learn!

So, please kick out my scribbling about Ptranal.olf_backend
and instead add Ptranal.initialize.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment