Skip to content

C Delitmus

Matt Windsor edited this page Mar 22, 2019 · 4 revisions

The c delitmus command converts C litmus tests into compilable C files.

Synopsis

$ act c delitmus [FLAGS] path/to/c/litmus/file.litmus

Details

act c delitmus tries to convert a C litmus test to a flat C file, ready for compilation. Similarly to the sanitiser for assembly files, the de-litmusifier makes some minor changes to the litmus test:

  • Thread-local variables are lifted to the global scope, and prefixed with tN, where N is the thread identifier;
  • Global variables are lifted from the init block to regular atomic_int declarations;
  • Thread function parameters carrying pointers to global variables are deleted;
  • Since the type of global variables has therefore changed from atomic_int* to atomic_int, references to them inside atomic actions are prefixed by &.
Clone this wiki locally