- Setup main arachne infrastructure.
This commit is contained in:
parent
0008b58739
commit
9cf3bf3da3
16
src/arachne.c
Normal file
16
src/arachne.c
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
/**
|
||||||
|
*@file arachne.c
|
||||||
|
*
|
||||||
|
* Introduces a method for proofs akin to the Athena modelchecker
|
||||||
|
* http://www.ece.cmu.edu/~dawnsong/athena/
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "system.h"
|
||||||
|
#include "arachne.h"
|
||||||
|
|
||||||
|
//! Main recursive procedure for Arachne
|
||||||
|
int
|
||||||
|
arachne (const System sys)
|
||||||
|
{
|
||||||
|
}
|
8
src/arachne.h
Normal file
8
src/arachne.h
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
#ifndef ARACHNE
|
||||||
|
#define ARACHNE
|
||||||
|
|
||||||
|
#include "system.h"
|
||||||
|
|
||||||
|
int arachne (const System sys);
|
||||||
|
|
||||||
|
#endif
|
21
src/main.c
21
src/main.c
@ -87,6 +87,8 @@ main (int argc, char **argv)
|
|||||||
arg_file0 (NULL, NULL, "FILE", "input file ('-' for stdin)");
|
arg_file0 (NULL, NULL, "FILE", "input file ('-' for stdin)");
|
||||||
struct arg_file *outfile = arg_file0 ("o", "output", "FILE",
|
struct arg_file *outfile = arg_file0 ("o", "output", "FILE",
|
||||||
"output file (default is stdout)");
|
"output file (default is stdout)");
|
||||||
|
struct arg_lit *switch_arachne =
|
||||||
|
arg_lit0 ("a", "arachne", "use Arachne engine");
|
||||||
struct arg_str *switch_check = arg_str0 (NULL, "check", "CLAIM",
|
struct arg_str *switch_check = arg_str0 (NULL, "check", "CLAIM",
|
||||||
"claim type to check (default is all)");
|
"claim type to check (default is all)");
|
||||||
struct arg_int *switch_scenario = arg_int0 ("s", "scenario", NULL,
|
struct arg_int *switch_scenario = arg_int0 ("s", "scenario", NULL,
|
||||||
@ -166,6 +168,7 @@ main (int argc, char **argv)
|
|||||||
switch_echo,
|
switch_echo,
|
||||||
switch_progress_bar,
|
switch_progress_bar,
|
||||||
|
|
||||||
|
switch_arachne,
|
||||||
switch_check,
|
switch_check,
|
||||||
switch_traversal_method,
|
switch_traversal_method,
|
||||||
switch_match_method,
|
switch_match_method,
|
||||||
@ -333,8 +336,10 @@ main (int argc, char **argv)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
sys = systemInit ();
|
sys = systemInit ();
|
||||||
/* select default engine */
|
if (switch_arachne->count > 0)
|
||||||
sys->engine = POR_ENGINE;
|
{
|
||||||
|
sys->engine = ARACHNE_ENGINE;
|
||||||
|
}
|
||||||
/* init compiler for this system */
|
/* init compiler for this system */
|
||||||
compilerInit (sys);
|
compilerInit (sys);
|
||||||
|
|
||||||
@ -892,7 +897,17 @@ modelCheck (const System sys)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* modelcheck the system */
|
/* modelcheck the system */
|
||||||
traverse (sys);
|
switch (sys->engine)
|
||||||
|
{
|
||||||
|
case POR_ENGINE:
|
||||||
|
traverse (sys);
|
||||||
|
break;
|
||||||
|
case ARACHNE_ENGINE:
|
||||||
|
arachne (sys);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
error ("Unknown engine type %i.", sys->engine);
|
||||||
|
}
|
||||||
|
|
||||||
/* clean up any states display */
|
/* clean up any states display */
|
||||||
if (sys->switchS > 0)
|
if (sys->switchS > 0)
|
||||||
|
@ -54,6 +54,7 @@ systemInit ()
|
|||||||
sys->attack = tracebufInit ();
|
sys->attack = tracebufInit ();
|
||||||
|
|
||||||
/* switches */
|
/* switches */
|
||||||
|
sys->engine = POR_ENGINE; // default is partial ordering engine
|
||||||
sys->output = ATTACK; // default is to show the attacks
|
sys->output = ATTACK; // default is to show the attacks
|
||||||
sys->porparam = 0; // multi-purpose parameter
|
sys->porparam = 0; // multi-purpose parameter
|
||||||
sys->latex = 0; // latex output?
|
sys->latex = 0; // latex output?
|
||||||
|
Loading…
Reference in New Issue
Block a user