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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
|
# testchill
## Description
TODO: better description
testchill is a Python module that runs a series of tests to aid in the development and maintence of CHiLL.
testchill tests that chill compiles successfully, that scripts can be run without error, and that they generate compilable code.
It can also optionally test optimized code for correctness and provide code coverage.
## Running testchill
testchill is a Python module, and can be run like any other Python module:
`python -m testchill <suite-args>* <sub-command> <sub-command-args>*`
The most basic subcommand that runs the testsuite is [`local`](#-local-chill-home-). `local` runs a set of tests
on the parent chill source directory.
`python -m testchill [-O <path-to-omega>] local [-C <path-to-chill>]` If the environment variable $OMEGAHOME is set, the `-O` argument can be ommited.
### Arguments common to all sub commands (with the exception of `local`):
- `-w <working-directory>, --working-dir <working-directory>`
Sets the working directory where testchill will compile and run test scripts. If not set, the current working directory will be used.
- `-R <rose-home>, --rose-home <rose-home>`
Set ROSEHOME environment variable for building omega. If not set, the current ROSEHOME environment variable will be used.
- `-C <chill directory>, --chill-home <chill-home>`
Set the path to chill. If not set, the current CHILLHOME environment variable will be used.
- `-O <omega directory>, --omega-home <omega-home>`
Set the path to omega. If not set, the current OMEGAHOME environment variable will be used.
- `-b <binary directory>, --binary-dir <binary directory>`
Set the directory were all chill binary files will be placed after being compiled. The chill directory will be used by default.
### Subcommands for running individual tests:
- <h4> `build-chill-testcase ...`
Build chill. It will fail if the build process returns non zero.
Optional arguments:
- `-v {release | dev}` or `--chill-branch {release | dev}`
`release` will build the old release version, and `dev` will build the current development version.
`dev` is used by default.
- `-u | -c` or `--target-cuda | --target-c`
`-c` will build chill, and `-u` will build cuda-chill.
`-c` is used by default.
- `-i {script | lua | python}` or `--interface-lang {script | lua | python}`
Set the interface language chill will be build for.
`script` will build chill with the original chill script language.
`lua` will build chill with lua as the interface language.
`python` will build chill with python as the interface language.
By default, `script` is used for chill and `lua` is used for cuda-chill.
- `--build-coverage | --no-build-coverage`
`--build-coverage` will build chill to work with gcov.
`--no-build-coverage` will build chill normally.
It is on by default.
- <h4> `chill-testcase <chill-script> <chill-src> ...`
Run a chill test script.
Arguments:
- `chill-script`
Path to the script file.
- `chill-src`
Path to the source file.
Optional arguments:
- `-v {release | dev}` or `--chill-branch {release | dev}`
`release` will run scripts as the old release version, and `dev` will run them as the current development version.
`dev` is used by default.
- `-u | -c` or `--target-cuda | --target-c`
`-c` will run chill, and `-u` will run cuda-chill.
`-c` is used by default.
- `-i {script | lua | python}` or `--interface-lang {script | lua | python}`
Set the interface language chill will be run with.
`script` will run chill with the original chill script language.
`lua` will run chill with lua as the interface language.
`python` will run chill with python as the interface language.
By default, `script` is used for chill and `lua` is used for cuda-chill.
- `--compile-src | --no-compile-src`
Turns source compilation test on or off. If on, the source file will be compiled prior to transormation.
On by default.
- `--run-script | --no-run-script`
If on, the script file will be run.
On by default.
- `--compile-gensrc | --no-compile-gensrc`
If on, the generated source file will be compiled.
On by default.
- `--check-run-script | --no-check-run-script`
If on, the generated object file will be run. If there are any validation tests, each one will be compiled and run.
On by default.
- `--test-coverage | --no-test-coverage`
If on, coverage data will be compiled during the run-script test.
On by default.
- <h4> `batch <batch-file>`
Run a test case list (*.tclist) file. Each line constists of a subcommand to be passed to testchill (including additional `batch` commands).
Arguments:
- `<batch-file>`
Path to a test case list file.
- <h4> `local <chill-home> ...`
Compile and test a local chill source directory.
Arguments:
- `<chill-home>`
Path to chill.
Optional arguments:
- `-v {release | dev}` or `--chill-branch {release | dev}`
`release` will run scripts as the old release version, and `dev` will run them as the current development version.
`dev` is used by default.
|