Skip to content

Repository files navigation

EnergyAwareLLVM

Installation

Note: This was tested on Ubuntu 20.04 and my Intel Mac

Create and activate conda environment:

conda create -y -n cse583 python=3.8
conda activate cse583

Fix some packages:

pip install setuptools==65.5.0 pip==21  # gym 0.21 installation is broken with more recent versions
pip install wheel==0.38.0

Install CompilerGym:

pip install -U compiler_gym

Install Other Requirements

pip install -r requirements.txt

Reinforcement Learning

run the training code here:

cd ppo/
python3 train.py

At the moment, the code uses the Autophase observation space. Base code was adapted from nikhilbarhate99 and ymahlau

Static Energy Estimation

Our implementation was heavily based on Neville Grech's Code adapted to use llvmlite.

cd llvm-energy
python3 inferCR_converted.py ir_tests/test1.ll

Usage

Run the testing script:

python3 random_actions.py

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages