简体   繁体   中英

Slicing with Frama-c

I installed frama-c with opam on my MacOs. I need to slice Hello World by manually. I mean not with Gui. I searched on the internet but I could not understand how do it. My english is not well enough. So can somebody help me to slice HelloWorld.c ?

To launch Frama-C's slicing from the command-line, you must have a C file that parses, and a slicing criterion (return code, accesses to a global variable, statement, etc). The various available criterion are described at http://frama-c.com/slicing.html .

Furthermore, if you want to slice eg on a statement, you will have to use slicing pragmas , with the following syntax:

/*@ slice pragma stmt; */
    Preserves the effects of the next statement. 
/*@ slice pragma expr e; */
    Preserves the value of the ACSL expression e at this control-flow point.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM