blob: 934f0702b44575e83b07c28d88dd41a8a0ff650f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
#include "SMTParser.h"
#include "klee/ExprBuilder.h"
#include <iostream>
using namespace std;
using namespace klee;
int main(int argc, char** argv) {
if (argc != 2) {
cout << "Usage: " << argv[0] << " <smt-filename>\n";
return 1;
}
enum BuilderKinds {
DefaultBuilder,
ConstantFoldingBuilder,
SimplifyingBuilder
} BuilderKind = SimplifyingBuilder;
ExprBuilder *Builder = 0;
switch (BuilderKind) {
case DefaultBuilder:
Builder = createDefaultExprBuilder();
break;
case ConstantFoldingBuilder:
Builder = createDefaultExprBuilder();
Builder = createConstantFoldingExprBuilder(Builder);
break;
case SimplifyingBuilder:
Builder = createDefaultExprBuilder();
Builder = createConstantFoldingExprBuilder(Builder);
Builder = createSimplifyingExprBuilder(Builder);
break;
}
klee::expr::SMTParser smtParser(argv[1], Builder);
smtParser.Init();
cout << smtParser.query << "\n";
}
|