blob: 5b5c45ef45c2a637ae53f336259fda53b215f8ff (
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
//===-- KTest.h --------------------------------------------------*- C++ -*-===//
//
// The KLEE Symbolic Virtual Machine
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#ifndef KLEE_KTEST_H
#define KLEE_KTEST_H
#ifdef __cplusplus
extern "C" {
#endif
typedef struct KTestObject KTestObject;
struct KTestObject {
char *name;
unsigned numBytes;
unsigned char *bytes;
};
typedef struct KTest KTest;
struct KTest {
/* file format version */
unsigned version;
unsigned numArgs;
char **args;
unsigned symArgvs;
unsigned symArgvLen;
unsigned numObjects;
KTestObject *objects;
};
/* returns the current .ktest file format version */
unsigned kTest_getCurrentVersion();
/* return true iff file at path matches KTest header */
int kTest_isKTestFile(const char *path);
/* returns NULL on (unspecified) error */
KTest* kTest_fromFile(const char *path);
/* returns 1 on success, 0 on (unspecified) error */
int kTest_toFile(KTest *, const char *path);
/* returns total number of object bytes */
unsigned kTest_numBytes(KTest *);
void kTest_free(KTest *);
#ifdef __cplusplus
}
#endif
#endif /* KLEE_KTEST_H */
|