Welcome to the setup guide for the Gametime project! This document provides instructions for setting up and running the Gametime project on both Linux and macOS. Follow the steps below to install the required dependencies and configure your environment for development and testing.
Begin by cloning the Gametime repository from GitHub and initializing the submodules:
git clone https://github.com/icyphy/gametime.git
cd gametime
git submodule update --init --recursive
Gametime requires LLVM and Clang version 16. The installation instructions differ slightly between Linux and macOS:
Update your package manager and install LLVM and Clang version 13:
sudo apt update
sudo apt install clang-16 llvm-16
Ensure that version 13 is used by setting it as the default:
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 100
sudo update-alternatives --install /usr/bin/llvm-config llvm-config /usr/bin/llvm-config-16 100
First, ensure that Homebrew is installed, then install LLVM version 16 using the following commands:
brew install llvm@16
After installation, update your PATH
to include LLVM version 13:
export PATH="/usr/local/opt/llvm@16/bin:$PATH"
Install additional system libraries:
sudo apt-get install graphviz libgraphviz-dev
Install the additional libraries via Homebrew:
brew install graphviz
Install the required Python packages and additional system libraries:
pip install -e .
pip install -r requirements.txt
If you are having trouble installing pygraphviz on macOS try the following: StackOverflow
To use KLEE with Gametime, follow the installation instructions on the KLEE official website.
Once the setup is complete, you can run tests within the Gametime environment. Follow these steps to configure and execute your tests:
Each test requires a YAML configuration file. Ensure that your YAML file is correctly set up with all the necessary test configurations.
Navigate to the wcet_test.py
file and create a new test class based on one of the available backend configurations. Specify the path to your YAML configuration file in the config_path
attribute.
class TestBinarysearchARM(TestARMBackend):
config_path = "./programs/binarysearch/config.yaml"
In the main
function of wcet_test.py
, add your newly created test class to the suite for execution.
suite.addTests(loader.loadTestsFromTestCase(TestBinarysearchARM))
Run the test using the following command:
python wcet_test.py
This project is licensed under the terms of the MIT License.
If you have any questions or encounter any issues, please open an issue on the GitHub repository or reach out to the project maintainers.
By following these instructions, you should be able to get Gametime up and running on your machine. Happy coding!