-
Notifications
You must be signed in to change notification settings - Fork 1
Configuration
act
needs some configuration to work properly. It looks for a config file called act.conf
in the current working directory (or, if you provide -config FILENAME
, that path instead). This page describes that file.
Note: each act
subcommand also takes various command-line arguments; see each subcommand's documentation, and the standard flags, for details.
act
's source distribution contains a documented example file at bin/act.conf.example
.
- The configuration file consists of multiple items, each of which is either a line of configuration or a brace-delimited, named block.
- Each configuration line consists of a run of multiple keywords and arguments (the exact syntax depends on the line, but usually starts with one or more keywords). Arguments, at time of writing, can be identifiers (dot-separated, mostly-alphanumeric unquoted strings) or string literals (double-quoted).
-
#
is the comment character, and discards up to the end of the line. - Lines containing only whitespace/comments are ignored.
The machine ID { ... }
block tells act
about a machine on which it can run compilers.
See machine configuration for more details.
machine example {
enabled off
via ssh {
host "example.com"
user "johndoe"
copy to "/home/johndoe/actscratch"
}
litmus {
enabled on
cmd "/usr/local/bin/litmus7"
}
}
The compiler ID { ... }
block tells act
about a compiler it can use. act
uses compiler
blocks both for running compiler tests, and also to compile single files in other modes.
See compiler configuration for more details.
compiler gcc.x86 {
enabled on
style gcc
emits x86.att
cmd "gcc"
argv "-m32" "-DNO_PTHREADS"
herd on
machine default
}
The fuzz { ... }
block permits overriding act
's fuzzer action weightings.
See fuzzer configuration for more details.
fuzz {
action program.make.empty weight 0
store.make.int.single weight 1
var.make.global weight 2
}
The cpp { ... }
block tells act
how to run the C preprocessor. act
uses the C preprocessor whenever it needs to read a (non-Litmus) C program.
cpp {
enabled on
cmd "cpp"
argv "-DNO_PTHREADS" "-P" # suppress line directives and memalloy pthread harnesses
}
The herd { ... }
block tells herd
how to run the Herd memory model simulator. act
uses Herd in test mode to compare C program state sets with their compiled assembly equivalents.
herd {
cmd "herd7"
c_model "c11_lahav.cat"
asm_model x86.att "x86_example.cat"
asm_model x86.intel "x86_example.cat"
}
See machine configuration: since litmus
checks behaviours by running programs, we associate its configuration with the machine on which the programs should be run.